import { IdObjectSkeletonInterface, NoIdObjectSkeletonInterface } from '../api/ApiTypes';
import { IdmConfigStub } from '../api/IdmConfigApi';
import { ConnectorServerStatusInterface } from '../api/IdmSystemApi';
import { State } from '../shared/State';
import { ExportMetaData } from './OpsTypes';
export type IdmConfig = {
    /**
     * Read available config entity types
     * @returns {string[]} promise resolving to an array of config entity types
     */
    readConfigEntityTypes(): Promise<string[]>;
    /**
     * Read all config entity stubs. For full entities use {@link IdmConfig.readConfigEntities | readConfigEntities}.
     * @returns {IdmConfigStub[]} promise resolving to an array of config entity stubs
     */
    readConfigEntityStubs(): Promise<IdmConfigStub[]>;
    /**
     * Read all config entities
     * @returns {IdObjectSkeletonInterface[]} promise reolving to an array of config entities
     */
    readConfigEntities(): Promise<IdObjectSkeletonInterface[]>;
    /**
     * Read all config entities of a type
     * @param {string} type config entity type
     * @returns {IdObjectSkeletonInterface[]} promise resolving to an array of config entities of a type
     */
    readConfigEntitiesByType(type: string): Promise<IdObjectSkeletonInterface[]>;
    /**
     * Read config entity
     * @param {string} entityId config entity id/name
     * @returns {IdObjectSkeletonInterface} promise resolving to a config entity
     */
    readConfigEntity(entityId: string): Promise<IdObjectSkeletonInterface>;
    /**
     * Export a single IDM config entity
     * @param {string} entityId config entity id
     * @param {ConfigEntityExportOptions} options export options
     * @returns {ConfigEntityExportInterface} promise resolving to a ConfigEntityExportInterface object
     */
    exportConfigEntity(entityId: string, options?: ConfigEntityExportOptions): Promise<ConfigEntityExportInterface>;
    /**
     * Export all IDM config entities
     * @param {ConfigEntityExportOptions} options export options
     * @returns {ConfigEntityExportInterface} promise resolving to a ConfigEntityExportInterface object
     */
    exportConfigEntities(options?: ConfigEntityExportOptions): Promise<ConfigEntityExportInterface>;
    /**
     * Create config entity
     * @param {string} entityId config entity id/name
     * @param {IdObjectSkeletonInterface} entityData config entity data
     * @param {boolean} wait delay the response until an OSGi service event confirms the change has been consumed by the corresponding service or the request times out.
     * @returns {IdObjectSkeletonInterface} promise resolving to a config entity
     */
    createConfigEntity(entityId: string, entityData: IdObjectSkeletonInterface, wait?: boolean): Promise<IdObjectSkeletonInterface>;
    /**
     * Update or create config entity
     * @param {string} entityId config entity id/name
     * @param {IdObjectSkeletonInterface} entityData config entity data
     * @param {boolean} wait delay the response until an OSGi service event confirms the change has been consumed by the corresponding service or the request times out.
     * @returns {IdObjectSkeletonInterface} promise resolving to a config entity
     */
    updateConfigEntity(entityId: string, entityData: IdObjectSkeletonInterface, wait?: boolean): Promise<IdObjectSkeletonInterface>;
    /**
     * Import idm config entities.
     * @param {ConfigEntityExportInterface} importData idm config entity import data.
     * @param {string} entityId Optional entity id that, when provided, will only import the entity of that id from the importData
     * @param {ConfigEntityImportOptions} options import options
     * @returns {Promise<IdObjectSkeletonInterface[]>} a promise resolving to an array of config entity objects
     */
    importConfigEntities(importData: ConfigEntityExportInterface, entityId?: string, options?: ConfigEntityImportOptions): Promise<IdObjectSkeletonInterface[]>;
    /**
     * Delete all config entities
     * @returns {IdObjectSkeletonInterface[]} promise reolving to an array of config entities
     */
    deleteConfigEntities(): Promise<IdObjectSkeletonInterface[]>;
    /**
     * Delete all config entities of a type
     * @param {string} type config entity type
     * @returns {IdObjectSkeletonInterface[]} promise resolving to an array of config entities of a type
     */
    deleteConfigEntitiesByType(type: string): Promise<IdObjectSkeletonInterface[]>;
    /**
     * Delete config entity
     * @param {string} entityId config entity id/name
     * @returns {IdObjectSkeletonInterface} promise resolving to a config entity
     */
    deleteConfigEntity(entityId: string): Promise<IdObjectSkeletonInterface>;
    /**
     * Read a idm sub config entity.
     * @param {string} entityId entity id for the parent config entity of the sub config entity that is being read
     * @param {string} name name of the sub config entity that is being read
     * @param {ConfigEntityExportOptions} options export options
     * @returns {Promise<IdObjectSkeletonInterface>} a promise resolving to a sub config entity object
     */
    readSubConfigEntity(entityId: string, name: string, options?: ConfigEntityExportOptions): Promise<NoIdObjectSkeletonInterface>;
    /**
     * Import a idm sub config entity.
     * @param {string} entityId entity id for parent config entity of the sub config that is being updated
     * @param {NoIdObjectSkeletonInterface} updatedSubConfigEntity the updated sub config entity
     * @param {ConfigEntityImportOptions} options import options
     * @returns {Promise<IdObjectSkeletonInterface[]>} a promise resolving to an array of config entity objects
     */
    importSubConfigEntity(entityId: string, updatedSubConfigEntity: IdObjectSkeletonInterface, options?: ConfigEntityImportOptions): Promise<IdObjectSkeletonInterface[]>;
    /**
     * Get available config entity types
     * @returns {string[]} promise resolving to an array of config entity types
     * @deprecated since v2.0.0 use {@link IdmConfig.readConfigEntityTypes | readConfigEntityTypes} instead
     * ```javascript
     * readConfigEntityTypes(): Promise<string[]>
     * ```
     * @group Deprecated
     */
    getConfigEntityTypes(): Promise<string[]>;
    /**
     * Get all config entities
     * @returns {IdObjectSkeletonInterface[]} promise reolving to an array of config entities
     * @deprecated since v2.0.0 use {@link IdmConfig.readConfigEntities | readConfigEntities} instead
     * ```javascript
     * readConfigEntities(): Promise<IdObjectSkeletonInterface[]>
     * ```
     * @group Deprecated
     */
    getAllConfigEntities(): Promise<IdmConfigStub[]>;
    /**
     * Get all config entities of a type
     * @param {string} type config entity type
     * @returns {IdObjectSkeletonInterface[]} promise resolving to an array of config entities of a type
     * @deprecated since v2.0.0 use {@link IdmConfig.readConfigEntitiesByType | readConfigEntitiesByType} instead
     * ```javascript
     * readConfigEntitiesByType(type: string): Promise<IdObjectSkeletonInterface[]>
     * ```
     * @group Deprecated
     */
    getConfigEntitiesByType(type: string): Promise<IdObjectSkeletonInterface[]>;
    /**
     * Get config entity
     * @param {string} entityId config entity id/name
     * @returns {IdObjectSkeletonInterface} promise resolving to a config entity
     * @deprecated since v2.0.0 use {@link IdmConfig.readConfigEntity | readConfigEntity} instead
     * ```javascript
     * readConfigEntity(entityId: string): Promise<IdObjectSkeletonInterface>
     * ```
     * @group Deprecated
     */
    getConfigEntity(entityId: string): Promise<IdObjectSkeletonInterface>;
    /**
     * Put config entity
     * @param {string} entityId config entity id/name
     * @param {IdObjectSkeletonInterface} entityData config entity data
     * @returns {IdObjectSkeletonInterface} promise resolving to a config entity
     * @deprecated since v2.0.0 use {@link IdmConfig.updateConfigEntity | updateConfigEntity} or {@link IdmConfig.createConfigEntity | createConfigEntity} instead
     * ```javascript
     * updateConfigEntity(entityId: string, entityData: IdObjectSkeletonInterface): Promise<IdObjectSkeletonInterface>
     * createConfigEntity(entityId: string, entityData: IdObjectSkeletonInterface): Promise<IdObjectSkeletonInterface>
     * ```
     * @group Deprecated
     */
    putConfigEntity(entityId: string, entityData: IdObjectSkeletonInterface): Promise<IdObjectSkeletonInterface>;
    /**
     * Test connector servers
     * @deprecated since v2.0.0-42 use {@link IdmSystem.testConnectorServers | testConnectorServers} or {@link IdmSystem.testConnectorServers | testConnectorServers} instead
     * @returns {Promise<ConnectorServerStatusInterface[]>} a promise that resolves to an array of ConnectorServerStatusInterface objects
     */
    testConnectorServers(): Promise<ConnectorServerStatusInterface[]>;
};
declare const _default: (state: State) => IdmConfig;
export default _default;
/**
 * Idm export options
 */
export interface ConfigEntityExportOptions {
    /**
     * Gives a list of entities to export. If undefined or empty, it will export all entities.
     */
    entitiesToExport?: string[];
    /**
     * Gives the list of key-value pairs of env replacements. Replaces each occurrence of the value with '${key}', where key is the correspond key to the value.
     */
    envReplaceParams?: string[][];
}
/**
 * Config entity import options
 */
export interface ConfigEntityImportOptions {
    /**
     * Gives a list of entities to import. If undefined or empty, it will import all entities.
     */
    entitiesToImport?: string[];
    /**
     * Gives the list of key-value pairs of env replacements. Replaces each occurrence of '${key}' with its value.
     */
    envReplaceParams?: string[][];
    /**
     * validate script hooks
     */
    validate: boolean;
}
export interface ConfigEntityExportInterface {
    meta?: ExportMetaData;
    idm: Record<string, IdObjectSkeletonInterface>;
}
/**
 * Create an empty config entity export template
 * @returns {ConfigEntityExportInterface} an empty config entity export template
 */
export declare function createConfigEntityExportTemplate({ state, }: {
    state: State;
}): ConfigEntityExportInterface;
export declare function readConfigEntityStubs({ state, }: {
    state: State;
}): Promise<IdmConfigStub[]>;
export declare function readConfigEntityTypes({ state, }: {
    state: State;
}): Promise<string[]>;
export declare function readConfigEntities({ state, }: {
    state: State;
}): Promise<IdObjectSkeletonInterface[]>;
export declare function readConfigEntitiesByType({ type, state, }: {
    type: string;
    state: State;
}): Promise<NoIdObjectSkeletonInterface[]>;
export declare function readConfigEntity({ entityId, state, }: {
    entityId: string;
    state: State;
}): Promise<IdObjectSkeletonInterface>;
export declare const AIC_PROTECTED_ENTITIES: string[];
/**
 * Export a single IDM config entity
 * @param {string} entityId config entity id
 * @param {ConfigEntityExportOptions} options export options
 * @returns {ConfigEntityExportInterface} promise resolving to a ConfigEntityExportInterface object
 */
export declare function exportConfigEntity({ entityId, options, state, }: {
    entityId: string;
    options?: ConfigEntityExportOptions;
    state: State;
}): Promise<ConfigEntityExportInterface>;
/**
 * Export all IDM config entities
 * @param {ConfigEntityExportOptions} options export options
 * @returns {ConfigEntityExportInterface} promise resolving to a ConfigEntityExportInterface object
 */
export declare function exportConfigEntities({ options, state, }: {
    options?: ConfigEntityExportOptions;
    state: State;
}): Promise<ConfigEntityExportInterface>;
export declare function createConfigEntity({ entityId, entityData, wait, state, }: {
    entityId: string;
    entityData: IdObjectSkeletonInterface;
    wait?: boolean;
    state: State;
}): Promise<IdObjectSkeletonInterface>;
export declare function updateConfigEntity({ entityId, entityData, wait, state, }: {
    entityId: string;
    entityData: IdObjectSkeletonInterface;
    wait?: boolean;
    state: State;
}): Promise<IdObjectSkeletonInterface>;
export declare function importConfigEntities({ entityId, importData, options, state, }: {
    entityId?: string;
    importData: ConfigEntityExportInterface;
    options: ConfigEntityImportOptions;
    state: State;
}): Promise<IdObjectSkeletonInterface[]>;
export declare function deleteConfigEntities({ state, }: {
    state: State;
}): Promise<IdObjectSkeletonInterface[]>;
export declare function deleteConfigEntitiesByType({ type, state, }: {
    type: string;
    state: State;
}): Promise<IdObjectSkeletonInterface[]>;
export declare function deleteConfigEntity({ entityId, state, }: {
    entityId: string;
    state: State;
}): Promise<IdObjectSkeletonInterface>;
export declare function readSubConfigEntity({ entityId, name, options, state, }: {
    entityId: string;
    name: string;
    options?: ConfigEntityExportOptions;
    state: State;
}): Promise<NoIdObjectSkeletonInterface>;
export declare function importSubConfigEntity({ entityId, updatedSubConfigEntity, options, state, }: {
    entityId: string;
    updatedSubConfigEntity: IdObjectSkeletonInterface;
    options: ConfigEntityImportOptions;
    state: State;
}): Promise<IdObjectSkeletonInterface[]>;
//# sourceMappingURL=IdmConfigOps.d.ts.map