import * as client from '@botpress/client';
import type { Logger } from '../logger';
import { ApiPackageRef, NamePackageRef } from '../package-ref';
import * as utils from '../utils';
import * as paging from './paging';
import { ApiClientProps, PublicOrUnlistedIntegration, PrivateIntegration, PublicOrPrivateIntegration, PublicInterface, PrivateInterface, PublicOrPrivateInterface, PrivatePlugin, PublicPlugin, PublicOrPrivatePlugin, BotSummary } from './types';
export * from './types';
/**
 * This class is used to wrap the Botpress API and provide a more convenient way to interact with it.
 */
export declare class ApiClient {
    private _logger;
    readonly client: client.Client;
    readonly url: string;
    readonly token: string;
    readonly workspaceId: string;
    readonly botId?: string;
    static newClient: (props: ApiClientProps, logger: Logger) => ApiClient;
    constructor(props: ApiClientProps, _logger: Logger);
    get isBotpressWorkspace(): boolean;
    safeListTables(req: client.ClientInputs['listTables']): Promise<{
        success: true;
        tables: client.ClientOutputs['listTables']['tables'];
    } | {
        success: false;
        error: Error;
    }>;
    getWorkspace(): Promise<client.ClientOutputs['getWorkspace']>;
    findWorkspaceByHandle(handle: string): Promise<client.ClientOutputs['getWorkspace'] | undefined>;
    switchWorkspace(workspaceId: string): ApiClient;
    switchBot(botId: string): ApiClient;
    updateWorkspace(props: utils.types.SafeOmit<client.ClientInputs['updateWorkspace'], 'id'>): Promise<client.ClientOutputs['updateWorkspace']>;
    getPublicOrPrivateIntegration(ref: ApiPackageRef): Promise<PublicOrPrivateIntegration>;
    findPublicOrPrivateIntegration(ref: ApiPackageRef): Promise<PublicOrPrivateIntegration | undefined>;
    findPrivateIntegration(ref: ApiPackageRef): Promise<PrivateIntegration | undefined>;
    findPublicIntegration(ref: ApiPackageRef): Promise<PublicOrUnlistedIntegration | undefined>;
    findPublicOrPrivateInterface(ref: ApiPackageRef): Promise<PublicOrPrivateInterface | undefined>;
    findPrivateInterface(ref: ApiPackageRef): Promise<PrivateInterface | undefined>;
    getPublicInterface(ref: ApiPackageRef): Promise<PublicInterface>;
    findPublicInterface(ref: ApiPackageRef): Promise<PublicInterface | undefined>;
    findPublicPlugin(ref: ApiPackageRef): Promise<PublicPlugin | undefined>;
    getPublicOrPrivatePlugin(ref: ApiPackageRef): Promise<PublicOrPrivatePlugin>;
    findPublicOrPrivatePlugin(ref: ApiPackageRef): Promise<PublicOrPrivatePlugin | undefined>;
    findPrivatePlugin(ref: ApiPackageRef): Promise<PrivatePlugin | undefined>;
    testLogin(): Promise<void>;
    listAllPages: typeof paging.listAllPages;
    findPreviousIntegrationVersion(ref: NamePackageRef): Promise<PublicOrPrivateIntegration | undefined>;
    findBotByName(name: string): Promise<BotSummary | undefined>;
    private _returnUndefinedOnError;
}
