Staking Data

Credits & Limits

Rate limits, credit calculation, and optimization strategies.

Rate Limits

The API enforces a limit of 60 requests per minute per API Key.

Credit Calculation

Each credit represents approximately one data point. The system measures resource consumption based on query complexity and data returned.

Credit Consumption Formula

The core calculation involves three components:

  1. Field Count: Total number of fields requested in the GraphQL query
  2. Response Entries: Number of records returned
  3. Total Calculation: (Fields × Entries) + Fields = Credits Consumed

Per-Field Credit Rates

Not all fields cost the same. The credit rate depends on which entity the field belongs to:

EntityCredits per datapoint
metrics3 credits
All other entities1 credit

Fields under a metrics node — such as metricKey, defaultValue, value, or createdAt — cost 3 credits per leaf scalar, both in the query fields counted and in the response data returned.

Example

Querying 1 non-metrics field and 2 metrics fields across 100 assets:

Non-metrics: (1 field × 100 entries) + 1 = 101 credits
Metrics:     (2 fields × 100 entries) + 2 = 202 credits × 3 = 606 credits
Total: 707 credits

Credits are based on actual data returned, not theoretical maximums. If only 50 assets exist instead of 100, actual consumption is lower.

Nested Query Complexity

For queries with nested fields, credits accumulate at each level. Parent and child field counts are multiplied by their respective entry counts, then summed together with total unique fields in the query.

Historical Data Surcharge

Historical data queries incur a flat 5,000-credit surcharge on top of the normal per-field cost. This reflects the higher value of historical data.

The following fields are not available for historical data queries: changePercentages, changeAbsolutes. Requesting, filtering, or ordering by these fields in a historical query returns a 400 error.

Tracking Credit Usage Per Request

Every successful GraphQL and Ratings API response includes an X-Used-Credits header showing the exact number of credits consumed by that request:

X-Used-Credits: 703

You can use this header to monitor consumption in real time, validate your credit estimates, and identify expensive queries before they impact your quota.

Optimization Strategies

  • Request only necessary fields to reduce per-query consumption
  • Use specific filters (date ranges, metric keys) to limit returned data
  • Structure queries to explicitly target needed datapoints rather than requesting broad results

On this page