1. Packages
  2. Packages
  3. Volcenginecc Provider
  4. API Docs
  5. cen
  6. GrantInstance
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

    Authorize this account’s network instance for use by the specified account’s Cloud Enterprise Network instance

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as volcenginecc from "@volcengine/pulumi-volcenginecc";
    
    const cenGranInstanceDemo = new volcenginecc.cen.GrantInstance("CenGranInstanceDemo", {
        cenId: "cen-2v72wo******",
        cenOwnerId: "210102***",
        instanceId: "vpc-bu3j9gfdv01s****",
        instanceRegionId: "cn-beijing",
        instanceType: "VPC",
    });
    
    import pulumi
    import pulumi_volcenginecc as volcenginecc
    
    cen_gran_instance_demo = volcenginecc.cen.GrantInstance("CenGranInstanceDemo",
        cen_id="cen-2v72wo******",
        cen_owner_id="210102***",
        instance_id="vpc-bu3j9gfdv01s****",
        instance_region_id="cn-beijing",
        instance_type="VPC")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/volcengine/pulumi-volcenginecc/sdk/go/volcenginecc/cen"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := cen.NewGrantInstance(ctx, "CenGranInstanceDemo", &cen.GrantInstanceArgs{
    			CenId:            pulumi.String("cen-2v72wo******"),
    			CenOwnerId:       pulumi.String("210102***"),
    			InstanceId:       pulumi.String("vpc-bu3j9gfdv01s****"),
    			InstanceRegionId: pulumi.String("cn-beijing"),
    			InstanceType:     pulumi.String("VPC"),
    		})
    		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 cenGranInstanceDemo = new Volcenginecc.Cen.GrantInstance("CenGranInstanceDemo", new()
        {
            CenId = "cen-2v72wo******",
            CenOwnerId = "210102***",
            InstanceId = "vpc-bu3j9gfdv01s****",
            InstanceRegionId = "cn-beijing",
            InstanceType = "VPC",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.volcengine.volcenginecc.cen.GrantInstance;
    import com.volcengine.volcenginecc.cen.GrantInstanceArgs;
    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 cenGranInstanceDemo = new GrantInstance("cenGranInstanceDemo", GrantInstanceArgs.builder()
                .cenId("cen-2v72wo******")
                .cenOwnerId("210102***")
                .instanceId("vpc-bu3j9gfdv01s****")
                .instanceRegionId("cn-beijing")
                .instanceType("VPC")
                .build());
    
        }
    }
    
    resources:
      cenGranInstanceDemo:
        type: volcenginecc:cen:GrantInstance
        name: CenGranInstanceDemo
        properties:
          cenId: cen-2v72wo******
          cenOwnerId: 210102***
          instanceId: vpc-bu3j9gfdv01s****
          instanceRegionId: cn-beijing
          instanceType: VPC
    

    Create GrantInstance Resource

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

    Constructor syntax

    new GrantInstance(name: string, args: GrantInstanceArgs, opts?: CustomResourceOptions);
    @overload
    def GrantInstance(resource_name: str,
                      args: GrantInstanceArgs,
                      opts: Optional[ResourceOptions] = None)
    
    @overload
    def GrantInstance(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      cen_id: Optional[str] = None,
                      cen_owner_id: Optional[str] = None,
                      instance_id: Optional[str] = None,
                      instance_region_id: Optional[str] = None,
                      instance_type: Optional[str] = None)
    func NewGrantInstance(ctx *Context, name string, args GrantInstanceArgs, opts ...ResourceOption) (*GrantInstance, error)
    public GrantInstance(string name, GrantInstanceArgs args, CustomResourceOptions? opts = null)
    public GrantInstance(String name, GrantInstanceArgs args)
    public GrantInstance(String name, GrantInstanceArgs args, CustomResourceOptions options)
    
    type: volcenginecc:cen:GrantInstance
    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 GrantInstanceArgs
    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 GrantInstanceArgs
    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 GrantInstanceArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args GrantInstanceArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args GrantInstanceArgs
    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 grantInstanceResource = new Volcenginecc.Cen.GrantInstance("grantInstanceResource", new()
    {
        CenId = "string",
        CenOwnerId = "string",
        InstanceId = "string",
        InstanceRegionId = "string",
        InstanceType = "string",
    });
    
    example, err := cen.NewGrantInstance(ctx, "grantInstanceResource", &cen.GrantInstanceArgs{
    	CenId:            pulumi.String("string"),
    	CenOwnerId:       pulumi.String("string"),
    	InstanceId:       pulumi.String("string"),
    	InstanceRegionId: pulumi.String("string"),
    	InstanceType:     pulumi.String("string"),
    })
    
    var grantInstanceResource = new GrantInstance("grantInstanceResource", GrantInstanceArgs.builder()
        .cenId("string")
        .cenOwnerId("string")
        .instanceId("string")
        .instanceRegionId("string")
        .instanceType("string")
        .build());
    
    grant_instance_resource = volcenginecc.cen.GrantInstance("grantInstanceResource",
        cen_id="string",
        cen_owner_id="string",
        instance_id="string",
        instance_region_id="string",
        instance_type="string")
    
    const grantInstanceResource = new volcenginecc.cen.GrantInstance("grantInstanceResource", {
        cenId: "string",
        cenOwnerId: "string",
        instanceId: "string",
        instanceRegionId: "string",
        instanceType: "string",
    });
    
    type: volcenginecc:cen:GrantInstance
    properties:
        cenId: string
        cenOwnerId: string
        instanceId: string
        instanceRegionId: string
        instanceType: string
    

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

    CenId string
    Cloud Enterprise Network instance ID of the other party's account
    CenOwnerId string
    Other party's account
    InstanceId string
    ID of the network instance to be authorized
    InstanceRegionId string
    Region where the network instance is located
    InstanceType string
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    CenId string
    Cloud Enterprise Network instance ID of the other party's account
    CenOwnerId string
    Other party's account
    InstanceId string
    ID of the network instance to be authorized
    InstanceRegionId string
    Region where the network instance is located
    InstanceType string
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cenId String
    Cloud Enterprise Network instance ID of the other party's account
    cenOwnerId String
    Other party's account
    instanceId String
    ID of the network instance to be authorized
    instanceRegionId String
    Region where the network instance is located
    instanceType String
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cenId string
    Cloud Enterprise Network instance ID of the other party's account
    cenOwnerId string
    Other party's account
    instanceId string
    ID of the network instance to be authorized
    instanceRegionId string
    Region where the network instance is located
    instanceType string
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cen_id str
    Cloud Enterprise Network instance ID of the other party's account
    cen_owner_id str
    Other party's account
    instance_id str
    ID of the network instance to be authorized
    instance_region_id str
    Region where the network instance is located
    instance_type str
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cenId String
    Cloud Enterprise Network instance ID of the other party's account
    cenOwnerId String
    Other party's account
    instanceId String
    ID of the network instance to be authorized
    instanceRegionId String
    Region where the network instance is located
    instanceType String
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway

    Outputs

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

    CreationTime string
    Network instance authorization time
    Id string
    The provider-assigned unique ID for this managed resource.
    CreationTime string
    Network instance authorization time
    Id string
    The provider-assigned unique ID for this managed resource.
    creationTime String
    Network instance authorization time
    id String
    The provider-assigned unique ID for this managed resource.
    creationTime string
    Network instance authorization time
    id string
    The provider-assigned unique ID for this managed resource.
    creation_time str
    Network instance authorization time
    id str
    The provider-assigned unique ID for this managed resource.
    creationTime String
    Network instance authorization time
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing GrantInstance Resource

    Get an existing GrantInstance 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?: GrantInstanceState, opts?: CustomResourceOptions): GrantInstance
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            cen_id: Optional[str] = None,
            cen_owner_id: Optional[str] = None,
            creation_time: Optional[str] = None,
            instance_id: Optional[str] = None,
            instance_region_id: Optional[str] = None,
            instance_type: Optional[str] = None) -> GrantInstance
    func GetGrantInstance(ctx *Context, name string, id IDInput, state *GrantInstanceState, opts ...ResourceOption) (*GrantInstance, error)
    public static GrantInstance Get(string name, Input<string> id, GrantInstanceState? state, CustomResourceOptions? opts = null)
    public static GrantInstance get(String name, Output<String> id, GrantInstanceState state, CustomResourceOptions options)
    resources:  _:    type: volcenginecc:cen:GrantInstance    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:
    CenId string
    Cloud Enterprise Network instance ID of the other party's account
    CenOwnerId string
    Other party's account
    CreationTime string
    Network instance authorization time
    InstanceId string
    ID of the network instance to be authorized
    InstanceRegionId string
    Region where the network instance is located
    InstanceType string
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    CenId string
    Cloud Enterprise Network instance ID of the other party's account
    CenOwnerId string
    Other party's account
    CreationTime string
    Network instance authorization time
    InstanceId string
    ID of the network instance to be authorized
    InstanceRegionId string
    Region where the network instance is located
    InstanceType string
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cenId String
    Cloud Enterprise Network instance ID of the other party's account
    cenOwnerId String
    Other party's account
    creationTime String
    Network instance authorization time
    instanceId String
    ID of the network instance to be authorized
    instanceRegionId String
    Region where the network instance is located
    instanceType String
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cenId string
    Cloud Enterprise Network instance ID of the other party's account
    cenOwnerId string
    Other party's account
    creationTime string
    Network instance authorization time
    instanceId string
    ID of the network instance to be authorized
    instanceRegionId string
    Region where the network instance is located
    instanceType string
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cen_id str
    Cloud Enterprise Network instance ID of the other party's account
    cen_owner_id str
    Other party's account
    creation_time str
    Network instance authorization time
    instance_id str
    ID of the network instance to be authorized
    instance_region_id str
    Region where the network instance is located
    instance_type str
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway
    cenId String
    Cloud Enterprise Network instance ID of the other party's account
    cenOwnerId String
    Other party's account
    creationTime String
    Network instance authorization time
    instanceId String
    ID of the network instance to be authorized
    instanceRegionId String
    Region where the network instance is located
    instanceType String
    Network instance type. Options: VPC: Virtual Private Cloud. DCGW: Direct Connect Gateway

    Import

    $ pulumi import volcenginecc:cen/grantInstance:GrantInstance example "instance_id|cen_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.