/// <reference types="fhir" />
import Practitioner from './lib/models/fhir/Practitioner';
import DocumentReference from './lib/models/fhir/DocumentReference';
import Attachment from './lib/models/fhir/Attachment';
export declare const D4LSDK: {
    getCurrentUserId: () => string;
    getCurrentAppId: () => string;
    grantPermission: (appId: string, annotations?: string[]) => Promise<void>;
    getReceivedPermissions: () => Promise<import("./services/userService").Permission[]>;
    setCurrentUserLanguage: (languageCode: string) => void;
    createAppData: (ownerId: string, data: any, date?: Date, annotations?: string[]) => Promise<any>;
    fetchAppData: (ownerId: string, appDataId: string) => Promise<import("./services/types").DecryptedAppData>;
    updateAppData: (ownerId: string, data: any, id: string, date: any, annotations?: string[]) => Promise<any>;
    deleteAppData: (ownerId: string, resourceId: string) => Promise<void>;
    fetchAllAppData: (ownerId: string, params?: import("./services/types").Params) => Promise<import("./services/types").FetchResponse<import("./services/types").AppData>>;
    createResource: (ownerId: string, fhirResource: fhir.DomainResource, date?: Date, annotations?: string[]) => Promise<import("./services/types").Record>;
    fetchResource: (ownerId: string, resourceId: string) => Promise<import("./services/types").Record>;
    updateResource: (ownerId: string, fhirResource: fhir.DomainResource, date: Date, annotations?: string[]) => Promise<import("./services/types").Record>;
    deleteResource: (ownerId: string, resourceId: string) => Promise<void>;
    countResources: (ownerId: string, params?: import("./services/types").Params) => Promise<number>;
    fetchResources: (ownerId: string, params?: import("./services/types").Params) => Promise<import("./services/types").FetchResponse<import("./services/types").Record>>;
    downloadResource: (ownerId: string, resourceId: string, options?: {
        imageSize: string;
    }) => Promise<import("./services/types").Record>;
    createCodeableConcept: (display?: string, code?: string, system?: string) => fhir.CodeableConcept;
    getCodeFromCodeableConcept: (fhirCodeableConcept: fhir.CodeableConcept) => string;
    getDisplayFromCodeableConcept: (fhirCodeableConcept: fhir.CodeableConcept) => string;
    isAllowedFileType: (file: import("./lib/BlobFile").IBlobFile) => Promise<unknown>;
    crypto: {
        createChangePasswordPayload: (currentPassword: string, newPassword: string, decryptedCup: string) => Promise<{
            password_hash: string;
            new_password_hash: string;
            new_password_key_salt: any;
            new_cup: any;
        }>;
        createResetPasswordPayload: (recoveryKey: string, newPassword: string, decryptedCup: string) => Promise<{
            recovery_password_hash: string;
            new_password_hash: string;
            new_password_key_salt: any;
            new_cup: any;
        }>;
        createKeyRotationPayload: (args: {
            permissionIdsToRevoke: string[];
            permissionsToKeep: {
                permission_id: string;
                grantee_public_key: string;
            }[];
            keys: {
                cap: CryptoKey;
                encryptedCommonKey: string;
                encryptedTagEncryptionKey: string;
            };
            userPublicKey: CryptoKey;
        }) => Promise<{
            tek: any;
            common_key: any;
            revoked_grantees: string[];
            shared_common_keys: {
                permission_id: string;
                common_key: any;
            }[];
        }>;
        createLoginHash: (password: string) => Promise<string>;
        createRegisterPayload: (email: string, password: string, recoveryKey: string) => Promise<{
            password_hash: string;
            password_key_salt: string;
            cup: string;
            recovery_password_hash: string;
            recovery_password_key_salt: string;
            recovery_cup: string;
            public_key: string;
            tag_encryption_key: string;
            common_key: string;
            email: string;
        }>;
        createShareApproveDetails: (args: {
            keys: {
                cap: CryptoKey;
                encryptedCommonKey: string;
                encryptedTagEncryptionKey: string;
            };
            commonKeyHistory: {
                common_key_id: string;
                common_key: string;
            }[];
            requesterPublicKey: CryptoKey;
            tag: string;
        }) => Promise<{
            encryptedTag: any;
            requesterCommonKeyHistory: {
                common_key_id: string;
                common_key: any;
            }[];
        }>;
        decryptCUP: (password: string, passwordSalt: string, cup: string) => Promise<string>;
        getEncryptedCommonKeyWithAppPublicKey: ({ appPubKey, loginResponse, password, }: {
            appPubKey: any;
            loginResponse: any;
            password: any;
        }) => Promise<any>;
        generateAppKeyPair: () => Promise<any>;
        importKey: any;
        encryptString: (string: any) => Promise<any[]>;
        decryptString: (keyObject: any, cipherString: any) => Promise<any>;
    };
    throttleRequest: (interval?: number) => Promise<undefined>;
    createCAP: () => any;
    sealCAP: (privateKey: any) => any;
    models: {
        Practitioner: typeof Practitioner;
        DocumentReference: typeof DocumentReference;
        Attachment: typeof Attachment;
    };
    /**
     * sets up the D4L SDK
     * @param clientId the clientId provided by data4life
     * @param environment the environment in which the SDK is run
     * @param privateKey the privateKey returned from the sealCAP method
     * @param requestAccessToken returns a new valid accessToken
     *      of the logged in user
     * @param extendedEnvConfig environment config to extend the base config
     * @param fhirVersion the FHIR Version in use
     * @returns the id of the logged in user
     */
    setup({ clientId, environment, privateKey, requestAccessToken, extendedEnvConfig, fhirVersion, }: {
        clientId: string;
        environment: string;
        privateKey: any;
        requestAccessToken: () => Promise<string>;
        extendedEnvConfig?: any;
        fhirVersion?: string;
    }): Promise<string>;
    /**
     * resets the SDK
     */
    reset(): void;
};
export default D4LSDK;
