How can I Get 403 Forbidden for endpoint 'users'? #114738
-
Select Topic AreaQuestion BodyI have to verify a scenario when I need to verify the 403 forbidden status for endpoint 'user'. so I have created an OAuth token with No Scope. End Point: https://api.github.com/user https://docs.github.com/en/rest/users/users?apiVersion=2022-11-28#get-the-authenticated-user |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
Hey Shivam, you get a HTTP/2 403 response once your API rate limit is exceeded (5000 requests). Add parameter I've just tested it on my end - after hitting the {"message":"API rate limit exceeded for user ID [removed]. If you reach out to GitHub Support for help, please include the request ID [removed].","documentation_url":"https://docs.github.com/rest/overview/rate-limits-for-the-rest-api"} Please be aware that the rate limit is user ID specific and not token specific. Hope that helps! |
Beta Was this translation helpful? Give feedback.
-
{"message":"API rate limit exceeded for user ID [removed]. If you reach out to GitHub Support for help, please include the request ID [removed].","documentation_url":"https://docs.github.com/rest/overview/rate-limits-for-the-rest-api"} |
Beta Was this translation helpful? Give feedback.
-
{"message":"API rate limit exceeded for user ID [removed]. If you reach out to GitHub Support for help, please include the request ID [removed].","documentation_url":"https://docs.github.com/rest/overview/rate-limits-for-the-rest-api"} |
Beta Was this translation helpful? Give feedback.
Hey Shivam,
you get a HTTP/2 403 response once your API rate limit is exceeded (5000 requests).
Add parameter
-i
to see how many requests remain until you hit your limit, i.e.curl -i -L (and so on)
.I've just tested it on my end - after hitting the
x-ratelimit-limit
, you receive a 403 along with the messagePlease be aware that the rate limit is user ID specific and not token specific.
Hope that helps!