api:pbx:dialplan:get-references
Table of Contents
API : PBX : Dialplan Get References
Introduction
Dialplan item points to one another - this is how a call progresses through the dialplan.
An example: a trunk points to a time router and if open, it points to a playback message which then points to a queue which points to member extensions to dial.
A dialplan item cannot be deleted when it is being pointed to by another dialplan item. Therefore this API call exists, to list the dialplan items that points to a given dialplan item.
Request
This request will return a list of dialplan items that points the to given dialplan item.
| URL | https://api.telecomx.dk/pbx/dialplan/ID/references | |
|---|---|---|
| Method | GET | |
| Access level | VIEWER, MANAGER or OWNER if user belongs to the customer. RESELLER if customer belongs to the reseller. ADMIN. |
|
| Param | ID | Id of the item (24 hex-char string) |
| Query | expand | If true, instead of returning only the id's, the full basics of the dialplan items are returned. |
Query examples
https://api.telecomx.dk/pbx/dialplan/1234567890ABCDEF12345678/references https://api.telecomx.dk/pbx/dialplan/1234567890ABCDEF12345678/references?expand=true
Response (normal)
An array of id's of the dialplan items.
Example
[ '1234567890123457890AAAA', '1234567890123457890AAAB', '1234567890123457890BBCD', '1234567890123457890A53F' ]
Response (expand=true)
An array of dialplan items.
| Array of JSON objects | ||
|---|---|---|
| _id | Id | Unique id of the group. |
| type | String | Type of dialplan item. |
| name | String | Item name. |
| number | String | The phone number to dial to reach this item, null if it should not be dial-able. |
| redirect | String | Number to redirect to when execution starts. Used to quickly circumvent the item, e.g. redirect to a mobile. |
| notes | String | Notes about the item. |
Example
[ { _id: '12345678901234567890ABCD', type: 'QUEUE', name: 'VIP Support', number: '888', redirect: null, notes: 'Important queue!' }, { ... } ]
Errors
| Error code | Message | Description |
|---|---|---|
| 400 | bad_request | Id not found in requestURI |
| 404 | id | Dialplan item not found |
| 403 | access_denied | Insufficient access level |
| 500 | internal_error | <Unspecified> |
api/pbx/dialplan/get-references.txt · Last modified: 2015/11/12 11:09 by Per Møller