GET/api/whoamiAuthenticated

Who am I

Returns the identity resolved from the presented credential, plus which auth scheme resolved it and the scope granted to the token.

operationId get_api_whoamiAccount

Authentication & permissionsAuthenticated

Any authenticated user

Accepted credentials
Who may call
Any authenticated user

Responses

application/json
Whoami
PropertyTypeDescription
uid*string

SchemaVaults user id

email*string | null | null
admin*boolean
scheme*string

Name of the auth scheme that resolved the credential

scope*string | null | null

Space separated scope granted to the token, or null when it carries no scope claim

JSONExample
"uid""string"
"email""string"
"admin"true
"scheme""schemavaults-access-token"
"scope""string"

Example request

bashcurl
curl -X GET 'https://example-nextjs-resource-server.schemavaults.com/api/whoami' \
  -H 'Authorization: Bearer <access_token>'