Appearance
Rate Limits
Rate limits are applied to every API request and allow users to make a finite number of requests within a set time period. Rate limits apply to both OAuth access tokens and Personal Access Tokens. Users have separate limits for each team they are a member of.
API v2 rate limits are applied differently to v1. If you have an existing v1 integration you may need to account for these changes. See Application Examples for more details.
Headers
When a request is made, rate limit details are returned in the response headers:
bash
HTTP/1.1 204 No Content
X-RateLimit-Limit: 200
X-RateLimit-Remaining: 187
Rate limits may differ depending on the endpoint, with some being lower than others. Each time a request is made, X-RateLimit-Remaining
decreases until it reaches 0
.
Limit Exceeded
Once the rate limit has been reached, subsequent requests return a 429 Too Many Requests
response with additional headers:
bash
HTTP/1.1 429 Too Many Requests
X-RateLimit-Limit: 200
X-RateLimit-Remaining: 0
Retry-After: 47
X-RateLimit-Reset: 1693220870
Header | Description |
---|---|
Retry-After | The number of seconds remaining before the rate limit resets. |
X-RateLimit-Reset | The timestamp of when the rate limit resets. |
Application Examples
A single rate limit is shared by all tokens created by or for a user on a single team. The following are common scenarios:
- A user has three Personal Access Tokens for one team, each token shares the same rate limit.
- A user has a Personal Access Token and an OAuth access token for one team, each token shares the same rate limit.
- A user has a Personal Access Token for team A and another Personal Access Token for team B, each token has a separate rate limit.