Skip to main content
DELETE
/
api
/
v2
/
platform
/
telephony
/
bridges
/
{slug}
Delete Bridge
curl --request DELETE \
  --url http://localhost:3001/api/v2/platform/telephony/bridges/{slug}/ \
  --header 'Authorization: <api-key>' \
  --header 'Org-Handle: <org-handle>'
HTTP/1.1 204 No Content
HTTP/1.1 204 No Content

Delete Bridge

Permanently delete a telephony bridge by its slug. Once deleted, the bridge and all associated configurations are removed. This action cannot be undone.
Prerequisites: Make sure you have your API Token and Org-Handle ready. See Authentication for details.
Deleting a bridge that has active phone numbers or is actively routing calls will disrupt service. Disconnect all providers and reassign numbers before deleting.

Path Parameters

NameTypeRequiredDescription
slugstringYesUnique bridge slug
You can get the bridge slug by hitting the Get All Bridges API. The slug field in the response is your Bridge Slug.

Headers

NameTypeRequiredDescription
AuthorizationstringYesAPI Key format: Token <token>
Org-HandlestringYesOrganization domain handle

Common Error Codes

Status CodeDescription
204No Content - Bridge deleted successfully
401Unauthorized - Invalid or missing API token
403Forbidden - Invalid organization handle
404Not Found - Bridge not found
500Internal Server Error - Server-side error

Code Examples

const axios = require('axios');

const headers = {
  'Authorization': 'Token your-api-token',
  'Org-Handle': 'your-org-handle'
};

// Delete a bridge
const deleteBridge = async (slug) => {
  await axios.delete(
    `https://unpod.dev/api/v2/platform/telephony/bridges/${slug}/`,
    { headers }
  );
  console.log(`Bridge '${slug}' deleted successfully`);
};

// Example usage
deleteBridge('sales-bridge-001');

Best Practices

  1. Disconnect First: Always disconnect the provider from the bridge before deleting it
  2. Irreversible: Deletion is permanent — verify the correct slug before proceeding
  3. 204 Response: A successful delete returns HTTP 204 with no body — handle this in your code
  4. Error Handling: Handle 404 gracefully — the bridge may have already been deleted
  5. Pre-check: Use Get Bridge by Slug to verify the bridge exists and check for active numbers before deletion
  6. Security: Keep API tokens secure and rotate them regularly

Authorizations

Authorization
string
header
required

Format: Token

Headers

Org-Handle
string
required

Organization domain handle

Example:

"unpod"

Path Parameters

slug
string
required
Example:

"sales-bridge"

Response

Bridge deleted