import { BimCoreApi } from './BimCoreApi';
import { BimContainerInfo, TwinfinityInfo, BimContainer } from './loader/bim-api-client';
import { BimApiLoadOptions } from './BimApiLoadOptions';
import { TwinfinityApiClient } from './loader/client/TwinfinityApiClient';
import { TwinfinityApiOptions } from './loader/client/TwinfinityApiOptions';
import type { MeshStoreLoaderOptions } from '@twinfinity/geometry';
/**
 * Creation options for {@link BimApi}
 */
export type BimApiOptions = ({
    /**
     * If `true` then {@link BimApi} will automatically redirect the user
     * to the PS login page if the user is not already authenticated.
     */
    readonly isPSAuthenticationRedirectEnabled?: false;
    session?: TwinfinityApiOptions['session'];
} | {
    /**
     * If `true` then {@link BimApi} will automatically redirect the user
     * to the PS login page if the user is not already authenticated.
     */
    readonly isPSAuthenticationRedirectEnabled: true;
}) & {
    /** set this to a unique name for the appliation. Will allow log filtering on application name. */
    readonly applicationName?: string;
    /** Options for WASM-based geometry deflation. If provided, enables WASM loading. */
    readonly wasmLoaderOptions?: MeshStoreLoaderOptions;
};
/**
 * BimApi is the main API class. This a subclass of {@link BimCoreApi} that is extended
 * with information only available from the Twinfinity API backend.
 */
export declare class BimApi extends BimCoreApi {
    private readonly _apiClient;
    private _info?;
    private _containerInfo?;
    private readonly _bimApiOptions;
    private _twinfinitySession?;
    /**
     * Creates a new instance of {@link BimApi}.
     * @param _htmlElementOrId ID of the HTML element where the viewer should be created.
     * @param absoluteContainerUrlOrApiClient Absolute URL to the container.
     * @param options Creation options.
     * @example
     * ```typescript
     * // Create an API instance.
     * const api = await BimApi.create('viewer', 'project-url'); // Open project directly.
     * const api = await BimApi.create('viewer', new BimTwinfinityApiClient(url)); // Create API. If a valid container url is given, the API automatically switches to it, otherwise calls api.setContainer() afterwards.
     * ```
     */
    static create(_htmlElementOrId: string | HTMLElement, absoluteContainerUrlOrApiClient: URL | string | TwinfinityApiClient, options?: BimApiOptions): Promise<BimApi>;
    /** Constructor.
     * @param canvas Canvas element where 3D content will be rendered.
     * @param _apiClient Methods for communicating with the backend.
     */
    constructor(canvas: HTMLCanvasElement, _apiClient: TwinfinityApiClient, bimApiOptions?: BimApiOptions);
    /** General Twinfinity information such as customer portal name, Twinfinity API version etc. */
    info(): TwinfinityInfo;
    /** Direct access to the methods for communicating the backend. */
    get backend(): TwinfinityApiClient;
    /**
     * Gives information on currently selected container such as title, language
     * and also details of the current user.
     */
    get currentContainerInfo(): BimContainerInfo;
    /**
     * Sets the container of the current BimApi instance.
     * @param containerOrUrl Container object or absolute URL Example: https://bim.foo.com/sites/portal/projects/\{project name\}
     * @param options Loading options
     */
    setContainer(containerOrUrl: BimContainer | URL, options?: BimApiLoadOptions): Promise<void>;
    private static resolveTwinInput;
    private static getBaseUrl;
    protected initialize(): Promise<void>;
    private static getPsUrl;
    private static isTwinfinityApiClient;
}
//# sourceMappingURL=BimApi.d.ts.map