Skip to content

Latest commit

 

History

History
152 lines (128 loc) · 3.44 KB

File metadata and controls

152 lines (128 loc) · 3.44 KB

API Report File for "firebase-admin.app"

Do not edit this file. It is a report generated by API Extractor.

import { Agent } from 'http';

// @public
export interface App {
    name: string;
    options: AppOptions;
}

// @public
export class AppErrorCodes {
    // (undocumented)
    static APP_DELETED: string;
    // (undocumented)
    static DUPLICATE_APP: string;
    // (undocumented)
    static INTERNAL_ERROR: string;
    // (undocumented)
    static INVALID_APP_NAME: string;
    // (undocumented)
    static INVALID_APP_OPTIONS: string;
    // (undocumented)
    static INVALID_ARGUMENT: string;
    // (undocumented)
    static INVALID_CREDENTIAL: string;
    // (undocumented)
    static NETWORK_ERROR: string;
    // (undocumented)
    static NETWORK_TIMEOUT: string;
    // (undocumented)
    static NO_APP: string;
    // (undocumented)
    static UNABLE_TO_PARSE_RESPONSE: string;
}

// @public
export function applicationDefault(httpAgent?: Agent): Credential;

// @public
export interface AppOptions {
    credential?: Credential;
    databaseAuthVariableOverride?: object | null;
    databaseURL?: string;
    httpAgent?: Agent;
    projectId?: string;
    serviceAccountId?: string;
    storageBucket?: string;
}

// @public
export function cert(serviceAccountPathOrObject: string | ServiceAccount, httpAgent?: Agent): Credential;

// @public
export interface Credential {
    getAccessToken(): Promise<GoogleOAuthAccessToken>;
}

// @public
export function deleteApp(app: App): Promise<void>;

// @public
export interface ErrorInfo {
    // (undocumented)
    cause?: Error;
    // (undocumented)
    code: string;
    // (undocumented)
    httpResponse?: HttpResponse;
    // (undocumented)
    message: string;
}

// Warning: (ae-forgotten-export) The symbol "PrefixedFirebaseError" needs to be exported by the entry point index.d.ts
//
// @public
export class FirebaseAppError extends PrefixedFirebaseError {
}

// @public
export interface FirebaseArrayIndexError {
    error: FirebaseError;
    index: number;
}

// @public
export interface FirebaseError {
    // (undocumented)
    cause?: Error;
    code: string;
    // (undocumented)
    httpResponse?: HttpResponse;
    message: string;
    stack?: string;
    toJSON(): object;
}

// @public
export class FirebaseError extends Error implements FirebaseError {
    constructor(errorInfo: ErrorInfo);
}

// @public
export function getApp(appName?: string): App;

// @public
export function getApps(): App[];

// @public
export interface GoogleOAuthAccessToken {
    // (undocumented)
    access_token: string;
    // (undocumented)
    expires_in: number;
}

// @public (undocumented)
export interface HttpResponse {
    // (undocumented)
    data?: any;
    // (undocumented)
    headers: {
        [key: string]: any;
    };
    // (undocumented)
    status: number;
}

// @public
export function initializeApp(options?: AppOptions, appName?: string): App;

// @public
export function refreshToken(refreshTokenPathOrObject: string | object, httpAgent?: Agent): Credential;

// @public (undocumented)
export const SDK_VERSION: string;

// @public (undocumented)
export interface ServiceAccount {
    // (undocumented)
    clientEmail?: string;
    // (undocumented)
    privateKey?: string;
    // (undocumented)
    projectId?: string;
}