ZATA
ZATA is the credit unit used to pay for storage, compute, bandwidth, queries, and API calls across the Zatabase platform. You buy ZATA with USD and spend it on database operations. Every ZATA movement is signed, durable, and recorded in an auditable ledger. Current rates apply at checkout and are shown in your dashboard.
Overview
Section titled “Overview”- USD billing: Purchase ZATA in USD via Stripe checkout
- Signed and durable: Every transaction is cryptographically signed and persisted
- Auditable ledger: Every ZATA movement is recorded with a stable sequence and transaction id
- Escrow support: Lock ZATA for pending service, release on completion, refund if cancelled
All ZATA operations require authentication and are scoped to the authenticated organization.
API Endpoints
Section titled “API Endpoints”All ZATA endpoints are mounted under /v1/credits:
| Endpoint | Method | Description |
|---|---|---|
/v1/credits/balance | GET | Get current balance |
/v1/credits/purchase | POST | Purchase ZATA |
/v1/credits/transactions | GET | List transaction history |
/v1/credits/transactions/:tx_id | GET | Get single transaction |
/v1/credits/escrow/lock | POST | Lock ZATA in escrow |
/v1/credits/escrow/:id/release | POST | Release escrowed ZATA |
/v1/credits/escrow/:id/refund | POST | Refund escrowed ZATA |
/v1/credits/escrow | GET | List active escrows |
Balance
Section titled “Balance”Check your organization’s ZATA balance:
curl -s https://your-project.zatabase.io/v1/credits/balance \ -H "Authorization: Bearer $ZATABASE_TOKEN" | jqResponse:
{ "success": true, "data": { "available": "500.00", "locked": "50.00", "total": "550.00" }}- available: ZATA ready to spend
- locked: ZATA held in active escrow locks
- total: Sum of available + locked
Purchasing ZATA
Section titled “Purchasing ZATA”Initiate a ZATA purchase via Stripe:
curl -s -X POST https://your-project.zatabase.io/v1/credits/purchase \ -H "Authorization: Bearer $ZATABASE_TOKEN" \ -H "Content-Type: application/json" \ -d '{ "amount_usd_cents": 1000 }' | jqResponse:
{ "success": true, "data": { "checkout_url": "https://checkout.stripe.com/...", "credits_to_receive": "1000000.00" }}The amount of ZATA you receive depends on the current rate, shown in the checkout response. Current rates apply at checkout and are visible in your dashboard.
Transaction History
Section titled “Transaction History”List recent transactions with pagination:
curl -s "https://your-project.zatabase.io/v1/credits/transactions?limit=20&offset=0" \ -H "Authorization: Bearer $ZATABASE_TOKEN" | jqEach transaction includes:
{ "tx_id": "01HQRS...", "tx_type": {"Mint": {"source": {"StripePurchase": {"payment_intent_id": "pi_..."}}}}, "amount": "100.00", "balance_after": "600.00", "locked_after": "50.00", "sequence": 42, "signature": "...", "created_at": "2026-03-01T12:00:00Z"}Transaction Types
Section titled “Transaction Types”| Type | Description |
|---|---|
Mint | ZATA added (via Stripe, ACH, node reward, or promotion) |
Burn | ZATA removed (redemption, expiry, or account closure) |
Transfer | ZATA moved between accounts |
EscrowLock | ZATA locked for pending service |
EscrowRelease | Locked ZATA released to provider |
EscrowRefund | Locked ZATA returned to locker |
Fee | Platform, processing, or withdrawal fee |
Escrow
Section titled “Escrow”Escrow locks reserve ZATA for pending service consumption. This ensures providers can be paid without risk of insufficient balance.
Lock ZATA
Section titled “Lock ZATA”curl -s -X POST https://your-project.zatabase.io/v1/credits/escrow/lock \ -H "Authorization: Bearer $ZATABASE_TOKEN" \ -H "Content-Type: application/json" \ -d '{ "amount": "100.00", "service": "compute", "expires_in_hours": 24 }' | jqThe service field is a free-form string used to tag the escrow for your own accounting.
Release to Provider
Section titled “Release to Provider”Release escrowed ZATA to the service provider after work is completed:
curl -s -X POST https://your-project.zatabase.io/v1/credits/escrow/{escrow_id}/release \ -H "Authorization: Bearer $ZATABASE_TOKEN" \ -H "Content-Type: application/json" \ -d '{ "amount": "75.00", "recipient_org_id": 42 }'Partial releases are supported. The remainder stays locked until explicitly released or refunded.
Refund
Section titled “Refund”Return escrowed ZATA to the original account:
curl -s -X POST https://your-project.zatabase.io/v1/credits/escrow/{escrow_id}/refund \ -H "Authorization: Bearer $ZATABASE_TOKEN"List Active Escrows
Section titled “List Active Escrows”curl -s https://your-project.zatabase.io/v1/credits/escrow \ -H "Authorization: Bearer $ZATABASE_TOKEN" | jqEscrow Lifecycle
Section titled “Escrow Lifecycle”Locked ──> PartiallyReleased ──> Released │ ├──> Refunded │ └──> Expired (automatic, past expires_at)Stale escrows are automatically expired by a background cleanup task.
Node Operator Payouts
Section titled “Node Operator Payouts”Anyone can run a Zatabase node and earn ZATA for serving database traffic. ZATA can be redeemed for USD via your configured payout method. Vultr and Hetzner are supported out of the box; you can also bring your own server. See the Edge Cache docs for node operator details.