Documentation Index
Fetch the complete documentation index at: https://orbit-docs.devotel.io/llms.txt
Use this file to discover all available pages before exploring further.
Billing API
Access your subscription plan, track real-time usage, initiate plan changes, and download invoices. Powered by Stripe for payments and Orb for usage metering. Base path:/v1/billing
List Plans
GET /v1/billing/plans
Retrieve all available pricing plans.
cURL
curl -X GET "https://orbit-api.devotel.io/api/v1/billing/plans" \
-H "X-API-Key: dv_live_sk_your_key_here"
Node.js
import { Orbit } from '@devotel/orbit-sdk'
const orbit = new Orbit({
apiKey: process.env.ORBIT_API_KEY!,
})
const res = await fetch('https://orbit-api.devotel.io/api/v1/billing/plans', {
method: 'GET',
headers: {
'X-API-Key': process.env.ORBIT_API_KEY!,
},
})
console.log(await res.json())
Python
import os, requests
headers = {"X-API-Key": os.environ["ORBIT_API_KEY"]}
r = requests.get("https://orbit-api.devotel.io/api/v1/billing/plans", headers=headers)
print(r.json())
Go
package main
import (
"bytes"
"net/http"
"os"
)
func main() {
req, _ := http.NewRequest("GET", "https://orbit-api.devotel.io/api/v1/billing/plans", nil)
req.Header.Set("X-API-Key", os.Getenv("ORBIT_API_KEY"))
http.DefaultClient.Do(req)
}
Ruby
require 'net/http'
require 'json'
uri = URI('https://orbit-api.devotel.io/api/v1/billing/plans')
req = Net::HTTP::Get.new(uri)
req['X-API-Key'] = ENV['ORBIT_API_KEY']
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |h| h.request(req) }
puts res.body
PHP
<?php
$ch = curl_init('https://orbit-api.devotel.io/api/v1/billing/plans');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'X-API-Key: ' . getenv('ORBIT_API_KEY'),
]);
echo curl_exec($ch);
{
"data": [
{
"id": "plan_starter",
"name": "Starter",
"price_id": "price_abc123",
"price_monthly": 49,
"currency": "usd",
"features": {
"messages_included": 5000,
"channels": ["sms", "email"],
"agents": 1,
"support": "email"
}
},
{
"id": "plan_growth",
"name": "Growth",
"price_id": "price_def456",
"price_monthly": 199,
"currency": "usd",
"features": {
"messages_included": 25000,
"channels": ["sms", "whatsapp", "email", "rcs"],
"agents": 5,
"support": "priority"
}
},
{
"id": "plan_enterprise",
"name": "Enterprise",
"price_id": "price_ghi789",
"price_monthly": null,
"currency": "usd",
"features": {
"messages_included": "unlimited",
"channels": ["sms", "whatsapp", "rcs", "viber", "email", "voice"],
"agents": "unlimited",
"support": "dedicated"
}
}
],
"meta": {
"request_id": "req_plans_001",
"timestamp": "2026-03-08T12:00:00Z"
}
}
Create Checkout Session
POST /v1/billing/checkout
Create a Stripe checkout session for subscribing to or upgrading a plan. Returns a URL to redirect the user to the Stripe-hosted payment page.
Stripe price ID of the target plan (from the plans list)
URL to redirect to after successful payment
URL to redirect to if the user cancels
cURL
curl -X POST "https://orbit-api.devotel.io/api/v1/billing/checkout" \
-H "X-API-Key: dv_live_sk_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"priceId": "price_def456",
"successUrl": "https://orbit.devotel.io/settings/billing?success=true",
"cancelUrl": "https://orbit.devotel.io/settings/billing?cancelled=true"
}'
Node.js
import { Orbit } from '@devotel/orbit-sdk'
const orbit = new Orbit({
apiKey: process.env.ORBIT_API_KEY!,
})
const res = await fetch('https://orbit-api.devotel.io/api/v1/billing/checkout', {
method: 'POST',
headers: {
'X-API-Key': process.env.ORBIT_API_KEY!,
'Content-Type': 'application/json',
},
body: JSON.stringify({
"priceId": "price_def456",
"successUrl": "https://orbit.devotel.io/settings/billing?success=true",
"cancelUrl": "https://orbit.devotel.io/settings/billing?cancelled=true"
}),
})
console.log(await res.json())
Python
import os, requests
headers = {"X-API-Key": os.environ["ORBIT_API_KEY"]}
headers["Content-Type"] = "application/json"
r = requests.post("https://orbit-api.devotel.io/api/v1/billing/checkout", headers=headers, json={
"priceId": "price_def456",
"successUrl": "https://orbit.devotel.io/settings/billing?success=true",
"cancelUrl": "https://orbit.devotel.io/settings/billing?cancelled=true"
})
print(r.json())
Go
package main
import (
"bytes"
"net/http"
"os"
)
func main() {
req, _ := http.NewRequest("POST", "https://orbit-api.devotel.io/api/v1/billing/checkout", bytes.NewBuffer([]byte(`{
"priceId": "price_def456",
"successUrl": "https://orbit.devotel.io/settings/billing?success=true",
"cancelUrl": "https://orbit.devotel.io/settings/billing?cancelled=true"
}`)))
req.Header.Set("X-API-Key", os.Getenv("ORBIT_API_KEY"))
req.Header.Set("Content-Type", "application/json")
http.DefaultClient.Do(req)
}
Ruby
require 'net/http'
require 'json'
uri = URI('https://orbit-api.devotel.io/api/v1/billing/checkout')
req = Net::HTTP::Post.new(uri)
req['X-API-Key'] = ENV['ORBIT_API_KEY']
req['Content-Type'] = 'application/json'
req.body = {
"priceId": "price_def456",
"successUrl": "https://orbit.devotel.io/settings/billing?success=true",
"cancelUrl": "https://orbit.devotel.io/settings/billing?cancelled=true"
}.to_json
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |h| h.request(req) }
puts res.body
PHP
<?php
$ch = curl_init('https://orbit-api.devotel.io/api/v1/billing/checkout');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'X-API-Key: ' . getenv('ORBIT_API_KEY'),
'Content-Type: application/json',
]);
curl_setopt($ch, CURLOPT_POSTFIELDS, <<<JSON
{
"priceId": "price_def456",
"successUrl": "https://orbit.devotel.io/settings/billing?success=true",
"cancelUrl": "https://orbit.devotel.io/settings/billing?cancelled=true"
}
JSON);
echo curl_exec($ch);
{
"data": {
"checkoutUrl": "https://checkout.stripe.com/c/pay/cs_live_abc123..."
},
"meta": {
"request_id": "req_chk_001",
"timestamp": "2026-03-08T12:00:00Z"
}
}
Get Current Usage
GET /v1/billing/usage
Retrieve your current billing period usage metrics from Orb. Includes per-channel message counts, voice minutes, and agent invocations.
cURL
curl -X GET "https://orbit-api.devotel.io/api/v1/billing/usage" \
-H "X-API-Key: dv_live_sk_your_key_here"
Node.js
import { Orbit } from '@devotel/orbit-sdk'
const orbit = new Orbit({
apiKey: process.env.ORBIT_API_KEY!,
})
const res = await fetch('https://orbit-api.devotel.io/api/v1/billing/usage', {
method: 'GET',
headers: {
'X-API-Key': process.env.ORBIT_API_KEY!,
},
})
console.log(await res.json())
Python
import os, requests
headers = {"X-API-Key": os.environ["ORBIT_API_KEY"]}
r = requests.get("https://orbit-api.devotel.io/api/v1/billing/usage", headers=headers)
print(r.json())
Go
package main
import (
"bytes"
"net/http"
"os"
)
func main() {
req, _ := http.NewRequest("GET", "https://orbit-api.devotel.io/api/v1/billing/usage", nil)
req.Header.Set("X-API-Key", os.Getenv("ORBIT_API_KEY"))
http.DefaultClient.Do(req)
}
Ruby
require 'net/http'
require 'json'
uri = URI('https://orbit-api.devotel.io/api/v1/billing/usage')
req = Net::HTTP::Get.new(uri)
req['X-API-Key'] = ENV['ORBIT_API_KEY']
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |h| h.request(req) }
puts res.body
PHP
<?php
$ch = curl_init('https://orbit-api.devotel.io/api/v1/billing/usage');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'X-API-Key: ' . getenv('ORBIT_API_KEY'),
]);
echo curl_exec($ch);
{
"data": {
"billing_period": {
"start": "2026-03-01T00:00:00Z",
"end": "2026-03-31T23:59:59Z"
},
"messages": {
"sms": { "sent": 3420, "included": 25000 },
"whatsapp": { "sent": 1580, "included": 25000 },
"email": { "sent": 890, "included": 25000 },
"rcs": { "sent": 120, "included": 25000 },
"viber": { "sent": 45, "included": 25000 }
},
"voice": {
"minutes_used": 142,
"minutes_included": 500
},
"agents": {
"invocations": 2340,
"invocations_included": 10000
}
},
"meta": {
"request_id": "req_usage_001",
"timestamp": "2026-03-08T12:00:00Z"
}
}
List Invoices
GET /v1/billing/invoices
Retrieve past invoices for your organization from Stripe.
cURL
curl -X GET "https://orbit-api.devotel.io/api/v1/billing/invoices" \
-H "X-API-Key: dv_live_sk_your_key_here"
Node.js
import { Orbit } from '@devotel/orbit-sdk'
const orbit = new Orbit({
apiKey: process.env.ORBIT_API_KEY!,
})
const res = await fetch('https://orbit-api.devotel.io/api/v1/billing/invoices', {
method: 'GET',
headers: {
'X-API-Key': process.env.ORBIT_API_KEY!,
},
})
console.log(await res.json())
Python
import os, requests
headers = {"X-API-Key": os.environ["ORBIT_API_KEY"]}
r = requests.get("https://orbit-api.devotel.io/api/v1/billing/invoices", headers=headers)
print(r.json())
Go
package main
import (
"bytes"
"net/http"
"os"
)
func main() {
req, _ := http.NewRequest("GET", "https://orbit-api.devotel.io/api/v1/billing/invoices", nil)
req.Header.Set("X-API-Key", os.Getenv("ORBIT_API_KEY"))
http.DefaultClient.Do(req)
}
Ruby
require 'net/http'
require 'json'
uri = URI('https://orbit-api.devotel.io/api/v1/billing/invoices')
req = Net::HTTP::Get.new(uri)
req['X-API-Key'] = ENV['ORBIT_API_KEY']
res = Net::HTTP.start(uri.host, uri.port, use_ssl: true) { |h| h.request(req) }
puts res.body
PHP
<?php
$ch = curl_init('https://orbit-api.devotel.io/api/v1/billing/invoices');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'X-API-Key: ' . getenv('ORBIT_API_KEY'),
]);
echo curl_exec($ch);
{
"data": [
{
"id": "inv_abc123",
"number": "INV-2026-003",
"amount": 19900,
"currency": "usd",
"status": "paid",
"period_start": "2026-02-01T00:00:00Z",
"period_end": "2026-02-28T23:59:59Z",
"pdf_url": "https://pay.stripe.com/invoice/acct_xxx/inv_abc123/pdf",
"created_at": "2026-03-01T00:00:00Z"
},
{
"id": "inv_def456",
"number": "INV-2026-002",
"amount": 19900,
"currency": "usd",
"status": "paid",
"period_start": "2026-01-01T00:00:00Z",
"period_end": "2026-01-31T23:59:59Z",
"pdf_url": "https://pay.stripe.com/invoice/acct_xxx/inv_def456/pdf",
"created_at": "2026-02-01T00:00:00Z"
}
],
"meta": {
"request_id": "req_inv_001",
"timestamp": "2026-03-08T12:00:00Z"
}
}
Invoice amounts are in the smallest currency unit (e.g., cents for USD). Divide by 100 for display.