> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hybridbox.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Теги

> Управлять тегами ресурсов и назначениями тегов.

# Теги

Управлять тегами ресурсов и назначениями тегов.

<script src="/locale-bridge.js" />

В примерах используется режим кода A2A. MCP предоставляет тот же режим кода через инструмент `execute`.

## Функции

### `tags.add`

```text theme={null}
tags.add(account_id: str, tag_name: str, color_hex?: str, description?: str | null) -> Tag
```

Теги: `tags.add`.

| Свойство              | Значение                                     | Свойство                 | Значение     |
| --------------------- | -------------------------------------------- | ------------------------ | ------------ |
| Требуемое разрешение  | `tag.manage`                                 | Требуется аутентификация | `да`         |
| Режим выполнения      | `sync`                                       | Возможность              | `tag.manage` |
| Тип ресурса           | `account`                                    | Поле ID ресурса          | `account_id` |
| Публичный маршрут API | `POST /v1/public/accounts/{account_id}/tags` |                          |              |

<AccordionGroup>
  <Accordion title="Аргументы">
    | Имя           | Тип           | Обязательный |
    | ------------- | ------------- | ------------ |
    | `account_id`  | `str`         | да           |
    | `tag_name`    | `str`         | да           |
    | `color_hex`   | `str`         | нет          |
    | `description` | `str \| null` | нет          |
  </Accordion>

  <Accordion title="Возвращает">
    | Поле          | Тип           | Обязательный |
    | ------------- | ------------- | ------------ |
    | `color_hex`   | `str`         | да           |
    | `id`          | `str`         | да           |
    | `name`        | `str`         | да           |
    | `created_at`  | `str \| null` | нет          |
    | `description` | `str \| null` | нет          |
    | `updated_at`  | `str \| null` | нет          |
  </Accordion>

  <Accordion title="Пример A2A">
    Запрос:

    ```json theme={null}
    {
      "request_id": "example",
      "session_id": "session_123",
      "code": "tags.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_name=\"<string>\", color_hex=\"<string>\", description=\"<string>\")"
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "request_id": "example",
      "status": "completed",
      "result": {
        "last_value": "<string>"
      },
      "responses": [
        {
          "index": 0,
          "function": "tags.add",
          "status": "completed",
          "result": "<string>"
        }
      ],
      "complexity_score": 1
    }
    ```
  </Accordion>

  <Accordion title="Пример MCP">
    Запрос:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "method": "tools/call",
      "params": {
        "name": "hybridbox_execute",
        "arguments": {
          "code": "tags.add(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_name=\"<string>\", color_hex=\"<string>\", description=\"<string>\")"
        }
      }
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "result": {
        "content": [
          {
            "type": "text",
            "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": \"<string>\"\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"tags.add\",\n      \"status\": \"completed\",\n      \"result\": \"<string>\"\n    }\n  ],\n  \"complexity_score\": 1\n}"
          }
        ],
        "isError": false
      }
    }
    ```
  </Accordion>
</AccordionGroup>

### `tags.delete`

```text theme={null}
tags.delete(account_id: str, tag_id: str) -> {}
```

Теги: `tags.delete`.

| Свойство              | Значение                                                | Свойство                 | Значение     |
| --------------------- | ------------------------------------------------------- | ------------------------ | ------------ |
| Требуемое разрешение  | `tag.manage`                                            | Требуется аутентификация | `да`         |
| Режим выполнения      | `sync`                                                  | Возможность              | `tag.manage` |
| Тип ресурса           | `account`                                               | Поле ID ресурса          | `account_id` |
| Публичный маршрут API | `DELETE /v1/public/accounts/{account_id}/tags/{tag_id}` |                          |              |

<AccordionGroup>
  <Accordion title="Аргументы">
    | Имя          | Тип   | Обязательный |
    | ------------ | ----- | ------------ |
    | `account_id` | `str` | да           |
    | `tag_id`     | `str` | да           |
  </Accordion>

  <Accordion title="Возвращает">
    | Поле     | Тип  | Обязательный |
    | -------- | ---- | ------------ |
    | `result` | `{}` | да           |
  </Accordion>

  <Accordion title="Пример A2A">
    Запрос:

    ```json theme={null}
    {
      "request_id": "example",
      "session_id": "session_123",
      "code": "tags.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "request_id": "example",
      "status": "completed",
      "result": {
        "last_value": {}
      },
      "responses": [
        {
          "index": 0,
          "function": "tags.delete",
          "status": "completed",
          "result": {}
        }
      ],
      "complexity_score": 1
    }
    ```
  </Accordion>

  <Accordion title="Пример MCP">
    Запрос:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "method": "tools/call",
      "params": {
        "name": "hybridbox_execute",
        "arguments": {
          "code": "tags.delete(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\")"
        }
      }
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "result": {
        "content": [
          {
            "type": "text",
            "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": {}\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"tags.delete\",\n      \"status\": \"completed\",\n      \"result\": {}\n    }\n  ],\n  \"complexity_score\": 1\n}"
          }
        ],
        "isError": false
      }
    }
    ```
  </Accordion>
</AccordionGroup>

### `tags.domains.assign`

```text theme={null}
tags.domains.assign(account_id: str, tag_id: str, domain_ids: [str]) -> Tag
```

Теги: `tags.domains.assign`.

| Свойство              | Значение                                                             | Свойство                 | Значение     |
| --------------------- | -------------------------------------------------------------------- | ------------------------ | ------------ |
| Требуемое разрешение  | `tag.manage`                                                         | Требуется аутентификация | `да`         |
| Режим выполнения      | `sync`                                                               | Возможность              | `tag.manage` |
| Тип ресурса           | `account`                                                            | Поле ID ресурса          | `account_id` |
| Публичный маршрут API | `POST /v1/public/accounts/{account_id}/tags/{tag_id}/domains/assign` |                          |              |

<AccordionGroup>
  <Accordion title="Аргументы">
    | Имя          | Тип     | Обязательный |
    | ------------ | ------- | ------------ |
    | `account_id` | `str`   | да           |
    | `tag_id`     | `str`   | да           |
    | `domain_ids` | `[str]` | да           |
  </Accordion>

  <Accordion title="Возвращает">
    | Поле         | Тип     | Обязательный |
    | ------------ | ------- | ------------ |
    | `domain_ids` | `[str]` | да           |
    | `tag_id`     | `str`   | да           |
  </Accordion>

  <Accordion title="Пример A2A">
    Запрос:

    ```json theme={null}
    {
      "request_id": "example",
      "session_id": "session_123",
      "code": "tags.domains.assign(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain_ids=\"example.com\")"
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "request_id": "example",
      "status": "completed",
      "result": {
        "last_value": {
          "domain_ids": [
            "<string>"
          ],
          "tag_id": "<string>"
        }
      },
      "responses": [
        {
          "index": 0,
          "function": "tags.domains.assign",
          "status": "completed",
          "result": {
            "domain_ids": [
              "<string>"
            ],
            "tag_id": "<string>"
          }
        }
      ],
      "complexity_score": 1
    }
    ```
  </Accordion>

  <Accordion title="Пример MCP">
    Запрос:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "method": "tools/call",
      "params": {
        "name": "hybridbox_execute",
        "arguments": {
          "code": "tags.domains.assign(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain_ids=\"example.com\")"
        }
      }
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "result": {
        "content": [
          {
            "type": "text",
            "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": {\n      \"domain_ids\": [\n        \"<string>\"\n      ],\n      \"tag_id\": \"<string>\"\n    }\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"tags.domains.assign\",\n      \"status\": \"completed\",\n      \"result\": {\n        \"domain_ids\": [\n          \"<string>\"\n        ],\n        \"tag_id\": \"<string>\"\n      }\n    }\n  ],\n  \"complexity_score\": 1\n}"
          }
        ],
        "isError": false
      }
    }
    ```
  </Accordion>
</AccordionGroup>

### `tags.domains.unassign`

```text theme={null}
tags.domains.unassign(account_id: str, tag_id: str, domain_ids: [str]) -> {}
```

Теги: `tags.domains.unassign`.

| Свойство              | Значение                                                               | Свойство                 | Значение     |
| --------------------- | ---------------------------------------------------------------------- | ------------------------ | ------------ |
| Требуемое разрешение  | `tag.manage`                                                           | Требуется аутентификация | `да`         |
| Режим выполнения      | `sync`                                                                 | Возможность              | `tag.manage` |
| Тип ресурса           | `account`                                                              | Поле ID ресурса          | `account_id` |
| Публичный маршрут API | `POST /v1/public/accounts/{account_id}/tags/{tag_id}/domains/unassign` |                          |              |

<AccordionGroup>
  <Accordion title="Аргументы">
    | Имя          | Тип     | Обязательный |
    | ------------ | ------- | ------------ |
    | `account_id` | `str`   | да           |
    | `tag_id`     | `str`   | да           |
    | `domain_ids` | `[str]` | да           |
  </Accordion>

  <Accordion title="Возвращает">
    | Поле     | Тип  | Обязательный |
    | -------- | ---- | ------------ |
    | `result` | `{}` | да           |
  </Accordion>

  <Accordion title="Пример A2A">
    Запрос:

    ```json theme={null}
    {
      "request_id": "example",
      "session_id": "session_123",
      "code": "tags.domains.unassign(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain_ids=\"example.com\")"
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "request_id": "example",
      "status": "completed",
      "result": {
        "last_value": {}
      },
      "responses": [
        {
          "index": 0,
          "function": "tags.domains.unassign",
          "status": "completed",
          "result": {}
        }
      ],
      "complexity_score": 1
    }
    ```
  </Accordion>

  <Accordion title="Пример MCP">
    Запрос:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "method": "tools/call",
      "params": {
        "name": "hybridbox_execute",
        "arguments": {
          "code": "tags.domains.unassign(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", domain_ids=\"example.com\")"
        }
      }
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "result": {
        "content": [
          {
            "type": "text",
            "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": {}\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"tags.domains.unassign\",\n      \"status\": \"completed\",\n      \"result\": {}\n    }\n  ],\n  \"complexity_score\": 1\n}"
          }
        ],
        "isError": false
      }
    }
    ```
  </Accordion>
</AccordionGroup>

### `tags.list`

```text theme={null}
tags.list(account_id: str, page?: int, page_size?: int) -> Page[Tag]
```

Теги: `tags.list`.

| Свойство              | Значение                                    | Свойство                 | Значение     |
| --------------------- | ------------------------------------------- | ------------------------ | ------------ |
| Требуемое разрешение  | `tag.view`                                  | Требуется аутентификация | `да`         |
| Режим выполнения      | `sync`                                      | Возможность              | `tag.view`   |
| Тип ресурса           | `account`                                   | Поле ID ресурса          | `account_id` |
| Публичный маршрут API | `GET /v1/public/accounts/{account_id}/tags` |                          |              |

<AccordionGroup>
  <Accordion title="Аргументы">
    | Имя          | Тип   | Обязательный |
    | ------------ | ----- | ------------ |
    | `account_id` | `str` | да           |
    | `page`       | `int` | нет          |
    | `page_size`  | `int` | нет          |
  </Accordion>

  <Accordion title="Возвращает">
    | Поле        | Тип                                                                                                                                 | Обязательный |
    | ----------- | ----------------------------------------------------------------------------------------------------------------------------------- | ------------ |
    | `items`     | `[{"color_hex": str, "id": str, "name": str, "created_at"?: str \| null, "description"?: str \| null, "updated_at"?: str \| null}]` | да           |
    | `page`      | `int`                                                                                                                               | да           |
    | `page_size` | `int`                                                                                                                               | да           |
    | `total`     | `int`                                                                                                                               | да           |
  </Accordion>

  <Accordion title="Пример A2A">
    Запрос:

    ```json theme={null}
    {
      "request_id": "example",
      "session_id": "session_123",
      "code": "tags.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", page=123, page_size=123)"
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "request_id": "example",
      "status": "completed",
      "result": {
        "last_value": "<string>"
      },
      "responses": [
        {
          "index": 0,
          "function": "tags.list",
          "status": "completed",
          "result": "<string>"
        }
      ],
      "complexity_score": 1
    }
    ```
  </Accordion>

  <Accordion title="Пример MCP">
    Запрос:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "method": "tools/call",
      "params": {
        "name": "hybridbox_execute",
        "arguments": {
          "code": "tags.list(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", page=123, page_size=123)"
        }
      }
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "result": {
        "content": [
          {
            "type": "text",
            "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": \"<string>\"\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"tags.list\",\n      \"status\": \"completed\",\n      \"result\": \"<string>\"\n    }\n  ],\n  \"complexity_score\": 1\n}"
          }
        ],
        "isError": false
      }
    }
    ```
  </Accordion>
</AccordionGroup>

### `tags.update`

```text theme={null}
tags.update(account_id: str, tag_id: str, color_hex?: str | null, description?: str | null, tag_name?: str | null) -> Tag
```

Теги: `tags.update`.

| Свойство              | Значение                                               | Свойство                 | Значение     |
| --------------------- | ------------------------------------------------------ | ------------------------ | ------------ |
| Требуемое разрешение  | `tag.manage`                                           | Требуется аутентификация | `да`         |
| Режим выполнения      | `sync`                                                 | Возможность              | `tag.manage` |
| Тип ресурса           | `account`                                              | Поле ID ресурса          | `account_id` |
| Публичный маршрут API | `PATCH /v1/public/accounts/{account_id}/tags/{tag_id}` |                          |              |

<AccordionGroup>
  <Accordion title="Аргументы">
    | Имя           | Тип           | Обязательный |
    | ------------- | ------------- | ------------ |
    | `account_id`  | `str`         | да           |
    | `tag_id`      | `str`         | да           |
    | `color_hex`   | `str \| null` | нет          |
    | `description` | `str \| null` | нет          |
    | `tag_name`    | `str \| null` | нет          |
  </Accordion>

  <Accordion title="Возвращает">
    | Поле          | Тип           | Обязательный |
    | ------------- | ------------- | ------------ |
    | `color_hex`   | `str`         | да           |
    | `id`          | `str`         | да           |
    | `name`        | `str`         | да           |
    | `created_at`  | `str \| null` | нет          |
    | `description` | `str \| null` | нет          |
    | `updated_at`  | `str \| null` | нет          |
  </Accordion>

  <Accordion title="Пример A2A">
    Запрос:

    ```json theme={null}
    {
      "request_id": "example",
      "session_id": "session_123",
      "code": "tags.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", color_hex=\"<string>\", description=\"<string>\", tag_name=\"<string>\")"
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "request_id": "example",
      "status": "completed",
      "result": {
        "last_value": "<string>"
      },
      "responses": [
        {
          "index": 0,
          "function": "tags.update",
          "status": "completed",
          "result": "<string>"
        }
      ],
      "complexity_score": 1
    }
    ```
  </Accordion>

  <Accordion title="Пример MCP">
    Запрос:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "method": "tools/call",
      "params": {
        "name": "hybridbox_execute",
        "arguments": {
          "code": "tags.update(account_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", tag_id=\"3c90c3cc-0d44-4b50-8888-8dd25736052a\", color_hex=\"<string>\", description=\"<string>\", tag_name=\"<string>\")"
        }
      }
    }
    ```

    Ответ:

    ```json theme={null}
    {
      "jsonrpc": "2.0",
      "id": "example",
      "result": {
        "content": [
          {
            "type": "text",
            "text": "{\n  \"request_id\": \"example\",\n  \"status\": \"completed\",\n  \"result\": {\n    \"last_value\": \"<string>\"\n  },\n  \"responses\": [\n    {\n      \"index\": 0,\n      \"function\": \"tags.update\",\n      \"status\": \"completed\",\n      \"result\": \"<string>\"\n    }\n  ],\n  \"complexity_score\": 1\n}"
          }
        ],
        "isError": false
      }
    }
    ```
  </Accordion>
</AccordionGroup>
