Edit a priority

Use this request to update a priority.

This request cannot change a priority icon in the Tracker interface.

PATCH

https://api.tracker.yandex.net/v3/priorities/<priority_id_or_key>?version=<priority_version>

You need Administrator rights to run this request.

Request format

Before making the request, get access to the API.

To edit a priority, use an HTTP request with the PATCH method. In the request body, specify the parameters in JSON format.

PATCH /v3/priorities/<priority_id_or_key>?version=<priority_version>
Host: api.tracker.yandex.net
Authorization: OAuth <OAuth_token>
Content-Type: application/json
X-Org-ID or X-Cloud-Org-ID: <organization_ID>

{
    "name": {
        "en": "English name",
        "ru": "Название на русском"
    },
    "description": "Description"
}

To find out priority parameters, such as id, key, or version, make a request Get a list of priorities.

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 or X-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 AdministrationOrganizations and copy the value from the ID field.

Resource
Parameter Description Data type
priority_id_or_key The unique ID of the priority in Tracker or the priority key. Number or string
Query parameters

Additional parameters

Parameter Description Data type
version The priority version. Changes are only applied to the current priority version. Number
Request body parameters

Additional parameters

Parameter Description Data type
name Priority name Object
description Priority description String

Fields of the name object

Parameter Description Data type
en Priority name in English String
ru Priority name in Russian String

Example: Change a priority name.

  • An HTTP PATCH method is used.
  • A priority with key = one is being edited.
  • New priority name: "Low".
PATCH /v3/priorities/one?version=1
Host: api.tracker.yandex.net
Authorization: OAuth y0__xAbc******
Content-Type: application/json
X-Org-ID: 1234******

    {
        "name": {
        "en": "Low",
        "ru": "Низкий"
        },
        "description": "Description"
    }

Response format

If the request is successful, the API returns a response with code 200 OK.

The response body contains information about the edited priority in JSON format.

  {
      "self": "https://api.tracker.yandex.net/v3/priorities/6",
      "id": 6,
      "key": "one",
      "version": 2,
      "name": "Low",
      "description": "Description",
      "order": 60
  }
Response parameters
Parameter Description Data type
self The address of the API resource that contains information about the priority String
id The unique ID of the priority in Tracker Number
key Priority key String
version Priority version Number
name Priority name String
description Priority description String
order Priority weight. This parameter affects the order in which the priority is displayed in the interface Number

If the request is not processed successfully, the API returns a response with an error code:

401
The user is not authorized. Make sure that actions described in the API access section are performed.
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.
409
There was a conflict when editing the object. The error may be due to an invalid update version.
423
Object edits disabled. The version parameter value limit (the maximum number of object updates) might have been exceeded. The maximum version value is 10100 for robots and 11100 for users.