Getting trigger parameters

Use this request to get information about a queue trigger.

GET

https://api.tracker.yandex.net/v3/queues/{queue_ID}/triggers/{trigger_ID}

Query format

Before making a request, get permission to access the API.

To get trigger parameters, use an HTTP GET request:

GET /v3/queues/{queue_ID}/triggers/{trigger_ID}
Host: api.tracker.yandex.net
Authorization: OAuth API_TOKEN
X-Org-ID or X-Cloud-Org-ID: ORGANIZATION_ID
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 Identity Hub organization is linked to Tracker. Learn more

  • ID types

    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 Identity Hub.

    Finding the ID

    To get the organization ID, go to Administration → Organizations and copy the value from the ID field.

Resource

Parameter

Description

Data type

queue_ID

Queue ID or key. The queue key is case-sensitive.

String or number

trigger_ID

Trigger ID.

Number

Response format

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

The response body contains information about the trigger in JSON format.

{
"id": 16,
"self": "https://api.tracker.yandex.net/v3/queues/DESIGN/triggers/16",
"queue": {
    "self": "https://api.tracker.yandex.net/v3/queues/DESIGN",
    "id": "26",
    "key": "DESIGN",
    "display": "Design"
},
"name": "trigger_name",
"order": "0.0002",
"actions": [
    {
        "type": "Transition",
        "id": 1,
        "status": {
            "self": "https://api.tracker.yandex.net/v3/statuses/2",
            "id": "2",
            "key": "needInfo",
            "display": "Need Info"
        }
    }
],
"conditions": [
    {
        "type": "Or",
        "conditions": [
            {
                "type": "Event.comment-create"
            }
        ]
    }
],
"version": 1,
"active": true
}
Response parameters

Parameter

Description

Data type

id

Trigger ID.

Number

self

Link to the trigger.

String

queue

Queue where the trigger was created.

Can be set as an object, a string if the queue key is provided, or a number if the queue ID is provided.

name

Trigger name.

String

order

Trigger weight. This parameter affects the order of triggers in the interface.

String

actions

Array of trigger actions.

Array of objects

conditions

Array of trigger conditions.

Array of objects

version

Trigger version. Each trigger update increases the version number.

Number

active

Trigger status. Acceptable values:

  • true: Active.
  • false: Inactive.

Boolean

Fields of the queue object

Parameter Description Data type
self Address of the API resource with information about the queue. String
id Queue ID. String
key Queue key. String
display Queue name displayed. String

Fields of objects in the actions array

The set of parameters depends on the action type. For examples of action parameters, see Trigger action objects.

Parameter

Description

Data type

type

Action type. Acceptable values:

  • Transition: Change the issue status.
  • Update: Change field values.
  • Move: Move the issue.
  • CreateComment: Add a comment.
  • CreateChecklist: Create a checklist.
  • Webhook: Send an HTTP request.
  • CalculateFormula: Calculate a value.
  • CreateIssue: Create an issue.

String

id

Action ID.

Number

status

Status to transition the issue to. Returned for the Transition action.

Object

text

Comment text for the CreateComment action, if specified.

String

Fields of objects in the conditions array

Each object in the conditions array defines a check determined by its type field. The check can concern an event, such as issue creation, or issue and comment data. Objects with type Or or And combine checks into logical groups. Nested conditions are returned in the group’s own conditions array.

Parameter

Description

Data type

type

Condition type. See acceptable values of the type field

String

conditions

Nested conditions. Returned for Or and And logical groups. Each element has the same structure as an object in the top-level conditions array

Array of objects

The set of other fields depends on the type value. For examples of condition parameters, see Trigger condition objects.

Acceptable values of the condition object’s type field

Condition group

type values

Logical groups

  • Or: Logical OR. At least one nested condition is met.
  • And: Logical AND. All nested conditions are met.

Events

  • Event.create: An issue was created.
  • Event.update: An issue was updated.
  • Event.comment-create: A comment was created.
  • CalculationFormulaWatch: Formula fields were updated.

Examples of condition definitions

Checklist

  • ChecklistDone: All checklist items are complete.

Examples of condition definitions

Comment text

  • CommentAnyMatchCondition: Contains any of the fragments.
  • CommentStringMatchCondition: Contains the fragment.
  • CommentNoneMatchCondition: Does not contain any of the fragments.
  • CommentStringNotMatchCondition: Does not contain the fragment.
  • CommentFullyMatchCondition: Fully matches.

Examples of condition definitions

Comment author

  • CommentAuthor: The comment author matches the specified user.
  • CommentAuthorNot: The comment author does not match the specified user.

Examples of condition definitions

Comment type

  • CommentMessageInternal: A comment in Tracker.
  • CommentMessageExternal: An email.

Examples of condition definitions

Link action

  • CreatedLinkCondition: A link was created.
  • UpdatedLinkCondition: A link was updated.
  • RemovedLinkCondition: A link was deleted.

Examples of condition definitions

Field value

  • FieldChangedCondition: The field value changed.
  • FieldEquals: Equal to.
  • FieldBecameEqual: Became equal to.

Examples of condition definitions

Field state

  • FieldIsNotEmpty: The field is not empty.
  • FieldIsEmpty: The field is empty.
  • FieldBecameEmpty: The field value was deleted.
  • FieldBecameNotEmpty: The field value was set.

Examples of condition definitions

Date

  • DateEqualCondition: The date matches.
  • DateGreaterCondition: Later than.
  • DateGreaterOrEqualCondition: Later than or equal to.
  • DateLessCondition: Earlier than.
  • DateLessOrEqualCondition: Earlier than or equal to.

Examples of condition definitions

User groups

  • UserInGroups: The user belongs to one of the groups.
  • UserNotInGroups: The user does not belong to any of the groups.

Examples of condition definitions

Number of items

  • Container.SizeEquals: The number of items is equal to.
  • Container.SizeNotEquals: The number of items is not equal to.
  • Container.SizeGreater: The number of items is greater than.
  • Container.SizeGreaterOrEquals: The number of items is greater than or equal to.
  • Container.SizeLess: The number of items is less than.
  • Container.SizeLessOrEquals: The number of items is less than or equal to.
  • ContainerContainsAll: Contains all items.
  • ContainerContainsAny: Contains any of the items.
  • ContainerContainsNone: Does not contain any items.

Examples of condition definitions

Numeric values

  • GreaterCondition: Greater than.
  • GreaterOrEqualCondition: Greater than or equal to.
  • LessCondition: Less than.
  • LessOrEqualCondition: Less than or equal to.
  • BecameGreaterCondition: Became greater than.
  • BecameGreaterOrEqualCondition: Became greater than or equal to.
  • BecameLessCondition: Became less than.
  • BecameLessOrEqualCondition: Became less than or equal to.

Examples of condition definitions

String values

  • FieldEqualsString: Equal to the string.
  • ContainsAnyOfStrings: Contains any of the fragments.
  • ContainsNoneOfStrings: Does not contain any of the fragments.

Examples of condition definitions

Fields of the status object

Parameter Description Data type
self Address of the API resource with information about the status. String
id Status ID. String
key Status key. String
display Status name displayed. String

If the request fails, the response contains 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.
422
JSON validation error, the request is rejected.
500
Internal service error. Try again later.
503
The API service is temporarily unavailable.

A queue key is a unique code for a queue consisting of Latin characters, for example TEST. The key is contained in the link to the queue and its issues, and you need to specify it in API requests and auto action settings. You can't change the key after creating the queue.