Skip to main content
POST
Create a label

Authorizations

Authorization
string
header
required

A project API key, created in the dashboard.

Headers

Idempotency-Key
string

A unique key that makes the request safe to retry, such as a V4 UUID. 1 to 255 printable ASCII characters.

Required string length: 1 - 255

Body

application/json
agent_id
string
required

ID of the agent the label is for.

Maximum string length: 64
name
string
required

Unique within the agent, ignoring case. Repeated spaces are collapsed.

Required string length: 1 - 120
description
string | null
Maximum string length: 500
color
string

A hex color, stored in uppercase. If omitted, a color is picked from the dashboard's palette.

Pattern: ^#[0-9A-Fa-f]{6}$
Example:

"#3B82F6"

Response

The new label.

object
any
required
id
string
required
Example:

"k3x9q2m7"

agent
object
required

The agent this belongs to.

name
string
required
Example:

"Refund request"

description
string | null
required
color
string
required
Pattern: ^#[0-9A-F]{6}$
Example:

"#3B82F6"

created_at
string<date-time> | null
required
updated_at
string<date-time> | null
required