Skip to main content
DELETE
Unassign Number from Trunk
Use this endpoint to remove the assignment between a phone number and a SIP trunk. After unassignment, the number remains in your account inventory but no longer routes calls through the previously assigned trunk.
Authentication required:
  • X-Auth-ID - Your account Auth ID
  • X-Auth-Token - Your account Auth Token
  • Content-Type: application/json
Warning: Unassigning a number from a trunk immediately stops routing inbound calls to that number. Ensure you have an alternative routing configuration, or reassign the number to a different trunk if you want to continue receiving calls.
URL Encoding Notice: Always encode the phone number in the URL. Use %2B instead of the + symbol. For example: %2B912271264217 (not +912271264217). Failure to encode properly may result in a 404 error.
Note: This endpoint uses the DELETE HTTP method on the same URL path as the assignment endpoint. No request body is required.

URL Parameters

No Request Body Required: The DELETE method does not require a request body. The phone number specified in the URL will be unassigned from its currently associated trunk.

Examples

Response

On successful unassignment, the API returns 204 No Content with no response body.
Success Response - 204 No Content

Verifying the Unassignment

After unassignment, you can confirm the change by listing numbers (the trunk_group_id will be absent) and by retrieving the trunk to confirm it no longer references this number.
Number after unassign (from list-numbers)
Trunk after unassign (from retrieve-trunk)

Error Responses

Error Response - 404 Not Found (Invalid Phone Number)
Error Response - 400 Bad Request (Invalid Format)
Quick Tips:
  • Success Code: Look for 204 No Content response
  • URL Encoding: Always use %2B instead of + in the phone number
  • No Request Body: DELETE requests do not require a request body
  • Number Format: Use E.164 format with country code (e.g., +1234567890)
Important Considerations:
  • Immediate Effect: Unassignment takes effect immediately; inbound calls will no longer route
  • Number Retention: The number remains in your account inventory after unassignment
  • Reassignment: You can reassign the number to a different trunk or the same trunk later
  • Billing: Number rental charges continue until you release the number using the Unrent Number endpoint
Next Steps:
  • Reassign to a different trunk using the Assign Number endpoint
  • Or, release the number entirely using the Unrent Number endpoint
  • Verify the unassignment by listing your trunk details
  • Update your application logic to handle the routing change

Authorizations

X-Auth-ID
string
header
required

Your Vobiz account Auth ID

X-Auth-Token
string
header
required

Your Vobiz account Auth Token

Path Parameters

auth_id
string
required

Your account Auth ID

Example:

"MA_XXXXXX"

phone_number
string
required

The phone number to unassign, URL-encoded (use %2B instead of +).

Example:

"%2B912271264217"

Response

Number unassigned