This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Viewing docs for Azure Native v3.16.0
published on Friday, Mar 20, 2026 by Pulumi
published on Friday, Mar 20, 2026 by Pulumi
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Viewing docs for Azure Native v3.16.0
published on Friday, Mar 20, 2026 by Pulumi
published on Friday, Mar 20, 2026 by Pulumi
Get virtual network.
Uses Azure REST API version 2018-09-15.
Using getVirtualNetwork
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 getVirtualNetwork(args: GetVirtualNetworkArgs, opts?: InvokeOptions): Promise<GetVirtualNetworkResult>
function getVirtualNetworkOutput(args: GetVirtualNetworkOutputArgs, opts?: InvokeOptions): Output<GetVirtualNetworkResult>def get_virtual_network(expand: Optional[str] = None,
lab_name: Optional[str] = None,
name: Optional[str] = None,
resource_group_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetVirtualNetworkResult
def get_virtual_network_output(expand: Optional[pulumi.Input[str]] = None,
lab_name: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
resource_group_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetVirtualNetworkResult]func LookupVirtualNetwork(ctx *Context, args *LookupVirtualNetworkArgs, opts ...InvokeOption) (*LookupVirtualNetworkResult, error)
func LookupVirtualNetworkOutput(ctx *Context, args *LookupVirtualNetworkOutputArgs, opts ...InvokeOption) LookupVirtualNetworkResultOutput> Note: This function is named LookupVirtualNetwork in the Go SDK.
public static class GetVirtualNetwork
{
public static Task<GetVirtualNetworkResult> InvokeAsync(GetVirtualNetworkArgs args, InvokeOptions? opts = null)
public static Output<GetVirtualNetworkResult> Invoke(GetVirtualNetworkInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetVirtualNetworkResult> getVirtualNetwork(GetVirtualNetworkArgs args, InvokeOptions options)
public static Output<GetVirtualNetworkResult> getVirtualNetwork(GetVirtualNetworkArgs args, InvokeOptions options)
fn::invoke:
function: azure-native:devtestlab:getVirtualNetwork
arguments:
# arguments dictionaryThe following arguments are supported:
- Lab
Name string - The name of the lab.
- Name string
- The name of the virtual network.
- Resource
Group stringName - The name of the resource group. The name is case insensitive.
- Expand string
- Specify the $expand query. Example: 'properties($expand=externalSubnets)'
- Lab
Name string - The name of the lab.
- Name string
- The name of the virtual network.
- Resource
Group stringName - The name of the resource group. The name is case insensitive.
- Expand string
- Specify the $expand query. Example: 'properties($expand=externalSubnets)'
- lab
Name String - The name of the lab.
- name String
- The name of the virtual network.
- resource
Group StringName - The name of the resource group. The name is case insensitive.
- expand String
- Specify the $expand query. Example: 'properties($expand=externalSubnets)'
- lab
Name string - The name of the lab.
- name string
- The name of the virtual network.
- resource
Group stringName - The name of the resource group. The name is case insensitive.
- expand string
- Specify the $expand query. Example: 'properties($expand=externalSubnets)'
- lab_
name str - The name of the lab.
- name str
- The name of the virtual network.
- resource_
group_ strname - The name of the resource group. The name is case insensitive.
- expand str
- Specify the $expand query. Example: 'properties($expand=externalSubnets)'
- lab
Name String - The name of the lab.
- name String
- The name of the virtual network.
- resource
Group StringName - The name of the resource group. The name is case insensitive.
- expand String
- Specify the $expand query. Example: 'properties($expand=externalSubnets)'
getVirtualNetwork Result
The following output properties are available:
- Azure
Api stringVersion - The Azure API version of the resource.
- Created
Date string - The creation date of the virtual network.
- External
Subnets List<Pulumi.Azure Native. Dev Test Lab. Outputs. External Subnet Response> - The external subnet properties.
- Id string
- Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
- Name string
- The name of the resource
- Provisioning
State string - The provisioning status of the resource.
- System
Data Pulumi.Azure Native. Dev Test Lab. Outputs. System Data Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Unique
Identifier string - The unique immutable identifier of a resource (Guid).
- Allowed
Subnets List<Pulumi.Azure Native. Dev Test Lab. Outputs. Subnet Response> - The allowed subnets of the virtual network.
- Description string
- The description of the virtual network.
- External
Provider stringResource Id - The Microsoft.Network resource identifier of the virtual network.
- Location string
- The geo-location where the resource lives
- Subnet
Overrides List<Pulumi.Azure Native. Dev Test Lab. Outputs. Subnet Override Response> - The subnet overrides of the virtual network.
- Dictionary<string, string>
- Resource tags.
- Azure
Api stringVersion - The Azure API version of the resource.
- Created
Date string - The creation date of the virtual network.
- External
Subnets []ExternalSubnet Response - The external subnet properties.
- Id string
- Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
- Name string
- The name of the resource
- Provisioning
State string - The provisioning status of the resource.
- System
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- Type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- Unique
Identifier string - The unique immutable identifier of a resource (Guid).
- Allowed
Subnets []SubnetResponse - The allowed subnets of the virtual network.
- Description string
- The description of the virtual network.
- External
Provider stringResource Id - The Microsoft.Network resource identifier of the virtual network.
- Location string
- The geo-location where the resource lives
- Subnet
Overrides []SubnetOverride Response - The subnet overrides of the virtual network.
- map[string]string
- Resource tags.
- azure
Api StringVersion - The Azure API version of the resource.
- created
Date String - The creation date of the virtual network.
- external
Subnets List<ExternalSubnet Response> - The external subnet properties.
- id String
- Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
- name String
- The name of the resource
- provisioning
State String - The provisioning status of the resource.
- system
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- unique
Identifier String - The unique immutable identifier of a resource (Guid).
- allowed
Subnets List<SubnetResponse> - The allowed subnets of the virtual network.
- description String
- The description of the virtual network.
- external
Provider StringResource Id - The Microsoft.Network resource identifier of the virtual network.
- location String
- The geo-location where the resource lives
- subnet
Overrides List<SubnetOverride Response> - The subnet overrides of the virtual network.
- Map<String,String>
- Resource tags.
- azure
Api stringVersion - The Azure API version of the resource.
- created
Date string - The creation date of the virtual network.
- external
Subnets ExternalSubnet Response[] - The external subnet properties.
- id string
- Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
- name string
- The name of the resource
- provisioning
State string - The provisioning status of the resource.
- system
Data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type string
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- unique
Identifier string - The unique immutable identifier of a resource (Guid).
- allowed
Subnets SubnetResponse[] - The allowed subnets of the virtual network.
- description string
- The description of the virtual network.
- external
Provider stringResource Id - The Microsoft.Network resource identifier of the virtual network.
- location string
- The geo-location where the resource lives
- subnet
Overrides SubnetOverride Response[] - The subnet overrides of the virtual network.
- {[key: string]: string}
- Resource tags.
- azure_
api_ strversion - The Azure API version of the resource.
- created_
date str - The creation date of the virtual network.
- external_
subnets Sequence[ExternalSubnet Response] - The external subnet properties.
- id str
- Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
- name str
- The name of the resource
- provisioning_
state str - The provisioning status of the resource.
- system_
data SystemData Response - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type str
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- unique_
identifier str - The unique immutable identifier of a resource (Guid).
- allowed_
subnets Sequence[SubnetResponse] - The allowed subnets of the virtual network.
- description str
- The description of the virtual network.
- external_
provider_ strresource_ id - The Microsoft.Network resource identifier of the virtual network.
- location str
- The geo-location where the resource lives
- subnet_
overrides Sequence[SubnetOverride Response] - The subnet overrides of the virtual network.
- Mapping[str, str]
- Resource tags.
- azure
Api StringVersion - The Azure API version of the resource.
- created
Date String - The creation date of the virtual network.
- external
Subnets List<Property Map> - The external subnet properties.
- id String
- Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
- name String
- The name of the resource
- provisioning
State String - The provisioning status of the resource.
- system
Data Property Map - Azure Resource Manager metadata containing createdBy and modifiedBy information.
- type String
- The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
- unique
Identifier String - The unique immutable identifier of a resource (Guid).
- allowed
Subnets List<Property Map> - The allowed subnets of the virtual network.
- description String
- The description of the virtual network.
- external
Provider StringResource Id - The Microsoft.Network resource identifier of the virtual network.
- location String
- The geo-location where the resource lives
- subnet
Overrides List<Property Map> - The subnet overrides of the virtual network.
- Map<String>
- Resource tags.
Supporting Types
ExternalSubnetResponse
PortResponse
- Backend
Port int - Backend port of the target virtual machine.
- Transport
Protocol string - Protocol type of the port.
- Backend
Port int - Backend port of the target virtual machine.
- Transport
Protocol string - Protocol type of the port.
- backend
Port Integer - Backend port of the target virtual machine.
- transport
Protocol String - Protocol type of the port.
- backend
Port number - Backend port of the target virtual machine.
- transport
Protocol string - Protocol type of the port.
- backend_
port int - Backend port of the target virtual machine.
- transport_
protocol str - Protocol type of the port.
- backend
Port Number - Backend port of the target virtual machine.
- transport
Protocol String - Protocol type of the port.
SubnetOverrideResponse
- Lab
Subnet stringName - The name given to the subnet within the lab.
- Resource
Id string - The resource ID of the subnet.
-
Pulumi.
Azure Native. Dev Test Lab. Inputs. Subnet Shared Public Ip Address Configuration Response - Properties that virtual machines on this subnet will share.
- Use
In stringVm Creation Permission - Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).
- Use
Public stringIp Address Permission - Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).
- Virtual
Network stringPool Name - The virtual network pool associated with this subnet.
- Lab
Subnet stringName - The name given to the subnet within the lab.
- Resource
Id string - The resource ID of the subnet.
-
Subnet
Shared Public Ip Address Configuration Response - Properties that virtual machines on this subnet will share.
- Use
In stringVm Creation Permission - Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).
- Use
Public stringIp Address Permission - Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).
- Virtual
Network stringPool Name - The virtual network pool associated with this subnet.
- lab
Subnet StringName - The name given to the subnet within the lab.
- resource
Id String - The resource ID of the subnet.
-
Subnet
Shared Public Ip Address Configuration Response - Properties that virtual machines on this subnet will share.
- use
In StringVm Creation Permission - Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).
- use
Public StringIp Address Permission - Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).
- virtual
Network StringPool Name - The virtual network pool associated with this subnet.
- lab
Subnet stringName - The name given to the subnet within the lab.
- resource
Id string - The resource ID of the subnet.
-
Subnet
Shared Public Ip Address Configuration Response - Properties that virtual machines on this subnet will share.
- use
In stringVm Creation Permission - Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).
- use
Public stringIp Address Permission - Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).
- virtual
Network stringPool Name - The virtual network pool associated with this subnet.
- lab_
subnet_ strname - The name given to the subnet within the lab.
- resource_
id str - The resource ID of the subnet.
-
Subnet
Shared Public Ip Address Configuration Response - Properties that virtual machines on this subnet will share.
- use_
in_ strvm_ creation_ permission - Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).
- use_
public_ strip_ address_ permission - Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).
- virtual_
network_ strpool_ name - The virtual network pool associated with this subnet.
- lab
Subnet StringName - The name given to the subnet within the lab.
- resource
Id String - The resource ID of the subnet.
- Property Map
- Properties that virtual machines on this subnet will share.
- use
In StringVm Creation Permission - Indicates whether this subnet can be used during virtual machine creation (i.e. Allow, Deny).
- use
Public StringIp Address Permission - Indicates whether public IP addresses can be assigned to virtual machines on this subnet (i.e. Allow, Deny).
- virtual
Network StringPool Name - The virtual network pool associated with this subnet.
SubnetResponse
- Allow
Public stringIp - The permission policy of the subnet for allowing public IP addresses (i.e. Allow, Deny)).
- Lab
Subnet stringName - The name of the subnet as seen in the lab.
- Resource
Id string - The resource ID of the subnet.
- Allow
Public stringIp - The permission policy of the subnet for allowing public IP addresses (i.e. Allow, Deny)).
- Lab
Subnet stringName - The name of the subnet as seen in the lab.
- Resource
Id string - The resource ID of the subnet.
- allow
Public StringIp - The permission policy of the subnet for allowing public IP addresses (i.e. Allow, Deny)).
- lab
Subnet StringName - The name of the subnet as seen in the lab.
- resource
Id String - The resource ID of the subnet.
- allow
Public stringIp - The permission policy of the subnet for allowing public IP addresses (i.e. Allow, Deny)).
- lab
Subnet stringName - The name of the subnet as seen in the lab.
- resource
Id string - The resource ID of the subnet.
- allow_
public_ strip - The permission policy of the subnet for allowing public IP addresses (i.e. Allow, Deny)).
- lab_
subnet_ strname - The name of the subnet as seen in the lab.
- resource_
id str - The resource ID of the subnet.
- allow
Public StringIp - The permission policy of the subnet for allowing public IP addresses (i.e. Allow, Deny)).
- lab
Subnet StringName - The name of the subnet as seen in the lab.
- resource
Id String - The resource ID of the subnet.
SubnetSharedPublicIpAddressConfigurationResponse
- Allowed
Ports List<Pulumi.Azure Native. Dev Test Lab. Inputs. Port Response> - Backend ports that virtual machines on this subnet are allowed to expose
- Allowed
Ports []PortResponse - Backend ports that virtual machines on this subnet are allowed to expose
- allowed
Ports List<PortResponse> - Backend ports that virtual machines on this subnet are allowed to expose
- allowed
Ports PortResponse[] - Backend ports that virtual machines on this subnet are allowed to expose
- allowed_
ports Sequence[PortResponse] - Backend ports that virtual machines on this subnet are allowed to expose
- allowed
Ports List<Property Map> - Backend ports that virtual machines on this subnet are allowed to expose
SystemDataResponse
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- Created
At string - The timestamp of resource creation (UTC).
- Created
By string - The identity that created the resource.
- Created
By stringType - The type of identity that created the resource.
- Last
Modified stringAt - The timestamp of resource last modification (UTC)
- Last
Modified stringBy - The identity that last modified the resource.
- Last
Modified stringBy Type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
- created
At string - The timestamp of resource creation (UTC).
- created
By string - The identity that created the resource.
- created
By stringType - The type of identity that created the resource.
- last
Modified stringAt - The timestamp of resource last modification (UTC)
- last
Modified stringBy - The identity that last modified the resource.
- last
Modified stringBy Type - The type of identity that last modified the resource.
- created_
at str - The timestamp of resource creation (UTC).
- created_
by str - The identity that created the resource.
- created_
by_ strtype - The type of identity that created the resource.
- last_
modified_ strat - The timestamp of resource last modification (UTC)
- last_
modified_ strby - The identity that last modified the resource.
- last_
modified_ strby_ type - The type of identity that last modified the resource.
- created
At String - The timestamp of resource creation (UTC).
- created
By String - The identity that created the resource.
- created
By StringType - The type of identity that created the resource.
- last
Modified StringAt - The timestamp of resource last modification (UTC)
- last
Modified StringBy - The identity that last modified the resource.
- last
Modified StringBy Type - The type of identity that last modified the resource.
Package Details
- Repository
- Azure Native pulumi/pulumi-azure-native
- License
- Apache-2.0
This is the latest version of Azure Native. Use the Azure Native v2 docs if using the v2 version of this package.
Viewing docs for Azure Native v3.16.0
published on Friday, Mar 20, 2026 by Pulumi
published on Friday, Mar 20, 2026 by Pulumi
