1. Registry
  2. Packages
  3. Oracle Cloud Infrastructure
  4. API Docs
  5. Tenantmanagercontrolplane
  6. ChildTenancy
Viewing docs for Oracle Cloud Infrastructure v5.8.0
published on Thursday, Nov 19, 2026 by Pulumi
oci logo oci logo
Viewing docs for Oracle Cloud Infrastructure v5.8.0
published on Thursday, Nov 19, 2026 by Pulumi

    This resource provides the Child Tenancy resource in Oracle Cloud Infrastructure Tenantmanagercontrolplane service. Api doc link for the resource: https://docs.oracle.com/iaas/api/#/en/organizations/latest/ChildTenancy

    Example terraform configs related to the resource : https://github.com/oracle/terraform-provider-oci/tree/master/examples/tenantmanagercontrolplane

    Creates a child tenancy asynchronously.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testChildTenancy = new oci.tenantmanagercontrolplane.ChildTenancy("test_child_tenancy", {
        adminEmail: childTenancyAdminEmail,
        compartmentId: compartmentId,
        homeRegion: childTenancyHomeRegion,
        tenancyName: testTenancy.name,
        features: childTenancyFeatures,
        governanceStatus: childTenancyGovernanceStatus,
        policyName: testPolicy.name,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_child_tenancy = oci.tenantmanagercontrolplane.ChildTenancy("test_child_tenancy",
        admin_email=child_tenancy_admin_email,
        compartment_id=compartment_id,
        home_region=child_tenancy_home_region,
        tenancy_name=test_tenancy["name"],
        features=child_tenancy_features,
        governance_status=child_tenancy_governance_status,
        policy_name=test_policy["name"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v5/go/oci/tenantmanagercontrolplane"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := tenantmanagercontrolplane.NewChildTenancy(ctx, "test_child_tenancy", &tenantmanagercontrolplane.ChildTenancyArgs{
    			AdminEmail:       pulumi.Any(childTenancyAdminEmail),
    			CompartmentId:    pulumi.Any(compartmentId),
    			HomeRegion:       pulumi.Any(childTenancyHomeRegion),
    			TenancyName:      pulumi.Any(testTenancy.Name),
    			Features:         pulumi.Any(childTenancyFeatures),
    			GovernanceStatus: pulumi.Any(childTenancyGovernanceStatus),
    			PolicyName:       pulumi.Any(testPolicy.Name),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testChildTenancy = new Oci.Tenantmanagercontrolplane.ChildTenancy("test_child_tenancy", new()
        {
            AdminEmail = childTenancyAdminEmail,
            CompartmentId = compartmentId,
            HomeRegion = childTenancyHomeRegion,
            TenancyName = testTenancy.Name,
            Features = childTenancyFeatures,
            GovernanceStatus = childTenancyGovernanceStatus,
            PolicyName = testPolicy.Name,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Tenantmanagercontrolplane.ChildTenancy;
    import com.pulumi.oci.Tenantmanagercontrolplane.ChildTenancyArgs;
    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) {
            var testChildTenancy = new ChildTenancy("testChildTenancy", ChildTenancyArgs.builder()
                .adminEmail(childTenancyAdminEmail)
                .compartmentId(compartmentId)
                .homeRegion(childTenancyHomeRegion)
                .tenancyName(testTenancy.get("name"))
                .features(childTenancyFeatures)
                .governanceStatus(childTenancyGovernanceStatus)
                .policyName(testPolicy.get("name"))
                .build());
    
        }
    }
    
    resources:
      testChildTenancy:
        type: oci:Tenantmanagercontrolplane:ChildTenancy
        name: test_child_tenancy
        properties:
          adminEmail: ${childTenancyAdminEmail}
          compartmentId: ${compartmentId}
          homeRegion: ${childTenancyHomeRegion}
          tenancyName: ${testTenancy.name}
          features: ${childTenancyFeatures}
          governanceStatus: ${childTenancyGovernanceStatus}
          policyName: ${testPolicy.name}
    
    terraform {
      required_providers {
        oci = {
          source = "pulumi/oci"
        }
      }
    }
    
    resource "oci_tenantmanagercontrolplane_child_tenancy" "test_child_tenancy" {
      lifecycle {
        create_before_destroy = true
      }
      admin_email       = childTenancyAdminEmail
      compartment_id    = compartmentId
      home_region       = childTenancyHomeRegion
      tenancy_name      = testTenancy.name
      features          = childTenancyFeatures
      governance_status = childTenancyGovernanceStatus
      policy_name       = testPolicy.name
    }
    

    Create ChildTenancy Resource

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

    Constructor syntax

    new ChildTenancy(name: string, args: ChildTenancyArgs, opts?: CustomResourceOptions);
    @overload
    def ChildTenancy(resource_name: str,
                     args: ChildTenancyArgs,
                     opts: Optional[ResourceOptions] = None)
    
    @overload
    def ChildTenancy(resource_name: str,
                     opts: Optional[ResourceOptions] = None,
                     admin_email: Optional[str] = None,
                     compartment_id: Optional[str] = None,
                     home_region: Optional[str] = None,
                     tenancy_name: Optional[str] = None,
                     features: Optional[Sequence[str]] = None,
                     governance_status: Optional[str] = None,
                     policy_name: Optional[str] = None)
    func NewChildTenancy(ctx *Context, name string, args ChildTenancyArgs, opts ...ResourceOption) (*ChildTenancy, error)
    public ChildTenancy(string name, ChildTenancyArgs args, CustomResourceOptions? opts = null)
    public ChildTenancy(String name, ChildTenancyArgs args)
    public ChildTenancy(String name, ChildTenancyArgs args, CustomResourceOptions options)
    
    type: oci:Tenantmanagercontrolplane:ChildTenancy
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "oci_tenantmanagercontrolplane_child_tenancy" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args ChildTenancyArgs
    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 ChildTenancyArgs
    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 ChildTenancyArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ChildTenancyArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ChildTenancyArgs
    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 childTenancyResource = new Oci.Tenantmanagercontrolplane.ChildTenancy("childTenancyResource", new()
    {
        AdminEmail = "string",
        CompartmentId = "string",
        HomeRegion = "string",
        TenancyName = "string",
        Features = new[]
        {
            "string",
        },
        GovernanceStatus = "string",
        PolicyName = "string",
    });
    
    example, err := tenantmanagercontrolplane.NewChildTenancy(ctx, "childTenancyResource", &tenantmanagercontrolplane.ChildTenancyArgs{
    	AdminEmail:    pulumi.String("string"),
    	CompartmentId: pulumi.String("string"),
    	HomeRegion:    pulumi.String("string"),
    	TenancyName:   pulumi.String("string"),
    	Features: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	GovernanceStatus: pulumi.String("string"),
    	PolicyName:       pulumi.String("string"),
    })
    
    resource "oci_tenantmanagercontrolplane_child_tenancy" "childTenancyResource" {
      lifecycle {
        create_before_destroy = true
      }
      admin_email       = "string"
      compartment_id    = "string"
      home_region       = "string"
      tenancy_name      = "string"
      features          = ["string"]
      governance_status = "string"
      policy_name       = "string"
    }
    
    var childTenancyResource = new ChildTenancy("childTenancyResource", ChildTenancyArgs.builder()
        .adminEmail("string")
        .compartmentId("string")
        .homeRegion("string")
        .tenancyName("string")
        .features("string")
        .governanceStatus("string")
        .policyName("string")
        .build());
    
    child_tenancy_resource = oci.tenantmanagercontrolplane.ChildTenancy("childTenancyResource",
        admin_email="string",
        compartment_id="string",
        home_region="string",
        tenancy_name="string",
        features=["string"],
        governance_status="string",
        policy_name="string")
    
    const childTenancyResource = new oci.tenantmanagercontrolplane.ChildTenancy("childTenancyResource", {
        adminEmail: "string",
        compartmentId: "string",
        homeRegion: "string",
        tenancyName: "string",
        features: ["string"],
        governanceStatus: "string",
        policyName: "string",
    });
    
    type: oci:Tenantmanagercontrolplane:ChildTenancy
    properties:
        adminEmail: string
        compartmentId: string
        features:
            - string
        governanceStatus: string
        homeRegion: string
        policyName: string
        tenancyName: string
    

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

    AdminEmail string
    Email address of the child tenancy administrator.
    CompartmentId string
    The tenancy ID of the parent tenancy.
    HomeRegion string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    TenancyName string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Features List<string>
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    GovernanceStatus string
    The governance status of the child tenancy.
    PolicyName string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    AdminEmail string
    Email address of the child tenancy administrator.
    CompartmentId string
    The tenancy ID of the parent tenancy.
    HomeRegion string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    TenancyName string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Features []string
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    GovernanceStatus string
    The governance status of the child tenancy.
    PolicyName string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    admin_email string
    Email address of the child tenancy administrator.
    compartment_id string
    The tenancy ID of the parent tenancy.
    home_region string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    tenancy_name string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    features list(string)
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governance_status string
    The governance status of the child tenancy.
    policy_name string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    adminEmail String
    Email address of the child tenancy administrator.
    compartmentId String
    The tenancy ID of the parent tenancy.
    homeRegion String
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    tenancyName String

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    features List<String>
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governanceStatus String
    The governance status of the child tenancy.
    policyName String
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    adminEmail string
    Email address of the child tenancy administrator.
    compartmentId string
    The tenancy ID of the parent tenancy.
    homeRegion string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    tenancyName string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    features string[]
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governanceStatus string
    The governance status of the child tenancy.
    policyName string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    admin_email str
    Email address of the child tenancy administrator.
    compartment_id str
    The tenancy ID of the parent tenancy.
    home_region str
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    tenancy_name str

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    features Sequence[str]
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governance_status str
    The governance status of the child tenancy.
    policy_name str
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    adminEmail String
    Email address of the child tenancy administrator.
    compartmentId String
    The tenancy ID of the parent tenancy.
    homeRegion String
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    tenancyName String

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    features List<String>
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governanceStatus String
    The governance status of the child tenancy.
    policyName String
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the ChildTenancy 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 ChildTenancy Resource

    Get an existing ChildTenancy 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?: ChildTenancyState, opts?: CustomResourceOptions): ChildTenancy
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            admin_email: Optional[str] = None,
            compartment_id: Optional[str] = None,
            features: Optional[Sequence[str]] = None,
            governance_status: Optional[str] = None,
            home_region: Optional[str] = None,
            policy_name: Optional[str] = None,
            tenancy_name: Optional[str] = None) -> ChildTenancy
    func GetChildTenancy(ctx *Context, name string, id IDInput, state *ChildTenancyState, opts ...ResourceOption) (*ChildTenancy, error)
    public static ChildTenancy Get(string name, Input<string> id, ChildTenancyState? state, CustomResourceOptions? opts = null)
    public static ChildTenancy get(String name, Output<String> id, ChildTenancyState state, CustomResourceOptions options)
    resources:  existingChildTenancy:    type: oci:Tenantmanagercontrolplane:ChildTenancy    get:      id: ${id}
    import {
      to = oci_tenantmanagercontrolplane_child_tenancy.example
      id = "${id}"
    }
    
    name string
    The unique name of the resulting resource.
    id Input<ID>
    The unique provider ID of the resource to look up.
    state ChildTenancyState
    Known property values the provider needs, along with the ID, to find the resource. Usually not required.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resulting resource.
    id str
    The unique provider ID of the resource to look up.
    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 resulting resource.
    id IDInput
    The unique provider ID of the resource to look up.
    state ChildTenancyState
    Known property values the provider needs, along with the ID, to find the resource. Usually not required.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resulting resource.
    id Input<string>
    The unique provider ID of the resource to look up.
    state ChildTenancyState
    Known property values the provider needs, along with the ID, to find the resource. Usually not required.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resulting resource.
    id Output<String>
    The unique provider ID of the resource to look up.
    state ChildTenancyState
    Known property values the provider needs, along with the ID, to find the resource. Usually not required.
    options CustomResourceOptions
    Bag of options to control resource's behavior.
    The following state arguments are supported:
    AdminEmail string
    Email address of the child tenancy administrator.
    CompartmentId string
    The tenancy ID of the parent tenancy.
    Features List<string>
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    GovernanceStatus string
    The governance status of the child tenancy.
    HomeRegion string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    PolicyName string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    TenancyName string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    AdminEmail string
    Email address of the child tenancy administrator.
    CompartmentId string
    The tenancy ID of the parent tenancy.
    Features []string
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    GovernanceStatus string
    The governance status of the child tenancy.
    HomeRegion string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    PolicyName string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    TenancyName string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    admin_email string
    Email address of the child tenancy administrator.
    compartment_id string
    The tenancy ID of the parent tenancy.
    features list(string)
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governance_status string
    The governance status of the child tenancy.
    home_region string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    policy_name string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    tenancy_name string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    adminEmail String
    Email address of the child tenancy administrator.
    compartmentId String
    The tenancy ID of the parent tenancy.
    features List<String>
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governanceStatus String
    The governance status of the child tenancy.
    homeRegion String
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    policyName String
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    tenancyName String

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    adminEmail string
    Email address of the child tenancy administrator.
    compartmentId string
    The tenancy ID of the parent tenancy.
    features string[]
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governanceStatus string
    The governance status of the child tenancy.
    homeRegion string
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    policyName string
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    tenancyName string

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    admin_email str
    Email address of the child tenancy administrator.
    compartment_id str
    The tenancy ID of the parent tenancy.
    features Sequence[str]
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governance_status str
    The governance status of the child tenancy.
    home_region str
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    policy_name str
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    tenancy_name str

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    adminEmail String
    Email address of the child tenancy administrator.
    compartmentId String
    The tenancy ID of the parent tenancy.
    features List<String>
    List of features that the child and parent tenancies will have links for. Link with feature CORE will always be created.
    governanceStatus String
    The governance status of the child tenancy.
    homeRegion String
    The home region to use for the child tenancy. This must be a region where the parent tenancy is subscribed.
    policyName String
    The name to use for the administrator policy in the child tenancy. Must contain only letters and underscores.
    tenancyName String

    The tenancy name to use for the child tenancy.

    ** IMPORTANT ** Any change to a property that does not support update will force the destruction and recreation of the resource with the new property values

    Import

    ChildTenancies can be imported using the id, e.g.

    $ pulumi import oci:Tenantmanagercontrolplane/childTenancy:ChildTenancy test_child_tenancy "id"
    

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

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo oci logo
    Viewing docs for Oracle Cloud Infrastructure v5.8.0
    published on Thursday, Nov 19, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial