Skip to content

Conversation

@bflyblue
Copy link

I've been layering the GitHub Apps preview API (https://developer.github.com/v3/apps/) on top of the existing endpoints for a project of mine, but it requires Authorization: Bearer tokens.

Would you consider extending the Auth type to include bearer tokens?

FYI: I'm adding the Checks API as well, I don't know if I should send a PR for this when I'm done as it's a developer preview?

@phadej
Copy link
Contributor

phadej commented Feb 18, 2019

https://developer.github.com/v3/#authentication mentions only Authorization: token deadc0de tokens. How token and Bearer tokens are different?

@bflyblue bflyblue changed the title Extended Auth to include a Bearer token Extend Auth to include a Bearer token Feb 18, 2019
@bflyblue
Copy link
Author

bflyblue commented Feb 18, 2019

It looks like GitHub is moving away from "OAuth Apps" to "GitHub Apps" for some things which uses a different API, see:

https://developer.github.com/apps/differences-between-apps/
and
https://developer.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app

To authenticate as a GitHub App a JWT needs to be passed in the Authentication header with the Bearer prefix. I've tried using "token" and it's refused by the API.

@phadej
Copy link
Contributor

phadej commented Feb 18, 2019

I guess https://developer.github.com/v3/#authentication isn't updated because Apps are in preview.

Even this is seems safe change to do, I'm not willing to merge (or especially release) as far as

Warning: The API may change without advance notice during the preview period. Preview features are not supported for production use. If you experience any issues, contact GitHub Support.

Please use your fork for now, and ping me when preview period over.

@bflyblue
Copy link
Author

Understood! I'll keep this as a fork for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants