Opsgenie integration with JIRA Service Management (Server)
Asked by Eswara Prasad:

When a comment is added to the issue in JIRA Service Management, it is reflecting in Opsgenie. However, when the comment/notes added in Opsgenie, it is not reflecting on the issue in JIRA Service Management.

Please help me how to fix this issue.

Thank you!


Answers:
author: Samir
body: Hi [@Eswara Prasad](/t5/user/viewprofilepage/user-id/4515099) ,

Is your JSM integration setup to add a comment to the issue in JSM when a note is added to the alert in Opsgenie?

e.g.

![2021-08-13_15-29-34.png](https://community.atlassian.com/t5/image/serverpage/image-id/155932i09CA7617146F0171/image-size/large?v=v2&px=999 "2021-08-13_15-29-34.png")

If so - does the activity log in the alert in Opsgenie show an error when it tries to add the comment to the issue in JSM?

This can help us determine what exactly the issue is. If your JSM Server instance is not accessible over the internet, then you either have to A) open up firewall access to allow Opsgenie to send requests to the JSM instance, or B) [setup the JSM Opsgenie integration via OEC](https://support.atlassian.com/opsgenie/docs/integrate-opsgenie-with-jira-service-management/#Integration-via-OEC--for-On-Premise-Jira-Service-Management-Usage-)

This may be easier to troubleshoot via a support ticket, you can reach out to us in Opsgenie support via support.atlassian.com

Thanks,

Samir

comments: author: Eswara Prasad
body: Hi Samir

Hi,

Is your JSM integration setup to add a comment to the issue in JSM when a note is added to the alert in Opsgenie? - Yes

![Opsgenie.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/156188i99B0BF1F507CE65B/image-size/large?v=v2&px=999 "Opsgenie.jpg")

Error message in the activity log says:

Could not send \[addComment\] action to JiraServiceDesk \[Beaumont_Test_Users_Jira Service Management\]. Reason: 403 : \[{"errorMessages":\["You do not have the permission to see the specified issue."\],"errors":{}}\]


author: Samir
body: Hi [@Eswara Prasad](/t5/user/viewprofilepage/user-id/4515099) ,

403 permission errors are generally related to the user who you input in to the integration in Opsgenie...

e.g

.![2021-08-16_15-01-00.png](https://community.atlassian.com/t5/image/serverpage/image-id/156190i8CE455732E567D80/image-size/large?v=v2&px=999 "2021-08-16_15-01-00.png")

You will want to ensure you used the email address of the user who you want Opsgenie to create/update the issues in JSM as.

In this example, I used my email there. You will also want to [Create an API token for that user in Jira](https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/), and use that API token in the password/API token field.

Lastly, you will want to ensure the user whose credentials you're using in the integration, has permissions to create/update issues of that specific issue-type in that specific project.

In this example, the user with email samir.kafel@opsgenie.com will need to have permissions to create/update issues of the "Task" issue-type in the "JSM" project in that JSM instance. I can verify this by logging into JSM in the browser with that user's credentials, and ensure they are able to create/update the issues there.

If you have confirmed all of the above and are still running into issues, I would recommend reaching out to support via support.atlassian.com so we can assist you further!

Thanks,

Samir


author: Eswara Prasad
body: Hi Samir,

I am the admin and I have complete permissions for the project that was integrated with Opsgenie.

Added new comment now and Activity log in Opsgenie is not showing any error.

I am receiving email notifications when the note was added in Opsgenie, however, that note is not reflecting on the issue in JSM.


author: Samir
body: Okay - please reach out to Opsgenie support via support.atlassian.com so we can further troubleshoot why the comments are not being added.

Thanks,

Samir


author: Elzha Odie
body: hi team, i have an issue like i dont have any permission to see the comment. i have changed my username and password/token API but still cant change.. please let me know if there is any solution, fyi i also have tried the solution above. thankyou


author: Elzha Odie
body: ![Screenshot_2.png](https://community.atlassian.com/t5/image/serverpage/image-id/271676i6852A03E43EBC7D6/image-size/large?v=v2&px=999 "Screenshot_2.png")


Tags: cloud