Billing Transparency
ASG is built on a principle of full billing transparency. Every cent is traceable — from quote generation to on-chain settlement. This page explains exactly how your money flows through the system.Billing Lifecycle
Every paid tool call follows the same deterministic lifecycle:Step 1: Quote Generation
When you call a paid tool, ASG calculates the exact price before any payment:- Upstream cost lookup — ASG queries the upstream provider (e.g., OpenAI, Anthropic) for the current rate.
- Margin applied — A transparent margin is added (see Margin Disclosure below).
- Quote created — A quote object is returned with the total price in microUSD and a time-to-live (TTL).
Quotes expire after their TTL (typically 5 minutes). If a quote expires, request a new one — pricing may have changed.
What determines the price?
| Factor | Example |
|---|---|
| Model | gpt-4o-mini vs claude-sonnet-4 |
| Token count | Input + output tokens for inference |
| Execution time | Sandbox charges per second |
| Upstream rate | Current provider pricing |
Step 2: Payment Verification
After receiving a quote, you sign a USDC transfer on Solana:- Agent signs — Your agent signs a USDC transfer for the quoted amount to ASG’s settlement address.
- Proof submitted — The signed transaction (or its signature) is sent to ASG via the
X-Paymentheader orpayment_proofbody field. - On-chain verification — ASG verifies the transaction on Solana mainnet:
- Correct amount transferred
- Correct recipient address
- Transaction finalized on-chain
- Idempotency check — Each transaction signature can only be used once. Replaying the same proof will not result in a double charge.
Step 3: Receipt Creation
After successful execution, a receipt is generated and returned in the response:- Receipt minted — A unique
receipt_idis created. - Debit recorded — The exact amount debited is stored (always matches the quote).
- Solana reference — The on-chain transaction signature (
tx_signature) is linked to the receipt. - Returned to agent — The receipt metadata is included in the
_metafield of the tool response.
Step 4: Balance Deductions
If you use prepaid balance (deposited USDC) instead of per-call payment:- Balance checked — Your account balance is verified against the quoted amount.
- Atomic deduction — The exact quoted amount is deducted from your balance atomically.
- No partial charges — If the tool fails after payment, the full amount is refunded to your balance.
- Receipt issued — Same receipt flow as direct payment.
| Scenario | What happens |
|---|---|
| Balance ≥ quote | Deduct → Execute → Receipt |
| Balance < quote | Rejected with insufficient_balance error |
| Execution fails | Full refund to balance |
| Quote expired | New quote required |
Balance deductions are recorded with the same
tx_signature traceability as direct Solana payments.Margin Disclosure
ASG charges a transparent margin on top of upstream provider costs. Here’s how pricing breaks down:What you pay
What the margin covers
| Component | Description |
|---|---|
| Infrastructure | Gateway servers, Solana relayers, monitoring |
| Gas sponsorship | We pay all Solana transaction fees (Gasless) |
| Reliability | Automatic retries, failover, idempotency |
| Developer tools | Console, receipts, analytics, API key management |
How to see the breakdown
Every quote includes the total amount. You can compare ASG pricing with upstream provider rates on our Pricing page.Verification & Audit
Every transaction is auditable:- Receipt lookup — Query any receipt by ID via the
billing_get_receipttool. - On-chain verification — Every
tx_signaturecan be verified on Solana Explorer. - Balance history — Check your current balance and recent transactions via the Console at agent.asgcompute.com/console.
Next Steps
Pricing
Detailed rates for all services
Receipts
Verify and query receipts
Gasless Payments
How we cover transaction fees
Billing Overview
High-level billing model