UNPKG

674 BTypeScriptView Raw
1import { Interfaces } from '@oclif/core';
2import { APIClient } from './api-client';
3export declare namespace Login {
4 interface Options {
5 expiresIn?: number;
6 method?: 'interactive' | 'sso' | 'browser';
7 browser?: string;
8 }
9}
10export declare class Login {
11 private readonly config;
12 private readonly heroku;
13 loginHost: string;
14 constructor(config: Interfaces.Config, heroku: APIClient);
15 login(opts?: Login.Options): Promise<void>;
16 logout(token?: string | undefined): Promise<any>;
17 private browser;
18 private interactive;
19 private createOAuthToken;
20 private saveToken;
21 private defaultToken;
22 private sso;
23}