published on Tuesday, Oct 13, 2026 by Pulumi
published on Tuesday, Oct 13, 2026 by Pulumi
Manages a single license assignment for a group (group-based licensing).
License availability The SKU being assigned must be available in your tenant. You can find the available SKUs and their service plans in the Microsoft 365 admin center, or by inspecting the
subscribedSkusin Microsoft Graph.
Group-based licensing Licenses assigned to a group are inherited by all members of that group. Assignment to individual members happens asynchronously after the license is assigned to the group, and is managed by Microsoft Entra ID rather than by this resource. This resource only manages the license assignment on the group object itself.
API Permissions
The following API permissions are required in order to use this resource.
When authenticated with a service principal, this resource requires one of the following application roles: LicenseAssignment.ReadWrite.All, Group.ReadWrite.All or Directory.ReadWrite.All
When authenticated with a user principal, this resource may require one of the following directory roles: License Administrator, Groups Administrator, User Administrator or Global Administrator
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azuread from "@pulumi/azuread";
const example = new azuread.Group("example", {
displayName: "Sales Team",
securityEnabled: true,
});
const exampleGroupLicense = new azuread.GroupLicense("example", {
groupObjectId: example.objectId,
skuId: "c7df2760-2c81-4ef7-b578-5b5392b571df",
});
import pulumi
import pulumi_azuread as azuread
example = azuread.Group("example",
display_name="Sales Team",
security_enabled=True)
example_group_license = azuread.GroupLicense("example",
group_object_id=example.object_id,
sku_id="c7df2760-2c81-4ef7-b578-5b5392b571df")
package main
import (
"github.com/pulumi/pulumi-azuread/sdk/v6/go/azuread"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := azuread.NewGroup(ctx, "example", &azuread.GroupArgs{
DisplayName: pulumi.String("Sales Team"),
SecurityEnabled: pulumi.Bool(true),
})
if err != nil {
return err
}
_, err = azuread.NewGroupLicense(ctx, "example", &azuread.GroupLicenseArgs{
GroupObjectId: example.ObjectId,
SkuId: pulumi.String("c7df2760-2c81-4ef7-b578-5b5392b571df"),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureAD = Pulumi.AzureAD;
return await Deployment.RunAsync(() =>
{
var example = new AzureAD.Group("example", new()
{
DisplayName = "Sales Team",
SecurityEnabled = true,
});
var exampleGroupLicense = new AzureAD.GroupLicense("example", new()
{
GroupObjectId = example.ObjectId,
SkuId = "c7df2760-2c81-4ef7-b578-5b5392b571df",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azuread.Group;
import com.pulumi.azuread.GroupArgs;
import com.pulumi.azuread.GroupLicense;
import com.pulumi.azuread.GroupLicenseArgs;
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 example = new Group("example", GroupArgs.builder()
.displayName("Sales Team")
.securityEnabled(true)
.build());
var exampleGroupLicense = new GroupLicense("exampleGroupLicense", GroupLicenseArgs.builder()
.groupObjectId(example.objectId())
.skuId("c7df2760-2c81-4ef7-b578-5b5392b571df")
.build());
}
}
resources:
example:
type: azuread:Group
properties:
displayName: Sales Team
securityEnabled: true
exampleGroupLicense:
type: azuread:GroupLicense
name: example
properties:
groupObjectId: ${example.objectId}
skuId: c7df2760-2c81-4ef7-b578-5b5392b571df
terraform {
required_providers {
azuread = {
source = "pulumi/azuread"
}
}
}
resource "azuread_group" "example" {
lifecycle {
create_before_destroy = true
}
display_name = "Sales Team"
security_enabled = true
}
resource "azuread_group_license" "example" {
lifecycle {
create_before_destroy = true
}
group_object_id = azuread_group.example.object_id
sku_id = "c7df2760-2c81-4ef7-b578-5b5392b571df"
}
Disabling specific service plans
import * as pulumi from "@pulumi/pulumi";
import * as azuread from "@pulumi/azuread";
const example = new azuread.GroupLicense("example", {
groupObjectId: exampleAzureadGroup.objectId,
skuId: "c7df2760-2c81-4ef7-b578-5b5392b571df",
disabledPlans: ["a23b959c-7ce8-4e57-9140-b90eb88a9e97"],
});
import pulumi
import pulumi_azuread as azuread
example = azuread.GroupLicense("example",
group_object_id=example_azuread_group["objectId"],
sku_id="c7df2760-2c81-4ef7-b578-5b5392b571df",
disabled_plans=["a23b959c-7ce8-4e57-9140-b90eb88a9e97"])
package main
import (
"github.com/pulumi/pulumi-azuread/sdk/v6/go/azuread"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := azuread.NewGroupLicense(ctx, "example", &azuread.GroupLicenseArgs{
GroupObjectId: pulumi.Any(exampleAzureadGroup.ObjectId),
SkuId: pulumi.String("c7df2760-2c81-4ef7-b578-5b5392b571df"),
DisabledPlans: pulumi.StringArray{
pulumi.String("a23b959c-7ce8-4e57-9140-b90eb88a9e97"),
},
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureAD = Pulumi.AzureAD;
return await Deployment.RunAsync(() =>
{
var example = new AzureAD.GroupLicense("example", new()
{
GroupObjectId = exampleAzureadGroup.ObjectId,
SkuId = "c7df2760-2c81-4ef7-b578-5b5392b571df",
DisabledPlans = new[]
{
"a23b959c-7ce8-4e57-9140-b90eb88a9e97",
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azuread.GroupLicense;
import com.pulumi.azuread.GroupLicenseArgs;
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 example = new GroupLicense("example", GroupLicenseArgs.builder()
.groupObjectId(exampleAzureadGroup.get("objectId"))
.skuId("c7df2760-2c81-4ef7-b578-5b5392b571df")
.disabledPlans("a23b959c-7ce8-4e57-9140-b90eb88a9e97")
.build());
}
}
resources:
example:
type: azuread:GroupLicense
properties:
groupObjectId: ${exampleAzureadGroup.objectId}
skuId: c7df2760-2c81-4ef7-b578-5b5392b571df
disabledPlans:
- a23b959c-7ce8-4e57-9140-b90eb88a9e97
terraform {
required_providers {
azuread = {
source = "pulumi/azuread"
}
}
}
resource "azuread_group_license" "example" {
lifecycle {
create_before_destroy = true
}
group_object_id = exampleAzureadGroup.objectId
sku_id = "c7df2760-2c81-4ef7-b578-5b5392b571df"
disabled_plans = ["a23b959c-7ce8-4e57-9140-b90eb88a9e97"]
}
Tip For assigning more licenses to a group, create additional instances of this resource.
Create GroupLicense Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new GroupLicense(name: string, args: GroupLicenseArgs, opts?: CustomResourceOptions);@overload
def GroupLicense(resource_name: str,
args: GroupLicenseArgs,
opts: Optional[ResourceOptions] = None)
@overload
def GroupLicense(resource_name: str,
opts: Optional[ResourceOptions] = None,
group_object_id: Optional[str] = None,
sku_id: Optional[str] = None,
disabled_plans: Optional[Sequence[str]] = None)func NewGroupLicense(ctx *Context, name string, args GroupLicenseArgs, opts ...ResourceOption) (*GroupLicense, error)public GroupLicense(string name, GroupLicenseArgs args, CustomResourceOptions? opts = null)
public GroupLicense(String name, GroupLicenseArgs args)
public GroupLicense(String name, GroupLicenseArgs args, CustomResourceOptions options)
type: azuread:GroupLicense
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "azuread_group_license" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args GroupLicenseArgs
- 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 GroupLicenseArgs
- 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 GroupLicenseArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args GroupLicenseArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args GroupLicenseArgs
- 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 groupLicenseResource = new AzureAD.GroupLicense("groupLicenseResource", new()
{
GroupObjectId = "string",
SkuId = "string",
DisabledPlans = new[]
{
"string",
},
});
example, err := azuread.NewGroupLicense(ctx, "groupLicenseResource", &azuread.GroupLicenseArgs{
GroupObjectId: pulumi.String("string"),
SkuId: pulumi.String("string"),
DisabledPlans: pulumi.StringArray{
pulumi.String("string"),
},
})
resource "azuread_group_license" "groupLicenseResource" {
lifecycle {
create_before_destroy = true
}
group_object_id = "string"
sku_id = "string"
disabled_plans = ["string"]
}
var groupLicenseResource = new GroupLicense("groupLicenseResource", GroupLicenseArgs.builder()
.groupObjectId("string")
.skuId("string")
.disabledPlans("string")
.build());
group_license_resource = azuread.GroupLicense("groupLicenseResource",
group_object_id="string",
sku_id="string",
disabled_plans=["string"])
const groupLicenseResource = new azuread.GroupLicense("groupLicenseResource", {
groupObjectId: "string",
skuId: "string",
disabledPlans: ["string"],
});
type: azuread:GroupLicense
properties:
disabledPlans:
- string
groupObjectId: string
skuId: string
GroupLicense 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 GroupLicense resource accepts the following input properties:
- Group
Object stringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- Sku
Id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- Disabled
Plans List<string> - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- Group
Object stringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- Sku
Id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- Disabled
Plans []string - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group_
object_ stringid - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku_
id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled_
plans list(string) - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group
Object StringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku
Id String - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled
Plans List<String> - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group
Object stringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku
Id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled
Plans string[] - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group_
object_ strid - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku_
id str - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled_
plans Sequence[str] - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group
Object StringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku
Id String - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled
Plans List<String> - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
Outputs
All input properties are implicitly available as output properties. Additionally, the GroupLicense 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 GroupLicense Resource
Get an existing GroupLicense 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?: GroupLicenseState, opts?: CustomResourceOptions): GroupLicense@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
disabled_plans: Optional[Sequence[str]] = None,
group_object_id: Optional[str] = None,
sku_id: Optional[str] = None) -> GroupLicensefunc GetGroupLicense(ctx *Context, name string, id IDInput, state *GroupLicenseState, opts ...ResourceOption) (*GroupLicense, error)public static GroupLicense Get(string name, Input<string> id, GroupLicenseState? state, CustomResourceOptions? opts = null)public static GroupLicense get(String name, Output<String> id, GroupLicenseState state, CustomResourceOptions options)resources: _: type: azuread:GroupLicense get: id: ${id}import {
to = azuread_group_license.example
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.
- Disabled
Plans List<string> - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- Group
Object stringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- Sku
Id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- Disabled
Plans []string - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- Group
Object stringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- Sku
Id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled_
plans list(string) - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group_
object_ stringid - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku_
id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled
Plans List<String> - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group
Object StringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku
Id String - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled
Plans string[] - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group
Object stringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku
Id string - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled_
plans Sequence[str] - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group_
object_ strid - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku_
id str - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
- disabled
Plans List<String> - A set of unique identifiers (GUIDs) for the service plans to disable for this license. Changing this forces a new resource to be created.
- group
Object StringId - The object ID of the group to which the license should be assigned. Changing this forces a new resource to be created.
- sku
Id String - The unique identifier (GUID) for the SKU (license) to assign to the group. Changing this forces a new resource to be created.
Import
Group Licenses can be imported using the object ID of the group and the SKU ID of the license, in the following format.
$ pulumi import azuread:index/groupLicense:GroupLicense example 00000000-0000-0000-0000-000000000000/license/11111111-1111-1111-1111-111111111111
This ID format is unique to Terraform and is composed of the Azure AD Group Object ID and the license SKU ID in the format
{GroupObjectID}/license/{SkuID}.
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Azure Active Directory (Azure AD) pulumi/pulumi-azuread
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azureadTerraform Provider.
published on Tuesday, Oct 13, 2026 by Pulumi