API Keys
An alternate way to access Telmai APIs using API Key.
All Telmai APIs can be executed either with an OAuth access token or an API key. Use the APIs below to create a key, then send it in the header of any Telmai API instead of the Authorization bearer token:
X-TLM-Key:{API Key}Execute the Authenticate API to retrieve the access token used in the Authorization header for the calls below.
Key scope
API keys are user-scoped: a key belongs to the user who created it, and it carries that user's access. Any user can create a key for themselves — this is no longer restricted to tenant administrators.
The endpoints below take no tenant path parameter. The key's owner and tenant are resolved from the credentials used to call them.
API keys are managed through the API only — there is no UI for creating or revoking them.
Create an API Key
Creates an API key for the current user. The key value is returned only in this response — store it securely, as it cannot be retrieved again.
POST {auth_endpoint}/auth/api_keys
Request Body
name*
string
Name of the API Key
curl -X 'POST' \
'{auth_endpoint}/auth/api_keys' \
-H 'accept: */*' \
-H 'Content-Type: application/json' \
-d '{
"name": "<name>"
}'Responses
Unauthorized
Forbidden
Not Found
Retrieve all API Keys
Returns the API keys belonging to the current user. Key values are not included.
GET {auth_endpoint}/auth/api_keys
Responses
Unauthorized
Forbidden
Not Found
Get details of a specific API Key
Fetches one of the current user's API keys by its unique key ID.
GET {auth_endpoint}/auth/api_keys/{keyId}
Path Parameters
keyId*
string
Unique API Key ID
Responses
Unauthorized
Forbidden
Not Found
Delete an API Key
Removes one of the current user's API keys.
DELETE {auth_endpoint}/auth/api_keys/{keyId}
Path Parameters
keyId*
string
The unique identifier of the API Key to delete.
Responses
Unauthorized
Forbidden
Not Found
Tenant-scoped endpoints (deprecated)
These endpoints remain available to tenant administrators, and are how an administrator lists or revokes keys across an entire tenant rather than only their own.
Create a key
POST {auth_endpoint}/auth/{tenant}/apiKeys
List all tenant keys
GET {auth_endpoint}/auth/{tenant}/apiKeys
Get one key
GET {auth_endpoint}/auth/{tenant}/apiKeys/{keyId}
Delete a key
DELETE {auth_endpoint}/auth/{tenant}/apiKeys/{keyId}
Request bodies and response shapes are identical to the user-scoped endpoints. tenant is the tenant identifier, which can be retrieved from the URL.
Last updated