# API Credits & Rate Limits

API credits are consumed per asset in a request:

* **BTC**: 1 credit per request
* **All other assets**: 2 credits per request

For example, a single request for ETH market data consumes 2 credits, while a request for BTC market data consumes 1 credit.

{% hint style="info" %}
**Legacy plans**: Customers on API plans purchased before November 2025 may have different credit calculation formulas as part of their original plan terms. If you're unsure which model applies, contact your account manager.
{% endhint %}

### Bulk Endpoints and API Credits

Bulk endpoints allow users to retrieve data for multiple parameter combinations in a single request. While this is efficient in terms of reducing the number of API calls, it's essential to understand how API credits are consumed:

* **Credit Calculation**: Each request to a bulk endpoint consumes credits based on the number of assets requested (1 credit for BTC, 2 credits for any other asset). Other parameters like exchanges or networks do not affect credit consumption. For example:
  * Calling the `/market/mvrv/bulk` endpoint with BTC and 4 other assets will consume 1 + (4 × 2) = 9 API credits, regardless of how many exchanges are included.
* **Parameter Whitelists**: When the asset parameter is not specified, the bulk endpoint returns data for all available assets, which can lead to significant credit consumption. To manage and predict credit usage effectively, it's advisable to always specify the assets (`a`) parameter explicitly.

For more detailed information on bulk endpoints and their usage, refer to the [Bulk Metrics](https://docs.glassnode.com/basic-api/bulk-metrics) documentation.

### Track Current Month Credit Usage

You can monitor your API credit usage in two ways:

* **Studio dashboard**: Visit [studio.glassnode.com/settings/api](https://studio.glassnode.com/settings/api) to see your current month's credit usage and a history of recent API calls with their individual credit consumption.
* **API endpoint**: `https://api.glassnode.com/v1/user/api_usage` — returns a JSON object that includes a `creditsUsed` field (for example, `{ ..., "creditsUsed": 6, ... }`).

## Rate Limits

Rate limits are applied to all API requests to ensure stability and fair usage. If you exceed the rate limit, the API will return a **429 Too Many Requests** error.

To increase your rate limit, please contact your account manager.

#### General Limits

* **Standard Requests:** Defaults to **600 req/min**, or varies based on your specific access tier.
* **Metadata Endpoints:** Separately limited to **1200 req/min**. This bucket is fully isolated and does not impact your standard request quota.
* **Studio:** Requests made via Glassnode Studio from the same account do consume your API rate limit as well. Studio may request multiple metrics (e.g. on a dashboard) as well as call metadata endpoints.

***

#### Response Headers

Every API response includes headers to help you track your usage:

| Header                   | Description                                                      |
| ------------------------ | ---------------------------------------------------------------- |
| `x-rate-limit-limit`     | The total request limit per minute (e.g., `600`).                |
| `x-rate-limit-remaining` | The number of requests left in the current window (e.g., `599`). |
| `x-rate-limit-reset`     | Time in seconds until the limit resets (e.g., `60`).             |

#### Best Practices & Common Pitfalls

**1. High Cardinality Requests (Assets/Exchanges)** Running into limits when requesting many parameter combinations (e.g., iterating through a list of assets) is a common issue.

* **Solution:** Use [**Bulk Endpoints**](https://docs.glassnode.com/~/revisions/16NjoBk2BV1L86OQTWKU/basic-api/bulk-metrics). These allow you to fetch data for multiple parameters (like "all assets" or "all exchanges") in a single request.

**2. Looping Through Metrics** Scripts that loop through numerous metrics often trigger rate limits.

* **Solution:** Pass the `x-rate-limit` headers to your HTTP client library. Many modern libraries can read these headers to automatically pace requests and respect the reset window. Otherwise, you can implement a delay that adheres to the rate limit.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.glassnode.com/basic-api/api-credits.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
