# Tags

{% openapi src="/files/DFxnj85ZsASPYXzkPAko" path="/api/v3/tags" method="get" %}
[UshahidiV3.json](https://content.gitbook.com/content/tXIYKGMTeHub5C8O9fER/blobs/TC8KXqdBoVrA1ZGmo9Kk/UshahidiV3.json)
{% endopenapi %}

## Add tag

<mark style="color:green;">`POST`</mark> `ushahididocs.api.ushahidi.io/api/v3/tags`

#### Request Body

| Name        | Type    | Description                              |
| ----------- | ------- | ---------------------------------------- |
| parent\_id  | integer | Parent identifier for Tag                |
| icon        | String  | Tag icon name                            |
| description | String  | Tag description                          |
| color       | String  | Tag color                                |
| type        | String  | Type of tag                              |
| tag         | String  | Tag name                                 |
| role        | Array   | Tag role                                 |
| priority    | Integer | Tag priority value                       |
| children    | Array   | An array of other dependent children tag |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
  "id": 0,
  "url": "string",
  "parent_id": "string",
  "tag": "string",
  "slug": "string",
  "type": "string",
  "color": "string",
  "icon": "string",
  "description": "string",
  "priority": 0,
  "created": "string",
  "role": [
    "string"
  ],
  "children": [
    "string"
  ],
  "allowed_privileges": [
    "string"
  ]
}
```

{% endtab %}
{% endtabs %}

## Edit tag

<mark style="color:orange;">`PUT`</mark> `ushahididocs.api.ushahidi.io/api/v3/tags/2`

#### Request Body

| Name        | Type    | Description                              |
| ----------- | ------- | ---------------------------------------- |
| parent\_id  | Integer | Parent identifier for Tag                |
| icon        | String  | Tag icon name                            |
| description | String  | Tag description                          |
| color       | String  | Tag color                                |
| type        | String  | Type of tag                              |
| tag         | String  | Tag name                                 |
| role        | Array   | Tag role                                 |
| priority    | Integer | Tag priority value                       |
| children    | Array   | An array of other dependent children tag |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
  "id": 0,
  "url": "string",
  "parent_id": "string",
  "tag": "string",
  "slug": "string",
  "type": "string",
  "color": "string",
  "icon": "string",
  "description": "string",
  "priority": 0,
  "created": "string",
  "role": [
    "string"
  ],
  "children": [
    "string"
  ],
  "allowed_privileges": [
    "string"
  ]
}
```

{% endtab %}
{% endtabs %}

{% openapi src="/files/DFxnj85ZsASPYXzkPAko" path="/api/v3/tags/5" method="get" %}
[UshahidiV3.json](https://content.gitbook.com/content/tXIYKGMTeHub5C8O9fER/blobs/TC8KXqdBoVrA1ZGmo9Kk/UshahidiV3.json)
{% endopenapi %}

{% openapi src="/files/DFxnj85ZsASPYXzkPAko" path="/api/v3/tags/5" method="delete" %}
[UshahidiV3.json](https://content.gitbook.com/content/tXIYKGMTeHub5C8O9fER/blobs/TC8KXqdBoVrA1ZGmo9Kk/UshahidiV3.json)
{% endopenapi %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.ushahidi.com/v3-ushahidi-platform-rest-api-documentation/v3/tags.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
