Editing possible issue field values
PATCH
https://api.tracker.yandex.net/v3/fields/<field_ID>?version=<current_field_version>
Request format
To edit possible values of an issue field, use an HTTP PATCH
request:
PATCH /v3/fields/<field_ID>?version=<current_field_version>
Host: api.tracker.yandex.net
Authorization: OAuth <OAuth_token>
X-Org-ID or X-Cloud-Org-ID: <organization_ID>
{
"name":
{
"en": "Field name in English",
"ru": "Field name in Russian"
},
"category": "0000000000000002********",
"order": 102,
"description": "Field description",
"readonly": true,
"hidden": false,
"visible": false,
"optionsProvider":
{
"type": "FixedListOptionsProvider",
"values":
["value 1", "value 2"]
}
}
Headers
-
Host
: Address of the node that provides the API. -
Authorization
: Authorization token about these formats:-
OAuth <OAuth_token>
: For authorization using the OAuth 2.0 protocol. Learn more -
Bearer <IAM_token>
: For authorization using an IAM token, if a Yandex Cloud Organization organization is linked to Tracker. Learn more
-
-
X-Org-ID
orX-Cloud-Org-ID
: Organization ID.-
Use the
X-Org-ID
header if a Tracker organization is linked to Yandex 360 for Business. -
Use the
X-Cloud-Org-ID
header if a Tracker organization is linked to Yandex Cloud Organization.
To get the organization ID, go to Administration → Organizations and copy the value from the ID field.
-
Resource
Parameter | Description | Data type |
---|---|---|
<field_ID> | Issue field ID. | String |
<current_field_version> | Current version of the issue field. | String |
Request body parameters
Additional parameters
Parameter | Description | Data type |
---|---|---|
name | Local field name:
|
String |
category | Object with information about the field category. To get a list of all categories, use the HTTP request: GET /v3/fields/categories |
String |
order | Sequence number in the list of organization fields: https://tracker.yandex.com/admin/fields | Number |
description | Field description | String |
readonly | Shows if the field value is editable:
|
Boolean |
hidden | Indicates if the field should be hidden in the interface:
|
Boolean |
visible | Indicates if the field is visible in the interface:
|
Boolean |
optionsProvider | Object with information about allowed field values. | Map object |
optionsProvider
object fields
Parameter | Description | Data type |
---|---|---|
type | Type of field values. | String |
values | Array of field values. | Array |
Response format
If the request is successful, the API returns a response with code 200 OK
.
The response body contains a JSON object with all issue field parameters.
{
"self": "https://api.tracker.yandex.net/v3/fields/ruName",
"id": "ruName",
"name": "ru_name",
"description": "description text",
"version": 3,
"schema": {
"type": "array",
"items": "string",
"required": false
},
"readonly": false,
"options": true,
"suggest": true,
"suggestProvider": {
"type": "UserSuggestProvider"
},
"optionsProvider": {
"type": "FixedListOptionsProvider",
"values": [
"value 1",
"value 2"
]
},
"queryProvider": {
"type": "StringOptionalQueryProvider"
},
"order": 14,
"category": {
"self": "https://api.tracker.yandex.net/v3/fields/categories/58bc3b921d9c********",
"id": "58bc3b921d9c********",
"display": "System"
}
}
Response parameters
Parameter | Description | Data type |
---|---|---|
self | Address of the API resource with information about the issue field. | String |
id | Field ID | String |
name | Field name | String |
description | Field description | String |
version | Field version; each change to the field increases the version number | Number |
schema | Object with information about the field value's data type | Map object |
readonly | Shows if the field value is editable:
|
Boolean |
options | Shows if the list of values is restricted:
|
Boolean |
suggest | Enables/disables search suggestions when entering field values:
|
Boolean |
suggestProvider | Object with information about the search suggestion class. You cannot change the class using the API. |
Map object |
optionsProvider | Object with information about allowed field values. | Map object |
queryProvider | Object with information about the query language class. You cannot change the class using the API. |
Map object |
order | Sequence number in the list of organization fields: https://tracker.yandex.com/admin/fields | Number |
category | Object with information about the field category. To get a list of all categories, use the HTTP request: GET /v3/fields/categories |
Map object |
schema
object fields
Parameter | Description | Data type |
---|---|---|
type | Field value type Possible data types:
|
String |
items | Value type; available for fields with multiple values | String |
required | Shows if the field is required:
|
Boolean |
suggestProvider
object fields
Parameter | Description | Data type |
---|---|---|
type | Search suggestion class. | String |
optionsProvider
object fields
Parameter | Description | Data type |
---|---|---|
type | Type of field values. | String |
values | Array of field values. | Array |
queryProvider
object fields
Parameter | Description | Data type |
---|---|---|
type | Query language type | String |
category
object fields
Parameter | Description | Data type |
---|---|---|
self | Address of the API resource with information about the field category | String |
id | Field category ID | String |
display | Display name of the category. | String |
If the request is processed incorrectly, the API returns a message with error details:
- 400
- One or more request parameters have an invalid value.
- 403
- You are not authorized to perform this action. You can check what rights you have in the Tracker interface. The same rights are required to perform an action via the API and interface.
- 404
- The requested object was not found. You may have specified an invalid object ID or key.
- 412
- A conflict occurred while editing the object. The error may be due to an invalid update version.
- 422
- JSON validation error, the request is rejected.
- 428
- Access to the resource is denied. Make sure all required conditions for the request are specified.
- 500
- Internal service error. Try again later.
- 503
- The API service is temporarily unavailable.