# Tags

* [Getting the list of task tags through API: get\_task\_tags](#q1684)
* [Creating task tags through API: add\_task\_tags](#q1686)
* [Setting/removing task tags through API: update\_task\_tags](#q1687)
* [Getting the list of task tag groups through API: get\_task\_tag\_groups](#q1683)
* [Creating task tag groups through API: add\_task\_tag\_groups](#q1685)
* [Getting the list of project tags through API: get\_project\_tags](#q1688)
* [Creating project tags through API: add\_project\_tags](#q1689)
* [Setting/removing project tags through API: update\_project\_tags](#q1690)
* [Getting the list of project tag groups through API: get\_project\_tag\_groups](#q1906)
* [Creating project tag groups through API: add\_project\_tag\_groups](#q1907)

#### Getting the list of task tags through API: get\_task\_tags

Sample get\_task\_tags request

<br>

```
?action=get_task_tags
```

Returns task tags of all or selected group

Optional parameters:<br>

* group — tags of a particular group\
  You can specify group name or group ID (can be obtained through the same method from the returned group dataset or through [get\_task\_tag\_groups](https://about/en/faq/api-tags.html#q1683) method)
* type — groups only of particular type, possible values: status, label
* access — groups only with a particular visibility, possible values:
* public — available to all teams (including external client teams)\
  statuses are always visible and have public value
* private — available only for your company teams

***

Returned data:

* id — tag ID
* title — tag name
* group — tag group dataset

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{
    "status": "ok",
    "data": [
        {
            "title": "LABEL_NAME",
            "id": "LABEL_ID",
            "group": {
                "title": "GROUP_NAME",
                "id": GROUP_ID,
                "type": "label",
                "access": "public"
                 }
        },
        {
            "title": "STATUS_NAME",
            "id": "STATUS_ID",
            "group": {
                "title": "GROUP_NAME",
                "id": GROUP_ID,
                "type": "status",
                "access": "public"
             }
        }
    ]
}
```

<br>

#### Creating task tags through API: add\_task\_tags

Sample add\_task\_tags request

<br>

```
?action=add_task_tags&title=LABEL_NAME_1,LABEL_NAME_2&group=GROUP_ID
```

Creates task tags in selected group

*\*if there are no tags with the same name*

Required parameters:

* group — group, where tags will be created\
  You can specify group name or group ID (can be obtained through [get\_task\_tag\_groups](https://about/en/faq/api-tags.html#q1683) method)
* title — tag names separated by commas

***

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{
    "status": "ok",
    "data": [
        {
            "title": "LABEL_NAME_1",
            "id": LABEL_ID
        },
        {
            "title": "LABEL_NAME_2",
            "id": LABEL_ID
        }
    ]
}
```

#### Setting/removing task tags through API: update\_task\_tags

Sample update\_task\_tags request

<br>

```
?action=update_task_tags&id_task=TASK_ID&plus=Tag1,Tag2&minus=Tag3,Tag4
```

Sets new and removes previously set tags for selected task

Required parameters:

* id\_task — task ID

Optional parameters:\
\&#xNAN;*\*tags can be specified by their names (full match) or IDs (can be obtained through* [get\_task\_tags](https://about/en/faq/api-tags.html#q1684) *method)*

* plus — task tags separated by commas, which will be added
* minus — task tags separated by commas, which will be removed

***

Sample JSON response

If the request succeeds, the response will contain ok status

```
{
    "status": "ok"
}
```

<br>

#### Getting the list of task tag groups through API: get\_task\_tag\_groups

Sample get\_task\_tag\_groups request

<br>

```
?action=get_task_tag_groups
```

Returns task tag groups

Optional parameters:

* type — groups only of particular type, possible values: status, label
* access — groups only with a particular visibility, possible values:
* public — available to all teams (including external client teams)\
  statuses are always visible and have public value
* private — available only for your company teams

***

Returned data:

* id — group ID
* title — group name
* type — group type
* access — group visibility

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{
    "status": "ok",
    "data": [
        {
            "title": "GROUP_NAME_1",
            "id": GROUP_ID,
            "type": "status",
            "access": "public"
        },
        {
            "title": "GROUP_NAME_2",
            "id": GROUP_ID,
            "type": "label",
            "access": "public"
        },
        {
            "title": "GROUP_NAME_3",
            "id": GROUP_ID,
            "type": "label",
            "access": "private"
        }
    ]
}
```

#### Creating task tag groups through API: add\_task\_tag\_groups

Sample add\_task\_tag\_groups request

<br>

```
?action=add_task_tag_groups&title=GROUP_NAME_1,GROUP_NAME_2&type=label&access=public
```

Creates task tag groups\
\&#xNAN;*\*if there are no tag groups with same name*

Required parameters:

* title — group names separated by commas
* type — group type, possible values: status, label
* access — group visibility (statuses are always visible and have public value)
* public — available to all teams (including external client teams)
* private — available only for your company teams

***

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{
    "status": "ok",
    "data": [
        {
            "title": "GROUP_NAME_1",
            "id": GROUP_ID,
            "type": "label",
            "access": "public"
        },
        {
            "title": "GROUP_NAME_2",
            "id": GROUP_ID,
            "type": "status",
            "access": "public"
        }
    ]
}
```

#### Getting the list of project tags through API: get\_project\_tags

Sample get\_project\_tags request

<br>

```
?action=get_project_tags
```

Returns project tags of all or selected group

Optional parameters:

* group — tags of a particular group\
  You can specify group name or group ID (can be obtained through the same method from the returned group dataset or through [get\_project\_tag\_groups](https://about/en/faq/api-tags.html#q1683) method)
* type — groups only of particular type, possible values: status, label
* access — groups only with a particular visibility, possible values:
* public — available to all teams (including external client teams)<br>
* private — available only for your company teams

***

Returned data:

* id — project tag ID
* title — project tag name
* group — project tag group dataset

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{
    "status": "ok",        "data": [            {                "title": "PROJECT_STATUS_NAME_1",                "id": "PROJECT_STATUS_ID",                "group": {                              "title": "PROJECT_GROUP_NAME",                    "id": "PROJECT_GROUP_ID",                    "type": "status",                    "access": "public"            },
            {                "title": "_PROJECT_LABEL_NAME_2",                "id": "PROJECT_LABEL_ID",                "group": {                                 "title": "PROJECT_GROUP_NAME",                    "id": "PROJECT_GROUP_ID",                    "type": "label",                    "access": "public"            }        ]}
```

<br>

#### Creating project tags through API: add\_project\_tags

Sample add\_project\_tags request

<br>

```
?action=add_project_tags&title=PROJECT_LABEL_NAME_1,PROJECT_LABEL_NAME_2&
group=PROJECT_GROUP_ID
```

Creates project tags in selected group

*\*if there are no tags with the same name*

Required parameters:

* group — group, where project tags will be created\
  You can specify group name or group ID (can be obtained through [get\_project\_tag\_groups](https://about/en/faq/api-tags.html#q1906) method)
* title — project tag names separated by commas

***

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{     "status": "ok",    "data": [        {
            "title": "PROJECT_LABEL_NAME_1",
            "id": PROJECT_LABEL_ID
        },        {
            "title": "PROJECT_LABEL_NAME_2",
            "id": PROJECT_LABEL_ID
        }    ]}
```

#### Setting/removing project tags through API: update\_project\_tags

Sample update\_project\_tags request

<br>

```
?action=update_project_tags&id_project=PROJECT_ID&plus=Tag1,Tag2&minus=Tag3,Tag4
```

Sets new and removes previously set tags for selected project

Required parameters:

* id\_project — project ID

<br>

Optional parameters:\
\&#xNAN;*\*tags can be specified by their names (full match) or IDs (can be obtained through* [get\_project\_tags](https://about/en/faq/api-tags.html#q1688) *method)*

* plus — project tags separated by commas, which will be added
* minus — project tags separated by commas, which will be removed

***

Sample JSON response

If the request succeeds, the response will contain ok status

```
{
    "status": "ok"
}
```

<br>

#### Getting the list of project tag groups through API: get\_project\_tag\_groups

Sample get\_project\_tag\_groups request

<br>

```
?action=get_project_tag_groups
```

Returns project tag groups<br>

Optional parameters:

* type — groups only of particular type, possible values: status, label
* access — groups only with a particular visibility, possible values:
* public — available to all teams (including external client teams)
* private — available only for your company teams

***

Returned data:

* id — group ID
* title — group name
* type — group type
* access — group visibility

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{
    "status": "ok",
    "data": [
        {
            "title": "GROUP_NAME_1",
            "id": GROUP_ID,
            "type": "status",
            "access": "public"
        },
        {
            "title": "GROUP_NAME_2",
            "id": GROUP_ID,
            "type": "label",
            "access": "public"
        },
        {
            "title": "GROUP_NAME_3",
            "id": GROUP_ID,
            "type": "label",
            "access": "private"
        }
    ]
}
```

#### Creating project tag groups through API: add\_project\_tag\_groups

Sample add\_project\_tag\_groups request

<br>

```
?action=add_project_tag_groups&title=GROUP_NAME_1,GROUP_NAME_2&access=public
```

Creates project tag groups\
\&#xNAN;*\*if there are no tags with the same name*

Required parameters:

* title — group names separated by commas
* access — tag group visibility, possible values:
* public — available to all teams (including external client teams)
* private — available only for your company teams

***

Sample JSON response

If the request succeeds, the response will contain ok status and the following data:

<br>

```
{
    "status": "ok",
    "data": [
        {
            "title": "GROUP_NAME_1",
            "id": GROUP_ID,
            "type": "",
            "access": "public"
        },
        {
            "title": "GROUP_NAME_2",
            "id": GROUP_ID,
            "type": "",
            "access": "public"
        }
    ]
}
```
