where to find REST service Url in JIRA?

Senthilvedhan August 4, 2016

To integrate JIRA and jenkins, it requires JIRA Rest API URL to update relevant issue workflow from Jenkins build.

This URL is required to be configured in Jenkins, under JIRA Issue updated section.

If i configure - rest/api/issue/latest/DP1-1 url getting below error.

unable to connect to REST service.

 

 

2 answers

0 votes
Senthilvedhan August 5, 2016

 

Hi Cody,

we have configured the provided url in the jenkins and tried a test build but still we get below error.

Error:

 JIRA Update Build Step ------------------------------------------------------- Unable to connect to REST service java.io.IOException: Server returned HTTP response code: 400 for URL: http://hostname/rest/api/2/search?jqlArchiving artifacts Finished: SUCCESS

Attached the jenkins configuration screenshot for reference

configure.png

Thanks

 

0 votes
105349
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 4, 2016

Hello!

Try this URL:

http://yourjirainstance:9055/rest/api/2/

And if I remember correctly, in Jenkins you then provide it with a JQL query to find the relevant issues to update.

Good luck!

 

Senthilvedhan August 5, 2016

Hi Cody,

we have configured the provided url in the jenkins and tried a test build but still we get below error.

Error:

 JIRA Update Build Step ------------------------------------------------------- Unable to connect to REST service java.io.IOException: Server returned HTTP response code: 400 for URL: http://hostname/rest/api/2/search?jqlArchiving artifacts Finished: SUCCESS

Attached the jenkins configuration screenshot for reference

configure.png

105349
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 5, 2016

In the screenshot I see that you don't have the port explicitly set after the hostname.  Just want to make sure that you have that actually set in your environment.

Also, are you going over SSL?  Be sure to modify your URL to https if you are.

One more thing; what version of JIRA are you on?  If it's an older version, make sure that you have Allow Remote API Calls enabled under Administration -> General Configuration.

 

Like Venkatesh Kundelu likes this

Suggest an answer

Log in or Sign up to answer