API SIMPSY Voice

version v1           http://voice.simpsy.com/api/v1

/didnumber/queue/edit


POST http://voice.simpsy.com/api/v1/didnumber/queue/edit

GET

Add new queue

Query Parameters

ParameterTypeRequiredDescription
keystringYesAPI Key
secretstringYesAPI Secret
queue_namestringYesName of queue
maxlennumberYesMaximum number of callers waiting in the queue.
Option - 0 for unlimited, 5, 10, 15, 20, 30, 40, 50 seconds
acd_typestringYesDistributes incoming calls in the order of arrival to the first available agent.
Option - ringall, leastrecent, fewestcalls, random
announce_postionstringYesPlay caller's position in the queue.
Option - Yes,No
announce_frequencystringYesHow often to announce caller position and/or estimated holdtime.
Option - Yes,No
announce_holdtimestringYesAnnounce Average Hold Time to Caller .
Option - Yes,No, Once
retrynumberYesHow long do we wait before trying all the agents again.
Option - 0 for No, 5 , 10, 15, 20, 25, 30 seconds
timeoutnumberYesHow long does system let the agent phone ring before it considers this a timeout.
Option - 0 for No, 5 , 10, 15, 20, 25, 30 seconds
wrapuptimenumberYesAfter a successful call, how long to wait before sending another call to free agent.
Option - 0, 5 , 10, 15, 20, 25, 30 seconds
periodic_announcestringYesWhich sound file to play at regular intervals while a caller is in the queue.
Get sound name from /sound
periodic_announce_frequencynumberYesKeep Playing a sound file to the caller in the queue after every selected seconds.
Option - 0 for no, 20, 30, 40, 50, 60, 120 seconds
reportholdtimenumberYesReport the caller's hold time to the agent before they are connected.
Option - 0 for no, 1 for yes

Code Samples

JavaScript PHP Rails
var xmlHttp = new XMLHttpRequest();
xmlHttp.open("POST", "http://voice.simpsy.com/api/v1/didnumber/queue/edit", false);

// Make sure you set the appropriate headers
xmlHttp.setRequestHeader("Header Key", "Header Value");

var data = "# body is your JSON/ XML/ Text/ Form Query/ etc"
xmlHttp.send(data);

var response = xmlHttp.responseText;
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "http://voice.simpsy.com/api/v1/didnumber/queue/edit");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);

// Make sure you set the nessary headers as a $headers array
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);

curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "post")
$body = '';
curl_setopt($ch, CURLOPT_POSTFIELDS, $body);

$response = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
uri = URI.parse("http://voice.simpsy.com/api/v1/didnumber/queue/edit")
http = Net::HTTP.new(uri.host, uri.port)
request = Net::HTTP::Post.new(uri.request_uri)

# Make sure you set the appropriate headers
request["header"] = "header value"

# body is your JSON/ XML/ Text/ Form Query/ etc
request.set_form_data(body)

response = http.request(request)

Response

200:

application/json
{
"status": "200",
"message": "Successfully edited",


}

 

400:

Missing or invalid properties

 

401:

Invalid API Key & Password