Billing
List credit transactions
Transaction history, newest first. Amounts are in ₹; usage rows are negative.
GET
/
billing
/
transactions
List credit transactions
curl --request GET \
--url https://api.vocobase.com/api/v2/billing/transactions \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.vocobase.com/api/v2/billing/transactions"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.vocobase.com/api/v2/billing/transactions', 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.vocobase.com/api/v2/billing/transactions",
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: 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.vocobase.com/api/v2/billing/transactions"
req, _ := http.NewRequest("GET", url, nil)
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.vocobase.com/api/v2/billing/transactions")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vocobase.com/api/v2/billing/transactions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"transactions": [
{
"id": "tx_5f4e3d2c-1b0a-9876-5432-1fedcba09876",
"amount": -5.76,
"type": "usage",
"description": "Voice session",
"metadata": {
"session_id": "s2345678-abcd-1234-abcd-123456789012"
},
"created_at": "2026-08-20T09:36:28.000Z"
},
{
"id": "tx_6a5b4c3d-2e1f-0987-6543-2fedcba09877",
"amount": 25000,
"type": "purchase",
"description": "Top-up",
"metadata": null,
"created_at": "2026-08-18T11:02:00.000Z"
}
],
"total": 2,
"limit": 50,
"offset": 0
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "agent_name is required and must be max 50 characters"
}
}{
"success": false,
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid or missing API key"
}
}{
"success": false,
"error": {
"code": "RATE_LIMITED",
"message": "Rate limit exceeded. Retry after 60 seconds."
}
}{
"success": false,
"error": {
"code": "INTERNAL_ERROR",
"message": "An unexpected error occurred"
}
}Authorizations
API key in format: rg_live_xxxx. Pass as a Bearer token in the Authorization header.
Query Parameters
Page size. Default 50, maximum 100.
Required range:
x <= 100Rows to skip. Default 0.
Filter by transaction type.
Available options:
PURCHASE, USAGE, REFUND, BONUS Only transactions at or after this ISO 8601 date.
Only transactions at or before this ISO 8601 date.
⌘I
List credit transactions
curl --request GET \
--url https://api.vocobase.com/api/v2/billing/transactions \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.vocobase.com/api/v2/billing/transactions"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.vocobase.com/api/v2/billing/transactions', 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.vocobase.com/api/v2/billing/transactions",
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: 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.vocobase.com/api/v2/billing/transactions"
req, _ := http.NewRequest("GET", url, nil)
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.vocobase.com/api/v2/billing/transactions")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.vocobase.com/api/v2/billing/transactions")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"transactions": [
{
"id": "tx_5f4e3d2c-1b0a-9876-5432-1fedcba09876",
"amount": -5.76,
"type": "usage",
"description": "Voice session",
"metadata": {
"session_id": "s2345678-abcd-1234-abcd-123456789012"
},
"created_at": "2026-08-20T09:36:28.000Z"
},
{
"id": "tx_6a5b4c3d-2e1f-0987-6543-2fedcba09877",
"amount": 25000,
"type": "purchase",
"description": "Top-up",
"metadata": null,
"created_at": "2026-08-18T11:02:00.000Z"
}
],
"total": 2,
"limit": 50,
"offset": 0
}
}{
"success": false,
"error": {
"code": "VALIDATION_ERROR",
"message": "agent_name is required and must be max 50 characters"
}
}{
"success": false,
"error": {
"code": "UNAUTHORIZED",
"message": "Invalid or missing API key"
}
}{
"success": false,
"error": {
"code": "RATE_LIMITED",
"message": "Rate limit exceeded. Retry after 60 seconds."
}
}{
"success": false,
"error": {
"code": "INTERNAL_ERROR",
"message": "An unexpected error occurred"
}
}