How to find out which Jira instance triggered a webhook

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Summary

In environments with multiple Jira instances triggering webhooks on a target system, it's important to know which one has triggered the webhook.

Solution

The payload sent by Jira doesn't include a base URL attribute. However, it does include the actual base URL in each and  every self attribute value in the JSON. 

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 "issue": { "id": "10009", "self": "http://localhost:41313/j81313/rest/api/2/issue/10009", "key": "SCRUMMY-10", "fields": { "issuetype": { "self": "http://localhost:41313/j81313/rest/api/2/issuetype/10001", "id": "10001", "description": "Created by Jira Software - do not edit or delete. Issue type for a user story.", "iconUrl": "http://localhost:41313/j81313/images/icons/issuetypes/story.svg", "name": "Story", "subtask": false }, "timespent": null, "project": { "self": "http://localhost:41313/j81313/rest/api/2/project/10000",

In any self attribute, the string that comes before /rest is the base URL. 

Updated on February 25, 2025

Still need help?

The Atlassian Community is here for you.