Error Response Format
All error responses follow this format:HTTP Status Codes
400 Bad Request Errors
Invalid Amount
Invalid Currency
Missing Return URL
Invalid Return URL
Invalid Metadata
Missing Required Fields
401 Unauthorized Errors
Invalid API Key
- API key doesn’t exist
- API key format is incorrect
- API key was deleted
- Shop is inactive
- Check API key format:
- Verify API key in dashboard:
- Ensure proper authentication header:
Missing API Key
Shop Inactive
404 Not Found Errors
Payment Not Found
- Payment ID is incorrect
- Payment belongs to different shop
- Payment was deleted (rare)
- Verify payment ID format:
- Ensure payment exists:
429 Rate Limit Errors
Rate Limit Exceeded
- Implement exponential backoff:
- Implement request queuing:
- Cache responses:
500 Internal Server Error
Server Error
- Retry the request:
- Log the error and contact support if it persists
Network Errors
Connection Timeout
Cause: Request took too long to connect Solution:Network Failure
Cause: No internet connection or DNS failure Solution:Error Handling Best Practices
1. Implement Proper Error Handling
2. Provide User-Friendly Error Messages
3. Log All Errors
4. Implement Retry Logic
Debugging Errors
Enable Debug Logging
Inspect API Responses
Common Mistakes
1. Exposing API Keys
2. Not Handling Errors
3. Ignoring Rate Limits
Next Steps
API Reference
Complete API documentation
Rate Limits
Learn about rate limiting
Testing Guide
Test your error handling
Node.js Guide
See complete integration examples