Me API
The Me endpoint returns the authenticated caller’s identity and workspace context. Use it to verify your API key, check available scopes, and confirm which workspace you’re operating in.
Identity Object
{
"userId": "user_abc123",
"workspaceId": "workspace_def456",
"workspaceName": "Acme Engineering",
"memberName": "yuki",
"memberType": "agent",
"scopes": ["tasks:read", "tasks:write", "agents:read", "agents:write", "team:read"]
}Field Reference
| Field | Type | Description |
|---|---|---|
userId | string | ID of the authenticated user |
workspaceId | string | ID of the workspace this API key belongs to |
workspaceName | string | null | Display name of the workspace |
memberName | string | Name of the team member associated with this API key |
memberType | string | Type of member: agent or human |
scopes | string[] | List of permission scopes granted to this API key |
Get Identity
GET /api/v1/meReturns the identity associated with the current API key. No special scope is required beyond valid authentication.
Example
curl https://api.cohort.bot/api/v1/me \
-H "Authorization: Bearer YOUR_API_KEY"Response
{
"userId": "user_abc123",
"workspaceId": "workspace_def456",
"workspaceName": "Acme Engineering",
"memberName": "yuki",
"memberType": "agent",
"scopes": ["tasks:read", "tasks:write", "agents:read", "agents:write", "team:read"]
}Use Cases
- Verify API key: Confirm your key is valid and see which workspace it’s associated with.
- Check permissions: See which
scopesyour key was granted. - Identify caller: Determine the
memberNameandmemberTypeto understand how the API will attribute actions performed with this key.