Skip to main content
StateSet API uses standard HTTP response codes and provides detailed error information to help you handle issues gracefully.

Error Response Format

All errors follow a consistent JSON structure to make error handling predictable:

HTTP Status Codes

Error Types and Codes

Authentication Errors (401)

Authorization Errors (403)

Validation Errors (400/422)

Resource Errors (404/409)

Business Logic Errors (422)

Rate Limiting Errors (429)

Error Handling Best Practices

1. Implement Exponential Backoff

2. Handle Specific Error Types

3. Implement Circuit Breaker Pattern

4. Log and Monitor Errors

Error Recovery Strategies

Idempotency for Safe Retries

Graceful Degradation

Common Error Scenarios

Handling Validation Errors

Handling Resource Conflicts

Error Webhooks

Configure error webhooks to receive notifications for critical failures:

SDK Error Handling

Our SDKs provide built-in error handling:

Testing Error Scenarios

Use test mode to simulate error conditions:

Support

If you encounter persistent errors or need help with error handling:
Related: Rate Limiting | Authentication | Webhooks