I´m calling JIRA REST API from JavaScript in a Confluence User Macro and I´m facing CORS issues because JIRA and Confluence are on two different domains and preflight request . I have tried several CORS solutions as described below, without any success. So Im begging for some input from others that probably have solved this issue.
AJS.$.ajax({ type: "GET", url: "http://jira.mydomain.com/rest/api/latest/search/?jql=issue%20in%20linkedIssues(SR-45)", dataType: "json", contentType: "application/json", async: false })
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at http://jira.mydomain.com/rest/api/latest/search/?jql=issue%20in%20linkedIssues(SR-45). This can be fixed by moving the resource to the same domain or enabling CORS.
Access-Control-Allow-Headers:origin, content-type, accept
Access-Control-Allow-Methods:POST, GET, OPTIONS
Access-Control-Allow-Origin:*
Access-Control-Allow-Origin:*
ismar.slomic$ curl -X OPTIONS "http://jira.mydomain.com/rest/api/latest/search/?jql=issue in issueLink(SR-55)" -v * Trying 10.107.1.24... * Connected to jira.mydomain.com (127.0.0.1) port 80 (#0) > OPTIONS /rest/api/latest/search/?jql=issue in issueLink(SR-55) HTTP/1.1 > Host: jira.mydomain.com > User-Agent: curl/7.43.0 > Accept: */* > * Empty reply from server * Connection #0 to host jira.mydomain.com left intact curl: (52) Empty reply from server
This seems to be positive response.
OPTIONS http://jira.mydomain.com/rest/api/latest/search/?jql=issue in issueLink(SR-55)
Response error: Could not get any response. This seems to be like an error connecting to http://jira.mydomain.com/rest/api/latest/search/?jql=issue in issueLink(SR-55)
Hi Paul,
Our dev team is currently working on to improve this process. Today, HipChat integration with JIRA is only allowed when a transition happens on the issue. All the HipChat integration is done via workflow post-functions.
Cheers!
Thanks, Elisa. Any idea on what the timeframe is (6 months, year)? I just want to know how much effort to put in the workaround.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We don't have an ETA yet.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.