# GitHub Authentication with Octokit

DevFeed: [GitHub Authentication with Octokit](<https://devfeed.tech/articles/github-authentication-with-octokit-40695.md>)

Original publisher: [Read original article](<https://radek.io/posts/github-oauth-with-octokit/>)

Published: 2014-08-03T00:00:00Z

Content type: tutorial

Language: en

Sources: [Radek Pazdera](<https://devfeed.tech/sources/radek-pazdera.md>)

Topics: [GitHub](<https://devfeed.tech/topics/github.md>), [OAuth](<https://devfeed.tech/topics/oauth.md>), [GitHub API](<https://devfeed.tech/topics/github-api.md>), [Authentication](<https://devfeed.tech/topics/authentication.md>)

Tags: [api](<https://devfeed.tech/tags/api.md>), [callback](<https://devfeed.tech/tags/callback.md>), [client](<https://devfeed.tech/tags/client.md>), [framework](<https://devfeed.tech/tags/framework.md>), [github](<https://devfeed.tech/tags/github.md>), [oauth](<https://devfeed.tech/tags/oauth.md>), [scope](<https://devfeed.tech/tags/scope.md>), [token](<https://devfeed.tech/tags/token.md>)

## AI overview

This tutorial explains how to implement GitHub OAuth authentication with the Octokit toolkit and Sinatra. It covers redirecting users to GitHub, handling the callback and code parameter, exchanging application credentials for an access token, and using token scopes to limit API actions.

## Source excerpt

Using Sinatra + Octokit to get an OAuth token from GitHub