Frodo Library - v5.0.0-47
    Preparing search index...

    Type Alias SecretStore

    type SecretStore = {
        canSecretStoreHaveMappings(secretStoreTypeId: string): boolean;
        createSecretStoreExportTemplate(): SecretStoreExportInterface;
        createSecretStoreMapping(
            secretStoreId: string,
            secretStoreTypeId: string,
            secretStoreMappingData: SecretStoreMappingSkeleton,
            globalConfig: boolean,
        ): Promise<SecretStoreMappingSkeleton>;
        deleteSecretStore(
            secretStoreId: string,
            secretStoreTypeId: string,
            globalConfig: boolean,
        ): Promise<SecretStoreSkeleton>;
        deleteSecretStoreMapping(
            secretStoreId: string,
            secretStoreTypeId: string,
            secretId: string,
            globalConfig: boolean,
        ): Promise<SecretStoreMappingSkeleton>;
        deleteSecretStoreMappings(
            secretStoreId: string,
            secretStoreTypeId: string,
            globalConfig: boolean,
            resultCallback?: ResultCallback<SecretStoreMappingSkeleton>,
        ): Promise<SecretStoreMappingSkeleton[]>;
        deleteSecretStores(
            globalConfig: boolean,
            resultCallback?: ResultCallback<SecretStoreSkeleton>,
        ): Promise<SecretStoreSkeleton[]>;
        exportSecretStore(
            secretStoreId: string,
            secretStoreTypeId: string,
            globalConfig: boolean,
        ): Promise<SecretStoreExportInterface>;
        exportSecretStores(
            globalConfig: boolean,
            resultCallback?: ResultCallback<SecretStoreSkeleton>,
        ): Promise<SecretStoreExportInterface>;
        importSecretStores(
            importData: SecretStoreExportInterface,
            globalConfig: boolean,
            secretStoreId?: string,
            secretStoreTypeId?: string,
            resultCallback?: ResultCallback<SecretStoreSkeleton>,
        ): Promise<SecretStoreExportSkeleton[]>;
        readSecretStore(
            secretStoreId: string,
            secretStoreTypeId: string,
            globalConfig: boolean,
        ): Promise<SecretStoreSkeleton>;
        readSecretStoreMapping(
            secretStoreId: string,
            secretStoreTypeId: string,
            secretId: string,
            globalConfig: boolean,
        ): Promise<SecretStoreMappingSkeleton>;
        readSecretStoreMappings(
            secretStoreId: string,
            secretStoreTypeId: string,
            globalConfig: boolean,
        ): Promise<SecretStoreMappingSkeleton[]>;
        readSecretStores(globalConfig: boolean): Promise<SecretStoreSkeleton[]>;
        readSecretStoreSchema(
            secretStoreTypeId: string,
            globalConfig: boolean,
        ): Promise<SecretStoreSchemaSkeleton>;
        updateSecretStore(
            secretStoreData: SecretStoreSkeleton,
            globalConfig: boolean,
        ): Promise<SecretStoreSkeleton>;
        updateSecretStoreMapping(
            secretStoreId: string,
            secretStoreTypeId: string,
            secretStoreMappingData: SecretStoreMappingSkeleton,
            globalConfig: boolean,
        ): Promise<SecretStoreMappingSkeleton>;
    }
    Index
    • Function that returns true if the given secret store type can have mappings, false otherwise

      Parameters

      • secretStoreTypeId: string

        The secret store type

      Returns boolean

      true if the given secret store type can have mappings, false otherwise

    • Create secret store mapping. Will throw if type is not defined and multiple secret stores with the same id are found.

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • secretStoreMappingData: SecretStoreMappingSkeleton

        The secret store mapping data,

      • globalConfig: boolean

        true if the secret store is global, false otherwise. Default: false.

      Returns Promise<SecretStoreMappingSkeleton>

      a promise that resolves to a secret store mapping object of the mapping created

    • Delete secret store by id

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • globalConfig: boolean

        true if the secret store mapping is global, false otherwise. Default: false.

      Returns Promise<SecretStoreSkeleton>

      a promise that resolves to a secret store object

    • Delete secret store mapping

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • secretId: string

        Secret store mapping label. It is the last segment of the URL of the mapping, that is the _id of the mapping: it equals the label for a mapping that this library or the admin console created, but not for one created without an _id (the server then generates one and answers 404 to the label)

      • globalConfig: boolean

        true if the secret store mapping is global, false otherwise. Default: false.

      Returns Promise<SecretStoreMappingSkeleton>

      a promise that resolves to a secret store mapping object

    • Export a single secret store by id. The response can be saved to file as is. Will throw if type is not defined and multiple secret stores with the same id are found.

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • globalConfig: boolean

        true if global secret store is the target of the operation, false otherwise. Default: false.

      Returns Promise<SecretStoreExportInterface>

      Promise resolving to a SecretStoreExportInterface object.

    • Export all secret stores. The response can be saved to file as is. A secret store whose mappings cannot be read is not exported: the callback gets one error that names the store, or, without a callback, the function throws.

      Parameters

      • globalConfig: boolean

        true if global secret stores are the target of the operation, false otherwise. Default: false.

      • OptionalresultCallback: ResultCallback<SecretStoreSkeleton>

        Optional callback to process individual results

      Returns Promise<SecretStoreExportInterface>

      Promise resolving to a SecretStoreExportInterface object.

    • Import secret stores and mappings. A secret store that cannot be imported, or one of whose mappings cannot be imported, is reported to the callback once as an error that names the store, and is not part of the result.

      Parameters

      • importData: SecretStoreExportInterface

        secret store import data

      • globalConfig: boolean

        true if the secret store mapping is global, false otherwise. Default: false.

      • OptionalsecretStoreId: string

        optional secret store id. If supplied, only the secret store of that id is imported.

      • OptionalsecretStoreTypeId: string

        optional secret store type id

      • OptionalresultCallback: ResultCallback<SecretStoreSkeleton>

        Optional callback to process individual results

      Returns Promise<SecretStoreExportSkeleton[]>

      the imported secret stores and mappings

    • Read secret store by id. Will throw if type is not defined and multiple secret stores with the same id are found.

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • globalConfig: boolean

        true if global secret store is the target of the operation, false otherwise. Default: false.

      Returns Promise<SecretStoreSkeleton>

      a promise that resolves to a secret store object

    • Read secret store mapping. Will throw if type is not defined and multiple secret stores with the same id are found.

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • secretId: string

        Secret store mapping label

      • globalConfig: boolean

        true if the secret store is global, false otherwise. Default: false.

      Returns Promise<SecretStoreMappingSkeleton>

      a promise that resolves to an array of secret store mapping objects

    • Read secret store mappings. Will throw if type is not defined and multiple secret stores with the same id are found.

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • globalConfig: boolean

        true if the secret store is global, false otherwise. Default: false.

      Returns Promise<SecretStoreMappingSkeleton[]>

      a promise that resolves to an array of secret store mapping objects

    • Read all secret stores.

      Parameters

      • globalConfig: boolean

        true if global secret stores are the target of the operation, false otherwise. Default: false.

      Returns Promise<SecretStoreSkeleton[]>

      a promise that resolves to an array of secret store objects

    • Read secret store schema

      Parameters

      • secretStoreTypeId: string

        Secret store type id

      • globalConfig: boolean

        true if the secret store is global, false otherwise. Default: false.

      Returns Promise<SecretStoreSchemaSkeleton>

      a promise that resolves to a secret store schema object

    • Update secret store mapping. Will throw if type is not defined and multiple secret stores with the same id are found.

      Parameters

      • secretStoreId: string

        Secret store id

      • secretStoreTypeId: string

        Secret store type id (optional)

      • secretStoreMappingData: SecretStoreMappingSkeleton

        secret store mapping to import

      • globalConfig: boolean

        true if the secret store mapping is global, false otherwise. Default: false.

      Returns Promise<SecretStoreMappingSkeleton>

      a promise that resolves to a secret store mapping object