Closed as not planned
Description
Code of Conduct
- I have read and agree to the GitHub Docs project's Code of Conduct
What article on docs.github.com is affected?
https://docs.github.com/en/rest/apps/oauth-applications?apiVersion=2022-11-28#check-a-token
What part(s) of the article would you like to see updated?
The article says:
You must use Basic Authentication to use this endpoint, where the username is the application client_id and the password is its client_secret
However, the curl example does not do this:
curl -L \
-X POST \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer <YOUR-TOKEN>"\
-H "X-GitHub-Api-Version: 2022-11-28" \
https://api.github.com/applications/Iv1.8a61f9b3a7aba766/token \
-d '{"access_token":"e72e16c7e42f292c6912e7710c838347ae178b4a"}'
I found this confusing, and eventually figured out that I need to follow the advice here and modify the curl example accordingly.
It would be good to have the example code match the text.
Additional information
No response