For AI agents: a documentation index is available at /llms.txt. Markdown versions of all pages can be requested by appending `.md` to the URL, or by setting the `Accept` header to `text/markdown`.
Skip to main content
Management API

Create an API key

POST https://mp.speechmatics.com/v1/api-keys

Create an API key in your workspace.

This endpoint issues two kinds of key:

  • Permanent key — a long-lived key for a project. Set project_id (and optionally name) and omit ttl. Use this for a normal project API key.
  • Temporary key — a short-lived key that expires automatically. Set ttl to the lifetime in seconds. Use temporary keys to authenticate end-user requests without exposing a long-lived key.

A long-lived API key can create only temporary keys. Creating a permanent key needs a management token.

The au region supports Batch only, so it cannot be combined with type=rt.

Authentication

Any one of:

  • managementToken Authorization: Bearer <token>

    A management token, scoped to the workspace.

  • apiKey Authorization: Bearer <token>

    A long-lived API key.

Query parameters

type
"rt" | "batch" | "tts"
optional

The product this key can access: batch (default), rt (Realtime), or tts (Text to Speech).

Request body

application/json
project_id
integer<int64> | null
optional

The project the API key belongs to. Set this to create a permanent key for a specific project.

name
string | null≤ 120 characters
optional

A display name for the API key (up to 120 characters).

client_ref
string | null
optional

An end-user reference. For batch keys, it restricts the key to jobs created with the same client_ref; it is ignored for rt keys.

ttl
integer<int64> | null≥ 60, ≤ 86400
optional

Time to live for a temporary key, in seconds, from 60 (1 minute) to 86400 (24 hours). Set ttl to create a temporary key that expires automatically; omit it to create a permanent key.

region
"eu" | "usa" | "au" | nulldeprecated
optionaldeprecated

Deprecated. Region (eu (default), usa, or au) is now determined by the endpoint you call. Still accepted for backward compatibility, but it has no effect.

Responses

Created

application/json
key_value
string
apikey_id
string

Request

MANAGEMENT_TOKEN="YOUR_MANAGEMENT_TOKEN"

curl -L -X POST "https://mp.speechmatics.com/v1/api-keys?type=batch" \
-H "Authorization: Bearer ${MANAGEMENT_TOKEN}" \
-H "Content-Type: application/json" \
-d '{"project_id": 12345, "name": "ci-pipeline"}'