| Total Complexity | 2 |
| Total Lines | 24 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 22 | class TwitterCC extends OAuth2Provider implements ClientCredentials{ |
||
| 23 | |||
| 24 | protected const AUTH_ERRMSG = 'TwitterCC only supports Client Credentials Grant, use the Twitter OAuth1 class for authentication instead.'; |
||
| 25 | |||
| 26 | protected string $apiURL = 'https://api.twitter.com'; |
||
| 27 | protected ?string $clientCredentialsTokenURL = 'https://api.twitter.com/oauth2/token'; |
||
| 28 | protected ?string $userRevokeURL = 'https://twitter.com/settings/applications'; |
||
| 29 | protected ?string $apiDocs = 'https://developer.twitter.com/en/docs/basics/authentication/overview/application-only'; |
||
| 30 | protected ?string $applicationURL = 'https://developer.twitter.com/apps'; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @inheritdoc |
||
| 34 | * @throws \chillerlan\OAuth\Core\ProviderException |
||
| 35 | */ |
||
| 36 | public function getAuthURL(array $params = null, array $scopes = null):UriInterface{ |
||
| 38 | } |
||
| 39 | |||
| 40 | /** |
||
| 41 | * @inheritdoc |
||
| 42 | * @throws \chillerlan\OAuth\Core\ProviderException |
||
| 43 | */ |
||
| 44 | public function getAccessToken(string $code, string $state = null):AccessToken{ |
||
| 49 |