Skip to main content
All APIs return errors in a consistent envelope format.

Error Format

Error Codes

Validation Errors

422 VALIDATION_ERROR responses include field-level details:

Best Practices

  • Check the code field for programmatic error handling, not the message
  • Log the full error response for debugging
  • Implement retry logic with exponential backoff for 429 and 5xx errors
  • Do not retry 4xx errors (except 429) — they indicate a client issue

Domain-specific 422 responses

Some endpoints return 422 with a domain-specific message identifying which input field failed which rule. See:
  • AB 660 / Date Labels — the Products API returns 422 when product_name, description, net_content, or usage_instructions contains a phrase banned by California AB 660 (e.g. "sell by", "best before", "expires on").