1 | <?php namespace Arcanedev\Socialite\OAuth\Two; |
||
12 | class GithubProvider extends AbstractProvider |
||
13 | { |
||
14 | /* ------------------------------------------------------------------------------------------------ |
||
15 | | Properties |
||
16 | | ------------------------------------------------------------------------------------------------ |
||
17 | */ |
||
18 | /** |
||
19 | * The scopes being requested. |
||
20 | * |
||
21 | * @var array |
||
22 | */ |
||
23 | protected $scopes = ['user:email']; |
||
24 | |||
25 | /* ------------------------------------------------------------------------------------------------ |
||
26 | | Main Functions |
||
27 | | ------------------------------------------------------------------------------------------------ |
||
28 | */ |
||
29 | /** |
||
30 | * {@inheritdoc} |
||
31 | */ |
||
32 | protected function getAuthUrl($state) |
||
36 | |||
37 | /** |
||
38 | * {@inheritdoc} |
||
39 | */ |
||
40 | protected function getTokenUrl() |
||
44 | |||
45 | /** |
||
46 | * {@inheritdoc} |
||
47 | */ |
||
48 | protected function getUserByToken($token) |
||
62 | |||
63 | /** |
||
64 | * Get the email for the given access token. |
||
65 | * |
||
66 | * @param string $token |
||
67 | * |
||
68 | * @return string|null |
||
69 | */ |
||
70 | protected function getEmailByToken($token) |
||
89 | |||
90 | /** |
||
91 | * {@inheritdoc} |
||
92 | */ |
||
93 | protected function mapUserToObject(array $user) |
||
103 | |||
104 | /** |
||
105 | * Get the default options for an HTTP request. |
||
106 | * |
||
107 | * @return array |
||
108 | */ |
||
109 | protected function getRequestOptions() |
||
117 | } |
||
118 |