List plans you can buy
curl --request GET \
--url https://test-api.segmnt.cloud/v1/billing/plans \
--cookie segmnt_session=import requests
url = "https://test-api.segmnt.cloud/v1/billing/plans"
headers = {"cookie": "segmnt_session="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'segmnt_session='}};
fetch('https://test-api.segmnt.cloud/v1/billing/plans', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://test-api.segmnt.cloud/v1/billing/plans",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_COOKIE => "segmnt_session=",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://test-api.segmnt.cloud/v1/billing/plans"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("cookie", "segmnt_session=")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://test-api.segmnt.cloud/v1/billing/plans")
.header("cookie", "segmnt_session=")
.asString();require 'uri'
require 'net/http'
url = URI("https://test-api.segmnt.cloud/v1/billing/plans")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["cookie"] = 'segmnt_session='
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "free",
"name": "<string>",
"price": {
"amount": 1,
"currency": "SAR",
"interval": "month"
},
"limits": {
"storedSeconds": 123,
"uploadSecondsPerPeriod": 123,
"watchedMinutesPerPeriod": 123,
"verifiedDomains": 123,
"projects": 123,
"maxQuality": "360p",
"whiteLabel": true
}
}
]
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "plan_limit_reached",
"detail": "<string>"
}Billing
List plans you can buy
GET
/
v1
/
billing
/
plans
List plans you can buy
curl --request GET \
--url https://test-api.segmnt.cloud/v1/billing/plans \
--cookie segmnt_session=import requests
url = "https://test-api.segmnt.cloud/v1/billing/plans"
headers = {"cookie": "segmnt_session="}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {cookie: 'segmnt_session='}};
fetch('https://test-api.segmnt.cloud/v1/billing/plans', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://test-api.segmnt.cloud/v1/billing/plans",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_COOKIE => "segmnt_session=",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://test-api.segmnt.cloud/v1/billing/plans"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("cookie", "segmnt_session=")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://test-api.segmnt.cloud/v1/billing/plans")
.header("cookie", "segmnt_session=")
.asString();require 'uri'
require 'net/http'
url = URI("https://test-api.segmnt.cloud/v1/billing/plans")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["cookie"] = 'segmnt_session='
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "free",
"name": "<string>",
"price": {
"amount": 1,
"currency": "SAR",
"interval": "month"
},
"limits": {
"storedSeconds": 123,
"uploadSecondsPerPeriod": 123,
"watchedMinutesPerPeriod": 123,
"verifiedDomains": 123,
"projects": 123,
"maxQuality": "360p",
"whiteLabel": true
}
}
]
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"code": "plan_limit_reached",
"detail": "<string>"
}