Skip to content

Create API key

POST
/api/v1/api-keys

Generates a new API key. The raw key is returned in the response and will never be shown again. Store it securely.

Use the key as Authorization: Bearer pong_... in API requests.

object
name
required

A descriptive name for the key.

string
Example
CI Pipeline

API key created. The raw key is included in this response only.

Returned only once at creation time. The raw key is never stored or retrievable again.

object
id
integer
Example
1
user_id
integer
Example
1
name
string
Example
CI Pipeline
prefix

First 8 characters of the key, used for identification.

string
Example
pong_a3f
last_used_at
string format: date-time
nullable
Example
2026-03-29T12:00:00Z
created_at
string format: date-time
Example
2026-03-29T10:00:00Z
key

The raw API key. Copy it now — it will not be shown again.

string
Example
pong_a3f8b2c1d4e5f6a7b8c9d0e1f2a3b4c5

The request body is invalid or missing required fields.

Error response returned when a request fails.

object
error
required

A human-readable error message.

string
Example
monitor not found
Example
{
"error": "invalid request body"
}

Authentication credentials are missing or invalid.

Error response returned when a request fails.

object
error
required

A human-readable error message.

string
Example
monitor not found
Example
{
"error": "unauthorized"
}