Introspect active API credentials, verify permission scopes, and check workspace quota limits.
GET /v1/me — Introspect Caller Identity
Scope: None (Any active key) · Rate Limit: 60/min · Idempotent: Yes
Retrieves the authenticated principal's user account details, active subscription plan, assigned permission scopes, and current resource usage. Useful for startup health checks, CLI handshakes, and credential verification.
Headers
| Header | Type | Required | Description |
|---|---|---|---|
Authorization | string | Yes* | Bearer token format: Bearer afp_.... |
x-api-key | string | Yes* | Alternative API key header. |
* Exactly one authentication header must be supplied.
Example Request
curl -X GET "https://api.aliasfleet.com/v1/me" \
-H "Authorization: Bearer afp_4a8f9c1b2d3e4f5a6b7c8d9e0f1a2b3c4d5e6f7a8b9c0d1e" \
-H "Accept: application/json"
Response (200 OK)
{
"user": {
"id": "usr_9f83a2c1b4d5e6f7",
"email": "alex.mercer@company.com",
"username": "alexm",
"plan": "pro",
"is_active": true
},
"auth": {
"type": "api_key",
"key_id": "key_1a2b3c4d5e6f7g8h",
"name": "Production Deploy Bot",
"masked_key": "afp_••••••••••••••••0d1e",
"scopes": [
"aliases:read",
"aliases:write",
"domains:read",
"destinations:read"
],
"expires_at": null,
"last_used_at": "2026-09-04T12:00:00.000Z"
},
"quotas": {
"aliases_used": 24,
"aliases_limit": 500,
"domains_used": 3,
"domains_limit": 10,
"destinations_used": 2,
"destinations_limit": 5
}
}
Errors
| Status | Code | Cause & Resolution |
|---|---|---|
401 Unauthorized | UNAUTHORIZED | Missing, expired, or invalid API key. Verify token prefix (afp_). |
429 Too Many Requests | RATE_LIMIT_EXCEEDED | Request rate limit exceeded. Check Retry-After header. |
GET /v1/auth/whoami — Gateway Introspection Alias
Scope: None (Any active key) · Rate Limit: 60/min · Idempotent: Yes
Standard RFC 7662 token introspection endpoint. Operates identically to GET /v1/me, provided for API gateway plugins (Kong, Envoy, Cloudflare Workers) and OAuth2 reverse proxies that require a standard whoami URL.
Example Request
curl -X GET "https://api.aliasfleet.com/v1/auth/whoami" \
-H "x-api-key: afp_4a8f9c1b2d3e4f5a6b7c8d9e0f1a2b3c4d5e6f7a8b9c0d1e" \
-H "Accept: application/json"
Response (200 OK)
{
"user": {
"id": "usr_9f83a2c1b4d5e6f7",
"email": "alex.mercer@company.com",
"username": "alexm",
"plan": "pro",
"is_active": true
},
"auth": {
"type": "api_key",
"key_id": "key_1a2b3c4d5e6f7g8h",
"name": "Production Deploy Bot",
"masked_key": "afp_••••••••••••••••0d1e",
"scopes": [
"aliases:read",
"aliases:write"
]
}
}
Errors
| Status | Code | Cause & Resolution |
|---|---|---|
401 Unauthorized | UNAUTHORIZED | Missing, expired, or invalid token. |
429 Too Many Requests | RATE_LIMIT_EXCEEDED | Request threshold reached. Back off for the duration in Retry-After. |