You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.
View groupJoin the community to find out what other Atlassian users are discussing, debating and creating.
Dear Community,
I would like to update an existing issue. I use following REST Call:
curl -u admin:admin -s -X PUT --data '{"fields":{"fixVersions":[{"version":"1.8.0"}]}}' -H 'Content-Type: application/json' https://jira/rest/api/2/issue/ISSUE-1
The response is empty. What am I doing wrong?
Thanks
Darius
Try this:
curl -D- -u admin:admin -X PUT --data '{"update":{"fixVersions":[{"set": [ {"name":"1.8.0"} ] }]}}' -H "Content-Type: application/json" https://jira/rest/api/2/issue/ISSUE-1
I am sorry, but this call is not working.
{"errorMessages":["Can not deserialize instance of java.util.ArrayList out of START_OBJECT token\\n at [Source: org.apache.catalina.connector.CoyoteInputStream@3956ce; line: 1, column: 12] (through reference chain: com.atlassian.jira.rest.v2.issue.IssueUpdateBean[\\"update\\"])"]}
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.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This works for me. However, it overwrote the existing values. What option to use for appending the new value instead?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The JSON needs to be like this:
let JiraClient = require("jira-connector");
let labels = ["label1", "label2", "label3", "label4"];
let jiraIssueLabels = [];
let fixVersionsLabels = [ {"add" : {"name" : "release_TEST"}} ];
labels.forEach(label => jiraIssueLabels.push({"add": label}));
let bodyData = { issueId: `ENG-224`,
issue: {
update: {
labels: jiraIssueLabels,
fixVersions: fixVersionsLabels
}
}
};
jira.issue.editIssue(bodyData);
More simply:
{
issueId: `ENG-224`,
issue: {
update: {
fixVersions: [ {"add" : {"name" : "release_TEST"}} ]
}
}
}
Note: the fixVersions value (ex: release_TEST) must already exist in Jira to work
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.