We recommend using Azure Native.
Azure Classic v5.81.0 published on Monday, Jun 24, 2024 by Pulumi
azure.network.getExpressRouteCircuit
Explore with Pulumi AI
Use this data source to access information about an existing ExpressRoute circuit.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const example = azure.network.getExpressRouteCircuit({
resourceGroupName: exampleAzurermResourceGroup.name,
name: exampleAzurermExpressRouteCircuit.name,
});
export const expressRouteCircuitId = example.then(example => example.id);
export const serviceKey = example.then(example => example.serviceKey);
import pulumi
import pulumi_azure as azure
example = azure.network.get_express_route_circuit(resource_group_name=example_azurerm_resource_group["name"],
name=example_azurerm_express_route_circuit["name"])
pulumi.export("expressRouteCircuitId", example.id)
pulumi.export("serviceKey", example.service_key)
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/network"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := network.LookupExpressRouteCircuit(ctx, &network.LookupExpressRouteCircuitArgs{
ResourceGroupName: exampleAzurermResourceGroup.Name,
Name: exampleAzurermExpressRouteCircuit.Name,
}, nil)
if err != nil {
return err
}
ctx.Export("expressRouteCircuitId", example.Id)
ctx.Export("serviceKey", example.ServiceKey)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Azure = Pulumi.Azure;
return await Deployment.RunAsync(() =>
{
var example = Azure.Network.GetExpressRouteCircuit.Invoke(new()
{
ResourceGroupName = exampleAzurermResourceGroup.Name,
Name = exampleAzurermExpressRouteCircuit.Name,
});
return new Dictionary<string, object?>
{
["expressRouteCircuitId"] = example.Apply(getExpressRouteCircuitResult => getExpressRouteCircuitResult.Id),
["serviceKey"] = example.Apply(getExpressRouteCircuitResult => getExpressRouteCircuitResult.ServiceKey),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.network.NetworkFunctions;
import com.pulumi.azure.network.inputs.GetExpressRouteCircuitArgs;
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 = NetworkFunctions.getExpressRouteCircuit(GetExpressRouteCircuitArgs.builder()
.resourceGroupName(exampleAzurermResourceGroup.name())
.name(exampleAzurermExpressRouteCircuit.name())
.build());
ctx.export("expressRouteCircuitId", example.applyValue(getExpressRouteCircuitResult -> getExpressRouteCircuitResult.id()));
ctx.export("serviceKey", example.applyValue(getExpressRouteCircuitResult -> getExpressRouteCircuitResult.serviceKey()));
}
}
variables:
example:
fn::invoke:
Function: azure:network:getExpressRouteCircuit
Arguments:
resourceGroupName: ${exampleAzurermResourceGroup.name}
name: ${exampleAzurermExpressRouteCircuit.name}
outputs:
expressRouteCircuitId: ${example.id}
serviceKey: ${example.serviceKey}
Using getExpressRouteCircuit
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 getExpressRouteCircuit(args: GetExpressRouteCircuitArgs, opts?: InvokeOptions): Promise<GetExpressRouteCircuitResult>
function getExpressRouteCircuitOutput(args: GetExpressRouteCircuitOutputArgs, opts?: InvokeOptions): Output<GetExpressRouteCircuitResult>
def get_express_route_circuit(name: Optional[str] = None,
resource_group_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetExpressRouteCircuitResult
def get_express_route_circuit_output(name: Optional[pulumi.Input[str]] = None,
resource_group_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetExpressRouteCircuitResult]
func LookupExpressRouteCircuit(ctx *Context, args *LookupExpressRouteCircuitArgs, opts ...InvokeOption) (*LookupExpressRouteCircuitResult, error)
func LookupExpressRouteCircuitOutput(ctx *Context, args *LookupExpressRouteCircuitOutputArgs, opts ...InvokeOption) LookupExpressRouteCircuitResultOutput
> Note: This function is named LookupExpressRouteCircuit
in the Go SDK.
public static class GetExpressRouteCircuit
{
public static Task<GetExpressRouteCircuitResult> InvokeAsync(GetExpressRouteCircuitArgs args, InvokeOptions? opts = null)
public static Output<GetExpressRouteCircuitResult> Invoke(GetExpressRouteCircuitInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetExpressRouteCircuitResult> getExpressRouteCircuit(GetExpressRouteCircuitArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: azure:network/getExpressRouteCircuit:getExpressRouteCircuit
arguments:
# arguments dictionary
The following arguments are supported:
- Name string
- The name of the ExpressRoute circuit.
- Resource
Group stringName - The Name of the Resource Group where the ExpressRoute circuit exists.
- Name string
- The name of the ExpressRoute circuit.
- Resource
Group stringName - The Name of the Resource Group where the ExpressRoute circuit exists.
- name String
- The name of the ExpressRoute circuit.
- resource
Group StringName - The Name of the Resource Group where the ExpressRoute circuit exists.
- name string
- The name of the ExpressRoute circuit.
- resource
Group stringName - The Name of the Resource Group where the ExpressRoute circuit exists.
- name str
- The name of the ExpressRoute circuit.
- resource_
group_ strname - The Name of the Resource Group where the ExpressRoute circuit exists.
- name String
- The name of the ExpressRoute circuit.
- resource
Group StringName - The Name of the Resource Group where the ExpressRoute circuit exists.
getExpressRouteCircuit Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Location string
- The Azure location where the ExpressRoute circuit exists
- Name string
- Peerings
List<Get
Express Route Circuit Peering> - A
peerings
block for the ExpressRoute circuit as documented below - Resource
Group stringName - Service
Key string - The string needed by the service provider to provision the ExpressRoute circuit.
- Service
Provider List<GetProperties Express Route Circuit Service Provider Property> - A
service_provider_properties
block for the ExpressRoute circuit as documented below - Service
Provider stringProvisioning State - The ExpressRoute circuit provisioning state from your chosen service provider. Possible values are
NotProvisioned
,Provisioning
,Provisioned
, andDeprovisioning
. - Sku
Get
Express Route Circuit Sku - A
sku
block for the ExpressRoute circuit as documented below.
- Id string
- The provider-assigned unique ID for this managed resource.
- Location string
- The Azure location where the ExpressRoute circuit exists
- Name string
- Peerings
[]Get
Express Route Circuit Peering Type - A
peerings
block for the ExpressRoute circuit as documented below - Resource
Group stringName - Service
Key string - The string needed by the service provider to provision the ExpressRoute circuit.
- Service
Provider []GetProperties Express Route Circuit Service Provider Property - A
service_provider_properties
block for the ExpressRoute circuit as documented below - Service
Provider stringProvisioning State - The ExpressRoute circuit provisioning state from your chosen service provider. Possible values are
NotProvisioned
,Provisioning
,Provisioned
, andDeprovisioning
. - Sku
Get
Express Route Circuit Sku - A
sku
block for the ExpressRoute circuit as documented below.
- id String
- The provider-assigned unique ID for this managed resource.
- location String
- The Azure location where the ExpressRoute circuit exists
- name String
- peerings
List<Get
Express Route Circuit Peering> - A
peerings
block for the ExpressRoute circuit as documented below - resource
Group StringName - service
Key String - The string needed by the service provider to provision the ExpressRoute circuit.
- service
Provider List<GetProperties Express Route Circuit Service Provider Property> - A
service_provider_properties
block for the ExpressRoute circuit as documented below - service
Provider StringProvisioning State - The ExpressRoute circuit provisioning state from your chosen service provider. Possible values are
NotProvisioned
,Provisioning
,Provisioned
, andDeprovisioning
. - sku
Get
Express Route Circuit Sku - A
sku
block for the ExpressRoute circuit as documented below.
- id string
- The provider-assigned unique ID for this managed resource.
- location string
- The Azure location where the ExpressRoute circuit exists
- name string
- peerings
Get
Express Route Circuit Peering[] - A
peerings
block for the ExpressRoute circuit as documented below - resource
Group stringName - service
Key string - The string needed by the service provider to provision the ExpressRoute circuit.
- service
Provider GetProperties Express Route Circuit Service Provider Property[] - A
service_provider_properties
block for the ExpressRoute circuit as documented below - service
Provider stringProvisioning State - The ExpressRoute circuit provisioning state from your chosen service provider. Possible values are
NotProvisioned
,Provisioning
,Provisioned
, andDeprovisioning
. - sku
Get
Express Route Circuit Sku - A
sku
block for the ExpressRoute circuit as documented below.
- id str
- The provider-assigned unique ID for this managed resource.
- location str
- The Azure location where the ExpressRoute circuit exists
- name str
- peerings
Sequence[Get
Express Route Circuit Peering] - A
peerings
block for the ExpressRoute circuit as documented below - resource_
group_ strname - service_
key str - The string needed by the service provider to provision the ExpressRoute circuit.
- service_
provider_ Sequence[Getproperties Express Route Circuit Service Provider Property] - A
service_provider_properties
block for the ExpressRoute circuit as documented below - service_
provider_ strprovisioning_ state - The ExpressRoute circuit provisioning state from your chosen service provider. Possible values are
NotProvisioned
,Provisioning
,Provisioned
, andDeprovisioning
. - sku
Get
Express Route Circuit Sku - A
sku
block for the ExpressRoute circuit as documented below.
- id String
- The provider-assigned unique ID for this managed resource.
- location String
- The Azure location where the ExpressRoute circuit exists
- name String
- peerings List<Property Map>
- A
peerings
block for the ExpressRoute circuit as documented below - resource
Group StringName - service
Key String - The string needed by the service provider to provision the ExpressRoute circuit.
- service
Provider List<Property Map>Properties - A
service_provider_properties
block for the ExpressRoute circuit as documented below - service
Provider StringProvisioning State - The ExpressRoute circuit provisioning state from your chosen service provider. Possible values are
NotProvisioned
,Provisioning
,Provisioned
, andDeprovisioning
. - sku Property Map
- A
sku
block for the ExpressRoute circuit as documented below.
Supporting Types
GetExpressRouteCircuitPeering
- Azure
Asn int - The Either a 16-bit or a 32-bit ASN for Azure.
- Peer
Asn int - The Either a 16-bit or a 32-bit ASN. Can either be public or private.
- Peering
Type string - The type of the ExpressRoute Circuit Peering. Acceptable values include
AzurePrivatePeering
,AzurePublicPeering
andMicrosoftPeering
. Changing this forces a new resource to be created. - Primary
Peer stringAddress Prefix - A
/30
subnet for the primary link. - Secondary
Peer stringAddress Prefix - A
/30
subnet for the secondary link. - string
- The shared key. Can be a maximum of 25 characters.
- Vlan
Id int - A valid VLAN ID to establish this peering on.
- Azure
Asn int - The Either a 16-bit or a 32-bit ASN for Azure.
- Peer
Asn int - The Either a 16-bit or a 32-bit ASN. Can either be public or private.
- Peering
Type string - The type of the ExpressRoute Circuit Peering. Acceptable values include
AzurePrivatePeering
,AzurePublicPeering
andMicrosoftPeering
. Changing this forces a new resource to be created. - Primary
Peer stringAddress Prefix - A
/30
subnet for the primary link. - Secondary
Peer stringAddress Prefix - A
/30
subnet for the secondary link. - string
- The shared key. Can be a maximum of 25 characters.
- Vlan
Id int - A valid VLAN ID to establish this peering on.
- azure
Asn Integer - The Either a 16-bit or a 32-bit ASN for Azure.
- peer
Asn Integer - The Either a 16-bit or a 32-bit ASN. Can either be public or private.
- peering
Type String - The type of the ExpressRoute Circuit Peering. Acceptable values include
AzurePrivatePeering
,AzurePublicPeering
andMicrosoftPeering
. Changing this forces a new resource to be created. - primary
Peer StringAddress Prefix - A
/30
subnet for the primary link. - secondary
Peer StringAddress Prefix - A
/30
subnet for the secondary link. - String
- The shared key. Can be a maximum of 25 characters.
- vlan
Id Integer - A valid VLAN ID to establish this peering on.
- azure
Asn number - The Either a 16-bit or a 32-bit ASN for Azure.
- peer
Asn number - The Either a 16-bit or a 32-bit ASN. Can either be public or private.
- peering
Type string - The type of the ExpressRoute Circuit Peering. Acceptable values include
AzurePrivatePeering
,AzurePublicPeering
andMicrosoftPeering
. Changing this forces a new resource to be created. - primary
Peer stringAddress Prefix - A
/30
subnet for the primary link. - secondary
Peer stringAddress Prefix - A
/30
subnet for the secondary link. - string
- The shared key. Can be a maximum of 25 characters.
- vlan
Id number - A valid VLAN ID to establish this peering on.
- azure_
asn int - The Either a 16-bit or a 32-bit ASN for Azure.
- peer_
asn int - The Either a 16-bit or a 32-bit ASN. Can either be public or private.
- peering_
type str - The type of the ExpressRoute Circuit Peering. Acceptable values include
AzurePrivatePeering
,AzurePublicPeering
andMicrosoftPeering
. Changing this forces a new resource to be created. - primary_
peer_ straddress_ prefix - A
/30
subnet for the primary link. - secondary_
peer_ straddress_ prefix - A
/30
subnet for the secondary link. - str
- The shared key. Can be a maximum of 25 characters.
- vlan_
id int - A valid VLAN ID to establish this peering on.
- azure
Asn Number - The Either a 16-bit or a 32-bit ASN for Azure.
- peer
Asn Number - The Either a 16-bit or a 32-bit ASN. Can either be public or private.
- peering
Type String - The type of the ExpressRoute Circuit Peering. Acceptable values include
AzurePrivatePeering
,AzurePublicPeering
andMicrosoftPeering
. Changing this forces a new resource to be created. - primary
Peer StringAddress Prefix - A
/30
subnet for the primary link. - secondary
Peer StringAddress Prefix - A
/30
subnet for the secondary link. - String
- The shared key. Can be a maximum of 25 characters.
- vlan
Id Number - A valid VLAN ID to establish this peering on.
GetExpressRouteCircuitServiceProviderProperty
- Bandwidth
In intMbps - The bandwidth in Mbps of the ExpressRoute circuit.
- Peering
Location string - The name of the peering location and not the Azure resource location.
- Service
Provider stringName - The name of the ExpressRoute Service Provider.
- Bandwidth
In intMbps - The bandwidth in Mbps of the ExpressRoute circuit.
- Peering
Location string - The name of the peering location and not the Azure resource location.
- Service
Provider stringName - The name of the ExpressRoute Service Provider.
- bandwidth
In IntegerMbps - The bandwidth in Mbps of the ExpressRoute circuit.
- peering
Location String - The name of the peering location and not the Azure resource location.
- service
Provider StringName - The name of the ExpressRoute Service Provider.
- bandwidth
In numberMbps - The bandwidth in Mbps of the ExpressRoute circuit.
- peering
Location string - The name of the peering location and not the Azure resource location.
- service
Provider stringName - The name of the ExpressRoute Service Provider.
- bandwidth_
in_ intmbps - The bandwidth in Mbps of the ExpressRoute circuit.
- peering_
location str - The name of the peering location and not the Azure resource location.
- service_
provider_ strname - The name of the ExpressRoute Service Provider.
- bandwidth
In NumberMbps - The bandwidth in Mbps of the ExpressRoute circuit.
- peering
Location String - The name of the peering location and not the Azure resource location.
- service
Provider StringName - The name of the ExpressRoute Service Provider.
GetExpressRouteCircuitSku
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurerm
Terraform Provider.