Skip to main content

Announce Update

This service is used to edit an audio file for the mass calling section.

Parameters

DescriptionDefined DataExample DataRequired[**]/Optional[*]Parameters
Unique Audio ID obtained from search-6033876dc92de036d1390923**id_
Audio Name-test_sound_new*name
Audio File Name-file-20200825065434-58826-bbc-farsi-pargarmp3_.wav*filename
Description-Just for test-description

Sample Invocation

Show Full Source Code PHP

	<?php

$curl = curl_init();

curl_setopt_array($curl, array(
CURLOPT_URL => "http://192.168.51.21/api/v4/autodialer/announcements/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS =>"{\r\n \"_id\":\"6033876dc92de036d1390923\",\r\n \"name\":\"test_sound_new\",\r\n \"filename\":\"file-20200825065434-58826-bbc-farsi-pargarmp3_.wav\",\r\n \"description\":\"Just for test\"\r\n}",
CURLOPT_HTTPHEADER => array(
"X-APIKEY: vZKtIKWsld0egNlkzHo8i5LVBqLNBSWARCQsPOSgDjFmAHM3tG",
"Authorization: Basic dGVzdDpBYTEyMzQ1Ng==",
"Content-Type: application/json"
),
));

$response = curl_exec($curl);
if (!curl_errno($curl)) {
$httpcode = curl_getinfo($curl, CURLINFO_HTTP_CODE);
echo 'response code:'.$httpcode, '<br/>';
}

curl_close($curl);
echo $response;
?>