PUT call get a 400 response back

I am trying to Archive a ProjectVersion programmatically using the following rest api:

http://jira/rest/api/2/version/10074

the payload I send in this put call is following: {"Id":"10074","archived":true}

However, I am receiving a "400 Bad Request" response back from the Jira server.

a get call to the same URL listed above downloads the following content:

{"self":"http://jira/rest/api/2/version/10074","id":"10074","name":"AAPT_221_CP11","archived":false,"released":true,"releaseDate":"2009-02-04","userReleaseDate":"Feb 04 2009"}

Any idea what I am doing wrong in the payload here?

Thanks.

1 answer

Additional info: I did a GET then updated just the boolean field and PUT the string back, and still received the same 400 Error. So this time there should be no malform in my message. What else am I missing?

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Julia Dillon
Posted Tuesday in Jira

Tell us how your team runs on Jira!

Hey Atlassian Community! Today we are launching a bunch of customer stories about the amazing work teams, like Dropbox and Twilio, are doing with Jira. You can check out the stories here. The thi...

147 views 1 17
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you