Get subscription details
curl --request GET \
--url https://api-stg.pandablue.com/v3/subscriptions/{subscription_id} \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--header 'X-Date: <x-date>' \
--header 'X-Login: <x-login>'import requests
url = "https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}"
headers = {
"Content-Type": "<content-type>",
"X-Date": "<x-date>",
"X-Login": "<x-login>",
"Authorization": "<authorization>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'Content-Type': '<content-type>',
'X-Date': '<x-date>',
'X-Login': '<x-login>',
Authorization: '<authorization>'
}
};
fetch('https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}', 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://api-stg.pandablue.com/v3/subscriptions/{subscription_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>",
"X-Date: <x-date>",
"X-Login: <x-login>"
],
]);
$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://api-stg.pandablue.com/v3/subscriptions/{subscription_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("X-Date", "<x-date>")
req.Header.Add("X-Login", "<x-login>")
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}")
.header("Content-Type", "<content-type>")
.header("X-Date", "<x-date>")
.header("X-Login", "<x-login>")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["X-Date"] = '<x-date>'
request["X-Login"] = '<x-login>'
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"id": 123,
"status": "PENDING",
"start_date": "2023-12-25",
"creation_date": "2023-11-07T05:31:56Z",
"subscription_plan": "DAILY",
"plan_unit": 123,
"amount": 123,
"auto_renewal": true,
"renewals": 123,
"currency": "<string>",
"country": "<string>",
"end_date": "2023-12-25",
"last_renovation_date": "2023-12-25",
"last_modified_date": "2023-11-07T05:31:56Z",
"cancellation_date": "2023-12-25",
"last_charge_date": "2023-12-25",
"payment_method": "<string>",
"invoice_id": "<string>",
"error_url": "<string>",
"success_url": "<string>",
"back_url": "<string>",
"description": "<string>",
"deposits": [
{
"deposit_id": "<string>",
"status": "<string>"
}
]
}{
"code": 123,
"description": "<string>",
"type": "<string>"
}{
"code": 123,
"description": "<string>",
"type": "<string>"
}Manage subscriptions
Get a subscription
This endpoint retrieves the details of a specific subscription by ID.
GET
/
v3
/
subscriptions
/
{subscription_id}
Get subscription details
curl --request GET \
--url https://api-stg.pandablue.com/v3/subscriptions/{subscription_id} \
--header 'Authorization: <authorization>' \
--header 'Content-Type: <content-type>' \
--header 'X-Date: <x-date>' \
--header 'X-Login: <x-login>'import requests
url = "https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}"
headers = {
"Content-Type": "<content-type>",
"X-Date": "<x-date>",
"X-Login": "<x-login>",
"Authorization": "<authorization>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {
'Content-Type': '<content-type>',
'X-Date': '<x-date>',
'X-Login': '<x-login>',
Authorization: '<authorization>'
}
};
fetch('https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}', 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://api-stg.pandablue.com/v3/subscriptions/{subscription_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: <content-type>",
"X-Date: <x-date>",
"X-Login: <x-login>"
],
]);
$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://api-stg.pandablue.com/v3/subscriptions/{subscription_id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Content-Type", "<content-type>")
req.Header.Add("X-Date", "<x-date>")
req.Header.Add("X-Login", "<x-login>")
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}")
.header("Content-Type", "<content-type>")
.header("X-Date", "<x-date>")
.header("X-Login", "<x-login>")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-stg.pandablue.com/v3/subscriptions/{subscription_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Content-Type"] = '<content-type>'
request["X-Date"] = '<x-date>'
request["X-Login"] = '<x-login>'
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"id": 123,
"status": "PENDING",
"start_date": "2023-12-25",
"creation_date": "2023-11-07T05:31:56Z",
"subscription_plan": "DAILY",
"plan_unit": 123,
"amount": 123,
"auto_renewal": true,
"renewals": 123,
"currency": "<string>",
"country": "<string>",
"end_date": "2023-12-25",
"last_renovation_date": "2023-12-25",
"last_modified_date": "2023-11-07T05:31:56Z",
"cancellation_date": "2023-12-25",
"last_charge_date": "2023-12-25",
"payment_method": "<string>",
"invoice_id": "<string>",
"error_url": "<string>",
"success_url": "<string>",
"back_url": "<string>",
"description": "<string>",
"deposits": [
{
"deposit_id": "<string>",
"status": "<string>"
}
]
}{
"code": 123,
"description": "<string>",
"type": "<string>"
}{
"code": 123,
"description": "<string>",
"type": "<string>"
}Headers
Path Parameters
Response
Subscription details retrieved successfully