It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

c# REST API - Updating Issue not work


i'm trying to edit an issue (status,summary,ecc..) from my website.

the url i'm trying to consume this API (Jira API i found at this link:




but the response return 405 (Method Not Allowed)


Here the code i written:


var obj = new UpdateViewModel { update = new UpdateTicketViewModel { summary = new List<UpdateSummary>() } };
obj.update.summary.Add(new UpdateSummary { set = model.Summary });
var httpWebRequest = (HttpWebRequest)WebRequest.Create(url);
httpWebRequest.Headers.Add("Authorization", $"Basic {Base64Encode(decrypted)}");
httpWebRequest.Headers.Add("Accept-Language", "en-US");
httpWebRequest.ContentType = "application/json";
httpWebRequest.Method = "PUT";
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12 | SecurityProtocolType.Tls11 | SecurityProtocolType.Tls;

using (var streamWriter = new StreamWriter(httpWebRequest.GetRequestStream()))
json = JsonConvert.SerializeObject(obj);

var httpResponse = (HttpWebResponse)httpWebRequest.GetResponse();
using (var streamReader = new StreamReader(httpResponse.GetResponseStream()))
var result = streamReader.ReadToEnd();


Here the JSON i'm trying to post.

{"update":{"summary":[{"set":"TEST ANDREA"}]}}

Anyone can help me?




1 answer

1 accepted

Hi Andrea - The doc you pointed to is for Atlassian apps (add-ons).  Here's the (very similar) call to edit an issue from an external source:

curl --request PUT \
--url '/rest/api/3/issue/{issueIdOrKey}' \
--user '<api_token>' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data '{
"fields": {
"summary": "Completed orders still displaying in pending"


Thanks for the report. Now i'm trying to change the status of an issue but it not work.

This is the JSON i'm trying to post:

"summary":"TEST ANDREA 2"
"transition" : {"id" : "1001"}


The code i receive is 204 No Content. The summary changes but not the status.

Can i edit it by REST API or not?



Suggest an answer

Log in or Sign up to answer

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you