PHP code example of antsar / incontact
1. Go to this page and download the library: Download antsar/incontact library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
antsar / incontact example snippets
// Autoload the inContact class.
e.
$inContact = new \antsar\incontact\InContact(
'exampleApp', // Application Name as registered with inContact
'exampleCompany', // Vendor Name as registered with inContact
'012345', // Business Unit number as registered with inContact
'exampleUser', // inContact User Name
'hunter2' // inContact User Password
);
// Get status for all agents
$agents = $inContact->get('/agents/states');
// Request a call-back
$response = $inContact->post('/queuecallback', ['phoneNumber' => '8005550100']);