Getting priorities
Written by
Updated at February 19, 2024
Use this request to get a list of priorities for an issue.
Request format
Before making the request, get permission to access the API.
To get a list of priorities, use an HTTP GET
request:
GET /v2/priorities
Host: https://api.tracker.yandex.net
Authorization: OAuth <OAuth token>
X-Org-ID: <organization ID>
Headers
-
Host
Address of the node that provides the API:
https://api.tracker.yandex.net
-
Authorization
OAuth token in
OAuth <OAuth_token>
format, e.g.:OAuth 0c4181a7c2cf4521964a72ff********
-
X-Org-ID or X-Cloud-Org-ID
Organization ID. You can find it out on the Tracker organizations page
.- If a Yandex 360 for Business organization is the only one linked to Tracker, the
X-Org-ID
header is used. - If a Yandex Cloud Organization organization is the only one linked to Tracker, the
X-Cloud-Org-ID
header is used. - If both Yandex 360 for Business and Yandex Cloud Organization organizations are linked to Tracker at the same time, the
X-Org-ID
header and the Yandex 360 for Business organization ID are used.
- If a Yandex 360 for Business organization is the only one linked to Tracker, the
Request parameters
Additional parameters
Parameter | Description | Data type |
---|---|---|
localized | Shows if the response contains translations. Acceptable values include:
|
Logical |
Request for priorities:
- An HTTP GET method is used.
GET /v2/priorities?localized=false HTTP/1.1 Host: https://api.tracker.yandex.net Authorization: OAuth <OAuth token> X-Org-ID: <organization ID>
Response format
Request executed successfully
Request failed
If the request is successful, the API returns a response with code 200 OK
.
The response body contains the results in JSON format.
[
{
"self": "https://https://api.tracker.yandex.net/v2/priorities/5",
"id": 5,
"key": "blocker",
"version": 1341632717561,
"name": "Blocker",
"order": 5
},
...
]
Response parameters
Parameter | Description | Data type |
---|---|---|
self | Address of the API resource with information about the priority. | String |
id | Priority ID. | Number |
key | Priority key. | String |
version | Priority version. | Number |
name | Priority name displayed. If localized=false is provided in the request, this parameter duplicates the name in other languages. |
String |
order | Priority weight. This parameter affects the order of priority display in the interface. | Number |
If the request is processed incorrectly, the API returns a response with an error code:
- 400
- One or more request parameters have an invalid value.
- 401
- The user isn't authorized. Make sure to perform the actions described in API access.
- 403
- Insufficient rights 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.