curl "https://api.saturn-pay.com/v1/wallet/transactions?limit=20" \
-H "Authorization: Bearer sk_agt_..."
curl "https://api.saturn-pay.com/v1/wallet/transactions?startDate=2024-01-01&endDate=2024-01-31" \
-H "Authorization: Bearer sk_agt_..."
const response = await fetch('https://api.saturn-pay.com/v1/wallet/transactions', {
headers: { 'Authorization': 'Bearer sk_agt_...' }
});
const { transactions } = await response.json();
// Sum total spend
const totalSpent = transactions
.filter(tx => tx.type === 'charge')
.reduce((sum, tx) => sum + tx.amountUsdCents, 0);
console.log(`Total spent: $${(totalSpent / 100).toFixed(2)}`);
{
"transactions": [
{
"id": "tx_abc123",
"type": "charge",
"amountUsdCents": 15,
"amountSats": 45,
"description": "reason (openai/gpt-4o)",
"agentId": "agt_xyz789",
"capability": "reason",
"provider": "openai",
"auditId": "aud_def456",
"createdAt": "2024-01-20T14:30:00Z"
},
{
"id": "tx_def456",
"type": "credit",
"amountUsdCents": 1000,
"amountSats": 30000,
"description": "Card payment",
"createdAt": "2024-01-20T10:00:00Z"
}
],
"total": 2,
"limit": 50,
"offset": 0
}
Wallets
List Transactions
List all wallet transactions
GET
/
v1
/
wallet
/
transactions
curl "https://api.saturn-pay.com/v1/wallet/transactions?limit=20" \
-H "Authorization: Bearer sk_agt_..."
curl "https://api.saturn-pay.com/v1/wallet/transactions?startDate=2024-01-01&endDate=2024-01-31" \
-H "Authorization: Bearer sk_agt_..."
const response = await fetch('https://api.saturn-pay.com/v1/wallet/transactions', {
headers: { 'Authorization': 'Bearer sk_agt_...' }
});
const { transactions } = await response.json();
// Sum total spend
const totalSpent = transactions
.filter(tx => tx.type === 'charge')
.reduce((sum, tx) => sum + tx.amountUsdCents, 0);
console.log(`Total spent: $${(totalSpent / 100).toFixed(2)}`);
{
"transactions": [
{
"id": "tx_abc123",
"type": "charge",
"amountUsdCents": 15,
"amountSats": 45,
"description": "reason (openai/gpt-4o)",
"agentId": "agt_xyz789",
"capability": "reason",
"provider": "openai",
"auditId": "aud_def456",
"createdAt": "2024-01-20T14:30:00Z"
},
{
"id": "tx_def456",
"type": "credit",
"amountUsdCents": 1000,
"amountSats": 30000,
"description": "Card payment",
"createdAt": "2024-01-20T10:00:00Z"
}
],
"total": 2,
"limit": 50,
"offset": 0
}
Returns a list of all transactions (charges, credits, refunds) for your wallet.
Query Parameters
string
Filter by type:
charge, credit, refundstring
Filter by agent ID
string
ISO 8601 date to filter from
string
ISO 8601 date to filter to
number
Maximum number of results (default: 50, max: 100)
number
Number of results to skip (for pagination)
Response
array
Array of transaction objects
Show Transaction object
Show Transaction object
string
Transaction ID
string
charge, credit, or refundnumber
Amount in USD cents
number
Amount in satoshis
string
Human-readable description
string
Agent that initiated the transaction
string
Capability used (for charges)
string
Provider used (for charges)
string
Audit log ID (for charges)
string
ISO 8601 timestamp
curl "https://api.saturn-pay.com/v1/wallet/transactions?limit=20" \
-H "Authorization: Bearer sk_agt_..."
curl "https://api.saturn-pay.com/v1/wallet/transactions?startDate=2024-01-01&endDate=2024-01-31" \
-H "Authorization: Bearer sk_agt_..."
const response = await fetch('https://api.saturn-pay.com/v1/wallet/transactions', {
headers: { 'Authorization': 'Bearer sk_agt_...' }
});
const { transactions } = await response.json();
// Sum total spend
const totalSpent = transactions
.filter(tx => tx.type === 'charge')
.reduce((sum, tx) => sum + tx.amountUsdCents, 0);
console.log(`Total spent: $${(totalSpent / 100).toFixed(2)}`);
{
"transactions": [
{
"id": "tx_abc123",
"type": "charge",
"amountUsdCents": 15,
"amountSats": 45,
"description": "reason (openai/gpt-4o)",
"agentId": "agt_xyz789",
"capability": "reason",
"provider": "openai",
"auditId": "aud_def456",
"createdAt": "2024-01-20T14:30:00Z"
},
{
"id": "tx_def456",
"type": "credit",
"amountUsdCents": 1000,
"amountSats": 30000,
"description": "Card payment",
"createdAt": "2024-01-20T10:00:00Z"
}
],
"total": 2,
"limit": 50,
"offset": 0
}
⌘I