Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.heychocolate.com/llms.txt

Use this file to discover all available pages before exploring further.

The Hey Chocolate API enforces rate limits to ensure fair usage and platform stability.

Rate limit headers

Every API response includes rate limit information:
HeaderDescription
X-RateLimit-LimitMaximum requests per window
X-RateLimit-RemainingRemaining requests in the current window
X-RateLimit-ResetUnix timestamp when the window resets

Limits by tier

TierRequests/minCalculations/dayAsset renders/day
Free601,000100
Growth60050,0005,000
Enterprise6,000+Unlimited50,000+

Handling rate limits

When you exceed the rate limit, the API returns a 429 Too Many Requests response:
{
  "errors": [
    {
      "message": "Rate limit exceeded. Retry after 12 seconds.",
      "extensions": {
        "code": "RATE_LIMIT_EXCEEDED",
        "retryAfter": 12
      }
    }
  ]
}
Best practices:
  • Implement exponential backoff when receiving 429 responses
  • Cache frequently accessed data (product scores change infrequently)
  • Use pagination to reduce the number of requests
  • Batch related queries into a single GraphQL request

Caching recommendations

Product detail page (PDP) data is ideal for edge caching since impact scores update infrequently:
Data typeRecommended TTL
Product impact scores1 hour
Equivalency translations1 hour
Supply chain data15 minutes
Calculation resultsDo not cache (dynamic)
DPP documents24 hours