published on Friday, Aug 14, 2026 by tencentcloudstack
published on Friday, Aug 14, 2026 by tencentcloudstack
Provides a resource to manage a TSE cloud native API gateway IP restriction.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const example = new tencentcloud.TseCloudNativeApiGatewayIpRestriction("example", {
gatewayId: "gateway-ddbb709b",
sourceType: "route",
sourceId: "route-xxxx",
enabled: true,
restrictionType: "whiteList",
addressLists: [
"10.0.0.0/8",
"192.168.1.1",
],
});
import pulumi
import pulumi_tencentcloud as tencentcloud
example = tencentcloud.TseCloudNativeApiGatewayIpRestriction("example",
gateway_id="gateway-ddbb709b",
source_type="route",
source_id="route-xxxx",
enabled=True,
restriction_type="whiteList",
address_lists=[
"10.0.0.0/8",
"192.168.1.1",
])
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.NewTseCloudNativeApiGatewayIpRestriction(ctx, "example", &tencentcloud.TseCloudNativeApiGatewayIpRestrictionArgs{
GatewayId: pulumi.String("gateway-ddbb709b"),
SourceType: pulumi.String("route"),
SourceId: pulumi.String("route-xxxx"),
Enabled: pulumi.Bool(true),
RestrictionType: pulumi.String("whiteList"),
AddressLists: pulumi.StringArray{
pulumi.String("10.0.0.0/8"),
pulumi.String("192.168.1.1"),
},
})
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 example = new Tencentcloud.TseCloudNativeApiGatewayIpRestriction("example", new()
{
GatewayId = "gateway-ddbb709b",
SourceType = "route",
SourceId = "route-xxxx",
Enabled = true,
RestrictionType = "whiteList",
AddressLists = new[]
{
"10.0.0.0/8",
"192.168.1.1",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.TseCloudNativeApiGatewayIpRestriction;
import com.pulumi.tencentcloud.TseCloudNativeApiGatewayIpRestrictionArgs;
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) {
var example = new TseCloudNativeApiGatewayIpRestriction("example", TseCloudNativeApiGatewayIpRestrictionArgs.builder()
.gatewayId("gateway-ddbb709b")
.sourceType("route")
.sourceId("route-xxxx")
.enabled(true)
.restrictionType("whiteList")
.addressLists(
"10.0.0.0/8",
"192.168.1.1")
.build());
}
}
resources:
example:
type: tencentcloud:TseCloudNativeApiGatewayIpRestriction
properties:
gatewayId: gateway-ddbb709b
sourceType: route
sourceId: route-xxxx
enabled: true
restrictionType: whiteList
addressLists:
- 10.0.0.0/8
- 192.168.1.1
Example coming soon!
Create TseCloudNativeApiGatewayIpRestriction Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new TseCloudNativeApiGatewayIpRestriction(name: string, args: TseCloudNativeApiGatewayIpRestrictionArgs, opts?: CustomResourceOptions);@overload
def TseCloudNativeApiGatewayIpRestriction(resource_name: str,
args: TseCloudNativeApiGatewayIpRestrictionArgs,
opts: Optional[ResourceOptions] = None)
@overload
def TseCloudNativeApiGatewayIpRestriction(resource_name: str,
opts: Optional[ResourceOptions] = None,
gateway_id: Optional[str] = None,
source_id: Optional[str] = None,
source_type: Optional[str] = None,
address_lists: Optional[Sequence[str]] = None,
enabled: Optional[bool] = None,
restriction_type: Optional[str] = None,
tse_cloud_native_api_gateway_ip_restriction_id: Optional[str] = None)func NewTseCloudNativeApiGatewayIpRestriction(ctx *Context, name string, args TseCloudNativeApiGatewayIpRestrictionArgs, opts ...ResourceOption) (*TseCloudNativeApiGatewayIpRestriction, error)public TseCloudNativeApiGatewayIpRestriction(string name, TseCloudNativeApiGatewayIpRestrictionArgs args, CustomResourceOptions? opts = null)
public TseCloudNativeApiGatewayIpRestriction(String name, TseCloudNativeApiGatewayIpRestrictionArgs args)
public TseCloudNativeApiGatewayIpRestriction(String name, TseCloudNativeApiGatewayIpRestrictionArgs args, CustomResourceOptions options)
type: tencentcloud:TseCloudNativeApiGatewayIpRestriction
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "tencentcloud_tse_cloud_native_api_gateway_ip_restriction" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args TseCloudNativeApiGatewayIpRestrictionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args TseCloudNativeApiGatewayIpRestrictionArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args TseCloudNativeApiGatewayIpRestrictionArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args TseCloudNativeApiGatewayIpRestrictionArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args TseCloudNativeApiGatewayIpRestrictionArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
TseCloudNativeApiGatewayIpRestriction Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The TseCloudNativeApiGatewayIpRestriction resource accepts the following input properties:
- Gateway
Id string - Gateway ID.
- Source
Id string - Route or service ID.
- Source
Type string - Resource type bound to the IP restriction plugin: route|service.
- Address
Lists List<string> - IP/CIDR address list.
- Enabled bool
- Whether to enable the plugin.
- Restriction
Type string - IP restriction type: whiteList|blackList.
- Tse
Cloud stringNative Api Gateway Ip Restriction Id - ID of the resource.
- Gateway
Id string - Gateway ID.
- Source
Id string - Route or service ID.
- Source
Type string - Resource type bound to the IP restriction plugin: route|service.
- Address
Lists []string - IP/CIDR address list.
- Enabled bool
- Whether to enable the plugin.
- Restriction
Type string - IP restriction type: whiteList|blackList.
- Tse
Cloud stringNative Api Gateway Ip Restriction Id - ID of the resource.
- gateway_
id string - Gateway ID.
- source_
id string - Route or service ID.
- source_
type string - Resource type bound to the IP restriction plugin: route|service.
- address_
lists list(string) - IP/CIDR address list.
- enabled bool
- Whether to enable the plugin.
- restriction_
type string - IP restriction type: whiteList|blackList.
- tse_
cloud_ stringnative_ api_ gateway_ ip_ restriction_ id - ID of the resource.
- gateway
Id String - Gateway ID.
- source
Id String - Route or service ID.
- source
Type String - Resource type bound to the IP restriction plugin: route|service.
- address
Lists List<String> - IP/CIDR address list.
- enabled Boolean
- Whether to enable the plugin.
- restriction
Type String - IP restriction type: whiteList|blackList.
- tse
Cloud StringNative Api Gateway Ip Restriction Id - ID of the resource.
- gateway
Id string - Gateway ID.
- source
Id string - Route or service ID.
- source
Type string - Resource type bound to the IP restriction plugin: route|service.
- address
Lists string[] - IP/CIDR address list.
- enabled boolean
- Whether to enable the plugin.
- restriction
Type string - IP restriction type: whiteList|blackList.
- tse
Cloud stringNative Api Gateway Ip Restriction Id - ID of the resource.
- gateway_
id str - Gateway ID.
- source_
id str - Route or service ID.
- source_
type str - Resource type bound to the IP restriction plugin: route|service.
- address_
lists Sequence[str] - IP/CIDR address list.
- enabled bool
- Whether to enable the plugin.
- restriction_
type str - IP restriction type: whiteList|blackList.
- tse_
cloud_ strnative_ api_ gateway_ ip_ restriction_ id - ID of the resource.
- gateway
Id String - Gateway ID.
- source
Id String - Route or service ID.
- source
Type String - Resource type bound to the IP restriction plugin: route|service.
- address
Lists List<String> - IP/CIDR address list.
- enabled Boolean
- Whether to enable the plugin.
- restriction
Type String - IP restriction type: whiteList|blackList.
- tse
Cloud StringNative Api Gateway Ip Restriction Id - ID of the resource.
Outputs
All input properties are implicitly available as output properties. Additionally, the TseCloudNativeApiGatewayIpRestriction resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing TseCloudNativeApiGatewayIpRestriction Resource
Get an existing TseCloudNativeApiGatewayIpRestriction resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: TseCloudNativeApiGatewayIpRestrictionState, opts?: CustomResourceOptions): TseCloudNativeApiGatewayIpRestriction@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
address_lists: Optional[Sequence[str]] = None,
enabled: Optional[bool] = None,
gateway_id: Optional[str] = None,
restriction_type: Optional[str] = None,
source_id: Optional[str] = None,
source_type: Optional[str] = None,
tse_cloud_native_api_gateway_ip_restriction_id: Optional[str] = None) -> TseCloudNativeApiGatewayIpRestrictionfunc GetTseCloudNativeApiGatewayIpRestriction(ctx *Context, name string, id IDInput, state *TseCloudNativeApiGatewayIpRestrictionState, opts ...ResourceOption) (*TseCloudNativeApiGatewayIpRestriction, error)public static TseCloudNativeApiGatewayIpRestriction Get(string name, Input<string> id, TseCloudNativeApiGatewayIpRestrictionState? state, CustomResourceOptions? opts = null)public static TseCloudNativeApiGatewayIpRestriction get(String name, Output<String> id, TseCloudNativeApiGatewayIpRestrictionState state, CustomResourceOptions options)resources: _: type: tencentcloud:TseCloudNativeApiGatewayIpRestriction get: id: ${id}import {
to = tencentcloud_tse_cloud_native_api_gateway_ip_restriction.example
id = "${id}"
}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Address
Lists List<string> - IP/CIDR address list.
- Enabled bool
- Whether to enable the plugin.
- Gateway
Id string - Gateway ID.
- Restriction
Type string - IP restriction type: whiteList|blackList.
- Source
Id string - Route or service ID.
- Source
Type string - Resource type bound to the IP restriction plugin: route|service.
- Tse
Cloud stringNative Api Gateway Ip Restriction Id - ID of the resource.
- Address
Lists []string - IP/CIDR address list.
- Enabled bool
- Whether to enable the plugin.
- Gateway
Id string - Gateway ID.
- Restriction
Type string - IP restriction type: whiteList|blackList.
- Source
Id string - Route or service ID.
- Source
Type string - Resource type bound to the IP restriction plugin: route|service.
- Tse
Cloud stringNative Api Gateway Ip Restriction Id - ID of the resource.
- address_
lists list(string) - IP/CIDR address list.
- enabled bool
- Whether to enable the plugin.
- gateway_
id string - Gateway ID.
- restriction_
type string - IP restriction type: whiteList|blackList.
- source_
id string - Route or service ID.
- source_
type string - Resource type bound to the IP restriction plugin: route|service.
- tse_
cloud_ stringnative_ api_ gateway_ ip_ restriction_ id - ID of the resource.
- address
Lists List<String> - IP/CIDR address list.
- enabled Boolean
- Whether to enable the plugin.
- gateway
Id String - Gateway ID.
- restriction
Type String - IP restriction type: whiteList|blackList.
- source
Id String - Route or service ID.
- source
Type String - Resource type bound to the IP restriction plugin: route|service.
- tse
Cloud StringNative Api Gateway Ip Restriction Id - ID of the resource.
- address
Lists string[] - IP/CIDR address list.
- enabled boolean
- Whether to enable the plugin.
- gateway
Id string - Gateway ID.
- restriction
Type string - IP restriction type: whiteList|blackList.
- source
Id string - Route or service ID.
- source
Type string - Resource type bound to the IP restriction plugin: route|service.
- tse
Cloud stringNative Api Gateway Ip Restriction Id - ID of the resource.
- address_
lists Sequence[str] - IP/CIDR address list.
- enabled bool
- Whether to enable the plugin.
- gateway_
id str - Gateway ID.
- restriction_
type str - IP restriction type: whiteList|blackList.
- source_
id str - Route or service ID.
- source_
type str - Resource type bound to the IP restriction plugin: route|service.
- tse_
cloud_ strnative_ api_ gateway_ ip_ restriction_ id - ID of the resource.
- address
Lists List<String> - IP/CIDR address list.
- enabled Boolean
- Whether to enable the plugin.
- gateway
Id String - Gateway ID.
- restriction
Type String - IP restriction type: whiteList|blackList.
- source
Id String - Route or service ID.
- source
Type String - Resource type bound to the IP restriction plugin: route|service.
- tse
Cloud StringNative Api Gateway Ip Restriction Id - ID of the resource.
Import
tse cloud native api gateway ip restriction can be imported using the composite id, e.g.
$ pulumi import tencentcloud:index/tseCloudNativeApiGatewayIpRestriction:TseCloudNativeApiGatewayIpRestriction example gatewayId#sourceType#sourceId
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the
tencentcloudTerraform Provider.
published on Friday, Aug 14, 2026 by tencentcloudstack