Choices By URL Schema
Use choicesByUrl when a choice-based question should load choices from an external JSON endpoint.
Prefer static choices when options are known at design time. Use choicesByUrl only when the list must stay dynamic.
Minimal Shape
Section titled “Minimal Shape”{ "url": "https://example.com/api/departments", "valueName": "id", "titleName": "name"}Properties
Section titled “Properties”- Type:
string - Required: Yes
Endpoint that returns choice data.
valueName
Section titled “valueName”- Type:
string
Field name from each returned item to use as the stored choice value.
titleName
Section titled “titleName”- Type:
string
Field name from each returned item to use as the visible choice label.
- Type:
string
Path to the array inside the response object.
allowEmptyResponse
Section titled “allowEmptyResponse”- Type:
boolean
Allows the endpoint to return no choices without treating it as an error.
Example
Section titled “Example”{ "type": "dropdown", "name": "country", "title": "Country", "choicesByUrl": { "url": "https://example.com/countries.json", "path": "items", "valueName": "code", "titleName": "label" }}