# Rate limits and throttling

**Dynamic Throttling System**

The system incorporates a dynamic throttling mechanism designed to maintain fair resource allocation and prevent any single developer from monopolizing system resources in ways that could degrade performance for others.

**How It Works**

The throttling system operates on a token bucket model with two core components:

* **Rate Limit**: A maximum quota of requests allocated to each developer
* **Request Cost**: Each API request consumes a portion of your quota based on its resource intensity

When you make a request, the associated cost is deducted from your available quota. Your quota automatically replenishes at a steady rate over time, ensuring continuous access while preventing burst abuse patterns.

**Handling Throttled Requests**

If your request is throttled due to insufficient remaining quota, the API will return a `403 Forbidden` response with the status message "Rate Limit Exceeded." Your application should implement robust error handling to gracefully manage this scenario by:

* Catching the 403 response code
* Implementing exponential backoff or scheduled retry logic
* Deferring the request until quota has been replenished

**Monitoring Your Usage**

To help you proactively manage your API consumption and avoid throttling, every response includes informative headers:

* **`X-Request-Cost`**: A floating-point value indicating the exact quota amount consumed by the current request
* **`X-Rate-Limit-Remaining`**: Your current remaining quota balance (only included when throttling is active for your account)

By monitoring these headers, you can build intelligent rate-limiting logic into your application and optimize request patterns to stay within your allocated quota.


---

# 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.shiftiq.com/developers/api-v2/rate-limits-and-throttling.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.
