Create invoice
Create an invoice for agent payment.
The response contains two IDs:
- `id` is the merchant-side UUID
- `public_invoice_id` is the payer-facing `inv_*` identifier
Authentication
AuthorizationBearer
Merchant API key (`sk_m_*`).
```
Authorization: Bearer sk_m_abc123def456...
```
Headers
Idempotency-Key
Client-generated UUID v4 for safe retries. Requests with the same key return the original response.
Request
This endpoint expects an object.
amount_usdc
USDC amount in atomic units (6 decimals). Used in REST response bodies. 1000000 = 1.00 USDC.
description
metadata
metadata_public
expires_in_seconds
Response headers
X-Request-Id
Unique request identifier for debugging and support
Response
Invoice created
id
public_invoice_id
merchant_id
amount_usdc
USDC amount in atomic units (6 decimals). Used in REST response bodies. 1000000 = 1.00 USDC.
currency
Allowed values:
status
Allowed values:
metadata_public
created_at
expires_at
agent_protocol
description
metadata
Errors
400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
429
Too Many Requests Error