1. Packages
  2. Azure Classic
  3. API Docs
  4. netapp
  5. getAccount

We recommend using Azure Native.

Azure v6.21.0 published on Friday, Mar 7, 2025 by Pulumi

azure.netapp.getAccount

Explore with Pulumi AI

We recommend using Azure Native.

Azure v6.21.0 published on Friday, Mar 7, 2025 by Pulumi

Uses this data source to access information about an existing NetApp Account.

NetApp Account Usage

import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";

const example = azure.netapp.getAccount({
    resourceGroupName: "acctestRG",
    name: "acctestnetappaccount",
});
export const netappAccountId = example.then(example => example.id);
Copy
import pulumi
import pulumi_azure as azure

example = azure.netapp.get_account(resource_group_name="acctestRG",
    name="acctestnetappaccount")
pulumi.export("netappAccountId", example.id)
Copy
package main

import (
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/netapp"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		example, err := netapp.LookupAccount(ctx, &netapp.LookupAccountArgs{
			ResourceGroupName: "acctestRG",
			Name:              "acctestnetappaccount",
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("netappAccountId", example.Id)
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;

return await Deployment.RunAsync(() => 
{
    var example = Azure.NetApp.GetAccount.Invoke(new()
    {
        ResourceGroupName = "acctestRG",
        Name = "acctestnetappaccount",
    });

    return new Dictionary<string, object?>
    {
        ["netappAccountId"] = example.Apply(getAccountResult => getAccountResult.Id),
    };
});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.netapp.NetappFunctions;
import com.pulumi.azure.netapp.inputs.GetAccountArgs;
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 = NetappFunctions.getAccount(GetAccountArgs.builder()
            .resourceGroupName("acctestRG")
            .name("acctestnetappaccount")
            .build());

        ctx.export("netappAccountId", example.applyValue(getAccountResult -> getAccountResult.id()));
    }
}
Copy
variables:
  example:
    fn::invoke:
      function: azure:netapp:getAccount
      arguments:
        resourceGroupName: acctestRG
        name: acctestnetappaccount
outputs:
  netappAccountId: ${example.id}
Copy

Using getAccount

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 getAccount(args: GetAccountArgs, opts?: InvokeOptions): Promise<GetAccountResult>
function getAccountOutput(args: GetAccountOutputArgs, opts?: InvokeOptions): Output<GetAccountResult>
Copy
def get_account(identity: Optional[GetAccountIdentity] = None,
                name: Optional[str] = None,
                resource_group_name: Optional[str] = None,
                opts: Optional[InvokeOptions] = None) -> GetAccountResult
def get_account_output(identity: Optional[pulumi.Input[GetAccountIdentityArgs]] = None,
                name: Optional[pulumi.Input[str]] = None,
                resource_group_name: Optional[pulumi.Input[str]] = None,
                opts: Optional[InvokeOptions] = None) -> Output[GetAccountResult]
Copy
func LookupAccount(ctx *Context, args *LookupAccountArgs, opts ...InvokeOption) (*LookupAccountResult, error)
func LookupAccountOutput(ctx *Context, args *LookupAccountOutputArgs, opts ...InvokeOption) LookupAccountResultOutput
Copy

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

public static class GetAccount 
{
    public static Task<GetAccountResult> InvokeAsync(GetAccountArgs args, InvokeOptions? opts = null)
    public static Output<GetAccountResult> Invoke(GetAccountInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetAccountResult> getAccount(GetAccountArgs args, InvokeOptions options)
public static Output<GetAccountResult> getAccount(GetAccountArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: azure:netapp/getAccount:getAccount
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Name This property is required. string
The name of the NetApp Account.
ResourceGroupName This property is required. string
The Name of the Resource Group where the NetApp Account exists.
Identity GetAccountIdentity
Name This property is required. string
The name of the NetApp Account.
ResourceGroupName This property is required. string
The Name of the Resource Group where the NetApp Account exists.
Identity GetAccountIdentity
name This property is required. String
The name of the NetApp Account.
resourceGroupName This property is required. String
The Name of the Resource Group where the NetApp Account exists.
identity GetAccountIdentity
name This property is required. string
The name of the NetApp Account.
resourceGroupName This property is required. string
The Name of the Resource Group where the NetApp Account exists.
identity GetAccountIdentity
name This property is required. str
The name of the NetApp Account.
resource_group_name This property is required. str
The Name of the Resource Group where the NetApp Account exists.
identity GetAccountIdentity
name This property is required. String
The name of the NetApp Account.
resourceGroupName This property is required. String
The Name of the Resource Group where the NetApp Account exists.
identity Property Map

getAccount Result

The following output properties are available:

Id string
The provider-assigned unique ID for this managed resource.
Location string
The Azure Region where the NetApp Account exists.
Name string
ResourceGroupName string
Tags Dictionary<string, string>
Identity GetAccountIdentity
Id string
The provider-assigned unique ID for this managed resource.
Location string
The Azure Region where the NetApp Account exists.
Name string
ResourceGroupName string
Tags map[string]string
Identity GetAccountIdentity
id String
The provider-assigned unique ID for this managed resource.
location String
The Azure Region where the NetApp Account exists.
name String
resourceGroupName String
tags Map<String,String>
identity GetAccountIdentity
id string
The provider-assigned unique ID for this managed resource.
location string
The Azure Region where the NetApp Account exists.
name string
resourceGroupName string
tags {[key: string]: string}
identity GetAccountIdentity
id str
The provider-assigned unique ID for this managed resource.
location str
The Azure Region where the NetApp Account exists.
name str
resource_group_name str
tags Mapping[str, str]
identity GetAccountIdentity
id String
The provider-assigned unique ID for this managed resource.
location String
The Azure Region where the NetApp Account exists.
name String
resourceGroupName String
tags Map<String>
identity Property Map

Supporting Types

GetAccountIdentity

PrincipalId This property is required. string
TenantId This property is required. string
Type This property is required. string
IdentityIds List<string>
PrincipalId This property is required. string
TenantId This property is required. string
Type This property is required. string
IdentityIds []string
principalId This property is required. String
tenantId This property is required. String
type This property is required. String
identityIds List<String>
principalId This property is required. string
tenantId This property is required. string
type This property is required. string
identityIds string[]
principal_id This property is required. str
tenant_id This property is required. str
type This property is required. str
identity_ids Sequence[str]
principalId This property is required. String
tenantId This property is required. String
type This property is required. String
identityIds List<String>

Package Details

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

We recommend using Azure Native.

Azure v6.21.0 published on Friday, Mar 7, 2025 by Pulumi