You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The required value of `$password` depends on the chosen `$method`. For `Github\AuthMethod::AUTH_ACCESS_TOKEN`, `Github\Client::AUTH_ACCESS_TOKEN` and
25
-
`Github\Client::JWT` methods you should provide the API token in `$usernameOrToken` variable (`$password` is omitted in
24
+
The required value of `$password` depends on the chosen `$method`. For `Github\AuthMethod::CLIENT_ID`, `Github\AuthMethod::ACCESS_TOKEN` and
25
+
`Github\AuthMethod::JWT` methods you should provide the API token in `$usernameOrToken` variable (`$password` is omitted in
26
26
this particular case).
27
27
28
-
The `Github\Client::AUTH_JWT` authentication method sends the specified JSON Web Token in an Authorization header.
28
+
The `Github\AuthMethod::JWT` authentication method sends the specified JSON Web Token in an Authorization header.
29
29
30
30
After executing the `$client->authenticate($usernameOrToken, $secret, $method);` method using correct credentials, all
31
31
further requests are done as the given user.
32
32
33
33
### Authenticating as an Integration
34
34
35
-
To authenticate as an integration you need to supply a JSON Web Token with `Github\Client::AUTH_JWT` to request
36
-
and installation access token which is then usable with `Github\AuthMethod::AUTH_ACCESS_TOKEN`. [Github´s integration
35
+
To authenticate as an integration you need to supply a JSON Web Token with `Github\AuthMethod::JWT` to request
36
+
and installation access token which is then usable with `Github\AuthMethod::ACCESS_TOKEN`. [Github´s integration
37
37
authentication docs](https://developer.github.com/apps/building-github-apps/authentication-options-for-github-apps/#authenticating-as-a-github-app) describe the flow in detail.
38
38
It´s important for integration requests to use the custom Accept header `application/vnd.github.machine-man-preview`.
0 commit comments