Add/Update Values in Ticket Field
info
This method is available only for fields with the following types: Dropdown list (select), Related fields (hierarchy), Multi-button (multi_button)
POST /custom_fields/:field_id/options/
URL Example
https://system_domain/api/v2/custom_fields/123/options/
PATH Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
field_id | number | Yes | ID of the custom field |
Request Body Parameters (JSON)
| Parameter | Type | Required | Description |
|---|---|---|---|
options | array | Yes | Array of values |
Request Body Examples (JSON):
{
"options": [ // Adding a new value
{
"name": {
"ru": "Новая опция",
"en": "New option"
}
}
]
}
{
"options": [ // Updating an existing value
{
"id": 11016, // ID of the value to update
"name": {
"ru": "Обновлённое значение",
"en": "Updated option"
}
}
]
}
{
"options": [ // Adding a new value for related fields at a specific level
{
"pid": 4588, // ID of the parent value
"name": {
"ru": "Новая опция",
"en": "New option"
}
}
]
}
Response Examples:
Response Example
{
"data": [ // Response to adding a new value
{
"id": 11016,
"name": {
"ru": "Новая опция",
"en": "New option"
}
}
]
}
{
"data": [ // Response to updating an existing value
{
"id": 11016,
"name": {
"ru": "Обновлённое значение",
"en": "Updated option"
}
}
]
}
{
"data": [ // Response to adding a new value for related fields at a specific level
{
"id": 11016,
"name": {
"ru": "Новая опция",
"en": "New option"
}
}
]
}