Create Maskyoo
This function purpose is to set up a new maskyoo number in the system, including all functions & features that effects the user experience during the call • Please note! This may affect your rates, according to your commercial plan
/api/?service=create_maskyoo
Usage and SDK Samples
curl -H "Authorization: Bearer < TOKEN_FROM_SYSTEM >" -X get "https://[MASKYOO_URL]/api/?service=create_maskyoo&maskyoo=&call_destination_phone=&active_status=&greeting_out=&greeting_in=&description=&email=&private_field1=&private_field2=&private_field3=&private_field4=&private_field5=&sms_destination_phone=&callback_url=&working_hours=&extenstion=&record_presantge=&ringback_tone=fonetone&callback_url_option=2&record_option=2&dial_option=1&dial_timeout_in_sec=50&out_of_time_destination_phone=972544224421&expose=1&disallow_callback=0&format="
using System.Net;
using System.Collections.Specialized;
namespace Examples.System.Net
{
public class WebRequestPostExample
{
public static void Main ()
{
string url_query_string="https://[MASKYOO_URL]/api/?";
using (var client = new WebClient())
{
var values = new NameValueCollection();
values["service"] = "create_maskyoo";
values["maskyoo"] = "";
values["call_destination_phone"] = "972544224422";
values["active_status"] = "1";
values["greeting_out"] = "sound_for_caller";
values["ringback_tone"] = "fonetone";
values["greeting_in"] = "empty";
values["description"] = "testit";
values["email"] = "[email protected]";
values["private_field1"] = "1";
values["private_field2"] = "2";
values["private_field3"] = "3";
values["private_field4"] = "4";
values["private_field5"] = "5";
values["sms_destination_phone"] = "972544224422";
values["callback_url"] = "";
values["callback_url_option"] = "2";
values["working_hours"] = "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111";
values["extenstion"] = "";
values["record_presantge"] = "50";
values["record_option"] = "2";
values["dial_option"] = "1";
values["dial_timeout_in_sec"] = "50";
values["out_of_time_destination_phone"] = "972544224421";
values["expose"] = "1";
values["disallow_callback"] = "0";
values["format"] = "json";
client.Headers.Add("Authorization","Bearer < TOKEN_FROM_SYSTEM >");
var response = client.UploadValues(url_query_string, values);
var responseString = Encoding.Default.GetString(response);
Console.WriteLine (responseString);
}
}
}
}
<?php
$base_url="https://[MASKYOO_URL]/api/";
$data = array(
"service" => "create_maskyoo",
"maskyoo" => "",
"call_destination_phone" => "972544224422",
"active_status" => "1",
"greeting_out" => "sound_for_caller",
"ringback_tone" => "fonetone",
"greeting_in" => "empty",
"description" => "testit",
"email" => "[email protected]",
"private_field1" => "1",
"private_field2" => "2",
"private_field3" => "3",
"private_field4" => "4",
"private_field5" => "5",
"sms_destination_phone" => "972544224422",
"callback_url" => "",
"callback_url_option" => "2",
"working_hours" => "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111",
"extenstion" => "",
"record_presantge" => "50",
"record_option" => "2",
"dial_option" => "1",
"dial_timeout_in_sec" => "50",
"out_of_time_destination_phone" => "972544224421",
"expose" => "1",
"disallow_callback" => "0",
"format" => "json",
);
echo post_data($base_url, $data);
function post_data($url, $data){
$fields = '';
foreach($data as $key => $value) {
$fields .= $key . '=' . $value . '&';
}
rtrim($fields, '&');
$post = curl_init();
curl_setopt($post, CURLOPT_URL, $url);
curl_setopt($post, CURLOPT_POST, count($data));
curl_setopt($post, CURLOPT_POSTFIELDS, $fields);
curl_setopt($post, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($post, CURLOPT_HTTPHEADER, array("Authorization: Bearer < TOKEN_FROM_SYSTEM >"));
$result = curl_exec($post);
curl_close($post);
return $result;
}
?>
Parameters
Name | Description |
---|---|
maskyoo / prefix | |
call_destination_phone* | |
active_status* | |
greeting_out | |
ringback_tone | |
greeting_in | |
description* | |
private_field1 | |
private_field2 | |
private_field3 | |
private_field4 | |
private_field5 | |
sms_destination_phone | |
callback_url | |
callback_url_option | |
working_hours | |
out_of_time_destination_phone | |
extenstion | |
record_presantge | |
record_option | |
dial_option | |
dial_timeout_in_sec | |
expose | |
disallow_callback | |
format |