Skip to main content

Update App

Update an existing SFVoPI application's configuration. All fields are optional — only include the fields you want to change.

Authentication Required

Requires X-API-Key header. See Authentication for details.

HTTP Request​

PUT /sfvopi/apps/:app_id

Path Parameters​

ParameterTypeRequiredDescription
app_idstringYesUnique app identifier (format: sfv_app_xxxxxxxxxxxx)

Request Body​

All fields are optional. Only include the fields you want to update.

FieldTypeRequiredDescriptionValidation
namestringNoHuman-readable name for the app1-100 characters
answer_urlstringNoWebhook URL called when a call is answeredValid URL
answer_methodstringNoHTTP method for answer webhookPOST or GET
hangup_urlstring | nullNoWebhook URL called when a call endsValid URL, or null to remove
hangup_methodstringNoHTTP method for hangup webhookPOST or GET
fallback_answer_urlstring | nullNoFallback URL if answer_url failsValid URL, or null to remove
fallback_answer_methodstringNoHTTP method for fallback webhookPOST or GET
statusstringNoApp statusACTIVE or INACTIVE
concurrent_limitinteger | nullNoThe app's own limit on calls in progress at once. Send null to remove itPositive integer or null. Cannot exceed your organization's limit
cps_limitinteger | nullNoThe app's own limit on new calls per second. Send null to remove itPositive integer or null. Cannot exceed your organization's limit
cps_burstinteger | nullNoThe app's own peak CPS. Send null to remove itPositive integer or null. At least cps_limit when both are set. Cannot exceed your organization's limit
Org-limits release

App call limits ship with the org-limits release.

App call limits​

concurrent_limit, cps_limit and cps_burst let you cap one app below your organization's limits. Each is null by default, which means only the organization pool applies. Inbound and outbound calls count together. Read your organization's limits with Get Call Limits, and see Call Limits.

A value above your organization's limit is rejected with 400, for example cps_limit cannot exceed your organisation limit of 10.

Removing Optional URLs

To remove hangup_url or fallback_answer_url, set them to null in the request body:

{
"hangup_url": null,
"fallback_answer_url": null
}

Code Examples​

curl -X PUT https://prod-api.superfone.co.in/superfone/sfvopi/apps/sfv_app_abc123xyz456 \
-H "X-API-Key: your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"name": "Updated Voice App",
"answer_url": "https://new.example.com/webhook/answer",
"status": "ACTIVE"
}'

Success Response​

Status Code: 200 OK

{
"data": {
"app_id": "sfv_app_abc123xyz456",
"org_id": 12345,
"name": "Updated Voice App",
"answer_url": "https://new.example.com/webhook/answer",
"answer_method": "POST",
"hangup_url": "https://example.com/webhook/hangup",
"hangup_method": "POST",
"fallback_answer_url": null,
"fallback_answer_method": "POST",
"status": "ACTIVE",
"concurrent_limit": null,
"cps_limit": null,
"cps_burst": null,
"created_by": 67890,
"created_at": "2026-02-02T10:30:00.000Z",
"updated_at": "2026-02-02T15:45:00.000Z"
},
"message": "success"
}

Response Fields​

FieldTypeDescription
app_idstringUnique identifier for the app (format: sfv_app_xxxxxxxxxxxx)
org_idnumberOrganization ID that owns this app
namestringApp name
answer_urlstringWebhook URL for answered calls
answer_methodstringHTTP method for answer webhook (POST or GET)
hangup_urlstring | nullWebhook URL for call hangup events
hangup_methodstringHTTP method for hangup webhook
fallback_answer_urlstring | nullFallback webhook URL
fallback_answer_methodstringHTTP method for fallback webhook
statusstringApp status (ACTIVE or INACTIVE)
concurrent_limitnumber | nullThe app's own limit on calls in progress at once. null means only your organization's limit applies
cps_limitnumber | nullThe app's own limit on new calls per second. null means only your organization's limit applies
cps_burstnumber | nullThe app's own peak CPS. null means only your organization's limit applies
created_bynumber | nullUser ID who created the app
created_atstringISO 8601 timestamp of creation
updated_atstring | nullISO 8601 timestamp of last update

Error Responses​

Status CodeMessageWhen It Occurs
400Invalid request bodyRequest body fails validation (invalid URL format, name too long, invalid HTTP method, invalid status, a limit that is not a positive integer or null, cps_burst below cps_limit)
400<field> cannot exceed your organisation limit of <n>concurrent_limit, cps_limit or cps_burst is higher than your organization's limit. <n> is the organization's limit
404SFVoPI app not foundApp with the specified app_id does not exist or does not belong to your organization
401UnAuthorized, Please Provide Valid API KeyMissing or invalid X-API-Key header
500Failed to update SFVoPI app: {error}Server error during app update

Example Error Response​

{
"message": "SFVoPI app not found"
}

Use Cases​

Update Webhook URLs​

const appId = 'sfv_app_abc123xyz456';

const response = await fetch(`https://prod-api.superfone.co.in/superfone/sfvopi/apps/${appId}`, {
method: 'PUT',
headers: {
'X-API-Key': 'your_api_key_here',
'Content-Type': 'application/json'
},
body: JSON.stringify({
answer_url: 'https://new-server.example.com/webhook/answer',
hangup_url: 'https://new-server.example.com/webhook/hangup'
})
});

const result = await response.json();
console.log('Webhooks updated:', result.data);

Disable an App​

const appId = 'sfv_app_abc123xyz456';

const response = await fetch(`https://prod-api.superfone.co.in/superfone/sfvopi/apps/${appId}`, {
method: 'PUT',
headers: {
'X-API-Key': 'your_api_key_here',
'Content-Type': 'application/json'
},
body: JSON.stringify({
status: 'INACTIVE'
})
});

const result = await response.json();
console.log('App disabled:', result.data.status);

Remove Optional Webhooks​

const appId = 'sfv_app_abc123xyz456';

const response = await fetch(`https://prod-api.superfone.co.in/superfone/sfvopi/apps/${appId}`, {
method: 'PUT',
headers: {
'X-API-Key': 'your_api_key_here',
'Content-Type': 'application/json'
},
body: JSON.stringify({
hangup_url: null,
fallback_answer_url: null
})
});

const result = await response.json();
console.log('Optional webhooks removed');