Skip to main content
The Kotani Pay API uses conventional HTTP response codes to indicate the success or failure of an API request. In general:
  • 2xx codes indicate success
  • 4xx codes indicate an error that failed given the information provided
  • 5xx codes indicate an error with Kotani Pay’s servers

Error Response Format

All error responses follow a consistent format:

Common Error Codes

Best Practices

  1. Always check the response status before processing the response body
  2. Implement retry logic for 5xx errors with exponential backoff
  3. Log error responses for debugging and monitoring
  4. Handle rate limiting by implementing proper backoff strategies