1. Packages
  2. Azure Classic
  3. API Docs
  4. core
  5. getResourceGroupTemplateDeployment

We recommend using Azure Native.

Azure v6.30.0 published on Thursday, Nov 20, 2025 by Pulumi
azure logo

We recommend using Azure Native.

Azure v6.30.0 published on Thursday, Nov 20, 2025 by Pulumi

    Use this data source to access information about an existing Resource Group Template Deployment.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    import * as std from "@pulumi/std";
    
    const example = azure.core.getResourceGroupTemplateDeployment({
        name: "existing",
        resourceGroupName: "existing",
    });
    export const id = example.then(example => example.id);
    export const exampleOutput = example.then(example => std.jsondecode({
        input: example.outputContent,
    })).then(invoke => invoke.result?.exampleOutput?.value);
    
    import pulumi
    import pulumi_azure as azure
    import pulumi_std as std
    
    example = azure.core.get_resource_group_template_deployment(name="existing",
        resource_group_name="existing")
    pulumi.export("id", example.id)
    pulumi.export("exampleOutput", std.jsondecode(input=example.output_content).result["exampleOutput"]["value"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/core"
    	"github.com/pulumi/pulumi-std/sdk/go/std"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := core.LookupResourceGroupTemplateDeployment(ctx, &core.LookupResourceGroupTemplateDeploymentArgs{
    			Name:              "existing",
    			ResourceGroupName: "existing",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("id", example.Id)
    		ctx.Export("exampleOutput", pulumi.Any(std.Jsondecode(ctx, &std.JsondecodeArgs{
    			Input: example.OutputContent,
    		}, nil).Result.ExampleOutput.Value))
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Azure = Pulumi.Azure;
    using Std = Pulumi.Std;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Azure.Core.GetResourceGroupTemplateDeployment.Invoke(new()
        {
            Name = "existing",
            ResourceGroupName = "existing",
        });
    
        return new Dictionary<string, object?>
        {
            ["id"] = example.Apply(getResourceGroupTemplateDeploymentResult => getResourceGroupTemplateDeploymentResult.Id),
            ["exampleOutput"] = Std.Jsondecode.Invoke(new()
            {
                Input = example.Apply(getResourceGroupTemplateDeploymentResult => getResourceGroupTemplateDeploymentResult.OutputContent),
            }).Apply(invoke => invoke.Result?.ExampleOutput?.Value),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azure.core.CoreFunctions;
    import com.pulumi.azure.core.inputs.GetResourceGroupTemplateDeploymentArgs;
    import com.pulumi.std.StdFunctions;
    import com.pulumi.std.inputs.JsondecodeArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var example = CoreFunctions.getResourceGroupTemplateDeployment(GetResourceGroupTemplateDeploymentArgs.builder()
                .name("existing")
                .resourceGroupName("existing")
                .build());
    
            ctx.export("id", example.id());
            ctx.export("exampleOutput", StdFunctions.jsondecode(JsondecodeArgs.builder()
                .input(example.outputContent())
                .build()).result().exampleOutput().value());
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: azure:core:getResourceGroupTemplateDeployment
          arguments:
            name: existing
            resourceGroupName: existing
    outputs:
      id: ${example.id}
      exampleOutput:
        fn::invoke:
          function: std:jsondecode
          arguments:
            input: ${example.outputContent}
          return: result.exampleOutput.value
    

    Using getResourceGroupTemplateDeployment

    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 getResourceGroupTemplateDeployment(args: GetResourceGroupTemplateDeploymentArgs, opts?: InvokeOptions): Promise<GetResourceGroupTemplateDeploymentResult>
    function getResourceGroupTemplateDeploymentOutput(args: GetResourceGroupTemplateDeploymentOutputArgs, opts?: InvokeOptions): Output<GetResourceGroupTemplateDeploymentResult>
    def get_resource_group_template_deployment(name: Optional[str] = None,
                                               resource_group_name: Optional[str] = None,
                                               opts: Optional[InvokeOptions] = None) -> GetResourceGroupTemplateDeploymentResult
    def get_resource_group_template_deployment_output(name: Optional[pulumi.Input[str]] = None,
                                               resource_group_name: Optional[pulumi.Input[str]] = None,
                                               opts: Optional[InvokeOptions] = None) -> Output[GetResourceGroupTemplateDeploymentResult]
    func LookupResourceGroupTemplateDeployment(ctx *Context, args *LookupResourceGroupTemplateDeploymentArgs, opts ...InvokeOption) (*LookupResourceGroupTemplateDeploymentResult, error)
    func LookupResourceGroupTemplateDeploymentOutput(ctx *Context, args *LookupResourceGroupTemplateDeploymentOutputArgs, opts ...InvokeOption) LookupResourceGroupTemplateDeploymentResultOutput

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

    public static class GetResourceGroupTemplateDeployment 
    {
        public static Task<GetResourceGroupTemplateDeploymentResult> InvokeAsync(GetResourceGroupTemplateDeploymentArgs args, InvokeOptions? opts = null)
        public static Output<GetResourceGroupTemplateDeploymentResult> Invoke(GetResourceGroupTemplateDeploymentInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetResourceGroupTemplateDeploymentResult> getResourceGroupTemplateDeployment(GetResourceGroupTemplateDeploymentArgs args, InvokeOptions options)
    public static Output<GetResourceGroupTemplateDeploymentResult> getResourceGroupTemplateDeployment(GetResourceGroupTemplateDeploymentArgs args, InvokeOptions options)
    
    fn::invoke:
      function: azure:core/getResourceGroupTemplateDeployment:getResourceGroupTemplateDeployment
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Name string
    The name of this Resource Group Template Deployment.
    ResourceGroupName string
    The name of the Resource Group to which the Resource Group Template Deployment was applied.
    Name string
    The name of this Resource Group Template Deployment.
    ResourceGroupName string
    The name of the Resource Group to which the Resource Group Template Deployment was applied.
    name String
    The name of this Resource Group Template Deployment.
    resourceGroupName String
    The name of the Resource Group to which the Resource Group Template Deployment was applied.
    name string
    The name of this Resource Group Template Deployment.
    resourceGroupName string
    The name of the Resource Group to which the Resource Group Template Deployment was applied.
    name str
    The name of this Resource Group Template Deployment.
    resource_group_name str
    The name of the Resource Group to which the Resource Group Template Deployment was applied.
    name String
    The name of this Resource Group Template Deployment.
    resourceGroupName String
    The name of the Resource Group to which the Resource Group Template Deployment was applied.

    getResourceGroupTemplateDeployment Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    OutputContent string
    The JSON Content of the Outputs of the ARM Template Deployment.
    ResourceGroupName string
    Id string
    The provider-assigned unique ID for this managed resource.
    Name string
    OutputContent string
    The JSON Content of the Outputs of the ARM Template Deployment.
    ResourceGroupName string
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    outputContent String
    The JSON Content of the Outputs of the ARM Template Deployment.
    resourceGroupName String
    id string
    The provider-assigned unique ID for this managed resource.
    name string
    outputContent string
    The JSON Content of the Outputs of the ARM Template Deployment.
    resourceGroupName string
    id str
    The provider-assigned unique ID for this managed resource.
    name str
    output_content str
    The JSON Content of the Outputs of the ARM Template Deployment.
    resource_group_name str
    id String
    The provider-assigned unique ID for this managed resource.
    name String
    outputContent String
    The JSON Content of the Outputs of the ARM Template Deployment.
    resourceGroupName String

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azurerm Terraform Provider.
    azure logo

    We recommend using Azure Native.

    Azure v6.30.0 published on Thursday, Nov 20, 2025 by Pulumi
      Meet Neo: Your AI Platform Teammate