UNPKG

twitch-oauth

Version:
21 lines 798 B
import { TwitchOAuthResponse } from './twitch-oauth-response'; import { TwitchOAuthValidation } from './twitch-oauth-validation'; import TwitchScope from './twitch-scope'; type TwitchOAuthMethod = 'token' | 'code'; interface TwitchOAuthSettings { clientId: string; clientSecret: string; redirectUri: string; scope: TwitchScope[]; method?: TwitchOAuthMethod; } export declare class TwitchOAuth { private readonly settings; constructor(settings: TwitchOAuthSettings); authenticate(): string; verifyCodeResponse(code: string): Promise<TwitchOAuthResponse>; validate(accessToken: string): Promise<TwitchOAuthValidation>; refresh(refresh_token: string): Promise<TwitchOAuthResponse>; } export {}; //# sourceMappingURL=twitch-oauth.d.ts.map