Viewing docs for Alibaba Cloud v3.108.0
published on Thursday, Sep 17, 2026 by Pulumi
published on Thursday, Sep 17, 2026 by Pulumi
Viewing docs for Alibaba Cloud v3.108.0
published on Thursday, Sep 17, 2026 by Pulumi
published on Thursday, Sep 17, 2026 by Pulumi
This data source provides Apig Domain available to the user.What is Domain
NOTE: Available since v1.284.0.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "terraform-example";
const defaultDomain = new alicloud.apig.Domain("default", {
domainName: "example-domain.example.com",
gatewayType: "API",
protocol: "HTTP",
});
const _default = alicloud.apig.getDomainsOutput({
ids: [defaultDomain.id],
nameRegex: defaultDomain.domainName,
resourceGroupId: "",
});
export const alicloudApigDomainExampleId = _default.apply(_default => _default.domains?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "terraform-example"
default_domain = alicloud.apig.Domain("default",
domain_name="example-domain.example.com",
gateway_type="API",
protocol="HTTP")
default = alicloud.apig.get_domains_output(ids=[default_domain.id],
name_regex=default_domain.domain_name,
resource_group_id="")
pulumi.export("alicloudApigDomainExampleId", default.domains[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/apig"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "terraform-example"
if param := cfg.Get("name"); param != "" {
name = param
}
defaultDomain, err := apig.NewDomain(ctx, "default", &apig.DomainArgs{
DomainName: pulumi.String("example-domain.example.com"),
GatewayType: pulumi.String("API"),
Protocol: pulumi.String("HTTP"),
})
if err != nil {
return err
}
_default := apig.GetDomainsOutput(ctx, apig.GetDomainsOutputArgs{
Ids: pulumi.StringArray{
defaultDomain.ID().ToIDOutput().ToStringOutput(),
},
NameRegex: defaultDomain.DomainName,
ResourceGroupId: pulumi.String(""),
}, nil)
ctx.Export("alicloudApigDomainExampleId", _default.ApplyT(func(_default apig.GetDomainsResult) (*string, error) {
return _default.Domains[0].Id, nil
}).(pulumi.StringPtrOutput))
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "terraform-example";
var defaultDomain = new AliCloud.Apig.Domain("default", new()
{
DomainName = "example-domain.example.com",
GatewayType = "API",
Protocol = "HTTP",
});
var @default = AliCloud.Apig.GetDomains.Invoke(new()
{
Ids = new[]
{
defaultDomain.Id,
},
NameRegex = defaultDomain.DomainName,
ResourceGroupId = "",
});
return new Dictionary<string, object?>
{
["alicloudApigDomainExampleId"] = @default.Apply(@default => @default.Apply(getDomainsResult => getDomainsResult.Domains[0]?.Id)),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.apig.Domain;
import com.pulumi.alicloud.apig.DomainArgs;
import com.pulumi.alicloud.apig.ApigFunctions;
import com.pulumi.alicloud.apig.inputs.GetDomainsArgs;
import java.util.ArrayList;
import java.util.Arrays;
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 config = ctx.config();
final var name = config.get("name").orElse("terraform-example");
var defaultDomain = new Domain("defaultDomain", DomainArgs.builder()
.domainName("example-domain.example.com")
.gatewayType("API")
.protocol("HTTP")
.build());
final var default = ApigFunctions.getDomains(GetDomainsArgs.builder()
.ids(defaultDomain.id())
.nameRegex(defaultDomain.domainName())
.resourceGroupId("")
.build());
ctx.export("alicloudApigDomainExampleId", default_.applyValue(_default_ -> _default_.domains()[0].id()));
}
}
configuration:
name:
type: string
default: terraform-example
resources:
defaultDomain:
type: alicloud:apig:Domain
name: default
properties:
domainName: example-domain.example.com
gatewayType: API
protocol: HTTP
variables:
default:
fn::invoke:
function: alicloud:apig:getDomains
arguments:
ids:
- ${defaultDomain.id}
nameRegex: ${defaultDomain.domainName}
resourceGroupId: ""
outputs:
alicloudApigDomainExampleId: ${default.domains[0].id}
pulumi {
required_providers {
alicloud = {
source = "pulumi/alicloud"
}
}
}
data "alicloud_apig_getdomains" "default" {
ids = [alicloud_apig_domain.default.id]
name_regex = alicloud_apig_domain.default.domain_name
resource_group_id = ""
}
resource "alicloud_apig_domain" "default" {
domain_name = "example-domain.example.com"
gateway_type = "API"
protocol = "HTTP"
}
variable "name" {
type = string
default = "terraform-example"
}
output "alicloudApigDomainExampleId" {
value = data.alicloud_apig_getdomains.default.domains[0].id
}
Using getDomains
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 getDomains(args: GetDomainsArgs, opts?: InvokeOptions): Promise<GetDomainsResult>
function getDomainsOutput(args: GetDomainsOutputArgs, opts?: InvokeOutputOptions): Output<GetDomainsResult>def get_domains(enable_details: Optional[bool] = None,
ids: Optional[Sequence[str]] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
resource_group_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetDomainsResult
def get_domains_output(enable_details: pulumi.Input[Optional[bool]] = None,
ids: pulumi.Input[Optional[Sequence[pulumi.Input[str]]]] = None,
name_regex: pulumi.Input[Optional[str]] = None,
output_file: pulumi.Input[Optional[str]] = None,
resource_group_id: pulumi.Input[Optional[str]] = None,
opts: Optional[InvokeOutputOptions] = None) -> Output[GetDomainsResult]func GetDomains(ctx *Context, args *GetDomainsArgs, opts ...InvokeOption) (*GetDomainsResult, error)
func GetDomainsOutput(ctx *Context, args *GetDomainsOutputArgs, opts ...InvokeOption) GetDomainsResultOutput> Note: This function is named GetDomains in the Go SDK.
public static class GetDomains
{
public static Task<GetDomainsResult> InvokeAsync(GetDomainsArgs args, InvokeOptions? opts = null)
public static Output<GetDomainsResult> Invoke(GetDomainsInvokeArgs args, InvokeOptions? opts = null)
public static Output<GetDomainsResult> Invoke(GetDomainsInvokeArgs args, InvokeOutputOptions opts)
}public static CompletableFuture<GetDomainsResult> getDomains(GetDomainsArgs args, InvokeOptions options)
public static Output<GetDomainsResult> getDomains(GetDomainsArgs args, InvokeOptions options)
public static Output<GetDomainsResult> getDomains(GetDomainsArgs args, InvokeOutputOptions options)
fn::invoke:
function: alicloud:apig/getDomains:getDomains
arguments:
# arguments dictionarydata "alicloud_apig_get_domains" "name" {
# arguments
}The following arguments are supported:
- Enable
Details bool - Default to
false. Set it totruecan output more details about resource attributes. - Ids List<string>
- A list of Domain IDs.
- Name
Regex string - A regex string to filter results by Group Metric Rule name.
- Output
File string - File name where to save data source results (after running
pulumi preview). - Resource
Group stringId - The ID of the resource group
- Enable
Details bool - Default to
false. Set it totruecan output more details about resource attributes. - Ids []string
- A list of Domain IDs.
- Name
Regex string - A regex string to filter results by Group Metric Rule name.
- Output
File string - File name where to save data source results (after running
pulumi preview). - Resource
Group stringId - The ID of the resource group
- enable_
details bool - Default to
false. Set it totruecan output more details about resource attributes. - ids list(string)
- A list of Domain IDs.
- name_
regex string - A regex string to filter results by Group Metric Rule name.
- output_
file string - File name where to save data source results (after running
pulumi preview). - resource_
group_ stringid - The ID of the resource group
- enable
Details Boolean - Default to
false. Set it totruecan output more details about resource attributes. - ids List<String>
- A list of Domain IDs.
- name
Regex String - A regex string to filter results by Group Metric Rule name.
- output
File String - File name where to save data source results (after running
pulumi preview). - resource
Group StringId - The ID of the resource group
- enable
Details boolean - Default to
false. Set it totruecan output more details about resource attributes. - ids string[]
- A list of Domain IDs.
- name
Regex string - A regex string to filter results by Group Metric Rule name.
- output
File string - File name where to save data source results (after running
pulumi preview). - resource
Group stringId - The ID of the resource group
- enable_
details bool - Default to
false. Set it totruecan output more details about resource attributes. - ids Sequence[str]
- A list of Domain IDs.
- name_
regex str - A regex string to filter results by Group Metric Rule name.
- output_
file str - File name where to save data source results (after running
pulumi preview). - resource_
group_ strid - The ID of the resource group
- enable
Details Boolean - Default to
false. Set it totruecan output more details about resource attributes. - ids List<String>
- A list of Domain IDs.
- name
Regex String - A regex string to filter results by Group Metric Rule name.
- output
File String - File name where to save data source results (after running
pulumi preview). - resource
Group StringId - The ID of the resource group
getDomains Result
The following output properties are available:
- Domains
List<Pulumi.
Ali Cloud. Apig. Outputs. Get Domains Domain> - A list of Domain Entries. Each element contains the following attributes:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- A list of Domain IDs.
- Names List<string>
- A list of name of Domains.
- Enable
Details bool - Name
Regex string - Output
File string - Resource
Group stringId - The ID of the resource group.
- Domains
[]Get
Domains Domain - A list of Domain Entries. Each element contains the following attributes:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- A list of Domain IDs.
- Names []string
- A list of name of Domains.
- Enable
Details bool - Name
Regex string - Output
File string - Resource
Group stringId - The ID of the resource group.
- domains list(object)
- A list of Domain Entries. Each element contains the following attributes:
- id string
- The provider-assigned unique ID for this managed resource.
- ids list(string)
- A list of Domain IDs.
- names list(string)
- A list of name of Domains.
- enable_
details bool - name_
regex string - output_
file string - resource_
group_ stringid - The ID of the resource group.
- domains
List<Get
Domains Domain> - A list of Domain Entries. Each element contains the following attributes:
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- A list of Domain IDs.
- names List<String>
- A list of name of Domains.
- enable
Details Boolean - name
Regex String - output
File String - resource
Group StringId - The ID of the resource group.
- domains
Get
Domains Domain[] - A list of Domain Entries. Each element contains the following attributes:
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- A list of Domain IDs.
- names string[]
- A list of name of Domains.
- enable
Details boolean - name
Regex string - output
File string - resource
Group stringId - The ID of the resource group.
- domains
Sequence[Get
Domains Domain] - A list of Domain Entries. Each element contains the following attributes:
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- A list of Domain IDs.
- names Sequence[str]
- A list of name of Domains.
- enable_
details bool - name_
regex str - output_
file str - resource_
group_ strid - The ID of the resource group.
- domains List<Property Map>
- A list of Domain Entries. Each element contains the following attributes:
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- A list of Domain IDs.
- names List<String>
- A list of name of Domains.
- enable
Details Boolean - name
Regex String - output
File String - resource
Group StringId - The ID of the resource group.
Supporting Types
GetDomainsDomain
- Ca
Cert stringIdentifier - NOTE: This field is only available when
enableDetailsistrue. CA certificate identifier. - Cert
Identifier string - tls cert identifier.
- Client
Ca stringCert - client CA certificate.
- Domain
Id string - domain id.
- Domain
Name string - domain name.
- Domain
Scope string - domain scope.
- Force
Https bool - Set the HTTPS protocol type and whether to enable forced HTTPS redirection.
- Http2Option string
- NOTE: This field is only available when
enableDetailsistrue. Whether to enable http2 settings. - Id string
- The ID of the resource supplied above.
- MTls
Enabled bool - Whether to enable mTLS mutual authentication.
- Protocol string
- Protocol, HTTP/HTTPS.
- Resource
Group stringId - The ID of the resource group
- Tls
Cipher List<Pulumi.Suites Configs Ali Cloud. Apig. Inputs. Get Domains Domain Tls Cipher Suites Config> - NOTE: This field is only available when
enableDetailsistrue. TlsCipherSuitesConfig. - Tls
Max string - NOTE: This field is only available when
enableDetailsistrue. The maximum version of the TLS protocol. - Tls
Min string - NOTE: This field is only available when
enableDetailsistrue. The minimum version of the TLS protocol.
- Ca
Cert stringIdentifier - NOTE: This field is only available when
enableDetailsistrue. CA certificate identifier. - Cert
Identifier string - tls cert identifier.
- Client
Ca stringCert - client CA certificate.
- Domain
Id string - domain id.
- Domain
Name string - domain name.
- Domain
Scope string - domain scope.
- Force
Https bool - Set the HTTPS protocol type and whether to enable forced HTTPS redirection.
- Http2Option string
- NOTE: This field is only available when
enableDetailsistrue. Whether to enable http2 settings. - Id string
- The ID of the resource supplied above.
- MTls
Enabled bool - Whether to enable mTLS mutual authentication.
- Protocol string
- Protocol, HTTP/HTTPS.
- Resource
Group stringId - The ID of the resource group
- Tls
Cipher []GetSuites Configs Domains Domain Tls Cipher Suites Config - NOTE: This field is only available when
enableDetailsistrue. TlsCipherSuitesConfig. - Tls
Max string - NOTE: This field is only available when
enableDetailsistrue. The maximum version of the TLS protocol. - Tls
Min string - NOTE: This field is only available when
enableDetailsistrue. The minimum version of the TLS protocol.
- ca_
cert_ stringidentifier - NOTE: This field is only available when
enableDetailsistrue. CA certificate identifier. - cert_
identifier string - tls cert identifier.
- client_
ca_ stringcert - client CA certificate.
- domain_
id string - domain id.
- domain_
name string - domain name.
- domain_
scope string - domain scope.
- force_
https bool - Set the HTTPS protocol type and whether to enable forced HTTPS redirection.
- http2_
option string - NOTE: This field is only available when
enableDetailsistrue. Whether to enable http2 settings. - id string
- The ID of the resource supplied above.
- m_
tls_ boolenabled - Whether to enable mTLS mutual authentication.
- protocol string
- Protocol, HTTP/HTTPS.
- resource_
group_ stringid - The ID of the resource group
- tls_
cipher_ list(object)suites_ configs - NOTE: This field is only available when
enableDetailsistrue. TlsCipherSuitesConfig. - tls_
max string - NOTE: This field is only available when
enableDetailsistrue. The maximum version of the TLS protocol. - tls_
min string - NOTE: This field is only available when
enableDetailsistrue. The minimum version of the TLS protocol.
- ca
Cert StringIdentifier - NOTE: This field is only available when
enableDetailsistrue. CA certificate identifier. - cert
Identifier String - tls cert identifier.
- client
Ca StringCert - client CA certificate.
- domain
Id String - domain id.
- domain
Name String - domain name.
- domain
Scope String - domain scope.
- force
Https Boolean - Set the HTTPS protocol type and whether to enable forced HTTPS redirection.
- http2Option String
- NOTE: This field is only available when
enableDetailsistrue. Whether to enable http2 settings. - id String
- The ID of the resource supplied above.
- m
Tls BooleanEnabled - Whether to enable mTLS mutual authentication.
- protocol String
- Protocol, HTTP/HTTPS.
- resource
Group StringId - The ID of the resource group
- tls
Cipher List<GetSuites Configs Domains Domain Tls Cipher Suites Config> - NOTE: This field is only available when
enableDetailsistrue. TlsCipherSuitesConfig. - tls
Max String - NOTE: This field is only available when
enableDetailsistrue. The maximum version of the TLS protocol. - tls
Min String - NOTE: This field is only available when
enableDetailsistrue. The minimum version of the TLS protocol.
- ca
Cert stringIdentifier - NOTE: This field is only available when
enableDetailsistrue. CA certificate identifier. - cert
Identifier string - tls cert identifier.
- client
Ca stringCert - client CA certificate.
- domain
Id string - domain id.
- domain
Name string - domain name.
- domain
Scope string - domain scope.
- force
Https boolean - Set the HTTPS protocol type and whether to enable forced HTTPS redirection.
- http2Option string
- NOTE: This field is only available when
enableDetailsistrue. Whether to enable http2 settings. - id string
- The ID of the resource supplied above.
- m
Tls booleanEnabled - Whether to enable mTLS mutual authentication.
- protocol string
- Protocol, HTTP/HTTPS.
- resource
Group stringId - The ID of the resource group
- tls
Cipher GetSuites Configs Domains Domain Tls Cipher Suites Config[] - NOTE: This field is only available when
enableDetailsistrue. TlsCipherSuitesConfig. - tls
Max string - NOTE: This field is only available when
enableDetailsistrue. The maximum version of the TLS protocol. - tls
Min string - NOTE: This field is only available when
enableDetailsistrue. The minimum version of the TLS protocol.
- ca_
cert_ stridentifier - NOTE: This field is only available when
enableDetailsistrue. CA certificate identifier. - cert_
identifier str - tls cert identifier.
- client_
ca_ strcert - client CA certificate.
- domain_
id str - domain id.
- domain_
name str - domain name.
- domain_
scope str - domain scope.
- force_
https bool - Set the HTTPS protocol type and whether to enable forced HTTPS redirection.
- http2_
option str - NOTE: This field is only available when
enableDetailsistrue. Whether to enable http2 settings. - id str
- The ID of the resource supplied above.
- m_
tls_ boolenabled - Whether to enable mTLS mutual authentication.
- protocol str
- Protocol, HTTP/HTTPS.
- resource_
group_ strid - The ID of the resource group
- tls_
cipher_ Sequence[Getsuites_ configs Domains Domain Tls Cipher Suites Config] - NOTE: This field is only available when
enableDetailsistrue. TlsCipherSuitesConfig. - tls_
max str - NOTE: This field is only available when
enableDetailsistrue. The maximum version of the TLS protocol. - tls_
min str - NOTE: This field is only available when
enableDetailsistrue. The minimum version of the TLS protocol.
- ca
Cert StringIdentifier - NOTE: This field is only available when
enableDetailsistrue. CA certificate identifier. - cert
Identifier String - tls cert identifier.
- client
Ca StringCert - client CA certificate.
- domain
Id String - domain id.
- domain
Name String - domain name.
- domain
Scope String - domain scope.
- force
Https Boolean - Set the HTTPS protocol type and whether to enable forced HTTPS redirection.
- http2Option String
- NOTE: This field is only available when
enableDetailsistrue. Whether to enable http2 settings. - id String
- The ID of the resource supplied above.
- m
Tls BooleanEnabled - Whether to enable mTLS mutual authentication.
- protocol String
- Protocol, HTTP/HTTPS.
- resource
Group StringId - The ID of the resource group
- tls
Cipher List<Property Map>Suites Configs - NOTE: This field is only available when
enableDetailsistrue. TlsCipherSuitesConfig. - tls
Max String - NOTE: This field is only available when
enableDetailsistrue. The maximum version of the TLS protocol. - tls
Min String - NOTE: This field is only available when
enableDetailsistrue. The minimum version of the TLS protocol.
GetDomainsDomainTlsCipherSuitesConfig
- Config
Type string - config type, Default or Custom.
- Tls
Cipher List<Pulumi.Suites Ali Cloud. Apig. Inputs. Get Domains Domain Tls Cipher Suites Config Tls Cipher Suite> - tls Cipher Suite.
- Config
Type string - config type, Default or Custom.
- Tls
Cipher []GetSuites Domains Domain Tls Cipher Suites Config Tls Cipher Suite - tls Cipher Suite.
- config_
type string - config type, Default or Custom.
- tls_
cipher_ list(object)suites - tls Cipher Suite.
- config
Type String - config type, Default or Custom.
- tls
Cipher List<GetSuites Domains Domain Tls Cipher Suites Config Tls Cipher Suite> - tls Cipher Suite.
- config
Type string - config type, Default or Custom.
- tls
Cipher GetSuites Domains Domain Tls Cipher Suites Config Tls Cipher Suite[] - tls Cipher Suite.
- config_
type str - config type, Default or Custom.
- tls_
cipher_ Sequence[Getsuites Domains Domain Tls Cipher Suites Config Tls Cipher Suite] - tls Cipher Suite.
- config
Type String - config type, Default or Custom.
- tls
Cipher List<Property Map>Suites - tls Cipher Suite.
GetDomainsDomainTlsCipherSuitesConfigTlsCipherSuite
- Name string
- cipher suite name.
- Support
Versions List<string> - support versions.
- Name string
- cipher suite name.
- Support
Versions []string - support versions.
- name string
- cipher suite name.
- support_
versions list(string) - support versions.
- name String
- cipher suite name.
- support
Versions List<String> - support versions.
- name string
- cipher suite name.
- support
Versions string[] - support versions.
- name str
- cipher suite name.
- support_
versions Sequence[str] - support versions.
- name String
- cipher suite name.
- support
Versions List<String> - support versions.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloudTerraform Provider.
Viewing docs for Alibaba Cloud v3.108.0
published on Thursday, Sep 17, 2026 by Pulumi
published on Thursday, Sep 17, 2026 by Pulumi