dennougorilla / gi3t

gist for use with ComputerCraft
1 stars 0 forks source link

Github API rate limiting #4

Open dennougorilla opened 5 years ago

dennougorilla commented 5 years ago

https://developer.github.com/v3/#rate-limiting

Rate limiting

For API requests using Basic Authentication or OAuth, you can make up to 5000 requests per hour. Authenticated requests are associated with the authenticated user, regardless of whether Basic Authentication or an OAuth token was used. This means that all OAuth applications authorized by a user share the same quota of 5000 requests per hour when they authenticate with different tokens owned by the same user.

For unauthenticated requests, the rate limit allows for up to 60 requests per hour. Unauthenticated requests are associated with the originating IP address, and not the user making requests.

Note that the Search API has custom rate limit rules.

The returned HTTP headers of any API request show your current rate limit status:

curl -i https://api.github.com/users/octocat
HTTP/1.1 200 OK
Date: Mon, 01 Jul 2013 17:27:06 GMT
Status: 200 OK
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 56
X-RateLimit-Reset: 1372700873
dennougorilla commented 5 years ago

https://qiita.com/syossan27/items/dd3bd152792360c29d01

curl -u "username" https://api.github.com
Enter host password for user 'username':

run this code on your server of Minecraft.