api-keys

Create Api Key

Create a new API key.

A key that reads/writes TMS data operates on a connection (data box). The caller must name the TMS connection the key binds to — any TMS connection the workspace can see is eligible (a real external TMS like TAI/Sunnybrook, a client push connection, or Sandbox). The server does not pick one for you: binding is the most consequential property of a key, so it is always explicit. A key that touches no TMS data (e.g. a webhook-trigger key) carries no connection.

Important: The API key value is only returned once. Store it securely.

post/v1/api-keys/

Request

  • Base URL
    https://api.mentium.io (the document declares no server; this is the origin it was published from)
  • Auth
    HTTP bearer

Headers

mentium-workspace-idstring nullable

Request body

namestring required

Human-readable name for the API key

integration_connection_idstring uuid nullable

TMS data box the key reads/writes. Required for keys with TMS-data scopes; any TMS connection in the workspace (or org-level) is eligible — TAI, Sunnybrook, Sandbox, etc. Omit for keys that touch no TMS data (e.g. webhook keys).

scopesstring[] nullable

Permission scopes (defaults to all TMS API scopes if not specified)

descriptionstring nullable

Optional description

expires_atstring date-time nullable

Optional expiration datetime

rate_limit_per_minuteinteger

Rate limit per minute

rate_limit_per_dayinteger

Rate limit per day

Response

Successful Response

idstring uuid required
namestring required
key_prefixstring required
status'ACTIVE' | 'REVOKED' | 'EXPIRED' required
scopesstring[] required
descriptionstring nullable required
rate_limit_per_minuteinteger required
rate_limit_per_dayinteger required
last_used_atstring date-time nullable required
usage_countinteger required
expires_atstring date-time nullable required
revoked_atstring date-time nullable required
created_atstring date-time required
updated_atstring date-time required
integration_connection_idstring uuid nullable required
created_by_user_idstring uuid required
created_by_namestring nullable
integration_connection_namestring nullable
keystring required

The full API key (only shown once)

Changes

No recorded changes to this operation across all 2 revisions of this API.