We recommend using Azure Native.
Azure v6.21.0 published on Friday, Mar 7, 2025 by Pulumi
azure.network.getNetworkManager
Explore with Pulumi AI
Use this data source to access information about a Network Manager.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const exampleResourceGroup = new azure.core.ResourceGroup("example", {
    name: "example-resources",
    location: "West Europe",
});
const current = azure.core.getSubscription({});
const exampleNetworkManager = new azure.network.NetworkManager("example", {
    name: "example-network-manager",
    location: exampleResourceGroup.location,
    resourceGroupName: exampleResourceGroup.name,
    scope: {
        subscriptionIds: [current.then(current => current.id)],
    },
    scopeAccesses: [
        "Connectivity",
        "SecurityAdmin",
    ],
    description: "example network manager",
});
const example = azure.network.getNetworkManagerOutput({
    name: exampleNetworkManager.name,
    resourceGroupName: exampleNetworkManager.resourceGroupName,
});
import pulumi
import pulumi_azure as azure
example_resource_group = azure.core.ResourceGroup("example",
    name="example-resources",
    location="West Europe")
current = azure.core.get_subscription()
example_network_manager = azure.network.NetworkManager("example",
    name="example-network-manager",
    location=example_resource_group.location,
    resource_group_name=example_resource_group.name,
    scope={
        "subscription_ids": [current.id],
    },
    scope_accesses=[
        "Connectivity",
        "SecurityAdmin",
    ],
    description="example network manager")
example = azure.network.get_network_manager_output(name=example_network_manager.name,
    resource_group_name=example_network_manager.resource_group_name)
package main
import (
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/core"
	"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/network"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleResourceGroup, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
			Name:     pulumi.String("example-resources"),
			Location: pulumi.String("West Europe"),
		})
		if err != nil {
			return err
		}
		current, err := core.LookupSubscription(ctx, &core.LookupSubscriptionArgs{}, nil)
		if err != nil {
			return err
		}
		exampleNetworkManager, err := network.NewNetworkManager(ctx, "example", &network.NetworkManagerArgs{
			Name:              pulumi.String("example-network-manager"),
			Location:          exampleResourceGroup.Location,
			ResourceGroupName: exampleResourceGroup.Name,
			Scope: &network.NetworkManagerScopeArgs{
				SubscriptionIds: pulumi.StringArray{
					pulumi.String(current.Id),
				},
			},
			ScopeAccesses: pulumi.StringArray{
				pulumi.String("Connectivity"),
				pulumi.String("SecurityAdmin"),
			},
			Description: pulumi.String("example network manager"),
		})
		if err != nil {
			return err
		}
		_ = network.LookupNetworkManagerOutput(ctx, network.GetNetworkManagerOutputArgs{
			Name:              exampleNetworkManager.Name,
			ResourceGroupName: exampleNetworkManager.ResourceGroupName,
		}, nil)
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() => 
{
    var exampleResourceGroup = new Azure.Core.ResourceGroup("example", new()
    {
        Name = "example-resources",
        Location = "West Europe",
    });
    var current = Azure.Core.GetSubscription.Invoke();
    var exampleNetworkManager = new Azure.Network.NetworkManager("example", new()
    {
        Name = "example-network-manager",
        Location = exampleResourceGroup.Location,
        ResourceGroupName = exampleResourceGroup.Name,
        Scope = new Azure.Network.Inputs.NetworkManagerScopeArgs
        {
            SubscriptionIds = new[]
            {
                current.Apply(getSubscriptionResult => getSubscriptionResult.Id),
            },
        },
        ScopeAccesses = new[]
        {
            "Connectivity",
            "SecurityAdmin",
        },
        Description = "example network manager",
    });
    var example = Azure.Network.GetNetworkManager.Invoke(new()
    {
        Name = exampleNetworkManager.Name,
        ResourceGroupName = exampleNetworkManager.ResourceGroupName,
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.core.CoreFunctions;
import com.pulumi.azure.core.inputs.GetSubscriptionArgs;
import com.pulumi.azure.network.NetworkManager;
import com.pulumi.azure.network.NetworkManagerArgs;
import com.pulumi.azure.network.inputs.NetworkManagerScopeArgs;
import com.pulumi.azure.network.NetworkFunctions;
import com.pulumi.azure.network.inputs.GetNetworkManagerArgs;
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) {
        var exampleResourceGroup = new ResourceGroup("exampleResourceGroup", ResourceGroupArgs.builder()
            .name("example-resources")
            .location("West Europe")
            .build());
        final var current = CoreFunctions.getSubscription();
        var exampleNetworkManager = new NetworkManager("exampleNetworkManager", NetworkManagerArgs.builder()
            .name("example-network-manager")
            .location(exampleResourceGroup.location())
            .resourceGroupName(exampleResourceGroup.name())
            .scope(NetworkManagerScopeArgs.builder()
                .subscriptionIds(current.applyValue(getSubscriptionResult -> getSubscriptionResult.id()))
                .build())
            .scopeAccesses(            
                "Connectivity",
                "SecurityAdmin")
            .description("example network manager")
            .build());
        final var example = NetworkFunctions.getNetworkManager(GetNetworkManagerArgs.builder()
            .name(exampleNetworkManager.name())
            .resourceGroupName(exampleNetworkManager.resourceGroupName())
            .build());
    }
}
resources:
  exampleResourceGroup:
    type: azure:core:ResourceGroup
    name: example
    properties:
      name: example-resources
      location: West Europe
  exampleNetworkManager:
    type: azure:network:NetworkManager
    name: example
    properties:
      name: example-network-manager
      location: ${exampleResourceGroup.location}
      resourceGroupName: ${exampleResourceGroup.name}
      scope:
        subscriptionIds:
          - ${current.id}
      scopeAccesses:
        - Connectivity
        - SecurityAdmin
      description: example network manager
variables:
  current:
    fn::invoke:
      function: azure:core:getSubscription
      arguments: {}
  example:
    fn::invoke:
      function: azure:network:getNetworkManager
      arguments:
        name: ${exampleNetworkManager.name}
        resourceGroupName: ${exampleNetworkManager.resourceGroupName}
Using getNetworkManager
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 getNetworkManager(args: GetNetworkManagerArgs, opts?: InvokeOptions): Promise<GetNetworkManagerResult>
function getNetworkManagerOutput(args: GetNetworkManagerOutputArgs, opts?: InvokeOptions): Output<GetNetworkManagerResult>def get_network_manager(name: Optional[str] = None,
                        resource_group_name: Optional[str] = None,
                        opts: Optional[InvokeOptions] = None) -> GetNetworkManagerResult
def get_network_manager_output(name: Optional[pulumi.Input[str]] = None,
                        resource_group_name: Optional[pulumi.Input[str]] = None,
                        opts: Optional[InvokeOptions] = None) -> Output[GetNetworkManagerResult]func LookupNetworkManager(ctx *Context, args *LookupNetworkManagerArgs, opts ...InvokeOption) (*LookupNetworkManagerResult, error)
func LookupNetworkManagerOutput(ctx *Context, args *LookupNetworkManagerOutputArgs, opts ...InvokeOption) LookupNetworkManagerResultOutput> Note: This function is named LookupNetworkManager in the Go SDK.
public static class GetNetworkManager 
{
    public static Task<GetNetworkManagerResult> InvokeAsync(GetNetworkManagerArgs args, InvokeOptions? opts = null)
    public static Output<GetNetworkManagerResult> Invoke(GetNetworkManagerInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetNetworkManagerResult> getNetworkManager(GetNetworkManagerArgs args, InvokeOptions options)
public static Output<GetNetworkManagerResult> getNetworkManager(GetNetworkManagerArgs args, InvokeOptions options)
fn::invoke:
  function: azure:network/getNetworkManager:getNetworkManager
  arguments:
    # arguments dictionaryThe following arguments are supported:
- Name string
- The name of the Network Manager.
- ResourceGroup stringName 
- The Name of the Resource Group where the Network Manager exists.
- Name string
- The name of the Network Manager.
- ResourceGroup stringName 
- The Name of the Resource Group where the Network Manager exists.
- name String
- The name of the Network Manager.
- resourceGroup StringName 
- The Name of the Resource Group where the Network Manager exists.
- name string
- The name of the Network Manager.
- resourceGroup stringName 
- The Name of the Resource Group where the Network Manager exists.
- name str
- The name of the Network Manager.
- resource_group_ strname 
- The Name of the Resource Group where the Network Manager exists.
- name String
- The name of the Network Manager.
- resourceGroup StringName 
- The Name of the Resource Group where the Network Manager exists.
getNetworkManager Result
The following output properties are available:
- CrossTenant List<GetScopes Network Manager Cross Tenant Scope> 
- One or more cross_tenant_scopesblocks as defined below.
- Description string
- A description of the Network Manager.
- Id string
- The provider-assigned unique ID for this managed resource.
- Location string
- The Azure Region where the Network Manager exists.
- Name string
- ResourceGroup stringName 
- ScopeAccesses List<string>
- A list of configuration deployment type configured on the Network Manager.
- Scopes
List<GetNetwork Manager Scope> 
- A scopeblock as defined below.
- Dictionary<string, string>
- A mapping of tags assigned to the Network Manager.
- CrossTenant []GetScopes Network Manager Cross Tenant Scope 
- One or more cross_tenant_scopesblocks as defined below.
- Description string
- A description of the Network Manager.
- Id string
- The provider-assigned unique ID for this managed resource.
- Location string
- The Azure Region where the Network Manager exists.
- Name string
- ResourceGroup stringName 
- ScopeAccesses []string
- A list of configuration deployment type configured on the Network Manager.
- Scopes
[]GetNetwork Manager Scope 
- A scopeblock as defined below.
- map[string]string
- A mapping of tags assigned to the Network Manager.
- crossTenant List<GetScopes Network Manager Cross Tenant Scope> 
- One or more cross_tenant_scopesblocks as defined below.
- description String
- A description of the Network Manager.
- id String
- The provider-assigned unique ID for this managed resource.
- location String
- The Azure Region where the Network Manager exists.
- name String
- resourceGroup StringName 
- scopeAccesses List<String>
- A list of configuration deployment type configured on the Network Manager.
- scopes
List<GetNetwork Manager Scope> 
- A scopeblock as defined below.
- Map<String,String>
- A mapping of tags assigned to the Network Manager.
- crossTenant GetScopes Network Manager Cross Tenant Scope[] 
- One or more cross_tenant_scopesblocks as defined below.
- description string
- A description of the Network Manager.
- id string
- The provider-assigned unique ID for this managed resource.
- location string
- The Azure Region where the Network Manager exists.
- name string
- resourceGroup stringName 
- scopeAccesses string[]
- A list of configuration deployment type configured on the Network Manager.
- scopes
GetNetwork Manager Scope[] 
- A scopeblock as defined below.
- {[key: string]: string}
- A mapping of tags assigned to the Network Manager.
- cross_tenant_ Sequence[Getscopes Network Manager Cross Tenant Scope] 
- One or more cross_tenant_scopesblocks as defined below.
- description str
- A description of the Network Manager.
- id str
- The provider-assigned unique ID for this managed resource.
- location str
- The Azure Region where the Network Manager exists.
- name str
- resource_group_ strname 
- scope_accesses Sequence[str]
- A list of configuration deployment type configured on the Network Manager.
- scopes
Sequence[GetNetwork Manager Scope] 
- A scopeblock as defined below.
- Mapping[str, str]
- A mapping of tags assigned to the Network Manager.
- crossTenant List<Property Map>Scopes 
- One or more cross_tenant_scopesblocks as defined below.
- description String
- A description of the Network Manager.
- id String
- The provider-assigned unique ID for this managed resource.
- location String
- The Azure Region where the Network Manager exists.
- name String
- resourceGroup StringName 
- scopeAccesses List<String>
- A list of configuration deployment type configured on the Network Manager.
- scopes List<Property Map>
- A scopeblock as defined below.
- Map<String>
- A mapping of tags assigned to the Network Manager.
Supporting Types
GetNetworkManagerCrossTenantScope     
- ManagementGroups List<string>
- A list of management groups used as cross tenant scope for the Network Manager.
- Subscriptions List<string>
- A list of subscriptions used as cross tenant scope for the Network Manager.
- TenantId string
- The tenant ID of the cross tenant scope.
- ManagementGroups []string
- A list of management groups used as cross tenant scope for the Network Manager.
- Subscriptions []string
- A list of subscriptions used as cross tenant scope for the Network Manager.
- TenantId string
- The tenant ID of the cross tenant scope.
- managementGroups List<String>
- A list of management groups used as cross tenant scope for the Network Manager.
- subscriptions List<String>
- A list of subscriptions used as cross tenant scope for the Network Manager.
- tenantId String
- The tenant ID of the cross tenant scope.
- managementGroups string[]
- A list of management groups used as cross tenant scope for the Network Manager.
- subscriptions string[]
- A list of subscriptions used as cross tenant scope for the Network Manager.
- tenantId string
- The tenant ID of the cross tenant scope.
- management_groups Sequence[str]
- A list of management groups used as cross tenant scope for the Network Manager.
- subscriptions Sequence[str]
- A list of subscriptions used as cross tenant scope for the Network Manager.
- tenant_id str
- The tenant ID of the cross tenant scope.
- managementGroups List<String>
- A list of management groups used as cross tenant scope for the Network Manager.
- subscriptions List<String>
- A list of subscriptions used as cross tenant scope for the Network Manager.
- tenantId String
- The tenant ID of the cross tenant scope.
GetNetworkManagerScope   
- ManagementGroup List<string>Ids 
- A list of management group IDs used a scope for the Network Manager.
- SubscriptionIds List<string>
- A list of subscription IDs used as the scope for the Network Manager.
- ManagementGroup []stringIds 
- A list of management group IDs used a scope for the Network Manager.
- SubscriptionIds []string
- A list of subscription IDs used as the scope for the Network Manager.
- managementGroup List<String>Ids 
- A list of management group IDs used a scope for the Network Manager.
- subscriptionIds List<String>
- A list of subscription IDs used as the scope for the Network Manager.
- managementGroup string[]Ids 
- A list of management group IDs used a scope for the Network Manager.
- subscriptionIds string[]
- A list of subscription IDs used as the scope for the Network Manager.
- management_group_ Sequence[str]ids 
- A list of management group IDs used a scope for the Network Manager.
- subscription_ids Sequence[str]
- A list of subscription IDs used as the scope for the Network Manager.
- managementGroup List<String>Ids 
- A list of management group IDs used a scope for the Network Manager.
- subscriptionIds List<String>
- A list of subscription IDs used as the scope for the Network Manager.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the azurermTerraform Provider.