POST
/
labels
curl --request POST \
  --url https://api.portkey.ai/v1/labels \
  --header 'Content-Type: application/json' \
  --header 'x-portkey-api-key: <api-key>' \
  --data '{
  "organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "workspace_id": "<string>",
  "name": "<string>",
  "description": "<string>",
  "color_code": "<string>"
}'
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}

Authorizations

x-portkey-api-key
string
header
required

Body

application/json
name
string
required

Name of the label

organisation_id
string

ID of the organisation

workspace_id
string

ID or slug of the workspace

description
string

Description of the label

color_code
string

Color code for the label

Response

200
application/json
Label created successfully
id
string

ID of the created label