By default, Softdial Campaign Manager™ provides the record data included in the Data (DT) parameter in an XML document format.
The following is an example of contact record data as delivered to an agent appliction, e.g. Softdial Scripter™ 2. It is passed to and from Softdial Campaign Manager™, via Softdial CallGem™, in the Data (DT) parameter of the agent layer messages, e.g. Begin Preview [BP], Agent Connect [AC], Transaction Complete [TC].
It is formatted on a single line, without carriage return (CR) and linefeed (LF) characters, since in the SDMP protocol, CR LF indicates end of message. The example document below has been formatted for easy reading.
<MagicXMLDocument xmlns="http://www.sytelco.com/SCC/CM">
<r>
<c i="0" n="Contact_ID" m="true" d="130" />
<c i="0" n="Title" m="false" d="Ms" />
<c i="0" n="Forename" m="false" d="Janine" />
<c i="0" n="Surname" m="false" d="Grummitt" />
<c i="0" n="Address_1" m="false" d="193 Oak Road" />
<c i="0" n="Address_2" m="false" d="Bakerstone" />
<c i="0" n="Address_3" m="false" d="London" />
<c i="0" n="Address_4" m="false" d="" />
<c i="0" n="Address_5" m="false" d="" />
<c i="0" n="Address_6" m="false" d="" />
<c i="0" n="Postcode" m="false" d="SW9 2XZ" />
<c i="0" n="Telephone" m="false" d="01234000130" />
<c i="0" n="Switch_Result" m="true" d="0" />
<c i="0" n="Agent_Result" m="true" d="" />
<c i="0" n="Result_TS" m="true" d="40100.486463" />
<c i="0" n="Retry_Count" m="true" d="" />
<c i="0" n="Retry_TS" m="true" d="" />
<c i="0" n="Retry_Username" m="false" d="" />
<c i="0" n="Retry_Number" m="false" d="" />
<c i="0" n="Retry_Index" m="true" d="" />
<c i="0" n="Complete_TS" m="true" d="" />
</r>
</MagicXMLDocument>
There is no <?xml> header tag specified.
The r element represents a row. Each column (field) in the record is represented with a c element, which has the following attributes:
From V10.6.568 - the i parameter is no longer used (still present for legacy xml/ xsd validation compatibility but now set to '0' and ignored). This is likely to be a breaking change for existing integrations.
The n field (below) is now generally used as the key.
When an agent application returns a data update in the Transaction Complete [TC] message, the attributes i (pre V10.6.568), n and m must remain constant and as received in the original Agent Connect [AC] message. The d data attribute contains the updated data values.
Other applications can add to this set of data - see The Data (DT) Parameter.
As well as conforming to XML encoding rules, you must ensure that SDMP and XML characters are not directly used and encoded within each data attribute. These must be represented using XML entities, e.g:
For reference, the standard XML reserved characters that must be encoded are:
Some fields are reserved by Softdial Campaign Manager™ for its own contact management and attempts to update will be ignored. In the above example, these fields are:
From V10.7.1010 - the data type for the DT parameter has been changed from string to struct.
Depending on the framing type for the communication session, data in a struct type parameter may be presented as either XML or JSON. This enables the HTTP proxy and other library components to interrogate the DT parameter and present its content as individual pieces of data.
To give an example of this, when using the RESTful getstate api to get the current state of an agent endpoint, if the agent is on a call, the session data is presented as the individual data elements:
{
"Name": "John",
"Tenant": "default",
"Campaign": "foo",
"State": "Wrapping",
"OldState": "NotLoggedIn",
"MediaSessionGuid": "767C90D3511245CDA69666E82545913C",
"RecordingSessionGuid": "",
"ContactRecordKey": "1",
"MediaSessionID": "default_0001_1",
"Extension": "1206",
"Description": "John",
"Queue": "",
"Mute": false,
"Hold": false,
"Record": false,
"RequiresTC": true,
"CustomerTel": "1246",
"OurTel": "",
"SessionAgentSpecific": false,
"SessionAbandonRetry": false,
"SessionIsCallback": false,
"SessionIsOffering": false,
"SessionTransferState": 0,
"SessionIsPlayback": false,
"SessionCaptureData": "",
"AgentSessionGuid": "3DA84F6976C64EAC80B5C81BE53FDFF5",
"CampaignSessionGuid": "42A3A5DA3C5F41E4B983924BBFCD80B3",
"StateChanged": "True",
"SessionData": {
"Result_TS": "",
"Postcode": "RDVUOEEU",
"Surname": "Allnutt",
"Contact_ID": "1",
"Switch_Result": "",
"Mobile_Tel": "01234000001",
"Title": "Mrs",
"Address_1": "O",
"Address_2": "UOMIWUSE",
"Agent_Result": "",
"Retry_Number": "",
"Address_3": "RMHACJDEYLCAAJNOPPEQLIBPTUNHVSXXNDL",
"Address_4": "VFTVYZPJGH",
"Work_Tel": "01234000001",
"Income": "88197.000000",
"Address_5": "AJCQBAWGGORUSMFSLLXSCOJSPOJDFKUMYS",
"Address_6": "EQMBRMDXDWRHKB",
"Retry_Count": "",
"Retry_Index": "",
"Forename": "Wendy",
"Telephone": "1246",
"Age": "91",
"Retry_TS": "",
"Retry_Username": "",
"Complete_TS": ""
}
}
This enables the writer of a client to consume the JSON and then address the data items directly, e.g. agentstate.SessionData.Surname
See also The Data (DT) Parameter.