Martyn Houghton Posted October 17, 2019 Posted October 17, 2019 I am now looking to integrate to a JIRA Cloud instance as well as on premises, but have struck a problem with creating a test request as the integration process is failing, but the error in the logs is not given any indication of the why. I can create a request manually using the same credentials with only specifying the Summary, Description and Priority. I suspect the issue is the priority value but cannot be sure as there is not detailed error/response information being provided. Is there any additional logging we can check to help diagnose where it is failing? Cheers Martyn
HHH Posted October 17, 2019 Posted October 17, 2019 @Martyn Houghton What happens if you ignore the custom fields rather than set them blank? Also check in Jira what the actual ID for the priorities are
Martyn Houghton Posted October 17, 2019 Author Posted October 17, 2019 @HHH Good point on the custom fields. I give that a go. I struggling to identify the ID for the priorities as the /rest/api/2/issue/createmeta endpoint does not seem to list priorities. Cheers Martyn
Martyn Houghton Posted October 17, 2019 Author Posted October 17, 2019 Have set the custom fields to ignore but still getting a failure.
Martyn Houghton Posted October 17, 2019 Author Posted October 17, 2019 Now got the list of priority id using endpoint rest/api/2/priority and id value 1 is valid. There are only five of them P1 to P5 with id's of 1 to 5. I try setting reporter next to see if that helps. Cheers Martyn
Steve G Posted October 17, 2019 Posted October 17, 2019 Hi @Martyn Houghton, I've just given the Jira Cloud integration a whirl, and it's working ok with my account... The error you're getting would point to the API URL being broken though. In the key for Jira Cloud in Keysafe, it just needs the Jira instance ID, and not the full endpoint URL (which is what's needed by the Jira On-Prem integrations) - I don't suppose you've got the full URL in your key have you? Should look like this, where the Jira instance ID is hornbill: I did notice a minor issue with the Jira Cloud > Create Issue operation though, where the web URL returned for created issues is incorrect. I've fixed that and it'll be released shortly... Cheers, Steve
Martyn Houghton Posted October 18, 2019 Author Posted October 18, 2019 @Steve G Thanks for the advice, I had indeed got the full URL as we do for the on premise version, so will give a re-test now I have just the endpoint name. Cheers Martyn
Martyn Houghton Posted November 1, 2019 Author Posted November 1, 2019 @Steve G I finally got back to this after being tied up with an another service going live on Hornbill. I have correct the URL in the endpoint and trimmed down what I am trying to pass as a minimum, but still get an error returned in the UI. I am still struggling to determine where to locate the full error details in the logs, so that I can resolve this. Cheers Martyn
Martyn Houghton Posted November 1, 2019 Author Posted November 1, 2019 All I can see in the logs is 2019-11-01 09:33:52Z [DEBUG]:[SCRIPT]:[10260] iBridge Error message from payload response: { "errorType": "runtime", "errorMessage": "Jira Error: An unexpected reponse was returned by your Jira Cloud instance. HTTP Status: 401", "file": "main.js", "sourceLine": " throw \"Jira Error: \" + errors;", "lineNumber": 102, "columnStart": 4, "columnEnd": 5 } 2019-11-01 09:33:52Z [ERROR]:[SCRIPT]:[10260] iBridge MethodCall failure: iBridge Method: /Atlassian/Jira Cloud/Create Issue.m Error: Jira Error: An unexpected reponse was returned by your Jira Cloud instance. HTTP Status: 401
Martyn Houghton Posted November 1, 2019 Author Posted November 1, 2019 Through the UI using the same account, I am able to correct a JIRA case with the following minimum fields populated. Project Key, in this case TPI "id": "10700", "key": "TPI", "name": "Test Project - Ignore", Issue Type/Type Id, in this case 'Improvement' "id": "10900", "description": "An improvement or enhancement to an existing feature or task.", Priority, P1 "name": "P1", "id": "1" Summary - being inserted from flowcode Description - being inserted from flowcode Node is configured below, based on the above. API suggest a 400 response which would list missing fields, but not a 401. Keysafe is configured to just endpoint name given Cloud instance. Cheers Martyn
Martyn Houghton Posted November 1, 2019 Author Posted November 1, 2019 Okay I managed to get to the bottom of the issue which was down to an issue with our API token Cheers Martyn
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now