Subscriptions
List subscriptions
Returns a paginated list of subscriptions. Supports filtering by status, customer ID, and tag IDs.
GET
/
subscriptions
List subscriptions
curl --request GET \
--url https://api.alguna.io/subscriptions \
--header 'Alguna-Version: <alguna-version>' \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.alguna.io/subscriptions"
headers = {
"Alguna-Version": "<alguna-version>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Alguna-Version': '<alguna-version>', Authorization: 'Bearer <token>'}
};
fetch('https://api.alguna.io/subscriptions', 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.alguna.io/subscriptions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Alguna-Version: <alguna-version>",
"Authorization: Bearer <token>"
],
]);
$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.alguna.io/subscriptions"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Alguna-Version", "<alguna-version>")
req.Header.Add("Authorization", "Bearer <token>")
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.alguna.io/subscriptions")
.header("Alguna-Version", "<alguna-version>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.alguna.io/subscriptions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Alguna-Version"] = '<alguna-version>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"billing": {
"auto_issue_invoices": true,
"auto_pay_invoices": false,
"first_billing_date": "2026-01-01T00:00:00Z",
"payment_terms": "net_30"
},
"contract": {
"period_type": "fixed",
"duration_months": 12,
"end_date": "2027-01-01T00:00:00Z",
"start_date": "2026-01-01T00:00:00Z"
},
"created_at": "2025-12-15T10:30:00Z",
"currency": "USD",
"customer_id": "cust_abc123",
"id": "sub_abc123",
"metadata": {},
"name": "Acme Corp - Enterprise",
"pending_changes": [
{
"status": "draft",
"version_id": "subv_abc123",
"description": "Q3 upgrade",
"effective_at": "2027-01-01T00:00:00Z"
}
],
"renewal": {
"auto_renew": true,
"duration_months": 12,
"period_type": "fixed"
},
"status": "active",
"updated_at": "2026-04-04T10:00:05Z",
"activated_at": "2026-01-01T00:00:00Z",
"current_version_id": "subv_abc123",
"discount": {
"amount": "10",
"duration_type": "fixed",
"type": "percentage",
"duration_unit": "months",
"duration_value": 6
},
"maximum_spend": {
"amount": "500.00",
"period": "monthly",
"billing_direction": "arrears"
},
"minimum_spend": {
"amount": "500.00",
"period": "monthly",
"billing_direction": "arrears"
},
"plan_id": "pln_abc123",
"price_escalation": {
"enabled": true,
"interval_months": 12,
"type": "percentage",
"escalate_metered_unit_rates": false,
"percentage": "5.00"
},
"trial_period_days": 30
}
],
"pagination": {
"per_page": 20,
"total_pages": 5
}
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}Authorizations
API key authentication. Pass your API key as a Bearer token.
Headers
Available options:
2026-04-01 Query Parameters
Filter by customer ID
Example:
"cust_abc123"
Number of items per page
Example:
20
Number of items to skip
Example:
0
Sort field and direction in format field:order. Sortable fields: name, status, created_at, activated_at, ended_at, updated_at, contract_start_date, contract_end_date
Example:
"created_at:desc"
Filter by subscription status. Pass a comma-separated list to match any.
Available options:
draft, scheduled, active, paused, canceled, completed Example:
"active"
Filter by tag IDs (comma-separated to match any)
Example:
"tag_abc123"
⌘I
List subscriptions
curl --request GET \
--url https://api.alguna.io/subscriptions \
--header 'Alguna-Version: <alguna-version>' \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.alguna.io/subscriptions"
headers = {
"Alguna-Version": "<alguna-version>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'Alguna-Version': '<alguna-version>', Authorization: 'Bearer <token>'}
};
fetch('https://api.alguna.io/subscriptions', 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.alguna.io/subscriptions",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Alguna-Version: <alguna-version>",
"Authorization: Bearer <token>"
],
]);
$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.alguna.io/subscriptions"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Alguna-Version", "<alguna-version>")
req.Header.Add("Authorization", "Bearer <token>")
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.alguna.io/subscriptions")
.header("Alguna-Version", "<alguna-version>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.alguna.io/subscriptions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Alguna-Version"] = '<alguna-version>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": [
{
"billing": {
"auto_issue_invoices": true,
"auto_pay_invoices": false,
"first_billing_date": "2026-01-01T00:00:00Z",
"payment_terms": "net_30"
},
"contract": {
"period_type": "fixed",
"duration_months": 12,
"end_date": "2027-01-01T00:00:00Z",
"start_date": "2026-01-01T00:00:00Z"
},
"created_at": "2025-12-15T10:30:00Z",
"currency": "USD",
"customer_id": "cust_abc123",
"id": "sub_abc123",
"metadata": {},
"name": "Acme Corp - Enterprise",
"pending_changes": [
{
"status": "draft",
"version_id": "subv_abc123",
"description": "Q3 upgrade",
"effective_at": "2027-01-01T00:00:00Z"
}
],
"renewal": {
"auto_renew": true,
"duration_months": 12,
"period_type": "fixed"
},
"status": "active",
"updated_at": "2026-04-04T10:00:05Z",
"activated_at": "2026-01-01T00:00:00Z",
"current_version_id": "subv_abc123",
"discount": {
"amount": "10",
"duration_type": "fixed",
"type": "percentage",
"duration_unit": "months",
"duration_value": 6
},
"maximum_spend": {
"amount": "500.00",
"period": "monthly",
"billing_direction": "arrears"
},
"minimum_spend": {
"amount": "500.00",
"period": "monthly",
"billing_direction": "arrears"
},
"plan_id": "pln_abc123",
"price_escalation": {
"enabled": true,
"interval_months": 12,
"type": "percentage",
"escalate_metered_unit_rates": false,
"percentage": "5.00"
},
"trial_period_days": 30
}
],
"pagination": {
"per_page": 20,
"total_pages": 5
}
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}{
"detail": "<string>",
"status": 123
}