Hi Atlassian Jira Community Developers,
I am working on a ServiceNow Jira integration and I am using the Jira spoke to achieve the integration. The integration is working is working as expected, I am able to create a Jira issue from a ServiceNow incident. When the issue is created, Jira returns an issue id to ServiceNow which I am using to update the correlation id field in ServiceNow. The issue id that gets returned is a number like this one - 477825.
The problem I am running into though is I can't take this number and go to Jira and be able to tell which Jira issue this number belongs to. So basically, this number becomes useless to me because I am unable to use it in Jira and be able to say this is the issue that I created. Would you please advise if there is a way to search for a Jira issue using the issue id and be able to see the issue that has that issue id?
Thanks,
Johannes
It's not pretty, but you can manually construct a URL using the issue id, and use the Jira REST API to look up the issue key.
In Jira Data Center or Server, it would look like this:
https://jira.COMPANY.com/rest/api/latest/issue/477825?fields=key
In Jira Cloud I believe the URL would look like this:
https://COMPANY.atlassian.net/rest/api/latest/issue/477825?fields=key
Replace COMPANY to make the domain part of the URL match what you see in your browser when you're in Jira.
The response will be some ugly JSON, but the Jira key for the issue will be at the end:
{"expand":"renderedFields,names,schema,operations,editmeta,changelog,versionedRepresentations","id":"466239","self":"https://jira.COMPANY.com/rest/api/2/issue/477825","key":"ABC-1234"}
There is a way in ServiceNow to show the Jira Key instead if the ID. I don't know how, but I do know that our ServiceNow team did it, so that it shows in the Activity log:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.