graphBetaUserLicenseAssignment

package
v0.35.0-alpha Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2025 License: MPL-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ResourceName  = "graph_beta_users_user_license_assignment"
	CreateTimeout = 180
	UpdateTimeout = 180
	ReadTimeout   = 180
	DeleteTimeout = 180
)

Variables

This section is empty.

Functions

func MapLicenseDetailsToTerraform

func MapLicenseDetailsToTerraform(ctx context.Context, data *UserLicenseAssignmentResourceModel, licenseDetailsResponse graphmodels.LicenseDetailsCollectionResponseable)

MapLicenseDetailsToTerraform maps the license details response to Terraform state.

func MapRemoteResourceStateToTerraform

func MapRemoteResourceStateToTerraform(ctx context.Context, data *UserLicenseAssignmentResourceModel, remoteResource graphmodels.Userable)

MapRemoteResourceStateToTerraform maps the properties of a User to Terraform state for license assignment.

func NewUserLicenseAssignmentResource

func NewUserLicenseAssignmentResource() resource.Resource

Types

type AssignedLicenseResourceModel

type AssignedLicenseResourceModel struct {
	SkuId         types.String `tfsdk:"sku_id"`
	DisabledPlans types.Set    `tfsdk:"disabled_plans"`
}

AssignedLicenseResourceModel represents a license to be assigned to the user

type LicenseDetailsResourceModel

type LicenseDetailsResourceModel struct {
	SkuId         types.String `tfsdk:"sku_id"`
	SkuPartNumber types.String `tfsdk:"sku_part_number"`
	ServicePlans  types.List   `tfsdk:"service_plans"`
}

LicenseDetailsResourceModel represents the current license assignment state (read-only)

type ServicePlanResourceModel

type ServicePlanResourceModel struct {
	ServicePlanId      types.String `tfsdk:"service_plan_id"`
	ServicePlanName    types.String `tfsdk:"service_plan_name"`
	ProvisioningStatus types.String `tfsdk:"provisioning_status"`
	AppliesTo          types.String `tfsdk:"applies_to"`
}

ServicePlanResourceModel represents individual service plans within a license

type UserLicenseAssignmentResource

type UserLicenseAssignmentResource struct {
	ProviderTypeName string
	TypeName         string
	ReadPermissions  []string
	WritePermissions []string
	ResourcePath     string
	// contains filtered or unexported fields
}

func (*UserLicenseAssignmentResource) Configure

Configure sets the client for the resource.

func (*UserLicenseAssignmentResource) Create

Create handles the creation of a user license assignment.

func (*UserLicenseAssignmentResource) Delete

Delete handles the deletion of a user license assignment (removes all managed licenses).

func (*UserLicenseAssignmentResource) FullTypeName

func (r *UserLicenseAssignmentResource) FullTypeName() string

FullTypeName returns the full resource type name in the format "providername_resourcename".

func (*UserLicenseAssignmentResource) ImportState

ImportState imports the resource state.

func (*UserLicenseAssignmentResource) Metadata

Metadata returns the resource type name.

func (*UserLicenseAssignmentResource) ModifyPlan

ModifyPlan handles plan modification for device health script assignments

func (*UserLicenseAssignmentResource) Read

Read retrieves the current state of a user's license assignments.

func (*UserLicenseAssignmentResource) Schema

Schema returns the schema for the resource.

func (*UserLicenseAssignmentResource) Update

Update handles updates to a user's license assignments.

type UserLicenseAssignmentResourceModel

type UserLicenseAssignmentResourceModel struct {
	ID                types.String                   `tfsdk:"id"`
	UserId            types.String                   `tfsdk:"user_id"`
	UserPrincipalName types.String                   `tfsdk:"user_principal_name"`
	AddLicenses       []AssignedLicenseResourceModel `tfsdk:"add_licenses"`
	RemoveLicenses    types.Set                      `tfsdk:"remove_licenses"`
	AssignedLicenses  types.List                     `tfsdk:"assigned_licenses"`
	Timeouts          timeouts.Value                 `tfsdk:"timeouts"`
}

UserLicenseAssignmentResourceModel represents the Terraform resource model for user license assignment

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL