This resource represents the contract to create/read/update/delete of routing rules in Jira Service Management.
Lists all routing rules of given team. It optionally takes two parameters - offset and size.
read:ops-config:jira-service-management
string
Requiredinteger
integer
Returned if the request is successful.
1
2
3
4
curl --request GET \
--url 'https://api.atlassian.com/jsm/ops/api/{cloudId}/v1/teams/{teamId}/routing-rules' \
--user 'email@example.com:<api_token>' \
--header 'Accept: application/json'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
{
"values": [
{
"id": "4292c912-12ac-4ac0-b195-9484fbb98c5c",
"name": "My Primary Routing Rule",
"isDefault": "true",
"criteria": {
"type": "match-any-condition",
"conditions": [
{
"field": "message",
"operation": "matches",
"expectedValue": "my critical alert"
}
]
},
"timezone": "Europe/Istanbul",
"timeRestriction": {
"type": "weekday-and-time-of-day",
"restrictions": [
{
"startDay": "monday",
"endDay": "friday",
"startHour": 13,
"endHour": 18,
"startMin": 0,
"endMin": 0
}
]
},
"order": 0,
"notify": {
"id": "d2acfc54-a145-451e-a963-ffbc089baea1",
"type": "escalation"
}
}
],
"links": {
"next": "/v1/teams/77b933c9-92bb-46e7-a73c-764b8d7c3c25/routing-rules?offset=10&size=5"
}
}
Creates a routing rule with the given properties.
read:ops-config:jira-service-management
write:ops-config:jira-service-management
string
Requiredstring
integer
oneOf [RoutingRulesMatchAllAnyConditionsFilter, RoutingRulesMatchAllFilter]
oneOf [RoutingRulesTimeOfDayTimeRestrictionInterval, RoutingRulesWeekdayTimeRestrictionInterval]
Notify
Requiredstring
Returned if the request is successful.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
curl --request POST \
--url 'https://api.atlassian.com/jsm/ops/api/{cloudId}/v1/teams/{teamId}/routing-rules' \
--user 'email@example.com:<api_token>' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"name": "My Empty Rule",
"order": 1,
"criteria": {
"type": "match-all"
},
"notify": {
"type": "none"
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
{
"id": "4292c912-12ac-4ac0-b195-9484fbb98c5c",
"name": "My Primary Routing Rule",
"isDefault": "true",
"criteria": {
"type": "match-any-condition",
"conditions": [
{
"field": "message",
"operation": "matches",
"expectedValue": "my critical alert"
}
]
},
"timezone": "Europe/Istanbul",
"timeRestriction": {
"type": "weekday-and-time-of-day",
"restrictions": [
{
"startDay": "monday",
"endDay": "friday",
"startHour": 13,
"endHour": 18,
"startMin": 0,
"endMin": 0
}
]
},
"order": 0,
"notify": {
"id": "d2acfc54-a145-451e-a963-ffbc089baea1",
"type": "escalation"
}
}
Gets a routing rule with given id in the request.
read:ops-config:jira-service-management
string
Requiredstring
RequiredReturned if the request is successful.
1
2
3
4
curl --request GET \
--url 'https://api.atlassian.com/jsm/ops/api/{cloudId}/v1/teams/{teamId}/routing-rules/{id}' \
--user 'email@example.com:<api_token>' \
--header 'Accept: application/json'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
{
"id": "4292c912-12ac-4ac0-b195-9484fbb98c5c",
"name": "My Primary Routing Rule",
"isDefault": "true",
"criteria": {
"type": "match-any-condition",
"conditions": [
{
"field": "message",
"operation": "matches",
"expectedValue": "my critical alert"
}
]
},
"timezone": "Europe/Istanbul",
"timeRestriction": {
"type": "weekday-and-time-of-day",
"restrictions": [
{
"startDay": "monday",
"endDay": "friday",
"startHour": 13,
"endHour": 18,
"startMin": 0,
"endMin": 0
}
]
},
"order": 0,
"notify": {
"id": "d2acfc54-a145-451e-a963-ffbc089baea1",
"type": "escalation"
}
}
Deletes a routing rule with given id in the request.
read:ops-config:jira-service-management
delete:ops-config:jira-service-management
string
Requiredstring
RequiredReturned if the request is successful.
1
2
3
curl --request DELETE \
--url 'https://api.atlassian.com/jsm/ops/api/{cloudId}/v1/teams/{teamId}/routing-rules/{id}' \
--user 'email@example.com:<api_token>'
Updates a routing rule with given id in the request.
read:ops-config:jira-service-management
write:ops-config:jira-service-management
string
Requiredstring
Requiredstring
integer
oneOf [RoutingRulesMatchAllAnyConditionsFilter, RoutingRulesMatchAllFilter]
oneOf [RoutingRulesTimeOfDayTimeRestrictionInterval, RoutingRulesWeekdayTimeRestrictionInterval]
Notify
string
Returned if the request is successful.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
curl --request PATCH \
--url 'https://api.atlassian.com/jsm/ops/api/{cloudId}/v1/teams/{teamId}/routing-rules/{id}' \
--user 'email@example.com:<api_token>' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"name": "My Empty Rule",
"order": 1,
"criteria": {
"type": "match-all"
},
"notify": {
"type": "none"
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
{
"id": "4292c912-12ac-4ac0-b195-9484fbb98c5c",
"name": "My Primary Routing Rule",
"isDefault": "true",
"criteria": {
"type": "match-any-condition",
"conditions": [
{
"field": "message",
"operation": "matches",
"expectedValue": "my critical alert"
}
]
},
"timezone": "Europe/Istanbul",
"timeRestriction": {
"type": "weekday-and-time-of-day",
"restrictions": [
{
"startDay": "monday",
"endDay": "friday",
"startHour": 13,
"endHour": 18,
"startMin": 0,
"endMin": 0
}
]
},
"order": 0,
"notify": {
"id": "d2acfc54-a145-451e-a963-ffbc089baea1",
"type": "escalation"
}
}
Changes routing rule's order with given id in the request.
read:ops-config:jira-service-management
write:ops-config:jira-service-management
string
Requiredstring
Requiredinteger
RequiredReturned if the request is successful.
1
2
3
4
5
6
7
curl --request PATCH \
--url 'https://api.atlassian.com/jsm/ops/api/{cloudId}/v1/teams/{teamId}/routing-rules/{id}/change-order' \
--user 'email@example.com:<api_token>' \
--header 'Content-Type: application/json' \
--data '{
"order": 2154
}'
Rate this page: