File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11Authenticating as an installation
22
3- Once In order to authenticate to GitHub as an installation of your GitHub App, you must use the App Installation Token
4- authentication mechanism. This can be easily achieved with this library by obtaining a <<<GitHub>>> instance like this:
3+ In order to authenticate to GitHub as an installation of your GitHub App, you must use the App Installation Token
4+ authentication mechanism. This can be achieved with by creating a <<<GitHub>>> instance like this:
55
66+-----+
77GitHub githubAuthAsInst = new GitHubBuilder()
@@ -11,7 +11,7 @@ GitHub githubAuthAsInst = new GitHubBuilder()
1111
1212How do I create an App Installation Token?
1313
14- Considering that you followed the {{{/githubappjwtauth.html} GitHub App Authentication via JWT token guide}} then you
14+ Assuming that you followed the {{{/githubappjwtauth.html} GitHub App Authentication via JWT token guide}} then you
1515 can create the App Installation Token like this:
1616
1717+-----+
Original file line number Diff line number Diff line change 11GitHub App Auth Flow
22
33 GitHub Apps are commonly mistaken for OAuth Apps due to their similarities but understanding the differences between
4- them will help you decide which app you want to create.
4+ them will help you decide which kind of app you want to create.
55
66 In a nutshell, an OAuth App acts as a GitHub user, whereas a GitHub App uses its own identity when installed on an
77 organization or on repositories within an organization. For a comprehensive comparision please refer to the official
88 GitHub {{{https://developer.github.com/apps/differences-between-apps/}documentation}}.
99
1010 For this guide, we are going assume that you are using a GitHub App.
1111
12- How does it look like?
12+ Overview
1313
14- Considering that your GitHub app has already been installed on either a user or an organization, the programmatic flow
14+ Assuming that your GitHub app has already been installed on either a user or an organization, the programmatic flow
1515 the developer must follow in order to be able to authenticate on their behalf is:
1616
1717[images/GitHub_App_Auth_Flow.jpg] GitHub_App_Auth_Flow
1818
19- The key point here is that you must know that multiple <<<GitHub>>> instances will have to be created and each of
20- them will be using a different authentication mechanism. Some actions can only be accessible if you are authenticated
21- as as GitHub App while other will only be possible if you are authenticated on behalf of a user or org.
19+ Multiple <<<GitHub>>> instances will have to be created and each of them will be using a different authentication
20+ mechanism. Some actions are only accessible if you are authenticated as a GitHub App while others will only be
21+ possible if you are authenticated on behalf of a user or org.
2222
23- Pre-requisites
23+ Prerequisites
2424
2525 In order to follow this guide, you must have:
2626
You can’t perform that action at this time.
0 commit comments