Basix XML Request

When a call arrives, Basix will make a synchronous HTTP POST request to the XML Server URL (you can set more than one URL to permit fallback), and wait to receive XML in response. Basix sends call parameters to your application that you can act upon before responding.

Request Parameters

Basix sends the following parameters with its request:

Parameter Description
CallUUID A unique identifier for this call.
From The phone number of the party that initiated the call. It it is the caller's caller ID (if the caller ID was hidden it will show up as Anonymous, unless you are a local carrier and are allowed to see the hidden caller ID). If the call is outbound then it will be the caller ID used to place the call.
CallerName The caller name of the party that initiated the call. This is usually the same as the parameter From in case of calls from/to the PSTN. But in case of internal calls (for example, extension-to-extension inside your Basix PBX), it will be the SIP username of the entity that placed the call.
To The phone number of the called party.
CallStatus This parameter depicts the status for the call. "ringing" (not answered yet), "in-progress" (already answered)
Direction Indicates the direction of the call: "inbound" or "outbound".
Anonymous Indicates if the call is Anonymous (caller ID hidden) or not: "true" or "false"
DNIS Shows the original number (if available) that was dialed by the caller (in case of inbound calls). Usually the DNIS is the same as the parameter To. However, it might not always be the case depending on how the call arrived at your Basix PBX.
CACode If you are a local carrier and are allowed to see this information, it will provide the CACode of the calling party.
CarrierID If you are a local carrier and are allowed to see this information, it will provide the CarrierID of the calling party.
UserId/UserName basix user.id and user.name if the person at the distant-end is a basix user
GroupId/GroupName basix group.id and group.name if if the person at the distant-end is a basix user on the context of a group. Important: this doesn't indicate the call arrived to a certain group. Instead it indicates a call was generated from that group to a member of the group.

The parameters are sent in the body of the request as an URL encoded query string. Ex: Direction=inbound&To=05011112222From=090111122226&CallerName=09011112222&DomainName=brs.basix.ne.jp&CallUUID=c58ae32a-6f19-47ba-a402-6f3d031cb1ab&CallStatus=ringing

If we are not able to connect to the first XML Server URL within 10 seconds, we will try the next one till we get a response or till the list of URLs is exhausted.

These parameters will also be available as variables during processing of the XML doc. So that you can do things like these:

1
2
<?xml version="1.0" encoding="UTF-8" ?>
<Speak>Your calling number is {{From}}</Speak>

And elements GetDigits, ReceiveFax and SendFax will add extra variables after they complete.

When the call finishes, if configured to do so, Basix will notify the xml server that the call terminated with parameters CallStatus=completed and DisconnectedBy.

Name Description
CallStatus "completed" (this means the call ended so we are not asking for XML data, we are just informing the call terminated).
DisconnectedBy local-end" (your pbx disconnected the call) or "distant-end" (the distant-end terminated the call)

If there is an error during XML processing like invalid XML syntax or invalid parameters for Elements, this will terminate the call and the error will be notified to the XML Server URL with extra parameter Error:

Name Description
Error some error string like "Unable to parse XML document" or "Invalid parameter 'date' for Element Play"