Progressive Geoblocking Update
This operation allows you to define the new Geoblock for your stream live zone.
Parameters
Parameter | Type | Required | Description |
---|---|---|---|
user_key | string | Yes | API User Token |
user_secret | string | Yes | API User Secret Token |
zone_ids | integer | Yes | Zone ID |
countries | array | Yes | This field should contain country codes. |
rule_id | integer | No | Rule Id |
label | string | No | Label |
start_date | integer | No | It should be in Y-M-D H: M: S format. |
end_date | integer | No | It should be in Y-M-D H: M: S format. |
Return Values
Variable | Type |
---|---|
status | bool |
data | object |
Example PHP Code
<?php
$data = array(
"user_key" => "Your User Key",
"user_secret" =>"Your User Secret",
"zone_ids" => ["zone_id"],
"countries" => ["county_code"]
);
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.medianova.com/v1/geoblocking/edit",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => false,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => “PUT”,
CURLOPT_POSTFIELDS => json_encode($data),
CURLOPT_HTTPHEADER => array(
"Content-Type: application/json"
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;Example Output
Example Output
{
"status": true,
"opid": "576UWnEydPJfXAYB"
}