Get a Subscription
curl --request GET \
--url https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO \
--header 'Authorization: <api-key>'import requests
url = "https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO', 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://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO",
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: <api-key>"
],
]);
$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://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": "SUCCESS",
"data": {
"subscriptions": {
"publicKey": "SBTESTPUBK_9sN3TuLgW6a9redEfY48cKKkUa09Pz2u",
"amount": 100,
"country": "NG",
"customerId": "SBT4d26d47dcb33f9430507",
"cardName": "Kolade Samuel",
"cardNumber": "5123-45xx-xxxx-0008",
"plan": "c6d4096c8244b5e0dbda",
"status": "INACTIVE",
"billingId": "TPR2181t55PER542RPP1U1W4391WO",
"authorizationCode": "5f818a9f1191c423446b",
"startDate": "2020-02-25T00:00:00.000Z",
"createdAt": 1601385265000
},
"code": "00",
"message": "Successful"
}
}RECURRENT
Get a Subscription
Get customer subscription
GET
/
recurring
/
billingId
/
TPR2181t55PER542RPP1U1W4391WO
Get a Subscription
curl --request GET \
--url https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO \
--header 'Authorization: <api-key>'import requests
url = "https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO', 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://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO",
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: <api-key>"
],
]);
$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://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://seerbitapi.com/api/v2/recurring/billingId/TPR2181t55PER542RPP1U1W4391WO")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": "SUCCESS",
"data": {
"subscriptions": {
"publicKey": "SBTESTPUBK_9sN3TuLgW6a9redEfY48cKKkUa09Pz2u",
"amount": 100,
"country": "NG",
"customerId": "SBT4d26d47dcb33f9430507",
"cardName": "Kolade Samuel",
"cardNumber": "5123-45xx-xxxx-0008",
"plan": "c6d4096c8244b5e0dbda",
"status": "INACTIVE",
"billingId": "TPR2181t55PER542RPP1U1W4391WO",
"authorizationCode": "5f818a9f1191c423446b",
"startDate": "2020-02-25T00:00:00.000Z",
"createdAt": 1601385265000
},
"code": "00",
"message": "Successful"
}
}Authorizations
Response
The response is of type GetSubscriptionResponse · object.