Scaling Plans - Create

Create or update a scaling plan.

PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/scalingPlans/{scalingPlanName}?api-version=2026-04-16

URI Parameters

Name In Required Type Description
resourceGroupName
path True

string

minLength: 1
maxLength: 90

The name of the resource group. The name is case insensitive.

scalingPlanName
path True

string

minLength: 3
maxLength: 64
pattern: ^[A-Za-z0-9@.\-_ ]*$

The name of the scaling plan.

subscriptionId
path True

string (uuid)

The ID of the target subscription. The value must be an UUID.

api-version
query True

string

minLength: 1

The API version to use for this operation.

Request Body

Name Required Type Description
location True

string

The geo-location where the resource lives

properties.timeZone True

string

Timezone of the scaling plan.

identity

SystemAssignedServiceIdentity

The managed service identities assigned to this resource.

kind

string

pattern: ^[-\w\._,\(\)]+$

Metadata used by portal/tooling/etc to render different UX experiences for resources of the same type; e.g. ApiApps are a kind of Microsoft.Web/sites type. If supported, the resource provider must validate and persist this value.

managedBy

string

The fully qualified resource ID of the resource that manages this resource. Indicates if this resource is managed by another Azure resource. If this is present, complete mode deployment will not delete the resource if it is removed from the template since it is managed by another resource.

plan

Plan

Details of the resource plan.

properties.description

string

Description of scaling plan.

properties.exclusionTag

string

Exclusion tag for scaling plan.

properties.friendlyName

string

User friendly name of scaling plan.

properties.hostPoolReferences

ScalingHostPoolReference[]

List of ScalingHostPoolReference definitions.

properties.hostPoolType

ScalingHostPoolType

HostPool type for desktop.

properties.schedules

ScalingSchedule[]

List of ScalingPlanPooledSchedule definitions.

sku

Sku

The SKU (Stock Keeping Unit) assigned to this resource.

tags

object

Resource tags.

Responses

Name Type Description
200 OK

ScalingPlan

Resource 'ScalingPlan' update operation succeeded

201 Created

ScalingPlan

Resource 'ScalingPlan' create operation succeeded

Other Status Codes

ErrorResponse

An unexpected error response.

Security

azure_auth

Azure Active Directory OAuth2 Flow.

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

ScalingPlans_Create

Sample request

PUT https://management.azure.com/subscriptions/daefabc0-95b4-48b3-b645-8a753a63c4fa/resourceGroups/resourceGroup1/providers/Microsoft.DesktopVirtualization/scalingPlans/scalingPlan1?api-version=2026-04-16

{
  "location": "centralus",
  "tags": {
    "tag1": "value1",
    "tag2": "value2"
  },
  "properties": {
    "description": "Description of Scaling Plan",
    "friendlyName": "Scaling Plan 1",
    "timeZone": "Central Standard Time",
    "hostPoolType": "Pooled",
    "exclusionTag": "value",
    "schedules": [
      {
        "name": "schedule1",
        "daysOfWeek": [
          "Monday",
          "Tuesday",
          "Wednesday",
          "Thursday",
          "Friday"
        ],
        "rampUpStartTime": {
          "hour": 6,
          "minute": 0
        },
        "rampUpLoadBalancingAlgorithm": "DepthFirst",
        "rampUpMinimumHostsPct": 20,
        "rampUpCapacityThresholdPct": 80,
        "peakStartTime": {
          "hour": 8,
          "minute": 0
        },
        "peakLoadBalancingAlgorithm": "BreadthFirst",
        "rampDownStartTime": {
          "hour": 18,
          "minute": 0
        },
        "rampDownLoadBalancingAlgorithm": "DepthFirst",
        "rampDownMinimumHostsPct": 20,
        "rampDownCapacityThresholdPct": 50,
        "rampDownForceLogoffUsers": true,
        "rampDownWaitTimeMinutes": 30,
        "rampDownNotificationMessage": "message",
        "offPeakStartTime": {
          "hour": 20,
          "minute": 0
        },
        "offPeakLoadBalancingAlgorithm": "DepthFirst"
      }
    ],
    "hostPoolReferences": [
      {
        "hostPoolArmPath": "/subscriptions/daefabc0-95b4-48b3-b645-8a753a63c4fa/resourceGroups/resourceGroup1/providers/Microsoft.DesktopVirtualization/hostPools/hostPool1",
        "scalingPlanEnabled": true
      }
    ]
  }
}

Sample response

{
  "name": "scalingPlan1",
  "id": "/subscriptions/daefabc0-95b4-48b3-b645-8a753a63c4fa/resourceGroups/resourceGroup1/providers/Microsoft.DesktopVirtualization/scalingPlans/scalingPlan1",
  "type": "Microsoft.DesktopVirtualization/scalingPlans",
  "location": "centralus",
  "tags": {
    "key1": "value1",
    "key2": "value2"
  },
  "systemData": {
    "createdBy": "user1",
    "createdByType": "User",
    "createdAt": "2020-01-01T17:18:19.1234567Z",
    "lastModifiedBy": "user2",
    "lastModifiedByType": "User",
    "lastModifiedAt": "2020-01-02T17:18:19.1234567Z"
  },
  "properties": {
    "objectId": "00000000-0000-0000-0000-000000000000",
    "description": "Description of Scaling Plan",
    "friendlyName": "Scaling Plan 1",
    "timeZone": "Central Standard Time",
    "hostPoolType": "Pooled",
    "exclusionTag": "value",
    "schedules": [
      {
        "name": "schedule1",
        "daysOfWeek": [
          "Monday",
          "Tuesday",
          "Wednesday",
          "Thursday",
          "Friday"
        ],
        "rampUpStartTime": {
          "hour": 6,
          "minute": 0
        },
        "rampUpLoadBalancingAlgorithm": "DepthFirst",
        "rampUpMinimumHostsPct": 20,
        "rampUpCapacityThresholdPct": 80,
        "peakStartTime": {
          "hour": 8,
          "minute": 0
        },
        "peakLoadBalancingAlgorithm": "BreadthFirst",
        "rampDownStartTime": {
          "hour": 18,
          "minute": 0
        },
        "rampDownLoadBalancingAlgorithm": "DepthFirst",
        "rampDownMinimumHostsPct": 20,
        "rampDownCapacityThresholdPct": 50,
        "rampDownForceLogoffUsers": true,
        "rampDownWaitTimeMinutes": 30,
        "rampDownNotificationMessage": "message",
        "offPeakStartTime": {
          "hour": 20,
          "minute": 0
        },
        "offPeakLoadBalancingAlgorithm": "DepthFirst"
      }
    ],
    "hostPoolReferences": [
      {
        "hostPoolArmPath": "/subscriptions/daefabc0-95b4-48b3-b645-8a753a63c4fa/resourceGroups/resourceGroup1/providers/Microsoft.DesktopVirtualization/hostPools/hostPool1",
        "scalingPlanEnabled": true
      }
    ]
  }
}
{
  "name": "scalingPlan1",
  "id": "/subscriptions/daefabc0-95b4-48b3-b645-8a753a63c4fa/resourceGroups/resourceGroup1/providers/Microsoft.DesktopVirtualization/scalingPlans/scalingPlan1",
  "type": "Microsoft.DesktopVirtualization/scalingPlans",
  "location": "centralus",
  "tags": {
    "key1": "value1",
    "key2": "value2"
  },
  "systemData": {
    "createdBy": "user1",
    "createdByType": "User",
    "createdAt": "2020-01-01T17:18:19.1234567Z",
    "lastModifiedBy": "user2",
    "lastModifiedByType": "User",
    "lastModifiedAt": "2020-01-02T17:18:19.1234567Z"
  },
  "properties": {
    "objectId": "00000000-0000-0000-0000-000000000000",
    "description": "Description of Scaling Plan",
    "friendlyName": "Scaling Plan 1",
    "timeZone": "Central Standard Time",
    "hostPoolType": "Pooled",
    "exclusionTag": "value",
    "schedules": [
      {
        "name": "schedule1",
        "daysOfWeek": [
          "Monday",
          "Tuesday",
          "Wednesday",
          "Thursday",
          "Friday"
        ],
        "rampUpStartTime": {
          "hour": 6,
          "minute": 0
        },
        "rampUpLoadBalancingAlgorithm": "DepthFirst",
        "rampUpMinimumHostsPct": 20,
        "rampUpCapacityThresholdPct": 80,
        "peakStartTime": {
          "hour": 8,
          "minute": 0
        },
        "peakLoadBalancingAlgorithm": "BreadthFirst",
        "rampDownStartTime": {
          "hour": 18,
          "minute": 0
        },
        "rampDownLoadBalancingAlgorithm": "DepthFirst",
        "rampDownMinimumHostsPct": 20,
        "rampDownCapacityThresholdPct": 50,
        "rampDownForceLogoffUsers": true,
        "rampDownWaitTimeMinutes": 30,
        "rampDownNotificationMessage": "message",
        "offPeakStartTime": {
          "hour": 20,
          "minute": 0
        },
        "offPeakLoadBalancingAlgorithm": "DepthFirst"
      }
    ],
    "hostPoolReferences": [
      {
        "hostPoolArmPath": "/subscriptions/daefabc0-95b4-48b3-b645-8a753a63c4fa/resourceGroups/resourceGroup1/providers/Microsoft.DesktopVirtualization/hostPools/hostPool1",
        "scalingPlanEnabled": true
      }
    ]
  }
}

Definitions

Name Description
createdByType

The type of identity that created the resource.

DayOfWeek

Day of the week. Modeled as string

ErrorAdditionalInfo

The resource management error additional info.

ErrorDetail

The error detail.

ErrorResponse

Error response

Plan

Plan for the resource.

ScalingHostPoolReference

Scaling plan reference to hostpool.

ScalingHostPoolType

HostPool type for desktop.

ScalingPlan

Represents a scaling plan definition.

ScalingSchedule

A ScalingPlanPooledSchedule.

SessionHostLoadBalancingAlgorithm

Load balancing algorithm for ramp up period.

Sku

The resource model definition representing SKU

SkuTier

This field is required to be implemented by the Resource Provider if the service has more than one tier, but is not required on a PUT.

StopHostsWhen

Specifies when to stop hosts during ramp down period.

SystemAssignedServiceIdentity

Managed service identity (either system assigned, or none)

SystemAssignedServiceIdentityType

Type of managed service identity (either system assigned, or none).

systemData

Metadata pertaining to creation and last modification of the resource.

Time

The time for a scaling action to occur.

createdByType

The type of identity that created the resource.

Value Description
User
Application
ManagedIdentity
Key

DayOfWeek

Day of the week. Modeled as string

Value Description
Monday
Tuesday
Wednesday
Thursday
Friday
Saturday
Sunday

ErrorAdditionalInfo

The resource management error additional info.

Name Type Description
info

object

The additional info.

type

string

The additional info type.

ErrorDetail

The error detail.

Name Type Description
additionalInfo

ErrorAdditionalInfo[]

The error additional info.

code

string

The error code.

details

ErrorDetail[]

The error details.

message

string

The error message.

target

string

The error target.

ErrorResponse

Error response

Name Type Description
error

ErrorDetail

The error object.

Plan

Plan for the resource.

Name Type Description
name

string

A user defined name of the 3rd Party Artifact that is being procured.

product

string

The 3rd Party artifact that is being procured. E.g. NewRelic. Product maps to the OfferID specified for the artifact at the time of Data Market onboarding.

promotionCode

string

A publisher provided promotion code as provisioned in Data Market for the said product/artifact.

publisher

string

The publisher of the 3rd Party Artifact that is being bought. E.g. NewRelic

version

string

The version of the desired product/artifact.

ScalingHostPoolReference

Scaling plan reference to hostpool.

Name Type Description
hostPoolArmPath

string

Arm path of referenced hostpool.

scalingPlanEnabled

boolean

Is the scaling plan enabled for this hostpool.

ScalingHostPoolType

HostPool type for desktop.

Value Description
Pooled

Users get a new (random) SessionHost every time it connects to the HostPool.

Personal

Users will be assigned a SessionHost either by administrators (PersonalDesktopAssignmentType = Direct) or upon connecting to the pool (PersonalDesktopAssignmentType = Automatic). They will always be redirected to their assigned SessionHost.

ScalingPlan

Represents a scaling plan definition.

Name Type Default value Description
etag

string

If etag is provided in the response body, it may also be provided as a header per the normal etag convention. Entity tags are used for comparing two or more entities from the same requested resource. HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range (section 14.27) header fields.

id

string (arm-id)

Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"

identity

SystemAssignedServiceIdentity

The managed service identities assigned to this resource.

kind

string

pattern: ^[-\w\._,\(\)]+$

Metadata used by portal/tooling/etc to render different UX experiences for resources of the same type; e.g. ApiApps are a kind of Microsoft.Web/sites type. If supported, the resource provider must validate and persist this value.

location

string

The geo-location where the resource lives

managedBy

string

The fully qualified resource ID of the resource that manages this resource. Indicates if this resource is managed by another Azure resource. If this is present, complete mode deployment will not delete the resource if it is removed from the template since it is managed by another resource.

name

string

The name of the resource

plan

Plan

Details of the resource plan.

properties.description

string

Description of scaling plan.

properties.exclusionTag

string

Exclusion tag for scaling plan.

properties.friendlyName

string

User friendly name of scaling plan.

properties.hostPoolReferences

ScalingHostPoolReference[]

List of ScalingHostPoolReference definitions.

properties.hostPoolType

ScalingHostPoolType

Pooled

HostPool type for desktop.

properties.objectId

string

ObjectId of scaling plan. (internal use)

properties.schedules

ScalingSchedule[]

List of ScalingPlanPooledSchedule definitions.

properties.timeZone

string

Timezone of the scaling plan.

sku

Sku

The SKU (Stock Keeping Unit) assigned to this resource.

systemData

systemData

Azure Resource Manager metadata containing createdBy and modifiedBy information.

tags

object

Resource tags.

type

string

The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"

ScalingSchedule

A ScalingPlanPooledSchedule.

Name Type Description
daysOfWeek

DayOfWeek[]

Set of days of the week on which this schedule is active.

name

string

Name of the ScalingPlanPooledSchedule.

offPeakLoadBalancingAlgorithm

SessionHostLoadBalancingAlgorithm

Load balancing algorithm for off-peak period.

offPeakStartTime

Time

Starting time for off-peak period.

peakLoadBalancingAlgorithm

SessionHostLoadBalancingAlgorithm

Load balancing algorithm for peak period.

peakStartTime

Time

Starting time for peak period.

rampDownCapacityThresholdPct

integer (int32)

minimum: 1
maximum: 100

Capacity threshold for ramp down period.

rampDownForceLogoffUsers

boolean

Should users be logged off forcefully from hosts.

rampDownLoadBalancingAlgorithm

SessionHostLoadBalancingAlgorithm

Load balancing algorithm for ramp down period.

rampDownMinimumHostsPct

integer (int32)

minimum: 0
maximum: 100

Minimum host percentage for ramp down period.

rampDownNotificationMessage

string

Notification message for users during ramp down period.

rampDownStartTime

Time

Starting time for ramp down period.

rampDownStopHostsWhen

StopHostsWhen

Specifies when to stop hosts during ramp down period.

rampDownWaitTimeMinutes

integer (int32)

Number of minutes to wait to stop hosts during ramp down period.

rampUpCapacityThresholdPct

integer (int32)

minimum: 1
maximum: 100

Capacity threshold for ramp up period.

rampUpLoadBalancingAlgorithm

SessionHostLoadBalancingAlgorithm

Load balancing algorithm for ramp up period.

rampUpMinimumHostsPct

integer (int32)

minimum: 0
maximum: 100

Minimum host percentage for ramp up period.

rampUpStartTime

Time

Starting time for ramp up period.

SessionHostLoadBalancingAlgorithm

Load balancing algorithm for ramp up period.

Value Description
BreadthFirst

Breadth First Algorithm for Load Balancing

DepthFirst

Depth First Algorithm for Load Balancing

Sku

The resource model definition representing SKU

Name Type Description
capacity

integer (int32)

If the SKU supports scale out/in then the capacity integer should be included. If scale out/in is not possible for the resource this may be omitted.

family

string

If the service has different generations of hardware, for the same SKU, then that can be captured here.

name

string

The name of the SKU. E.g. P3. It is typically a letter+number code

size

string

The SKU size. When the name field is the combination of tier and some other value, this would be the standalone code.

tier

SkuTier

This field is required to be implemented by the Resource Provider if the service has more than one tier, but is not required on a PUT.

SkuTier

This field is required to be implemented by the Resource Provider if the service has more than one tier, but is not required on a PUT.

Value Description
Free
Basic
Standard
Premium

StopHostsWhen

Specifies when to stop hosts during ramp down period.

Value Description
ZeroSessions

Zero Total Sessions

ZeroActiveSessions

Zero Active Sessions

SystemAssignedServiceIdentity

Managed service identity (either system assigned, or none)

Name Type Description
principalId

string (uuid)

The service principal ID of the system assigned identity. This property will only be provided for a system assigned identity.

tenantId

string (uuid)

The tenant ID of the system assigned identity. This property will only be provided for a system assigned identity.

type

SystemAssignedServiceIdentityType

Type of managed service identity (either system assigned, or none).

SystemAssignedServiceIdentityType

Type of managed service identity (either system assigned, or none).

Value Description
None
SystemAssigned

systemData

Metadata pertaining to creation and last modification of the resource.

Name Type Description
createdAt

string (date-time)

The timestamp of resource creation (UTC).

createdBy

string

The identity that created the resource.

createdByType

createdByType

The type of identity that created the resource.

lastModifiedAt

string (date-time)

The timestamp of resource last modification (UTC)

lastModifiedBy

string

The identity that last modified the resource.

lastModifiedByType

createdByType

The type of identity that last modified the resource.

Time

The time for a scaling action to occur.

Name Type Description
hour

integer (int32)

minimum: 0
maximum: 23

The hour.

minute

integer (int32)

minimum: 0
maximum: 59

The minute.