1. Packages
  2. Standard Library
  3. API Docs
  4. merge
StandardLibrary v2.3.2 published on Tuesday, Feb 10, 2026 by Pulumi
std logo
StandardLibrary v2.3.2 published on Tuesday, Feb 10, 2026 by Pulumi

    Returns the union of 2 or more maps. The maps are consumed in the order provided, and duplicate keys overwrite previous entries.

    Using merge

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function merge(args: MergeArgs, opts?: InvokeOptions): Promise<MergeResult>
    function mergeOutput(args: MergeOutputArgs, opts?: InvokeOptions): Output<MergeResult>
    def merge(input: Optional[Sequence[Mapping[str, Any]]] = None,
              opts: Optional[InvokeOptions] = None) -> MergeResult
    def merge_output(input: Optional[pulumi.Input[Sequence[pulumi.Input[Mapping[str, Any]]]]] = None,
              opts: Optional[InvokeOptions] = None) -> Output[MergeResult]
    func Merge(ctx *Context, args *MergeArgs, opts ...InvokeOption) (*MergeResult, error)
    func MergeOutput(ctx *Context, args *MergeOutputArgs, opts ...InvokeOption) MergeResultOutput

    > Note: This function is named Merge in the Go SDK.

    public static class Merge 
    {
        public static Task<MergeResult> InvokeAsync(MergeArgs args, InvokeOptions? opts = null)
        public static Output<MergeResult> Invoke(MergeInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<MergeResult> merge(MergeArgs args, InvokeOptions options)
    public static Output<MergeResult> merge(MergeArgs args, InvokeOptions options)
    
    fn::invoke:
      function: std:merge
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Input List<ImmutableDictionary<string, object>>
    Input []map[string]interface{}
    input List<Map<String,Object>>
    input {[key: string]: any}[]
    input Sequence[Mapping[str, Any]]
    input List<Map<Any>>

    merge Result

    The following output properties are available:

    Result Dictionary<string, object>
    Result map[string]interface{}
    result Map<String,Object>
    result {[key: string]: any}
    result Mapping[str, Any]
    result Map<Any>

    Package Details

    Repository
    std pulumi/pulumi-std
    License
    std logo
    StandardLibrary v2.3.2 published on Tuesday, Feb 10, 2026 by Pulumi
      Meet Neo: Your AI Platform Teammate