Create destination
Add a new inbound destination for a DID number.
Destination Types:
- SIP addresses (e.g., sip:user@domain.com)
- Phone numbers (e.g., 18005551234)
- Extensions (SIP accounts created within didlogic)
Parameters:
- destination - The forwarding target (SIP URI or phone number)
- dialing_type - Dialing mode: sequence, ring_all or random
- callhunt - Legacy two-state mirror of dialing_type (boolean); ignored when dialing_type is sent
- active - Enable/disable this destination (boolean)
- transport - Transport type code (1 = SIP URI, 4 = Phone number, 5 = SIP device, 10 = Webphone, 12 = WebSocket)
transport: 12 streams the call to a WebSocket endpoint of your own instead of ringing a phone or a SIP device, and destination is then its public wss:// URL. It is available only to accounts enabled for voice streaming; any other account is refused with 422. The endpoint has to speak our protocol — see WebSocket Calls.
did_destination.id feeds purchases_destinations_update and purchases_destinations_destroy as id. Rows: purchases_destinations_index.
Request
- Base URL: https://app.didlogic.com
- URL: https://app.didlogic.com/api/v1/purchases/{purchase_id}/destinations
- Auth: HTTP bearer
Path parameters
Purchased number id or number from numbers_index, purchases_index: the phone number (e.g. 43800327987) or the numeric inventory id (e.g. 21869). Both resolve the same DID.
Request body
Example request
{
"destination": {
"destination": "sip:test@example.com",
"active": true,
"transport": 1
}
}Response
Successfully creates destination and returns destination details
Example response
{
"did_destination": {
"id": 27,
"transport": 1,
"destination": "sip:test@example.com",
"priority": 1,
"dialing_type": "sequence",
"active": true
}
}Changes
No recorded changes to this operation across all 1 revision of this API.