Lists in custom Webhook body

Fredrik Ivansson Flinta December 23, 2021

Hi,

 

I need some help to get lists (multi-select, checkboxes etc) in my custom webhook body using Automation For Jira using smartvalues.

 

I can get the values using smart values: {{issue.customfield_00000.value}}

Now I would like to use those values to format a body where I shall POST the data to another Jira instance.

Like: 

{

"fields": {

"customfield_11111": "{{issue.customfield_00000.value}}"..............

 

Hope my question is pretty clear at least ;)

 

Thanks in advance!

1 answer

1 accepted

0 votes
Answer accepted
Bill Sheboy
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.
December 23, 2021

Hi @Fredrik Ivansson Flinta 

I recommend reviewing this documentation page and its examples for how to format the JSON for the different Jira field types: https://support.atlassian.com/cloud-automation/docs/advanced-field-editing-using-json/

To confirm your source and target data, also consider looking over this how-to article which describes finding your smart values and their structure in the JSON: https://support.atlassian.com/cloud-automation/docs/find-the-smart-value-for-a-field/

Kind regards,
Bill

Fredrik Ivansson Flinta December 26, 2021

Thanks @Bill Sheboy 

Managed to solve it by:

"customfield_TARGETID": {{issue.customfield_FROMID.asJsonObjectArray("value")}}

Like Bill Sheboy likes this

Suggest an answer

Log in or Sign up to answer