Jira 6.0 REST API updating Issue fields

GG
Contributor
May 19, 2018

Hi,

 

Is there any API for update approvers field from other system? I need set approvers fields from another system from API.

 

Regards

Hamid

1 answer

1 accepted

0 votes
Answer accepted
Maarten Cautreels
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.
May 20, 2018

Hi Hamid,

It took a while but I just found the time to give it a try on my test instance. The approvers of an issue are stored in a custom field thus updating that custom field would be the solution.

I was able to update the field by executing the following API call;

PUT /rest/api/latest/issue/ISSUEKEY-1
{
"fields": {
"customfield_10206": [
{
"name":"mcautreels"
},{
"name":"shane.soukup"
}
]
}
}

BUT there's one important thing to make sure. The customfield ID (in my case: 10206) can be different on each instance.

Finding the right id can be done following the knowledge base article: How to find id for custom field(s)?

Hope this helps,

Maarten

Suggest an answer

Log in or Sign up to answer