Frodo Library - v4.0.0-10
    Preparing search index...

    Type Alias Variable

    type Variable = {
        createVariable(
            variableId: string,
            value: string,
            description: string,
            expressionType?: VariableExpressionType,
            noEncode?: boolean,
        ): Promise<VariableSkeleton>;
        deleteVariable(variableId: string): Promise<VariableSkeleton>;
        exportVariable(
            variableId: string,
            noDecode?: boolean,
        ): Promise<VariablesExportInterface>;
        exportVariables(noDecode?: boolean): Promise<VariablesExportInterface>;
        getVariable(variableId: string): Promise<VariableSkeleton>;
        getVariables(): Promise<VariableSkeleton[]>;
        importVariable(
            variableId: string,
            importData: VariablesExportInterface,
        ): Promise<VariableSkeleton>;
        importVariables(
            importData: VariablesExportInterface,
        ): Promise<VariableSkeleton[]>;
        putVariable(
            variableId: string,
            valueBase64: string,
            description: string,
            expressionType?: VariableExpressionType,
        ): Promise<VariableSkeleton>;
        readVariable(
            variableId: string,
            noDecode?: boolean,
        ): Promise<VariableSkeleton>;
        readVariables(noDecode?: boolean): Promise<VariableSkeleton[]>;
        resolveVariable(
            input: string,
            variables: Record<string, VariableSkeleton>,
        ): Promise<string>;
        setVariableDescription(
            variableId: string,
            description: string,
        ): Promise<any>;
        updateVariable(
            variableId: string,
            value: string,
            description: string,
            expressionType?: VariableExpressionType,
            noEncode?: boolean,
        ): Promise<VariableSkeleton>;
        updateVariableDescription(
            variableId: string,
            description: string,
        ): Promise<VariableSkeleton>;
    }
    Index

    Methods

    • Create variable

      Parameters

      • variableId: string

        variable id/name

      • value: string

        variable value

      • description: string

        variable description

      • OptionalexpressionType: VariableExpressionType

        type of the value

      • OptionalnoEncode: boolean

        do not encode if passing a pre-encoded (base64) value

      Returns Promise<VariableSkeleton>

      a promise that resolves to a variable object

    • Export variable. The response can be saved to file as is.

      Parameters

      • variableId: string

        variable id/name

      • OptionalnoDecode: boolean

        Do not decode value (default: false)

      Returns Promise<VariablesExportInterface>

      Promise resolving to a VariablesExportInterface object.

    • Read variable by id/name

      Parameters

      • variableId: string

        variable id/name

      • OptionalnoDecode: boolean

        Do not decode value (default: false)

      Returns Promise<VariableSkeleton>

      a promise that resolves to a variable object

    • Attempt to resolve a string to an ESV variable in AIC deployments.

      Parameters

      • input: string

        Input string to be evaluated as a possible ESV.

      • variables: Record<string, VariableSkeleton>

        Provide an empty or prepopulated map of ESV variables. The function adds any resolved variables to the map that don't exist.

      Returns Promise<string>

      Returns the resolved value of the ESV or the original input string

    • Update or create variable

      Parameters

      • variableId: string

        variable id/name

      • value: string

        variable value

      • description: string

        variable description

      • OptionalexpressionType: VariableExpressionType

        type of the value

      • OptionalnoEncode: boolean

        do not encode if passing a pre-encoded (base64) value

      Returns Promise<VariableSkeleton>

      a promise that resolves to a variable object

    • Update variable description

      Parameters

      • variableId: string

        variable id/name

      • description: string

        variable description

      Returns Promise<VariableSkeleton>

      a promise that resolves to a status object

    Deprecated

    • Create variable

      Parameters

      • variableId: string

        variable id/name

      • valueBase64: string

        base64-encoded variable value

      • description: string

        variable description

      • OptionalexpressionType: VariableExpressionType

        type of the value

      Returns Promise<VariableSkeleton>

      a promise that resolves to a variable object

      since v2.0.0 use createVariable instead

      createVariable(variableId: string, value: string, description: string, expressionType?: VariableExpressionType): Promise<VariableSkeleton>
      
    • Set variable description

      Parameters

      • variableId: string

        variable id/name

      • description: string

        variable description

      Returns Promise<any>

      a promise that resolves to an empty string

      since v2.0.0 use updateVariableDescription instead

      updateVariableDescription(variableId: string, description: string): Promise<any>