import type { LaraClient } from "./net/lara";
import type { MultiPartFile } from "./net/lara/client";
export interface Memory {
    readonly id: string;
    readonly createdAt: Date;
    readonly updatedAt: Date;
    readonly sharedAt: Date;
    readonly name: string;
    readonly externalId?: string;
    readonly secret?: string;
    readonly ownerId: string;
    readonly collaboratorsCount: number;
    readonly isPersonal: boolean;
}
export interface MemoryImport {
    readonly id: string;
    readonly begin: number;
    readonly end: number;
    readonly channel: number;
    readonly size: number;
    readonly progress: number;
}
export type MemoryImportCallback = (memoryImport: MemoryImport) => void;
export declare class Memories {
    private readonly client;
    private readonly pollingInterval;
    constructor(client: LaraClient);
    list(): Promise<Memory[]>;
    create(name: string, externalId?: string): Promise<Memory>;
    get(id: string): Promise<Memory | null>;
    delete(id: string): Promise<Memory>;
    update(id: string, name: string): Promise<Memory>;
    connect<T extends string | string[]>(ids: T): Promise<T extends string ? Memory : Memory[]>;
    importTmx(id: string, tmx: MultiPartFile): Promise<MemoryImport>;
    importTmx(id: string, tmx: MultiPartFile, gzip: boolean): Promise<MemoryImport>;
    importTmx(id: string, tmx: MultiPartFile, callbackUrl: string): Promise<MemoryImport>;
    importTmx(id: string, tmx: MultiPartFile, gzip: boolean, callbackUrl: string): Promise<MemoryImport>;
    exportAsync(id: string, callbackUrl: string, format?: "tmx" | "jtm"): Promise<{
        jobId: string;
    }>;
    addTranslation(id: string | string[], source: string, target: string, sentence: string, translation: string, tuid?: string, sentenceBefore?: string, sentenceAfter?: string, headers?: Record<string, string>): Promise<MemoryImport>;
    deleteTranslation(id: string | string[], source: string, target: string, sentence?: string, translation?: string, tuid?: string, sentenceBefore?: string, sentenceAfter?: string): Promise<MemoryImport>;
    getImportStatus(id: string): Promise<MemoryImport>;
    waitForImport(mImport: MemoryImport, updateCallback?: MemoryImportCallback, maxWaitTime?: number): Promise<MemoryImport>;
}
