node-socialite
Version:
Socialite is an OAuth2 authentication tool for Node.js
18 lines (17 loc) • 626 B
TypeScript
import { ProviderConfig } from "../../types/global";
import { BaseProvider } from "../Core/BaseProvider";
import { User } from "../Core/User";
/**
* @see [OAuth认证](https://coding.net/help/openapi)
*/
export declare class Coding extends BaseProvider {
static NAME: string;
protected _scopes: string[];
protected teamUrl: string;
constructor(config: ProviderConfig);
getAuthUrl(): string;
getTokenUrl(): string;
getUserByToken(token: string): Promise<Record<string, any>>;
mapUserToObject(user: Record<string, any>): User;
protected getTokenFields(code: string): Record<string, any>;
}