1. Packages
  2. Packages
  3. Twingate
  4. API Docs
  5. getTwingateGateway
Viewing docs for Twingate v4.1.0
published on Monday, Apr 13, 2026 by Twingate
twingate logo
Viewing docs for Twingate v4.1.0
published on Monday, Apr 13, 2026 by Twingate

    Gateways are the Twingate components that route traffic to remote networks.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as twingate from "@twingate/pulumi-twingate";
    
    const example = twingate.getTwingateGateway({
        id: "<your gateway's id>",
    });
    
    import pulumi
    import pulumi_twingate as twingate
    
    example = twingate.get_twingate_gateway(id="<your gateway's id>")
    
    package main
    
    import (
    	"github.com/Twingate/pulumi-twingate/sdk/v4/go/twingate"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := twingate.LookupTwingateGateway(ctx, &twingate.LookupTwingateGatewayArgs{
    			Id: "<your gateway's id>",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Twingate = Twingate.Twingate;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Twingate.GetTwingateGateway.Invoke(new()
        {
            Id = "<your gateway's id>",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.twingate.TwingateFunctions;
    import com.pulumi.twingate.inputs.GetTwingateGatewayArgs;
    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 = TwingateFunctions.getTwingateGateway(GetTwingateGatewayArgs.builder()
                .id("<your gateway's id>")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: twingate:getTwingateGateway
          arguments:
            id: <your gateway's id>
    

    Using getTwingateGateway

    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 getTwingateGateway(args: GetTwingateGatewayArgs, opts?: InvokeOptions): Promise<GetTwingateGatewayResult>
    function getTwingateGatewayOutput(args: GetTwingateGatewayOutputArgs, opts?: InvokeOptions): Output<GetTwingateGatewayResult>
    def get_twingate_gateway(id: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetTwingateGatewayResult
    def get_twingate_gateway_output(id: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetTwingateGatewayResult]
    func LookupTwingateGateway(ctx *Context, args *LookupTwingateGatewayArgs, opts ...InvokeOption) (*LookupTwingateGatewayResult, error)
    func LookupTwingateGatewayOutput(ctx *Context, args *LookupTwingateGatewayOutputArgs, opts ...InvokeOption) LookupTwingateGatewayResultOutput

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

    public static class GetTwingateGateway 
    {
        public static Task<GetTwingateGatewayResult> InvokeAsync(GetTwingateGatewayArgs args, InvokeOptions? opts = null)
        public static Output<GetTwingateGatewayResult> Invoke(GetTwingateGatewayInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetTwingateGatewayResult> getTwingateGateway(GetTwingateGatewayArgs args, InvokeOptions options)
    public static Output<GetTwingateGatewayResult> getTwingateGateway(GetTwingateGatewayArgs args, InvokeOptions options)
    
    fn::invoke:
      function: twingate:index/getTwingateGateway:getTwingateGateway
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    The ID of the Gateway.
    Id string
    The ID of the Gateway.
    id String
    The ID of the Gateway.
    id string
    The ID of the Gateway.
    id str
    The ID of the Gateway.
    id String
    The ID of the Gateway.

    getTwingateGateway Result

    The following output properties are available:

    Address string
    The address of the Gateway.
    Id string
    The ID of the Gateway.
    RemoteNetworkId string
    The ID of the Remote Network the Gateway belongs to.
    SshCaId string
    The ID of the SSH Certificate Authority used for SSH access.
    X509CaId string
    The ID of the X.509 Certificate Authority used for TLS.
    Address string
    The address of the Gateway.
    Id string
    The ID of the Gateway.
    RemoteNetworkId string
    The ID of the Remote Network the Gateway belongs to.
    SshCaId string
    The ID of the SSH Certificate Authority used for SSH access.
    X509CaId string
    The ID of the X.509 Certificate Authority used for TLS.
    address String
    The address of the Gateway.
    id String
    The ID of the Gateway.
    remoteNetworkId String
    The ID of the Remote Network the Gateway belongs to.
    sshCaId String
    The ID of the SSH Certificate Authority used for SSH access.
    x509CaId String
    The ID of the X.509 Certificate Authority used for TLS.
    address string
    The address of the Gateway.
    id string
    The ID of the Gateway.
    remoteNetworkId string
    The ID of the Remote Network the Gateway belongs to.
    sshCaId string
    The ID of the SSH Certificate Authority used for SSH access.
    x509CaId string
    The ID of the X.509 Certificate Authority used for TLS.
    address str
    The address of the Gateway.
    id str
    The ID of the Gateway.
    remote_network_id str
    The ID of the Remote Network the Gateway belongs to.
    ssh_ca_id str
    The ID of the SSH Certificate Authority used for SSH access.
    x509_ca_id str
    The ID of the X.509 Certificate Authority used for TLS.
    address String
    The address of the Gateway.
    id String
    The ID of the Gateway.
    remoteNetworkId String
    The ID of the Remote Network the Gateway belongs to.
    sshCaId String
    The ID of the SSH Certificate Authority used for SSH access.
    x509CaId String
    The ID of the X.509 Certificate Authority used for TLS.

    Package Details

    Repository
    twingate Twingate/pulumi-twingate
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the twingate Terraform Provider.
    twingate logo
    Viewing docs for Twingate v4.1.0
    published on Monday, Apr 13, 2026 by Twingate
      Try Pulumi Cloud free. Your team will thank you.