1. Packages
  2. Packages
  3. Volcenginecc Provider
  4. API Docs
  5. apig
  6. CustomDomain
Viewing docs for volcenginecc v0.0.32
published on Thursday, Apr 23, 2026 by Volcengine
volcenginecc logo
Viewing docs for volcenginecc v0.0.32
published on Thursday, Apr 23, 2026 by Volcengine

    The service serves as the entry point for external access. You can bind your custom domain to the service using the domain binding feature

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as volcenginecc from "@volcengine/pulumi-volcenginecc";
    
    const apigCustomDomainDemo = new volcenginecc.apig.CustomDomain("ApigCustomDomainDemo", {
        serviceId: "sd50d3h5xxxm0t5xxxxx",
        domain: "www.****.com",
        protocols: [
            "HTTP",
            "HTTPS",
        ],
        certificateId: "cert-775906d873xxx5bc9d1d372b5dxxxxx",
        comments: "ApigCustomDomainDemo custom domain",
        sslRedirect: true,
    });
    
    import pulumi
    import pulumi_volcenginecc as volcenginecc
    
    apig_custom_domain_demo = volcenginecc.apig.CustomDomain("ApigCustomDomainDemo",
        service_id="sd50d3h5xxxm0t5xxxxx",
        domain="www.****.com",
        protocols=[
            "HTTP",
            "HTTPS",
        ],
        certificate_id="cert-775906d873xxx5bc9d1d372b5dxxxxx",
        comments="ApigCustomDomainDemo custom domain",
        ssl_redirect=True)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/volcengine/pulumi-volcenginecc/sdk/go/volcenginecc/apig"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := apig.NewCustomDomain(ctx, "ApigCustomDomainDemo", &apig.CustomDomainArgs{
    			ServiceId: pulumi.String("sd50d3h5xxxm0t5xxxxx"),
    			Domain:    pulumi.String("www.****.com"),
    			Protocols: pulumi.StringArray{
    				pulumi.String("HTTP"),
    				pulumi.String("HTTPS"),
    			},
    			CertificateId: pulumi.String("cert-775906d873xxx5bc9d1d372b5dxxxxx"),
    			Comments:      pulumi.String("ApigCustomDomainDemo custom domain"),
    			SslRedirect:   pulumi.Bool(true),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Volcenginecc = Volcengine.Pulumi.Volcenginecc;
    
    return await Deployment.RunAsync(() => 
    {
        var apigCustomDomainDemo = new Volcenginecc.Apig.CustomDomain("ApigCustomDomainDemo", new()
        {
            ServiceId = "sd50d3h5xxxm0t5xxxxx",
            Domain = "www.****.com",
            Protocols = new[]
            {
                "HTTP",
                "HTTPS",
            },
            CertificateId = "cert-775906d873xxx5bc9d1d372b5dxxxxx",
            Comments = "ApigCustomDomainDemo custom domain",
            SslRedirect = true,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.volcengine.volcenginecc.apig.CustomDomain;
    import com.volcengine.volcenginecc.apig.CustomDomainArgs;
    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 apigCustomDomainDemo = new CustomDomain("apigCustomDomainDemo", CustomDomainArgs.builder()
                .serviceId("sd50d3h5xxxm0t5xxxxx")
                .domain("www.****.com")
                .protocols(            
                    "HTTP",
                    "HTTPS")
                .certificateId("cert-775906d873xxx5bc9d1d372b5dxxxxx")
                .comments("ApigCustomDomainDemo custom domain")
                .sslRedirect(true)
                .build());
    
        }
    }
    
    resources:
      apigCustomDomainDemo:
        type: volcenginecc:apig:CustomDomain
        name: ApigCustomDomainDemo
        properties:
          serviceId: sd50d3h5xxxm0t5xxxxx
          domain: www.****.com
          protocols:
            - HTTP
            - HTTPS
          certificateId: cert-775906d873xxx5bc9d1d372b5dxxxxx
          comments: ApigCustomDomainDemo custom domain
          sslRedirect: true
    

    Create CustomDomain Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new CustomDomain(name: string, args: CustomDomainArgs, opts?: CustomResourceOptions);
    @overload
    def CustomDomain(resource_name: str,
                     args: CustomDomainArgs,
                     opts: Optional[ResourceOptions] = None)
    
    @overload
    def CustomDomain(resource_name: str,
                     opts: Optional[ResourceOptions] = None,
                     domain: Optional[str] = None,
                     protocols: Optional[Sequence[str]] = None,
                     service_id: Optional[str] = None,
                     certificate_id: Optional[str] = None,
                     comments: Optional[str] = None,
                     ssl_redirect: Optional[bool] = None)
    func NewCustomDomain(ctx *Context, name string, args CustomDomainArgs, opts ...ResourceOption) (*CustomDomain, error)
    public CustomDomain(string name, CustomDomainArgs args, CustomResourceOptions? opts = null)
    public CustomDomain(String name, CustomDomainArgs args)
    public CustomDomain(String name, CustomDomainArgs args, CustomResourceOptions options)
    
    type: volcenginecc:apig:CustomDomain
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args CustomDomainArgs
    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 CustomDomainArgs
    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 CustomDomainArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args CustomDomainArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args CustomDomainArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var customDomainResource = new Volcenginecc.Apig.CustomDomain("customDomainResource", new()
    {
        Domain = "string",
        Protocols = new[]
        {
            "string",
        },
        ServiceId = "string",
        CertificateId = "string",
        Comments = "string",
        SslRedirect = false,
    });
    
    example, err := apig.NewCustomDomain(ctx, "customDomainResource", &apig.CustomDomainArgs{
    	Domain: pulumi.String("string"),
    	Protocols: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	ServiceId:     pulumi.String("string"),
    	CertificateId: pulumi.String("string"),
    	Comments:      pulumi.String("string"),
    	SslRedirect:   pulumi.Bool(false),
    })
    
    var customDomainResource = new CustomDomain("customDomainResource", CustomDomainArgs.builder()
        .domain("string")
        .protocols("string")
        .serviceId("string")
        .certificateId("string")
        .comments("string")
        .sslRedirect(false)
        .build());
    
    custom_domain_resource = volcenginecc.apig.CustomDomain("customDomainResource",
        domain="string",
        protocols=["string"],
        service_id="string",
        certificate_id="string",
        comments="string",
        ssl_redirect=False)
    
    const customDomainResource = new volcenginecc.apig.CustomDomain("customDomainResource", {
        domain: "string",
        protocols: ["string"],
        serviceId: "string",
        certificateId: "string",
        comments: "string",
        sslRedirect: false,
    });
    
    type: volcenginecc:apig:CustomDomain
    properties:
        certificateId: string
        comments: string
        domain: string
        protocols:
            - string
        serviceId: string
        sslRedirect: false
    

    CustomDomain 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 CustomDomain resource accepts the following input properties:

    Domain string
    Custom Domain
    Protocols List<string>
    Protocol. Values: HTTP, HTTPS
    ServiceId string
    Service ID
    CertificateId string
    Custom Domain Certificate ID
    Comments string
    Remarks
    SslRedirect bool
    Redirect to HTTPS
    Domain string
    Custom Domain
    Protocols []string
    Protocol. Values: HTTP, HTTPS
    ServiceId string
    Service ID
    CertificateId string
    Custom Domain Certificate ID
    Comments string
    Remarks
    SslRedirect bool
    Redirect to HTTPS
    domain String
    Custom Domain
    protocols List<String>
    Protocol. Values: HTTP, HTTPS
    serviceId String
    Service ID
    certificateId String
    Custom Domain Certificate ID
    comments String
    Remarks
    sslRedirect Boolean
    Redirect to HTTPS
    domain string
    Custom Domain
    protocols string[]
    Protocol. Values: HTTP, HTTPS
    serviceId string
    Service ID
    certificateId string
    Custom Domain Certificate ID
    comments string
    Remarks
    sslRedirect boolean
    Redirect to HTTPS
    domain str
    Custom Domain
    protocols Sequence[str]
    Protocol. Values: HTTP, HTTPS
    service_id str
    Service ID
    certificate_id str
    Custom Domain Certificate ID
    comments str
    Remarks
    ssl_redirect bool
    Redirect to HTTPS
    domain String
    Custom Domain
    protocols List<String>
    Protocol. Values: HTTP, HTTPS
    serviceId String
    Service ID
    certificateId String
    Custom Domain Certificate ID
    comments String
    Remarks
    sslRedirect Boolean
    Redirect to HTTPS

    Outputs

    All input properties are implicitly available as output properties. Additionally, the CustomDomain resource produces the following output properties:

    CreatedTime string
    Creation Time
    CustomDomainId string
    Custom Domain ID
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    UpdatedTime string
    Update Time
    CreatedTime string
    Creation Time
    CustomDomainId string
    Custom Domain ID
    Id string
    The provider-assigned unique ID for this managed resource.
    Status string
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    UpdatedTime string
    Update Time
    createdTime String
    Creation Time
    customDomainId String
    Custom Domain ID
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updatedTime String
    Update Time
    createdTime string
    Creation Time
    customDomainId string
    Custom Domain ID
    id string
    The provider-assigned unique ID for this managed resource.
    status string
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updatedTime string
    Update Time
    created_time str
    Creation Time
    custom_domain_id str
    Custom Domain ID
    id str
    The provider-assigned unique ID for this managed resource.
    status str
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updated_time str
    Update Time
    createdTime String
    Creation Time
    customDomainId String
    Custom Domain ID
    id String
    The provider-assigned unique ID for this managed resource.
    status String
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updatedTime String
    Update Time

    Look up Existing CustomDomain Resource

    Get an existing CustomDomain 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?: CustomDomainState, opts?: CustomResourceOptions): CustomDomain
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            certificate_id: Optional[str] = None,
            comments: Optional[str] = None,
            created_time: Optional[str] = None,
            custom_domain_id: Optional[str] = None,
            domain: Optional[str] = None,
            protocols: Optional[Sequence[str]] = None,
            service_id: Optional[str] = None,
            ssl_redirect: Optional[bool] = None,
            status: Optional[str] = None,
            updated_time: Optional[str] = None) -> CustomDomain
    func GetCustomDomain(ctx *Context, name string, id IDInput, state *CustomDomainState, opts ...ResourceOption) (*CustomDomain, error)
    public static CustomDomain Get(string name, Input<string> id, CustomDomainState? state, CustomResourceOptions? opts = null)
    public static CustomDomain get(String name, Output<String> id, CustomDomainState state, CustomResourceOptions options)
    resources:  _:    type: volcenginecc:apig:CustomDomain    get:      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.
    The following state arguments are supported:
    CertificateId string
    Custom Domain Certificate ID
    Comments string
    Remarks
    CreatedTime string
    Creation Time
    CustomDomainId string
    Custom Domain ID
    Domain string
    Custom Domain
    Protocols List<string>
    Protocol. Values: HTTP, HTTPS
    ServiceId string
    Service ID
    SslRedirect bool
    Redirect to HTTPS
    Status string
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    UpdatedTime string
    Update Time
    CertificateId string
    Custom Domain Certificate ID
    Comments string
    Remarks
    CreatedTime string
    Creation Time
    CustomDomainId string
    Custom Domain ID
    Domain string
    Custom Domain
    Protocols []string
    Protocol. Values: HTTP, HTTPS
    ServiceId string
    Service ID
    SslRedirect bool
    Redirect to HTTPS
    Status string
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    UpdatedTime string
    Update Time
    certificateId String
    Custom Domain Certificate ID
    comments String
    Remarks
    createdTime String
    Creation Time
    customDomainId String
    Custom Domain ID
    domain String
    Custom Domain
    protocols List<String>
    Protocol. Values: HTTP, HTTPS
    serviceId String
    Service ID
    sslRedirect Boolean
    Redirect to HTTPS
    status String
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updatedTime String
    Update Time
    certificateId string
    Custom Domain Certificate ID
    comments string
    Remarks
    createdTime string
    Creation Time
    customDomainId string
    Custom Domain ID
    domain string
    Custom Domain
    protocols string[]
    Protocol. Values: HTTP, HTTPS
    serviceId string
    Service ID
    sslRedirect boolean
    Redirect to HTTPS
    status string
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updatedTime string
    Update Time
    certificate_id str
    Custom Domain Certificate ID
    comments str
    Remarks
    created_time str
    Creation Time
    custom_domain_id str
    Custom Domain ID
    domain str
    Custom Domain
    protocols Sequence[str]
    Protocol. Values: HTTP, HTTPS
    service_id str
    Service ID
    ssl_redirect bool
    Redirect to HTTPS
    status str
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updated_time str
    Update Time
    certificateId String
    Custom Domain Certificate ID
    comments String
    Remarks
    createdTime String
    Creation Time
    customDomainId String
    Custom Domain ID
    domain String
    Custom Domain
    protocols List<String>
    Protocol. Values: HTTP, HTTPS
    serviceId String
    Service ID
    sslRedirect Boolean
    Redirect to HTTPS
    status String
    Status. Values: Creating: configuring; CreationFailed: configuration failed; Deleting: deleting; DeletionFailed: deletion failed; Verified: active
    updatedTime String
    Update Time

    Import

    $ pulumi import volcenginecc:apig/customDomain:CustomDomain example "custom_domain_id"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    volcenginecc volcengine/pulumi-volcenginecc
    License
    MPL-2.0
    Notes
    This Pulumi package is based on the volcenginecc Terraform Provider.
    volcenginecc logo
    Viewing docs for volcenginecc v0.0.32
    published on Thursday, Apr 23, 2026 by Volcengine
      Try Pulumi Cloud free. Your team will thank you.