5042002). Every request goes to a single base URL and authenticates with a single Bearer token, making integration straightforward whether you’re building a storefront, a server-side backend, or an autonomous agent.
Base URL
All API requests target the following base URL. There are no version prefixes — endpoint paths begin at/api/.
Authentication
Every request must carry aAuthorization: Bearer header containing your FlareHQ API key. Unauthenticated requests are rejected with HTTP 401.
API keys are prefixed to indicate their environment. Keys beginning with
fhq_sec_test_ are testnet keys scoped to Arc testnet. Production keys begin with fhq_sec_. Never commit either key type to source control.Key types
Request Format
Send all request bodies as JSON and include theContent-Type: application/json header. Query-string parameters are supported where documented (e.g. filtering and pagination on list endpoints).
Response Envelope
All responses return a JSON object. Successful responses include"success": true alongside endpoint-specific fields. Failed responses include "success": false and a human-readable error string.
HTTP status codes
Rate Limits
FlareHQ enforces per-API-key rate limits to ensure fair use. When a limit is exceeded the API returnsHTTP 429. Back off and retry after the Retry-After interval indicated in the response headers.
Environments
All testnet transactions use Circle’s test USDC token and settle on the Arc testnet (chain ID
5042002). No real funds ever move during testnet development. Get test USDC at faucet.circle.com.Endpoint Groups
The FlareHQ API is organised into seven functional groups. Each group maps to a distinct/api/ path prefix.
Payments — /api/payments/*
Create and verify USDC payment sessions with a hosted checkout page. Supports merchant-initiated payment links, consumer send/request flows, and autonomous agent payments. → Initialize Payment · → Verify Payment · → Payment History
Escrow — /api/escrow/*
Lock USDC on-chain into a smart contract escrow and release it programmatically once conditions are met. Useful for milestone-based payments, conditional delivery, and dispute-safe commerce.
Streaming — /api/payments/stream/*
Open, manage, and close per-second USDC payment streams. Built for real-time service billing, agentic compute pricing, and any use case where continuous micro-settlement replaces lump-sum invoices.
x402 — /api/x402/*
Micro-payment proxy and marketplace layer using the x402 HTTP payment protocol. Enables any HTTP resource or API to gate access behind a USDC micro-payment, fulfilled automatically by compliant agents or wallets.
Agents — /api/agent/*
Register and manage ERC-8004 agent identities with on-chain SCA wallets. Agents created through this group can be referenced by their scaAddress in payment and job requests, enabling fully autonomous on-chain spending.

