Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Labels

Delete label

delete

Permanently deletes a label by its ID.

Requires 'Delete labels' permission.

Deleting a label does not affect any existing data structures or links that reference it; only the label record is removed.

Path parameters
idintegerRequired

Label ID

Responses
204

Label deleted

No content

delete/api/labels/{id}
DELETE /api/labels/{id} HTTP/1.1
Accept: */*

No content

Delete label by name

delete

Permanently deletes a label by its name.

Requires the 'Delete labels' permission.

Deleting a label does not affect any existing data structures or links that reference it; only the label record is removed.

Body
namestringRequired
Responses
204

Label deleted

No content

delete/api/labels/search_delete_one
DELETE /api/labels/search_delete_one HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 24

{
  "name": "example_label"
}

No content

List labels

get

Returns a list of all labels available in the system. The list is not filtered by domain or structure; all global labels are returned.

Requires the 'View labels' permission.

No pagination is applied; the full list of labels is returned in a single response.

Responses
200

List labels

application/json
get/api/labels
GET /api/labels HTTP/1.1
Accept: */*
{
  "data": [
    {
      "data": {
        "id": 1,
        "name": "example_label"
      }
    },
    {
      "data": {
        "id": 2,
        "name": "another_label"
      }
    }
  ]
}

Create label

post

Creates a new label with the given name.

The name of the label must be unique, if a label with the same name already exists, the endpoint returns an error.

Requires the 'Create labels' permission.

Body
namestringRequired
Responses
201

Label created

application/json
post/api/labels
POST /api/labels HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 24

{
  "name": "example_label"
}
{
  "data": {
    "id": 1,
    "name": "example_label"
  }
}

Last updated