Hello, I am working on an automation within Jira to try and update a custom field.
The custom field does not appear in the drop-down box so I have to try and figure out the JSON, but I can't wrap my head around it.
My Googling leads me to think the below JSON is correct:
{
"fields": {
"customfield_10458": "My new value"
}
}
But it doesn't work and Jira reports this error when the rule is run:
Can not instantiate value of type [simple type, class com.atlassian.jira.issue.fields.rest.json.beans.CustomFieldOptionJsonBean] from JSON String; no single-String constructor/factory method (customfield_10458)
I have no idea what this means.
The custom field in question is a "Dependant dropdown", but I don't know if that is important or not.
I've been looking at this document plus a few other support tickets on here but haven't found a solution to my problem.
The custom field type here is a "Dependant dropdown". That's how it appears in the "Issue types" page in Jira.
In the document you mentioned it appears to be shown as a "Cascading select custom field".
This inconsistency probably explains why my searching was a bit fruitless.
After messing around with it a bit more I have landed on the JSON below which is working:
{
"fields": {
"customfield_10458": { "value": "My new value" }
}
}
Note: in this particular use case this particular "parent" has no associated "child" values (but other parents in the dropdown do).
Thanks for your help!
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.