1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. ApiGateway
  5. getGateway
Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi

oci.ApiGateway.getGateway

Explore with Pulumi AI

Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi

This data source provides details about a specific Gateway resource in Oracle Cloud Infrastructure API Gateway service.

Gets a gateway by identifier.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testGateway = oci.ApiGateway.getGateway({
    gatewayId: testGatewayOciApigatewayGateway.id,
});
Copy
import pulumi
import pulumi_oci as oci

test_gateway = oci.ApiGateway.get_gateway(gateway_id=test_gateway_oci_apigateway_gateway["id"])
Copy
package main

import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/apigateway"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := apigateway.GetGateway(ctx, &apigateway.GetGatewayArgs{
			GatewayId: testGatewayOciApigatewayGateway.Id,
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;

return await Deployment.RunAsync(() => 
{
    var testGateway = Oci.ApiGateway.GetGateway.Invoke(new()
    {
        GatewayId = testGatewayOciApigatewayGateway.Id,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.ApiGateway.ApiGatewayFunctions;
import com.pulumi.oci.ApiGateway.inputs.GetGatewayArgs;
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 testGateway = ApiGatewayFunctions.getGateway(GetGatewayArgs.builder()
            .gatewayId(testGatewayOciApigatewayGateway.id())
            .build());

    }
}
Copy
variables:
  testGateway:
    fn::invoke:
      function: oci:ApiGateway:getGateway
      arguments:
        gatewayId: ${testGatewayOciApigatewayGateway.id}
Copy

Using getGateway

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 getGateway(args: GetGatewayArgs, opts?: InvokeOptions): Promise<GetGatewayResult>
function getGatewayOutput(args: GetGatewayOutputArgs, opts?: InvokeOptions): Output<GetGatewayResult>
Copy
def get_gateway(gateway_id: Optional[str] = None,
                opts: Optional[InvokeOptions] = None) -> GetGatewayResult
def get_gateway_output(gateway_id: Optional[pulumi.Input[str]] = None,
                opts: Optional[InvokeOptions] = None) -> Output[GetGatewayResult]
Copy
func GetGateway(ctx *Context, args *GetGatewayArgs, opts ...InvokeOption) (*GetGatewayResult, error)
func GetGatewayOutput(ctx *Context, args *GetGatewayOutputArgs, opts ...InvokeOption) GetGatewayResultOutput
Copy

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

public static class GetGateway 
{
    public static Task<GetGatewayResult> InvokeAsync(GetGatewayArgs args, InvokeOptions? opts = null)
    public static Output<GetGatewayResult> Invoke(GetGatewayInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetGatewayResult> getGateway(GetGatewayArgs args, InvokeOptions options)
public static Output<GetGatewayResult> getGateway(GetGatewayArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: oci:ApiGateway/getGateway:getGateway
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

GatewayId This property is required. string
The ocid of the gateway.
GatewayId This property is required. string
The ocid of the gateway.
gatewayId This property is required. String
The ocid of the gateway.
gatewayId This property is required. string
The ocid of the gateway.
gateway_id This property is required. str
The ocid of the gateway.
gatewayId This property is required. String
The ocid of the gateway.

getGateway Result

The following output properties are available:

CaBundles List<GetGatewayCaBundle>
An array of CA bundles that should be used on the Gateway for TLS validation.
CertificateId string
The OCID of the resource.
CompartmentId string
The OCID of the compartment in which the resource is created.
DefinedTags Dictionary<string, string>
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
DisplayName string
A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
EndpointType string
Gateway endpoint type. PUBLIC will have a public ip address assigned to it, while PRIVATE will only be accessible on a private IP address on the subnet. Example: PUBLIC or PRIVATE
FreeformTags Dictionary<string, string>
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
GatewayId string
Hostname string
The hostname for APIs deployed on the gateway.
Id string
The OCID of the resource.
IpAddresses List<GetGatewayIpAddress>
An array of IP addresses associated with the gateway.
LifecycleDetails string
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in a Failed state.
NetworkSecurityGroupIds List<string>
An array of Network Security Groups OCIDs associated with this API Gateway.
ResponseCacheDetails List<GetGatewayResponseCacheDetail>
Base Gateway response cache.
State string
The current state of the gateway.
SubnetId string
The OCID of the subnet in which related resources are created.
TimeCreated string
The time this resource was created. An RFC3339 formatted datetime string.
TimeUpdated string
The time this resource was last updated. An RFC3339 formatted datetime string.
CaBundles []GetGatewayCaBundle
An array of CA bundles that should be used on the Gateway for TLS validation.
CertificateId string
The OCID of the resource.
CompartmentId string
The OCID of the compartment in which the resource is created.
DefinedTags map[string]string
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
DisplayName string
A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
EndpointType string
Gateway endpoint type. PUBLIC will have a public ip address assigned to it, while PRIVATE will only be accessible on a private IP address on the subnet. Example: PUBLIC or PRIVATE
FreeformTags map[string]string
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
GatewayId string
Hostname string
The hostname for APIs deployed on the gateway.
Id string
The OCID of the resource.
IpAddresses []GetGatewayIpAddress
An array of IP addresses associated with the gateway.
LifecycleDetails string
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in a Failed state.
NetworkSecurityGroupIds []string
An array of Network Security Groups OCIDs associated with this API Gateway.
ResponseCacheDetails []GetGatewayResponseCacheDetail
Base Gateway response cache.
State string
The current state of the gateway.
SubnetId string
The OCID of the subnet in which related resources are created.
TimeCreated string
The time this resource was created. An RFC3339 formatted datetime string.
TimeUpdated string
The time this resource was last updated. An RFC3339 formatted datetime string.
caBundles List<GetGatewayCaBundle>
An array of CA bundles that should be used on the Gateway for TLS validation.
certificateId String
The OCID of the resource.
compartmentId String
The OCID of the compartment in which the resource is created.
definedTags Map<String,String>
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
displayName String
A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
endpointType String
Gateway endpoint type. PUBLIC will have a public ip address assigned to it, while PRIVATE will only be accessible on a private IP address on the subnet. Example: PUBLIC or PRIVATE
freeformTags Map<String,String>
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
gatewayId String
hostname String
The hostname for APIs deployed on the gateway.
id String
The OCID of the resource.
ipAddresses List<GetGatewayIpAddress>
An array of IP addresses associated with the gateway.
lifecycleDetails String
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in a Failed state.
networkSecurityGroupIds List<String>
An array of Network Security Groups OCIDs associated with this API Gateway.
responseCacheDetails List<GetGatewayResponseCacheDetail>
Base Gateway response cache.
state String
The current state of the gateway.
subnetId String
The OCID of the subnet in which related resources are created.
timeCreated String
The time this resource was created. An RFC3339 formatted datetime string.
timeUpdated String
The time this resource was last updated. An RFC3339 formatted datetime string.
caBundles GetGatewayCaBundle[]
An array of CA bundles that should be used on the Gateway for TLS validation.
certificateId string
The OCID of the resource.
compartmentId string
The OCID of the compartment in which the resource is created.
definedTags {[key: string]: string}
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
displayName string
A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
endpointType string
Gateway endpoint type. PUBLIC will have a public ip address assigned to it, while PRIVATE will only be accessible on a private IP address on the subnet. Example: PUBLIC or PRIVATE
freeformTags {[key: string]: string}
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
gatewayId string
hostname string
The hostname for APIs deployed on the gateway.
id string
The OCID of the resource.
ipAddresses GetGatewayIpAddress[]
An array of IP addresses associated with the gateway.
lifecycleDetails string
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in a Failed state.
networkSecurityGroupIds string[]
An array of Network Security Groups OCIDs associated with this API Gateway.
responseCacheDetails GetGatewayResponseCacheDetail[]
Base Gateway response cache.
state string
The current state of the gateway.
subnetId string
The OCID of the subnet in which related resources are created.
timeCreated string
The time this resource was created. An RFC3339 formatted datetime string.
timeUpdated string
The time this resource was last updated. An RFC3339 formatted datetime string.
ca_bundles Sequence[apigateway.GetGatewayCaBundle]
An array of CA bundles that should be used on the Gateway for TLS validation.
certificate_id str
The OCID of the resource.
compartment_id str
The OCID of the compartment in which the resource is created.
defined_tags Mapping[str, str]
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
display_name str
A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
endpoint_type str
Gateway endpoint type. PUBLIC will have a public ip address assigned to it, while PRIVATE will only be accessible on a private IP address on the subnet. Example: PUBLIC or PRIVATE
freeform_tags Mapping[str, str]
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
gateway_id str
hostname str
The hostname for APIs deployed on the gateway.
id str
The OCID of the resource.
ip_addresses Sequence[apigateway.GetGatewayIpAddress]
An array of IP addresses associated with the gateway.
lifecycle_details str
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in a Failed state.
network_security_group_ids Sequence[str]
An array of Network Security Groups OCIDs associated with this API Gateway.
response_cache_details Sequence[apigateway.GetGatewayResponseCacheDetail]
Base Gateway response cache.
state str
The current state of the gateway.
subnet_id str
The OCID of the subnet in which related resources are created.
time_created str
The time this resource was created. An RFC3339 formatted datetime string.
time_updated str
The time this resource was last updated. An RFC3339 formatted datetime string.
caBundles List<Property Map>
An array of CA bundles that should be used on the Gateway for TLS validation.
certificateId String
The OCID of the resource.
compartmentId String
The OCID of the compartment in which the resource is created.
definedTags Map<String>
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example: {"Operations.CostCenter": "42"}
displayName String
A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information. Example: My new resource
endpointType String
Gateway endpoint type. PUBLIC will have a public ip address assigned to it, while PRIVATE will only be accessible on a private IP address on the subnet. Example: PUBLIC or PRIVATE
freeformTags Map<String>
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example: {"Department": "Finance"}
gatewayId String
hostname String
The hostname for APIs deployed on the gateway.
id String
The OCID of the resource.
ipAddresses List<Property Map>
An array of IP addresses associated with the gateway.
lifecycleDetails String
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in a Failed state.
networkSecurityGroupIds List<String>
An array of Network Security Groups OCIDs associated with this API Gateway.
responseCacheDetails List<Property Map>
Base Gateway response cache.
state String
The current state of the gateway.
subnetId String
The OCID of the subnet in which related resources are created.
timeCreated String
The time this resource was created. An RFC3339 formatted datetime string.
timeUpdated String
The time this resource was last updated. An RFC3339 formatted datetime string.

Supporting Types

GetGatewayCaBundle

CaBundleId This property is required. string
The OCID of the resource.
CertificateAuthorityId This property is required. string
The OCID of the resource.
Type This property is required. string
Type of the Response Cache.
CaBundleId This property is required. string
The OCID of the resource.
CertificateAuthorityId This property is required. string
The OCID of the resource.
Type This property is required. string
Type of the Response Cache.
caBundleId This property is required. String
The OCID of the resource.
certificateAuthorityId This property is required. String
The OCID of the resource.
type This property is required. String
Type of the Response Cache.
caBundleId This property is required. string
The OCID of the resource.
certificateAuthorityId This property is required. string
The OCID of the resource.
type This property is required. string
Type of the Response Cache.
ca_bundle_id This property is required. str
The OCID of the resource.
certificate_authority_id This property is required. str
The OCID of the resource.
type This property is required. str
Type of the Response Cache.
caBundleId This property is required. String
The OCID of the resource.
certificateAuthorityId This property is required. String
The OCID of the resource.
type This property is required. String
Type of the Response Cache.

GetGatewayIpAddress

IpAddress This property is required. string
An IP address.
IpAddress This property is required. string
An IP address.
ipAddress This property is required. String
An IP address.
ipAddress This property is required. string
An IP address.
ip_address This property is required. str
An IP address.
ipAddress This property is required. String
An IP address.

GetGatewayResponseCacheDetail

AuthenticationSecretId This property is required. string
The OCID of the Oracle Vault Service secret resource.
AuthenticationSecretVersionNumber This property is required. string
The version number of the authentication secret to use.
ConnectTimeoutInMs This property is required. int
Defines the timeout for establishing a connection with the Response Cache.
IsSslEnabled This property is required. bool
Defines if the connection should be over SSL.
IsSslVerifyDisabled This property is required. bool
Defines whether or not to uphold SSL verification.
ReadTimeoutInMs This property is required. int
Defines the timeout for reading data from the Response Cache.
SendTimeoutInMs This property is required. int
Defines the timeout for transmitting data to the Response Cache.
Servers This property is required. List<GetGatewayResponseCacheDetailServer>
The set of cache store members to connect to. At present only a single server is supported.
Type This property is required. string
Type of the Response Cache.
AuthenticationSecretId This property is required. string
The OCID of the Oracle Vault Service secret resource.
AuthenticationSecretVersionNumber This property is required. string
The version number of the authentication secret to use.
ConnectTimeoutInMs This property is required. int
Defines the timeout for establishing a connection with the Response Cache.
IsSslEnabled This property is required. bool
Defines if the connection should be over SSL.
IsSslVerifyDisabled This property is required. bool
Defines whether or not to uphold SSL verification.
ReadTimeoutInMs This property is required. int
Defines the timeout for reading data from the Response Cache.
SendTimeoutInMs This property is required. int
Defines the timeout for transmitting data to the Response Cache.
Servers This property is required. []GetGatewayResponseCacheDetailServer
The set of cache store members to connect to. At present only a single server is supported.
Type This property is required. string
Type of the Response Cache.
authenticationSecretId This property is required. String
The OCID of the Oracle Vault Service secret resource.
authenticationSecretVersionNumber This property is required. String
The version number of the authentication secret to use.
connectTimeoutInMs This property is required. Integer
Defines the timeout for establishing a connection with the Response Cache.
isSslEnabled This property is required. Boolean
Defines if the connection should be over SSL.
isSslVerifyDisabled This property is required. Boolean
Defines whether or not to uphold SSL verification.
readTimeoutInMs This property is required. Integer
Defines the timeout for reading data from the Response Cache.
sendTimeoutInMs This property is required. Integer
Defines the timeout for transmitting data to the Response Cache.
servers This property is required. List<GetGatewayResponseCacheDetailServer>
The set of cache store members to connect to. At present only a single server is supported.
type This property is required. String
Type of the Response Cache.
authenticationSecretId This property is required. string
The OCID of the Oracle Vault Service secret resource.
authenticationSecretVersionNumber This property is required. string
The version number of the authentication secret to use.
connectTimeoutInMs This property is required. number
Defines the timeout for establishing a connection with the Response Cache.
isSslEnabled This property is required. boolean
Defines if the connection should be over SSL.
isSslVerifyDisabled This property is required. boolean
Defines whether or not to uphold SSL verification.
readTimeoutInMs This property is required. number
Defines the timeout for reading data from the Response Cache.
sendTimeoutInMs This property is required. number
Defines the timeout for transmitting data to the Response Cache.
servers This property is required. GetGatewayResponseCacheDetailServer[]
The set of cache store members to connect to. At present only a single server is supported.
type This property is required. string
Type of the Response Cache.
authentication_secret_id This property is required. str
The OCID of the Oracle Vault Service secret resource.
authentication_secret_version_number This property is required. str
The version number of the authentication secret to use.
connect_timeout_in_ms This property is required. int
Defines the timeout for establishing a connection with the Response Cache.
is_ssl_enabled This property is required. bool
Defines if the connection should be over SSL.
is_ssl_verify_disabled This property is required. bool
Defines whether or not to uphold SSL verification.
read_timeout_in_ms This property is required. int
Defines the timeout for reading data from the Response Cache.
send_timeout_in_ms This property is required. int
Defines the timeout for transmitting data to the Response Cache.
servers This property is required. Sequence[apigateway.GetGatewayResponseCacheDetailServer]
The set of cache store members to connect to. At present only a single server is supported.
type This property is required. str
Type of the Response Cache.
authenticationSecretId This property is required. String
The OCID of the Oracle Vault Service secret resource.
authenticationSecretVersionNumber This property is required. String
The version number of the authentication secret to use.
connectTimeoutInMs This property is required. Number
Defines the timeout for establishing a connection with the Response Cache.
isSslEnabled This property is required. Boolean
Defines if the connection should be over SSL.
isSslVerifyDisabled This property is required. Boolean
Defines whether or not to uphold SSL verification.
readTimeoutInMs This property is required. Number
Defines the timeout for reading data from the Response Cache.
sendTimeoutInMs This property is required. Number
Defines the timeout for transmitting data to the Response Cache.
servers This property is required. List<Property Map>
The set of cache store members to connect to. At present only a single server is supported.
type This property is required. String
Type of the Response Cache.

GetGatewayResponseCacheDetailServer

Host This property is required. string
Hostname or IP address (IPv4 only) where the cache store is running.
Port This property is required. int
The port the cache store is exposed on.
Host This property is required. string
Hostname or IP address (IPv4 only) where the cache store is running.
Port This property is required. int
The port the cache store is exposed on.
host This property is required. String
Hostname or IP address (IPv4 only) where the cache store is running.
port This property is required. Integer
The port the cache store is exposed on.
host This property is required. string
Hostname or IP address (IPv4 only) where the cache store is running.
port This property is required. number
The port the cache store is exposed on.
host This property is required. str
Hostname or IP address (IPv4 only) where the cache store is running.
port This property is required. int
The port the cache store is exposed on.
host This property is required. String
Hostname or IP address (IPv4 only) where the cache store is running.
port This property is required. Number
The port the cache store is exposed on.

Package Details

Repository
oci pulumi/pulumi-oci
License
Apache-2.0
Notes
This Pulumi package is based on the oci Terraform Provider.
Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi