Get current user profile
Returns the consolidated profile of the authenticated user: identity, organisation membership (role + organisation id), and linked OAuth providers. **Required scope:** `users:read`
Authorization
BearerAuth Security scheme for OpenAPI endpoints. Validates both JWT tokens and API keys.
In: header
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/v1/users/me"{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "email": "string", "role": "admin", "scopes": [ "string" ], "organisationId": "c9b3f279-e3b5-4204-ad99-646257417f98", "workspaceId": "ef0efa32-d1c1-43d4-a5e2-fe7b4f00403c", "organisations": [ { "organisationId": "c9b3f279-e3b5-4204-ad99-646257417f98", "organisationName": "string", "role": "admin" } ], "workspaces": [ { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "isDefault": true } ], "providers": [ { "provider": "azure", "providerEmail": "string", "linkedAt": "string" } ], "createdAt": "string"}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}{ "code": "string", "message": "string", "request_id": "string", "details": [ { "field": "string", "message": "string" } ]}Accept an organisation invite
Accepts a pending invite, adding a membership in the inviting organisation. Purely additive (multi-org): the caller's other memberships are untouched, and the new membership does not become their default binding. **Required scope:** `org:read`
Unlink an OAuth provider from the authenticated user.
Cleans up: `user_provider_identity_linking` row, vault secret + token cache, and any storage configurations tied to this provider's scheme. Gated on `oauth:unlink` (not `users:write`) so non-Admin roles can self-recover from expired/revoked tokens without needing an Admin to intervene. The endpoint only acts on the caller's own `user_id` derived from `AuthContext`, so no IDOR exposure. **Required scope:** `oauth:unlink`