We recommend using Azure Native.
published on Monday, Mar 9, 2026 by Pulumi
We recommend using Azure Native.
published on Monday, Mar 9, 2026 by Pulumi
Manages a Management Group.
!> Note: Configuring subscription_ids is not supported when using the azure.management.GroupSubscriptionAssociation resource, results will be unpredictable.
Example Usage
using Pulumi;
using Azure = Pulumi.Azure;
class MyStack : Stack
{
public MyStack()
{
var current = Output.Create(Azure.Core.GetSubscription.InvokeAsync());
var exampleParent = new Azure.Management.Group("exampleParent", new Azure.Management.GroupArgs
{
DisplayName = "ParentGroup",
SubscriptionIds =
{
current.Apply(current => current.SubscriptionId),
},
});
var exampleChild = new Azure.Management.Group("exampleChild", new Azure.Management.GroupArgs
{
DisplayName = "ChildGroup",
ParentManagementGroupId = exampleParent.Id,
SubscriptionIds =
{
current.Apply(current => current.SubscriptionId),
},
});
// other subscription IDs can go here
}
}
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v4/go/azure/core"
"github.com/pulumi/pulumi-azure/sdk/v4/go/azure/management"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
current, err := core.LookupSubscription(ctx, nil, nil)
if err != nil {
return err
}
exampleParent, err := management.NewGroup(ctx, "exampleParent", &management.GroupArgs{
DisplayName: pulumi.String("ParentGroup"),
SubscriptionIds: pulumi.StringArray{
pulumi.String(current.SubscriptionId),
},
})
if err != nil {
return err
}
_, err = management.NewGroup(ctx, "exampleChild", &management.GroupArgs{
DisplayName: pulumi.String("ChildGroup"),
ParentManagementGroupId: exampleParent.ID(),
SubscriptionIds: pulumi.StringArray{
pulumi.String(current.SubscriptionId),
},
})
if err != nil {
return err
}
return nil
})
}
Example coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const current = azure.core.getSubscription({});
const exampleParent = new azure.management.Group("exampleParent", {
displayName: "ParentGroup",
subscriptionIds: [current.then(current => current.subscriptionId)],
});
const exampleChild = new azure.management.Group("exampleChild", {
displayName: "ChildGroup",
parentManagementGroupId: exampleParent.id,
subscriptionIds: [current.then(current => current.subscriptionId)],
});
// other subscription IDs can go here
import pulumi
import pulumi_azure as azure
current = azure.core.get_subscription()
example_parent = azure.management.Group("exampleParent",
display_name="ParentGroup",
subscription_ids=[current.subscription_id])
example_child = azure.management.Group("exampleChild",
display_name="ChildGroup",
parent_management_group_id=example_parent.id,
subscription_ids=[current.subscription_id])
# other subscription IDs can go here
Example coming soon!
Create Group Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Group(name: string, args?: GroupArgs, opts?: CustomResourceOptions);@overload
def Group(resource_name: str,
args: Optional[GroupArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def Group(resource_name: str,
opts: Optional[ResourceOptions] = None,
display_name: Optional[str] = None,
group_id: Optional[str] = None,
name: Optional[str] = None,
parent_management_group_id: Optional[str] = None,
subscription_ids: Optional[Sequence[str]] = None)func NewGroup(ctx *Context, name string, args *GroupArgs, opts ...ResourceOption) (*Group, error)public Group(string name, GroupArgs? args = null, CustomResourceOptions? opts = null)type: azure:management:Group
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 GroupArgs
- 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 GroupArgs
- 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 GroupArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args GroupArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args GroupArgs
- 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 examplegroupResourceResourceFromManagementgroup = new Azure.Management.Group("examplegroupResourceResourceFromManagementgroup", new()
{
DisplayName = "string",
Name = "string",
ParentManagementGroupId = "string",
SubscriptionIds = new[]
{
"string",
},
});
example, err := management.NewGroup(ctx, "examplegroupResourceResourceFromManagementgroup", &management.GroupArgs{
DisplayName: pulumi.String("string"),
Name: pulumi.String("string"),
ParentManagementGroupId: pulumi.String("string"),
SubscriptionIds: pulumi.StringArray{
pulumi.String("string"),
},
})
var examplegroupResourceResourceFromManagementgroup = new com.pulumi.azure.management.Group("examplegroupResourceResourceFromManagementgroup", com.pulumi.azure.management.GroupArgs.builder()
.displayName("string")
.name("string")
.parentManagementGroupId("string")
.subscriptionIds("string")
.build());
examplegroup_resource_resource_from_managementgroup = azure.management.Group("examplegroupResourceResourceFromManagementgroup",
display_name="string",
name="string",
parent_management_group_id="string",
subscription_ids=["string"])
const examplegroupResourceResourceFromManagementgroup = new azure.management.Group("examplegroupResourceResourceFromManagementgroup", {
displayName: "string",
name: "string",
parentManagementGroupId: "string",
subscriptionIds: ["string"],
});
type: azure:management:Group
properties:
displayName: string
name: string
parentManagementGroupId: string
subscriptionIds:
- string
Group 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 Group resource accepts the following input properties:
- Display
Name string - A friendly name for this Management Group. If not specified, this will be the same as the
name. - Group
Id string - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Name string
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Parent
Management stringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- Subscription
Ids List<string> - A list of Subscription GUIDs which should be assigned to the Management Group.
- Display
Name string - A friendly name for this Management Group. If not specified, this will be the same as the
name. - Group
Id string - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Name string
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Parent
Management stringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- Subscription
Ids []string - A list of Subscription GUIDs which should be assigned to the Management Group.
- display
Name String - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group
Id String - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name String
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent
Management StringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription
Ids List<String> - A list of Subscription GUIDs which should be assigned to the Management Group.
- display
Name string - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group
Id string - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name string
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent
Management stringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription
Ids string[] - A list of Subscription GUIDs which should be assigned to the Management Group.
- display_
name str - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group_
id str - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name str
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent_
management_ strgroup_ id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription_
ids Sequence[str] - A list of Subscription GUIDs which should be assigned to the Management Group.
- display
Name String - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group
Id String - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name String
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent
Management StringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription
Ids List<String> - A list of Subscription GUIDs which should be assigned to the Management Group.
Outputs
All input properties are implicitly available as output properties. Additionally, the Group 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 str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing Group Resource
Get an existing Group 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?: GroupState, opts?: CustomResourceOptions): Group@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
display_name: Optional[str] = None,
group_id: Optional[str] = None,
name: Optional[str] = None,
parent_management_group_id: Optional[str] = None,
subscription_ids: Optional[Sequence[str]] = None) -> Groupfunc GetGroup(ctx *Context, name string, id IDInput, state *GroupState, opts ...ResourceOption) (*Group, error)public static Group Get(string name, Input<string> id, GroupState? state, CustomResourceOptions? opts = null)public static Group get(String name, Output<String> id, GroupState state, CustomResourceOptions options)resources: _: type: azure:management:Group 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.
- Display
Name string - A friendly name for this Management Group. If not specified, this will be the same as the
name. - Group
Id string - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Name string
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Parent
Management stringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- Subscription
Ids List<string> - A list of Subscription GUIDs which should be assigned to the Management Group.
- Display
Name string - A friendly name for this Management Group. If not specified, this will be the same as the
name. - Group
Id string - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Name string
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- Parent
Management stringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- Subscription
Ids []string - A list of Subscription GUIDs which should be assigned to the Management Group.
- display
Name String - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group
Id String - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name String
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent
Management StringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription
Ids List<String> - A list of Subscription GUIDs which should be assigned to the Management Group.
- display
Name string - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group
Id string - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name string
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent
Management stringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription
Ids string[] - A list of Subscription GUIDs which should be assigned to the Management Group.
- display_
name str - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group_
id str - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name str
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent_
management_ strgroup_ id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription_
ids Sequence[str] - A list of Subscription GUIDs which should be assigned to the Management Group.
- display
Name String - A friendly name for this Management Group. If not specified, this will be the same as the
name. - group
Id String - The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- name String
- The name or UUID for this Management Group, which needs to be unique across your tenant. A new UUID will be generated if not provided. Changing this forces a new resource to be created.
- parent
Management StringGroup Id - The ID of the Parent Management Group. Changing this forces a new resource to be created.
- subscription
Ids List<String> - A list of Subscription GUIDs which should be assigned to the Management Group.
Import
Management Groups can be imported using the management group resource id, e.g.
$ pulumi import azure:management/group:Group example /providers/Microsoft.Management/managementGroups/group1
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurermTerraform Provider.
We recommend using Azure Native.
published on Monday, Mar 9, 2026 by Pulumi
