- DarkLight
Get Business Fields
- DarkLight
Overview
The GetBusinessFields API fetches business fields corresponding to the given account number.
Pre-requisite
The Agent must be on an active call or logged in to the application.
Sequence Diagram
Message Structure
Request Parameters | Value |
---|---|
channel | LCM |
topic | Webservice |
subtopic | GetContactDetail |
source | «app-name-broadcasting-this-message» |
data | «JSON Object» |
Data Parameters
Parameter | Mandatory | Data Type | Description |
---|---|---|---|
callid | Yes | String | Call ID. |
AccountNumber | Yes | String | LCM Key. |
Response Parameters | Value |
---|---|
channel | LCM |
topic | Webservice |
subtopic | ContactDetail |
message | «JSON Object» |
Message Parameters
Parameter | Mandatory | Data Type | Description |
---|---|---|---|
callid | Yes | String | Call ID. |
response | Yes | JSON Array | List of business fields. |
Response Parameters | |||
FieldName | Yes | String | The business field name. |
Value | Yes | String | The business field value. |
DataType | Yes | String | The data type of the business field. |
Format | Yes | String | The format for the business field. |
Editable | Yes | Boolean | Indicates if agents are allowed to edit this field. |
Possible Error Cases
Error Type | Actual Error | Message |
---|---|---|
WS_Error | Callid is empty | Invalid Call ID. |
WS_Error | Invalid Call ID:<call_id> | Invalid Call ID. |
Sample Request
{
"channel": "LCM",
"topic": "WebService",
"subtopic": "GetContactDetail",
"data":
{
"callid": "12345",
"AccountNumber": "5|3|1|0|0|44|1"
}
}
Sample Response
{
"channel": "LCM",
"topic": "WebService",
"subtopic": "ContactDetail",
"message":
{
"callid": "12345",
"response": [
{
"FieldName": "FName",
"Value": "Test",
"DataType": "String",
"Format": "",
"Editable": true
},
{
"FieldName": "LName",
"Value": "Berry",
"DataType": "String",
"Format": "",
"Editable": true
}
]
}
}