1 | <?php |
||
10 | class Douban extends Base |
||
11 | { |
||
12 | public const NAME = 'douban'; |
||
13 | |||
14 | protected function getAuthUrl(): string |
||
18 | |||
19 | protected function getTokenUrl(): string |
||
23 | |||
24 | /** |
||
25 | * @param string $token |
||
26 | * @param array|null $query |
||
27 | * |
||
28 | * @return array |
||
29 | */ |
||
30 | protected function getUserByToken(string $token, ?array $query = []): array |
||
40 | |||
41 | /** |
||
42 | * @param array $user |
||
43 | * |
||
44 | * @return \Overtrue\Socialite\User |
||
45 | */ |
||
46 | protected function mapUserToObject(array $user): User |
||
56 | |||
57 | /** |
||
58 | * @param string $code |
||
59 | * |
||
60 | * @return array|string[] |
||
61 | */ |
||
62 | protected function getTokenFields(string $code): array |
||
66 | |||
67 | /** |
||
68 | * @param string $code |
||
69 | * |
||
70 | * @return array |
||
71 | * @throws \Overtrue\Socialite\Exceptions\AuthorizeFailedException |
||
72 | */ |
||
73 | public function tokenFromCode(string $code): array |
||
81 | } |
||
82 |