POST /api/payroll/run resolves the payer from the authenticated merchant’s wallet and processes recipients sequentially. It is not one atomic transaction: some recipients can succeed while others fail or await signature.
Authenticated mainnet payroll has not been executed. Before using a team batch, review the wallet, token, funds/fees and each destination. See availability.
Prepare a batch
Use the verified active merchant’s server-side API key or supported merchant session. BodypayerSCA/payerWalletId does not choose the debited wallet. Each recipient supplies recipientSCA, positive decimal amount (up to 6 decimals) and optional label; a batch has 1–200 recipients.
Batch currency/tokenAddress selects one canonical USDC/EURC token. Tokens cannot be mixed or converted inside a batch. A spend-limit gate applies before fresh execution.
Wallet modes and results
- Circle Developer-Controlled wallet: server-authorized transfers; inspect each result’s status, hash and actual receipt.
- External merchant wallet: separate
PENDING_SIGNATURErequests, batchAWAITING_SIGNATURES. Queuing a request is not payment. Automatic batch completion as those requests land is not implemented; inspect actual signature-request receipt/state and reconcile manually. - Other final states include COMPLETED, FAILED and PARTIAL_FAILURE. Top-level
success: truemeans the handler returned a batch, not that everyone was paid.
batchRef is owner-scoped; GET without it lists the merchant’s recent batches. Replay/GET is not a live receipt scan.
Fees and retries
Gas and per-destination token fees may be additional. Testnet native USDC sends and ERC-20 operations have different measured fee behavior; do not assume contract payroll sends or mainnet are fee-exempt. After a timeout, inspect the saved batch, each Circle/signature request, receipts and recipient balances before retrying. Reusing the same batch key returns saved state; a new key can create new payments. Partial completion is not rolled back automatically.payroll.completed is an unsigned/best-effort notification and can report failed or partial final status; no durable retry or automatic external-signature completion is promised.
