Actions
Update scenario
Update a Callr Actions scenario. You may send a partial object.
patch/actions/{sid}
Request
- Base URLhttps://api.callr.com/v2.0
- URLhttps://api.callr.com/v2.0/actions/{sid}
- Auth
- API key in header x-api-key
- or HTTP basic
Path parameters
sidstring required
Short ID
Example:callrsid
Resource SID (8 lowercase alphanumeric characters)
Request body
Example request
{
"name": "Call Forwarding",
"script": "compat:\n version: '2025-09-01'\nbranches:\n inbound-call:\n actions:\n - action: gather@v4\n params:\n maxDigits: 1\n tts:\n text: Welcome to Callr. Press 1 for sales, or 2 for support.\n result: $choice\n - if: \"$choice.input == '1'\"\n goto:\n branch: sales\n - action: dial@v2\n params:\n targets:\n - number: '+33199004242'\n timeout: 30\n result: $dial\n sales:\n actions:\n - action: dial@v2\n params:\n targets:\n - number: '+33199004243'\n timeout: 30\n result: $dial\n",
"format": "yaml"
}Response
The updated actions scenario
Example response
{
"name": "Call Forwarding",
"script": "compat:\n version: '2025-09-01'\nbranches:\n inbound-call:\n actions:\n - action: gather@v4\n params:\n maxDigits: 1\n tts:\n text: Welcome to Callr. Press 1 for sales, or 2 for support.\n result: $choice\n - if: \"$choice.input == '1'\"\n goto:\n branch: sales\n - action: dial@v2\n params:\n targets:\n - number: '+33199004242'\n timeout: 30\n result: $dial\n sales:\n actions:\n - action: dial@v2\n params:\n targets:\n - number: '+33199004243'\n timeout: 30\n result: $dial\n",
"format": "yaml",
"sid": "callrsid",
"numbers": [
{
"e164": "+33199001234",
"class": "classic",
"type": "geographic",
"assigned": "2024-04-24T17:42:28Z",
"country": "FR"
}
],
"version": "1.0",
"created": "2024-04-24T17:42:28Z",
"updated": "2024-04-24T17:42:28Z"
}Changes
No recorded changes to this operation across all 2 revisions of this API.