Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Send web request with GET method

Sedrak Khachatryan
Contributor
September 16, 2021

Hi, I'm trying to send a web request with the "GET" method, but the response is 405. Here is the error:

Send web request
Error response HTTP body:
Error publishing web request. Response HTTP status:
405
can someone help solve this problem?
Screenshot 2021-09-16 150327.png



1 answer

1 accepted

2 votes
Answer accepted
Dirk Ronsmans
Community Champion
September 16, 2021

Hey @Sedrak Khachatryan ,

Are you really sending to that url?

I guess you wish to GET an issue?

Also your smartvalue seems wrong. instead of {{isse.key}} try {{issue.key}}

Sedrak Khachatryan
Contributor
September 16, 2021

Oh, thanks. I'm trying to get the issue.key and then I will use smart values to change time in the ticket fields which depends on the Status time changes.

Dirk Ronsmans
Community Champion
September 16, 2021

Unless I'm missing something that is not how this work.

With a GET you'll have to provide an issue key (which you can with the smart value) and then the GET call will return the details of this issue.

Get issue

GET /rest/api/2/issue/{issueIdOrKey}

Returns the details for an issue.

The issue is identified by its ID or key, however, if the identifier doesn't match an issue, a case-insensitive search and check for moved issues is performed. If a matching issue is found its details are returned, a 302 or other redirect is not returned. The issue key returned in the response is the key of the issue found.

If you don't have an issue key you'll first have to retrieve that some other way. (could be thru maybe a JQL call? https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-jql/#api-rest-api-2-jql-parse-post)

 

 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events