The GET/my/calls/ringing is a simple request that returns a list of all ringing calls for a user.
The request returns the following fields of information:
- server – this is usually a "null" value unless a special server was used for the call, in which case a number will identify the relevant server for making or receiving the call.
- uniqueid – a unique ID for a particular call segment (inside an entire call flow) created by combining its start time, direction and other values.
- callid – an unique ID for the entire call as a whole. This value will be identical among all call segments of a call. Usually callid and uniqueid have the same value for the first call segment in a call flow.
- start – the start time for the call or a particular call segment, in Unix time format.
- answered – indicates the time the relevant call segment was answered, in Unix time format (that is before it was transfered to the current user where it is presently ringing.)
- stype – a definition for the type of source point - where the call or call segment started from. This will always be "external" for an inbound call from an outside source. Otherwise it can be any of numerous points on the PBX - "ivr", "accessmenu, "queue", "extension", "access", etc.
- snumber – the phone number of the source point that initiated the call. This can be, depending on the direction of the call, either an internal extension/number, a full telephone number, or a temporary number assigned by the system to the point in case it doesn't have one (such as in the case of an IVR).
- spresent – a value of 1 indicates that the presentation of the source call supports the ISDN format. A value of 0 indicates it it not.
- stransferred – a value of 1 indicates that the source point(defined by snumber/stype) was transfered by the system to the present call segment. A value of 0 indicates it it not. This will always be 0 in the first segment or when a call arrives at the IVR menu.
- ctype – a definition for the type of called point (where the source customer originally dialed) in the current call or call segment. This has no value for outbound calls. For inbound or internal calls, the value is not absolute for the entire call but is assigned by the system based on the progression of the call in call flow.
- cnumber – the phone number of called point (where the source customer originally dialed) in the current call or call segment. The value is not absolute for the entire cal but is assigned by the system based on the progression of the call in call flow.
- dtype – a definition for the type of destination point (where the call was routed to) for the call or call segment. Examples can be "ivr", "accessmenu, "queue", "phone", etc. The type will always be "external" for outbound calls.
- dnumber – the phone number of the destination point where the call was routed to for the call or call segment.Note that in inbound and internal calls ctype and cnumber will differ from dtype and dnumber only in the first segment or two. After that they are usually identical.
- dtransferred – a value of 1 indicates that the destination point(defined by dnumber/dtype) requires a transfer between points to be reached from the current call segment. A value of 0 indicates it it not. For example when a call moves from a phone number to its mailbox this will have a 0 value since a mailbox is considered the same point as its number.
- ptransferred – an indication that the call was transfered to a parking area before reaching the user (where it is presently ringing).
- callerid_internal – a caller ID set for a call that is originated internally (that is an outbound call). It may apply to the external caller ID (hence they will appear identical.
- callerid_external – a caller ID set for a call that is originated externally (that is an inbound call). It may apply to the external caller ID.
- callername_internal – a name associated with the call that is originated internally (that is an outbound call) taken from PBX records. It may apply to the external caller name (hence they will appear identical.)
- callername_external – a name associated with a call that is originated externally (that is an inbound call) taken from caller ID information. It may apply to the internal caller name (hence they will appear identical.)
- park – if the call was parked during the call flow before reaching the user, this is the number of the extension or line where it was parked.
- status – indication of the status of the call, in the current call segment, in terms of connection between the caller and recipient. Possible responses include "answer","noanswer" (by the recipient), "cancel" (by the caller), "congestion" (too much traffic preventing a connection), "busy" (the recipient is on another call), or "chanunavail" - the destination communication channel is unavailable or the requested peer is not be registered.
- duration – total duration of the call segments in seconds. If the call was placed directly to the user this will say "ringing" instead as there is no valid duration yet.
- caller – name, extension, or number of the caller of the call. This may temporarily take the the virtual extension number of the IVR when the call is being handled by it.;
- called – name or extension or the recipient of the call. If not available (for external recipient) the called number will be given here.
- callednumber – phone number of the recipient of the call.
Parameters
Parameter | Type | Operation |
phone | string | (optional) The mailbox (phone line) from which the fax document is requested. |
The Limit and Offset optional parameters may be used if dealing with a large number of ringing calls (rarely, if ever, the case.)
Example
To see ringing calls for a user use this syntax:
HTTPS method: GET
webserv.telebroad.com/api/teleconsole/rest/get/my/calls/ringing
Response:
If there aren't any ringing calls for the user –
{
"error":
{ "code": 444, "message": "No ringing calls" }
}
Otherwise –
{
"error": null,
"result":
[
{"server": null,
"uniqueid": "1585200856.735108",
"callid": "1585200838.213795",
"start": "1585200856",
"answered": "0",
"stype": "access",
"snumber": "238",
"spresent": "1",
"stransferred": "0",
"ctype": "",
"cnumber": "1113852",
"dtype": "phone",
"dnumber": "1113852",
"dtransferred": "0",
"ptransferred": "0",
"callerid_internal": "",
"callerid_external": "",
"callername_internal": "Rick Goodwin",
"callername_external": "Rick Goodwin",
"park": "",
"status": "",
"duration": "ringing",
"caller": "238",
"called": "1113852"}
]
}