Limitations
- This action is designed for Jira Cloud and does not support Jira Server or Jira Data Center deployments.
- If the Jira administrator is not granted a site-wide access to the Jira OAuth app, users may see an error that the site admin must authorize the app before it can access their account.
- Limited to one Jira Cloud instance per customer per Jira action pack configuration. To work with multiple instances, create a separate Jira action pack for each instance.
Prerequisites
- An admin must complete the initial Jira setup and enable Jira actions in the Admin Console so that the Jira action pack is available in Agent Builder.
- Each user is prompted to connect their Jira account via OAuth in Glean before running agents that use Jira actions, including Jira Add watcher to issue.
- If your Jira organization uses Central OAuth, a Jira administrator must authorize the app for the site before users can run Jira actions in Glean.
- Optional: For multiple Jira instances, set up a separate Jira action pack per instance and give each pack a clear name, for example, Jira Actions – Acme or Jira Actions – Sales so builders can select the right instance.
Supported parameters
The underlying action defines the following parameters for Jira Add watcher to issue.| Name | Type | Description |
|---|---|---|
| Issue ID or key | String | Identifier of the Jira issue to watch, such as an issue key like ENG-1234. |
| Account ID | String | Jira account ID of the user who should be added as a watcher on the issue. |
Usage example
You want to ensure that key stakeholders are notified about an important release ticket so they stay informed as it progresses. Instruction to an agent: “Add Sarah Chen and Mike Johnson from the product team as watchers on Jira issue REL-456 so they receive updates as the release progresses. Also add me as a watcher.” Resulting behavior:- Identifies the Jira issue REL-456.
- Resolves the user names to their Jira account IDs.
-
Calls the Add watcher to issue action multiple times with:
-
Issue ID or keyset to REL-456. -
Account IDset to Sarah Chen’s Jira account ID (first call). -
Account IDset to Mike Johnson’s Jira account ID (second call). -
Account IDset to the current user’s Jira account ID (third call).
-
- Adds all three users as watchers on the issue.
- Each watcher will now receive Jira notifications for any updates or changes to REL-456 according to the Jira notification scheme.
Troubleshooting
Your site admin must authorize this application for the site before the application can access your account
Your site admin must authorize this application for the site before the application can access your account
Tools return status code 404 or 500 for this tool
Tools return status code 404 or 500 for this tool
- Possible cause: The tools server backing this action is unreachable (404) or returning an internal error (500).
- Fix: Confirm that the server information of the action is correct and reachable from Glean. For 500 errors, the tool creator needs to fix the server or investigate the underlying exception.
Invalid redirect URI during Jira authentication
Invalid redirect URI during Jira authentication
- Possible cause: The verify_code URI for tools OAuth has not been added to the allowed redirect URIs for the Jira OAuth app.
- Fix: An admin must add https://your-glean-instance-be.glean.com/tools/oauth/verify_code/toolUniqueIdentifier to the allowed redirect URIs of OAuth application and retry authentication. The tool unique identifier is case-sensitive.
FAQs
How is Jira Add watcher to issue different from Get issue watchers or Remove watcher from issue?
How is Jira Add watcher to issue different from Get issue watchers or Remove watcher from issue?
Jira Add watcher to issue adds a user as a watcher on an issue, Jira Get issue watchers retrieves the current watchers list, and Jira Remove watcher from issue removes an existing watcher.