Skip to main content
The Me resource returns information about whoever — or whatever — is making the request. It reflects the authenticated principal: the user account behind the token, the token itself and its granted scopes, and the workspace the call resolves against. Use it to verify credentials, debug scope problems, or bootstrap a CLI session. By the end of this page you will know what the endpoint returns and how that differs between API keys and OAuth sessions.

A first call

curl https://api.gavai.app/v1/me \
  -H "Authorization: Bearer gak_live_xxxxxxxxxxxxx"
Three blocks: user identifies the human (when there is one), token describes the credential that authenticated this request, and workspace is the tenant the call resolves to.

Endpoint

Returns the current principal: user, token id and scopes, active workspace.

Behavior notes

PrincipalWhat workspace resolves to
Workspace API key (gak_live_*, gak_test_*)The workspace the key was minted against. Always the same workspace for the life of the key.
OAuth session token (gst_*)The workspace active when the session was established or last switched. Use POST /v1/workspaces/{slug}/switch to change it.
The token.scopes list is exhaustive — every scope the token holds is included.

Workspaces

Enumerate accessible workspaces and switch the active context for OAuth sessions.