1. Packages
  2. Tencentcloud Provider
  3. API Docs
  4. getNatDcRoute
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

tencentcloud.getNatDcRoute

Explore with Pulumi AI

tencentcloud logo
tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack

    Use this data source to query detailed information of vpc nat_dc_route

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as tencentcloud from "@pulumi/tencentcloud";
    
    const natDcRoute = tencentcloud.getNatDcRoute({
        natGatewayId: "nat-gnxkey2e",
        vpcId: "vpc-pyyv5k3v",
    });
    
    import pulumi
    import pulumi_tencentcloud as tencentcloud
    
    nat_dc_route = tencentcloud.get_nat_dc_route(nat_gateway_id="nat-gnxkey2e",
        vpc_id="vpc-pyyv5k3v")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tencentcloud.GetNatDcRoute(ctx, &tencentcloud.GetNatDcRouteArgs{
    			NatGatewayId: "nat-gnxkey2e",
    			VpcId:        "vpc-pyyv5k3v",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Tencentcloud = Pulumi.Tencentcloud;
    
    return await Deployment.RunAsync(() => 
    {
        var natDcRoute = Tencentcloud.GetNatDcRoute.Invoke(new()
        {
            NatGatewayId = "nat-gnxkey2e",
            VpcId = "vpc-pyyv5k3v",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.tencentcloud.TencentcloudFunctions;
    import com.pulumi.tencentcloud.inputs.GetNatDcRouteArgs;
    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 natDcRoute = TencentcloudFunctions.getNatDcRoute(GetNatDcRouteArgs.builder()
                .natGatewayId("nat-gnxkey2e")
                .vpcId("vpc-pyyv5k3v")
                .build());
    
        }
    }
    
    variables:
      natDcRoute:
        fn::invoke:
          function: tencentcloud:getNatDcRoute
          arguments:
            natGatewayId: nat-gnxkey2e
            vpcId: vpc-pyyv5k3v
    

    Using getNatDcRoute

    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 getNatDcRoute(args: GetNatDcRouteArgs, opts?: InvokeOptions): Promise<GetNatDcRouteResult>
    function getNatDcRouteOutput(args: GetNatDcRouteOutputArgs, opts?: InvokeOptions): Output<GetNatDcRouteResult>
    def get_nat_dc_route(id: Optional[str] = None,
                         nat_gateway_id: Optional[str] = None,
                         result_output_file: Optional[str] = None,
                         vpc_id: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetNatDcRouteResult
    def get_nat_dc_route_output(id: Optional[pulumi.Input[str]] = None,
                         nat_gateway_id: Optional[pulumi.Input[str]] = None,
                         result_output_file: Optional[pulumi.Input[str]] = None,
                         vpc_id: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetNatDcRouteResult]
    func GetNatDcRoute(ctx *Context, args *GetNatDcRouteArgs, opts ...InvokeOption) (*GetNatDcRouteResult, error)
    func GetNatDcRouteOutput(ctx *Context, args *GetNatDcRouteOutputArgs, opts ...InvokeOption) GetNatDcRouteResultOutput

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

    public static class GetNatDcRoute 
    {
        public static Task<GetNatDcRouteResult> InvokeAsync(GetNatDcRouteArgs args, InvokeOptions? opts = null)
        public static Output<GetNatDcRouteResult> Invoke(GetNatDcRouteInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetNatDcRouteResult> getNatDcRoute(GetNatDcRouteArgs args, InvokeOptions options)
    public static Output<GetNatDcRouteResult> getNatDcRoute(GetNatDcRouteArgs args, InvokeOptions options)
    
    fn::invoke:
      function: tencentcloud:index/getNatDcRoute:getNatDcRoute
      arguments:
        # arguments dictionary

    The following arguments are supported:

    NatGatewayId string
    Unique identifier of Nat Gateway.
    VpcId string
    Unique identifier of Vpc.
    Id string
    ResultOutputFile string
    Used to save results.
    NatGatewayId string
    Unique identifier of Nat Gateway.
    VpcId string
    Unique identifier of Vpc.
    Id string
    ResultOutputFile string
    Used to save results.
    natGatewayId String
    Unique identifier of Nat Gateway.
    vpcId String
    Unique identifier of Vpc.
    id String
    resultOutputFile String
    Used to save results.
    natGatewayId string
    Unique identifier of Nat Gateway.
    vpcId string
    Unique identifier of Vpc.
    id string
    resultOutputFile string
    Used to save results.
    nat_gateway_id str
    Unique identifier of Nat Gateway.
    vpc_id str
    Unique identifier of Vpc.
    id str
    result_output_file str
    Used to save results.
    natGatewayId String
    Unique identifier of Nat Gateway.
    vpcId String
    Unique identifier of Vpc.
    id String
    resultOutputFile String
    Used to save results.

    getNatDcRoute Result

    The following output properties are available:

    Supporting Types

    GetNatDcRouteNatDirectConnectGatewayRouteSet

    CreateTime string
    Create time of route.
    DestinationCidrBlock string
    IPv4 CIDR of subnet.
    GatewayId string
    Id of next-hop gateway.
    GatewayType string
    Type of next-hop gateway, valid values: DIRECTCONNECT.
    UpdateTime string
    Update time of route.
    CreateTime string
    Create time of route.
    DestinationCidrBlock string
    IPv4 CIDR of subnet.
    GatewayId string
    Id of next-hop gateway.
    GatewayType string
    Type of next-hop gateway, valid values: DIRECTCONNECT.
    UpdateTime string
    Update time of route.
    createTime String
    Create time of route.
    destinationCidrBlock String
    IPv4 CIDR of subnet.
    gatewayId String
    Id of next-hop gateway.
    gatewayType String
    Type of next-hop gateway, valid values: DIRECTCONNECT.
    updateTime String
    Update time of route.
    createTime string
    Create time of route.
    destinationCidrBlock string
    IPv4 CIDR of subnet.
    gatewayId string
    Id of next-hop gateway.
    gatewayType string
    Type of next-hop gateway, valid values: DIRECTCONNECT.
    updateTime string
    Update time of route.
    create_time str
    Create time of route.
    destination_cidr_block str
    IPv4 CIDR of subnet.
    gateway_id str
    Id of next-hop gateway.
    gateway_type str
    Type of next-hop gateway, valid values: DIRECTCONNECT.
    update_time str
    Update time of route.
    createTime String
    Create time of route.
    destinationCidrBlock String
    IPv4 CIDR of subnet.
    gatewayId String
    Id of next-hop gateway.
    gatewayType String
    Type of next-hop gateway, valid values: DIRECTCONNECT.
    updateTime String
    Update time of route.

    Package Details

    Repository
    tencentcloud tencentcloudstack/terraform-provider-tencentcloud
    License
    Notes
    This Pulumi package is based on the tencentcloud Terraform Provider.
    tencentcloud logo
    tencentcloud 1.81.189 published on Wednesday, Apr 30, 2025 by tencentcloudstack