Order status lifecycle
Every AnySpend order moves through these states:Order statuses
Error codes
Payment errors
INSUFFICIENT_BALANCE
INSUFFICIENT_BALANCE
User doesn’t have enough tokens. Prompt them to add funds or switch to a different token.
INVALID_TOKEN_ADDRESS
INVALID_TOKEN_ADDRESS
Token contract isn’t supported on the target chain. Show the user which tokens are available.
MINIMUM_AMOUNT_NOT_MET
MINIMUM_AMOUNT_NOT_MET
Transaction amount is below the minimum threshold.
MAXIMUM_AMOUNT_EXCEEDED
MAXIMUM_AMOUNT_EXCEEDED
Transaction amount exceeds the limit. Split into multiple transactions or reduce the amount.
Network errors
SLIPPAGE
SLIPPAGE
Price moved beyond tolerance during execution. Retry or wait for the market to settle.
NETWORK_ERROR
NETWORK_ERROR
RPC connection issue or chain congestion. Retry after a short delay.
QUOTE_EXPIRED
QUOTE_EXPIRED
Price quote is stale. Fetch a new one.
CHAIN_NOT_SUPPORTED
CHAIN_NOT_SUPPORTED
Requested chain isn’t supported. Show the user which chains are available.
Contract errors
CONTRACT_CALL_FAILED
CONTRACT_CALL_FAILED
Smart contract execution failed. Double-check the contract parameters and state.
INSUFFICIENT_GAS
INSUFFICIENT_GAS
Gas limit was too low. Retry with a higher limit.
NONCE_TOO_LOW
NONCE_TOO_LOW
Nonce conflict from a pending transaction. Wait for the pending tx to confirm, then retry.
TRANSACTION_REVERTED
TRANSACTION_REVERTED
The contract reverted. Usually means a precondition wasn’t met (e.g., sale ended, not enough allowance).
Error handling patterns
Per-component error handling
Payment with error handling
Order status monitoring
Order tracker
Error boundary
Wrap AnySpend components in an error boundary to catch rendering crashes:Error boundary
User-friendly error messages
A helper that maps error codes to messages your users can actually understand:Error message helper
Tips
- Keep users informed during long operations. Cross-chain transactions can take a few minutes — show progress, not just a spinner.
- Retry transient errors (slippage, network, quote expired) with exponential backoff. Many resolve on the second try.
- Log errors with context (order ID, user address, timestamp) so you can debug issues after the fact.
- Offer fallbacks when possible. If cross-chain fails, suggest same-chain. If crypto fails, suggest fiat onramp.
Getting help
Discord
Get help from the community and support team
GitHub
Report bugs and request features
When reporting issues, include: error message/code, steps to reproduce, browser/device info, and order ID if applicable.
HypeDuel