Set JSM Forms cascading select field values via API in Jira Cloud
Platform Notice: Cloud Only - This article only applies to Atlassian apps on the cloud platform.
Summary
This article explains how to set values for a parent/child cascading select custom field using the Jira Service Management Cloud API when working with Forms (formerly Pro Forma).
Solution
To set a cascading select custom field (parent/child) via the Jira Service Management API when using Forms, follow these steps:
1. Identify the correct option IDs
Each option in a cascading select field has a unique ID for both the parent and child options.
You can find these IDs by:
Viewing the URL when selecting options in the Jira Service Management UI under Context and Values for the custom field.
Using the Issue custom field options REST API to retrieve available options and their IDs.
2. Use the correct API payload format
When creating a request via the /rest/servicedeskapi/request endpoint, include the cascading field in the form.answers object. The value should be a string in the format <parentOptionId>:<childOptionId> inside a choices array.
Example payload:
{
"serviceDeskId": "<serviceDeskId>",
"requestTypeId": "<requestTypeId>",
"requestFieldValues": {
"summary": "Example summary",
"description": "Example description"
},
"form": {
"answers": {
"<questionId>": {
"choices": [
"<parentOptionId>:<childOptionId>"
]
}
}
}
} Replace <questionId> with the ID of the form question mapped to your cascading field.
Replace <parentOptionId> and <childOptionId> with the actual option IDs for your parent and child selections.
Additional notes
To know the correct syntax needed to access/edit any Jira Service Management Form fields, follow the steps presented to Access forms data with the Forms API in Jira Cloud
The cascading field must be linked to the request type’s screen to be set via the API.
Troubleshoot 400 errors by verifying:
The question ID matches the form mapping for the cascading field.
The option IDs are correct and correspond to the parent and child options.
The field is available on the create screen for the request type.
Was this helpful?