Identity
The identity behind this credential: what it is, the organization it is scoped to, and the scopes it currently holds.
user is present for an OAuth token and ABSENT for an API key, which
has an organization but no person behind it. credential.kind says
which you are holding, so a client can branch without guessing from a
missing field.
Narrower than what the console shows its own user on purpose: an
integration needs a name to display and an organization to address, not
a profile. The scopes array is what the credential may do RIGHT NOW,
so a client can render its own capabilities rather than discovering
them from a 403.
Authorization
BearerAuth account.readAuthorization: Bearer <key>, with a key from the console. Keys are
default-deny: each operation names the scope it needs, and an existing
key does not gain an operation until that scope is added to it.
In: header
Scope: account.read
Response Body
application/json
application/json
application/json
curl -X GET "https://internetdata.io/api/v1/iam/identity"{
"rc": "SUCCESS",
"user": {
"id": "3d86d1ef-f70b-4063-a3b8-f69605a8fc57",
"fullname": "Ada Lovelace",
"email": "ada@example.com"
},
"org": {
"id": "7b309476-0e70-4225-9a46-5e25650094dd"
},
"scopes": [
"account.read",
"apikeys.read"
]
}{
"rc": "string"
}{
"rc": "string"
}History GET
Refusals are listed too: a denial is what answers "it stopped working", and its absence answers nothing.
Organization GET
The organization this credential is scoped to. There is no way to name a different one. A credential describes exactly one organization, so an identifier in the path could only ever be your own or a refusal.