1. Packages
  2. Azure Native v2
  3. API Docs
  4. network
  5. getVirtualRouter
These are the docs for Azure Native v2. We recommenend using the latest version, Azure Native v3.
Azure Native v2 v2.90.0 published on Thursday, Mar 27, 2025 by Pulumi

azure-native-v2.network.getVirtualRouter

Explore with Pulumi AI

These are the docs for Azure Native v2. We recommenend using the latest version, Azure Native v3.
Azure Native v2 v2.90.0 published on Thursday, Mar 27, 2025 by Pulumi

Gets the specified Virtual Router. Azure REST API version: 2023-02-01.

Other available API versions: 2023-04-01, 2023-05-01, 2023-06-01, 2023-09-01, 2023-11-01, 2024-01-01, 2024-03-01, 2024-05-01.

Using getVirtualRouter

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 getVirtualRouter(args: GetVirtualRouterArgs, opts?: InvokeOptions): Promise<GetVirtualRouterResult>
function getVirtualRouterOutput(args: GetVirtualRouterOutputArgs, opts?: InvokeOptions): Output<GetVirtualRouterResult>
Copy
def get_virtual_router(expand: Optional[str] = None,
                       resource_group_name: Optional[str] = None,
                       virtual_router_name: Optional[str] = None,
                       opts: Optional[InvokeOptions] = None) -> GetVirtualRouterResult
def get_virtual_router_output(expand: Optional[pulumi.Input[str]] = None,
                       resource_group_name: Optional[pulumi.Input[str]] = None,
                       virtual_router_name: Optional[pulumi.Input[str]] = None,
                       opts: Optional[InvokeOptions] = None) -> Output[GetVirtualRouterResult]
Copy
func LookupVirtualRouter(ctx *Context, args *LookupVirtualRouterArgs, opts ...InvokeOption) (*LookupVirtualRouterResult, error)
func LookupVirtualRouterOutput(ctx *Context, args *LookupVirtualRouterOutputArgs, opts ...InvokeOption) LookupVirtualRouterResultOutput
Copy

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

public static class GetVirtualRouter 
{
    public static Task<GetVirtualRouterResult> InvokeAsync(GetVirtualRouterArgs args, InvokeOptions? opts = null)
    public static Output<GetVirtualRouterResult> Invoke(GetVirtualRouterInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetVirtualRouterResult> getVirtualRouter(GetVirtualRouterArgs args, InvokeOptions options)
public static Output<GetVirtualRouterResult> getVirtualRouter(GetVirtualRouterArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: azure-native:network:getVirtualRouter
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group.
VirtualRouterName
This property is required.
Changes to this property will trigger replacement.
string
The name of the Virtual Router.
Expand string
Expands referenced resources.
ResourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group.
VirtualRouterName
This property is required.
Changes to this property will trigger replacement.
string
The name of the Virtual Router.
Expand string
Expands referenced resources.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the resource group.
virtualRouterName
This property is required.
Changes to this property will trigger replacement.
String
The name of the Virtual Router.
expand String
Expands referenced resources.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
string
The name of the resource group.
virtualRouterName
This property is required.
Changes to this property will trigger replacement.
string
The name of the Virtual Router.
expand string
Expands referenced resources.
resource_group_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the resource group.
virtual_router_name
This property is required.
Changes to this property will trigger replacement.
str
The name of the Virtual Router.
expand str
Expands referenced resources.
resourceGroupName
This property is required.
Changes to this property will trigger replacement.
String
The name of the resource group.
virtualRouterName
This property is required.
Changes to this property will trigger replacement.
String
The name of the Virtual Router.
expand String
Expands referenced resources.

getVirtualRouter Result

The following output properties are available:

Etag string
A unique read-only string that changes whenever the resource is updated.
Name string
Resource name.
Peerings List<Pulumi.AzureNative.Network.Outputs.SubResourceResponse>
List of references to VirtualRouterPeerings.
ProvisioningState string
The provisioning state of the resource.
Type string
Resource type.
HostedGateway Pulumi.AzureNative.Network.Outputs.SubResourceResponse
The Gateway on which VirtualRouter is hosted.
HostedSubnet Pulumi.AzureNative.Network.Outputs.SubResourceResponse
The Subnet on which VirtualRouter is hosted.
Id string
Resource ID.
Location string
Resource location.
Tags Dictionary<string, string>
Resource tags.
VirtualRouterAsn double
VirtualRouter ASN.
VirtualRouterIps List<string>
VirtualRouter IPs.
Etag string
A unique read-only string that changes whenever the resource is updated.
Name string
Resource name.
Peerings []SubResourceResponse
List of references to VirtualRouterPeerings.
ProvisioningState string
The provisioning state of the resource.
Type string
Resource type.
HostedGateway SubResourceResponse
The Gateway on which VirtualRouter is hosted.
HostedSubnet SubResourceResponse
The Subnet on which VirtualRouter is hosted.
Id string
Resource ID.
Location string
Resource location.
Tags map[string]string
Resource tags.
VirtualRouterAsn float64
VirtualRouter ASN.
VirtualRouterIps []string
VirtualRouter IPs.
etag String
A unique read-only string that changes whenever the resource is updated.
name String
Resource name.
peerings List<SubResourceResponse>
List of references to VirtualRouterPeerings.
provisioningState String
The provisioning state of the resource.
type String
Resource type.
hostedGateway SubResourceResponse
The Gateway on which VirtualRouter is hosted.
hostedSubnet SubResourceResponse
The Subnet on which VirtualRouter is hosted.
id String
Resource ID.
location String
Resource location.
tags Map<String,String>
Resource tags.
virtualRouterAsn Double
VirtualRouter ASN.
virtualRouterIps List<String>
VirtualRouter IPs.
etag string
A unique read-only string that changes whenever the resource is updated.
name string
Resource name.
peerings SubResourceResponse[]
List of references to VirtualRouterPeerings.
provisioningState string
The provisioning state of the resource.
type string
Resource type.
hostedGateway SubResourceResponse
The Gateway on which VirtualRouter is hosted.
hostedSubnet SubResourceResponse
The Subnet on which VirtualRouter is hosted.
id string
Resource ID.
location string
Resource location.
tags {[key: string]: string}
Resource tags.
virtualRouterAsn number
VirtualRouter ASN.
virtualRouterIps string[]
VirtualRouter IPs.
etag str
A unique read-only string that changes whenever the resource is updated.
name str
Resource name.
peerings Sequence[SubResourceResponse]
List of references to VirtualRouterPeerings.
provisioning_state str
The provisioning state of the resource.
type str
Resource type.
hosted_gateway SubResourceResponse
The Gateway on which VirtualRouter is hosted.
hosted_subnet SubResourceResponse
The Subnet on which VirtualRouter is hosted.
id str
Resource ID.
location str
Resource location.
tags Mapping[str, str]
Resource tags.
virtual_router_asn float
VirtualRouter ASN.
virtual_router_ips Sequence[str]
VirtualRouter IPs.
etag String
A unique read-only string that changes whenever the resource is updated.
name String
Resource name.
peerings List<Property Map>
List of references to VirtualRouterPeerings.
provisioningState String
The provisioning state of the resource.
type String
Resource type.
hostedGateway Property Map
The Gateway on which VirtualRouter is hosted.
hostedSubnet Property Map
The Subnet on which VirtualRouter is hosted.
id String
Resource ID.
location String
Resource location.
tags Map<String>
Resource tags.
virtualRouterAsn Number
VirtualRouter ASN.
virtualRouterIps List<String>
VirtualRouter IPs.

Supporting Types

SubResourceResponse

Id This property is required. string
Resource ID.
Id This property is required. string
Resource ID.
id This property is required. String
Resource ID.
id This property is required. string
Resource ID.
id This property is required. str
Resource ID.
id This property is required. String
Resource ID.

Package Details

Repository
azure-native-v2 pulumi/pulumi-azure-native
License
Apache-2.0
These are the docs for Azure Native v2. We recommenend using the latest version, Azure Native v3.
Azure Native v2 v2.90.0 published on Thursday, Mar 27, 2025 by Pulumi