We have created a service account with a scoped API token to fetch JIRA issues (including service management issues). We are able to fetch the issues, but still get the following error for fetching SLA custom fields (time to resolution/time to first response):
You do not have permission to fetch the list of SLA custom fields"
taken steps:
any idea on how we can manage to get the correct permissions to fetch data from these fields?
Hi @Ruud Bakker ,
Could you elaborate on what api endpoint you are using and the exact error message?
I would guess that you are perhaps missing a scope on the API token, however that would normally be specifically indicated in the error.
JSM request access
https://api.atlassian.com/ex/jira/xxxxxxxxxxxxx/rest/servicedeskapi/request/xxxxxxx
STATUS: 403
{ "errorMessage": "You do not have permission to view this request.",
"i18nErrorMessage": {
"i18nKey": "sd.request.view.error.no.permission",
"parameters": []
}
}
Jira issue field access
https://api.atlassian.com/ex/jira/xxxxxxxx/rest/api/3/issue/xxxxxx
PARAMS: {'fields': 'summary,customfield_10036,customfield_10037'}
STATUS: 200
{
"expand": "renderedFields,names,schema,operations,editmeta,changelog,versionedRepresentations",
"id": "xxxxx",
"self": "https://api.atlassian.com/ex/jira/xxxxxxxxxx/rest/api/3/issue/xxxxx",
"key": "xxxxxx",
"fields": {
"summary": "xxxxxxxx",
"customfield_10036": {
"errorMessage": "You do not have permission to fetch the list of SLA custom fields",
"i18nErrorMessage": {
"i18nKey": "sd.sla.field.service.permission.error.fetch",
"parameters": [] } },it should not be a problem with the scopes of the API token, as i have created a personal token with the same scopes as the token for the service account and i was able to get a valid response with that.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.