Microsoft Azure Session Host Management API

The SessionHostManagement API from Microsoft Azure, for sessionhostmanagement.

GitHub OpenAPI

Operations 4

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

PUT /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/hostPools/{hostPoolName}/sessionHostManagements/default Configure session host management for a host pool · Microsoft Azure Put Subscriptions Subscriptionid Resourcegroups… #
Ask an LLM
“How do I set up session host management settings for an Azure Virtual Desktop host pool?”
“Can I replace a host pool's session host management configuration?”
Tell an agent
Create the session host management configuration for host pool {hostPoolName}.
Replace session host management settings on {hostPoolName} with {properties}.
PATCH /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/hostPools/{hostPoolName}/sessionHostManagements/default Update session host management for a host pool · Microsoft Azure Patch Subscriptions Subscriptionid Resourcegroups… #
Ask an LLM
“Can I change only some session host management settings on a host pool?”
“Is partial update supported for a host pool's session host management?”
Tell an agent
Patch the session host management settings for host pool {hostPoolName}.
Tweak session host management properties on {hostPoolName}.
POST /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/hostPools/{hostPoolName}/sessionHostManagements/default/initiateSessionHostUpdate Start or schedule a host pool session host update · Microsoft Azure Post Subscriptions Subscriptionid Resourcegroups… #
Ask an LLM
“Can I schedule an Azure Virtual Desktop host pool update for later?”
“Which time zone does a scheduled session host update use?”
Tell an agent
Start a session host update on host pool {hostPoolName} now.
Schedule a session host update for {hostPoolName} at {scheduledDateTime} in time zone {scheduledDateTimeZone}.
POST /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/hostPools/{hostPoolName}/sessionHostManagements/default/controlSessionHostUpdate Pause, resume or cancel a host pool update · Microsoft Azure Post Subscriptions Subscriptionid Resourcegroups… #
Ask an LLM
“Can I pause or cancel a session host update that is in progress?”
“Is there a way to leave a message for users when I cancel a host pool update?”
Tell an agent
Apply action {action} to the running update on host pool {hostPoolName}.
Cancel the host pool update on {hostPoolName} with message {cancelMessage}.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/microsoft-azure:microsoft-azure-sessionhostmanagement-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

microsoft-azure-sessionhostmanagement-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: 2023-11-01-preview
  title: Microsoft Azure Desktop Virtualization API Client Session…
servers:
- url: https://management.azure.com
tags:
- name: SessionHostManagement
paths:
  ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/hostPools/{hostPoolName}/sessionHostManagements/default
  : put:
      tags:
      - SessionHostManagement
      operationId: microsoftAzureSessionhostmanagementsCreateorupdate
      description: Create or update a SessionHostManagement.
      x-ms-examples:
        SessionHostManagements_Create:
          $ref: ./examples/SessionHostManagements_Create.json
      parameters:
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter
      - $ref: '#/components/parameters/HostPoolNameParameter'
      responses:
        '200':
          description: Successfully updated SessionHostManagement.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SessionHostManagement'
        '201':
          description: Successfully created SessionHostManagement.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SessionHostManagement'
        default:
          description: Automation error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CloudError'
      summary: Microsoft Azure Put Subscriptions Subscriptionid Resourcegroups…
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SessionHostManagement'
        description: Object containing SessionHostManagement definitions.
        required: true
    patch:
      tags:
      - SessionHostManagement
      operationId: microsoftAzureSessionhostmanagementsUpdate
      description: Update a SessionHostManagement.
      x-ms-examples:
        SessionHostManagements_Update:
          $ref: ./examples/SessionHostManagements_Update.json
      parameters:
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter
      - $ref: '#/components/parameters/HostPoolNameParameter'
      responses:
        '200':
          description: Update SessionHostManagement success.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SessionHostManagement'
        default:
          description: Automation error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CloudError'
      summary: Microsoft Azure Patch Subscriptions Subscriptionid Resourcegroups…
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SessionHostManagementPatch'
        description: Object containing SessionHostManagement definitions.
  ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/hostPools/{hostPoolName}/sessionHostManagements/default/initiateSessionHostUpdate
  : post:
      tags:
      - SessionHostManagement
      operationId: microsoftAzureInitiatesessionhostupdatePost
      description: Initiates a hostpool update or schedule an update for the future.
      x-ms-examples:
        HostPools_Update_Post:
          $ref: ./examples/SessionHostManagements_UpdateSessionHosts_Post.json
      parameters:
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter
      - $ref: '#/components/parameters/HostPoolNameParameter'
      responses:
        '202':
          description: Successfully initiated hostpool update.
          headers:
            Location:
              description: The URL of the resource used to check the status of the asynchronous operation.
              schema:
                type: string
            Azure-AsyncOperation:
              description: The URL of the resource used to check the status of the asynchronous operation.
              schema:
                type: string
            Retry-After:
              description: Suggested delay to check the status of the asynchronous operation. The value is an integer that represents the seconds.
              schema:
                type: integer
                format: int32
        default:
          description: Automation error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: ../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse
      x-ms-long-running-operation: true
      x-ms-long-running-operation-options:
        final-state-via: location
      summary: Microsoft Azure Post Subscriptions Subscriptionid Resourcegroups…
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateSessionHostsRequestBody'
        description: Object containing the definition for properties to be used in the sessionHostUpdate validation.
  ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DesktopVirtualization/hostPools/{hostPoolName}/sessionHostManagements/default/controlSessionHostUpdate
  : post:
      tags:
      - SessionHostManagement
      operationId: microsoftAzureControlsessionhostupdatePost
      description: Control update of a hostpool.
      x-ms-examples:
        SessionHostManagements_ControlUpdate_Post:
          $ref: ./examples/SessionHostManagements_ControlSessionHostUpdate_Post.json
      parameters:
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter
      - $ref: ../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter
      - $ref: '#/components/parameters/HostPoolNameParameter'
      responses:
        '202':
          description: Successfully controlled hostpool update.
          headers:
            Location:
              description: The URL of the resource used to check the status of the asynchronous operation.
              schema:
                type: string
            Azure-AsyncOperation:
              description: The URL of the resource used to check the status of the asynchronous operation.
              schema:
                type: string
            Retry-After:
              description: Suggested delay to check the status of the asynchronous operation. The value is an integer that represents the seconds.
              schema:
                type: integer
                format: int32
        default:
          description: Automation error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: ../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse
      x-ms-long-running-operation: true
      x-ms-long-running-operation-options:
        final-state-via: location
      summary: Microsoft Azure Post Subscriptions Subscriptionid Resourcegroups…
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/HostPoolControlParameter'
        description: Object containing control action for hostpool update.
        required: true
components:
  schemas:
    SessionHostManagementPatch:
      type: object
      description: Represents a SessionHostManagementPatch definition.
      properties:
        systemData:
          $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/systemData
          description: Metadata pertaining to creation and last modification of the resource.
        properties:
          description: Detailed properties for SessionHostManagementPatch
          x-ms-client-flatten: true
          $ref: '#/components/schemas/SessionHostManagementPatchProperties'
    CloudErrorProperties:
      description: Cloud error object properties.
      type: object
      properties:
        code:
          description: Error code
          type: string
        message:
          description: Error message indicating why the operation failed.
          type: string
    SessionHostManagementProperties:
      description: Session host Managements of HostPool.
      type: object
      required:
      - scheduledDateTimeZone
      - update
      properties:
        scheduledDateTimeZone:
          type: string
          description: Time zone for sessionHostManagement operations as defined in https://docs.microsoft.com/dotnet/api/system.timezoneinfo.findsystemtimezonebyid. Must be set if useLocalTime is true.
        update:
          $ref: '#/components/schemas/HostPoolUpdateConfigurationProperties'
          description: Parameters for a hostpool update.
    SessionHostManagement:
      type: object
      description: Represents a SessionHostManagement definition.
      allOf:
      - $ref: ../../../../../common-types/resource-management/v1/types.json#/definitions/ProxyResource
      required:
      - properties
      properties:
        systemData:
          $ref: ../../../../../common-types/resource-management/v2/types.json#/definitions/systemData
          description: Metadata pertaining to creation and last modification of the resource.
        properties:
          description: Detailed properties for SessionHostManagement
          x-ms-client-flatten: true
          $ref: '#/components/schemas/SessionHostManagementProperties'
    CloudError:
      description: Cloud error object.
      type: object
      x-ms-external: true
      properties:
        error:
          $ref: '#/components/schemas/CloudErrorProperties'
    UpdateSessionHostsRequestBody:
      description: Object containing the definition for properties to be used for a sessionHostUpdate operation.
      type: object
      properties:
        scheduledDateTime:
          type: string
          format: date-time
          description: The timestamp that the update validation is scheduled for. If none is provided, the update will be executed immediately
        scheduledDateTimeZone:
          type: string
          description: The timeZone as defined in https://docs.microsoft.com/dotnet/api/system.timezoneinfo.findsystemtimezonebyid.
        update:
          description: settings for management information for the hostpool update operation. If none is provided the update will use the settings saved in the sessionHostManagement object.
          $ref: '#/components/schemas/HostPoolUpdateConfigurationPatchProperties'
    HostPoolUpdateConfigurationProperties:
      description: The configurations of a hostpool update.
      type: object
      required:
      - maxVmsRemoved
      - logOffDelayMinutes
      properties:
        deleteOriginalVm:
          type: boolean
          description: Whether not to save original disk. False by default.
        maxVmsRemoved:
          type: integer
          format: int32
          description: The maximum number of virtual machines to be removed during hostpool update.
          minimum: 1
        logOffDelayMinutes:
          type: integer
          format: int32
          description: Grace period before logging off users in minutes.
        logOffMessage:
          type: string
          description: Log off message sent to user for logoff. Default value is an empty string.
          maxLength: 260
          default: ''
    HostPoolControlParameter:
      description: Represents properties for a hostpool update.
      type: object
      required:
      - action
      properties:
        action:
          enum:
          - Start
          - Pause
          - Cancel
          - Retry
          - Resume
          x-ms-enum:
            name: HostPoolUpdateAction
            modelAsString: true
            values:
            - value: Start
              description: Start the hostpool update.
            - value: Pause
              description: Pause the hostpool update.
            - value: Cancel
              description: Cancel the hostpool update.
            - value: Retry
              description: Retry the hostpool update.
            - value: Resume
              description: Resume the hostpool update.
          type: string
          description: Action types for controlling hostpool update.
        cancelMessage:
          type: string
          description: The cancel message sent to the user on the session host. This is can only be specified if the action is 'Cancel'.
          maxLength: 260
    HostPoolUpdateConfigurationPatchProperties:
      description: The configurations of a hostpool update.
      type: object
      properties:
        deleteOriginalVm:
          type: boolean
          description: Whether not to save original disk. False by default.
        maxVmsRemoved:
          type: integer
          format: int32
          description: The maximum number of virtual machines to be removed during hostpool update.
          minimum: 1
        logOffDelayMinutes:
          type: integer
          format: int32
          description: Grace period before logging off users in minutes.
        logOffMessage:
          type: string
          description: Log off message sent to user for logoff.
          maxLength: 260
    SessionHostManagementPatchProperties:
      description: Session host Managements of HostPool.
      type: object
      properties:
        scheduledDateTimeZone:
          type: string
          description: Time zone for sessionHostManagement operations as defined in https://docs.microsoft.com/dotnet/api/system.timezoneinfo.findsystemtimezonebyid. Must be set if useLocalTime is true.
        update:
          $ref: '#/components/schemas/HostPoolUpdateConfigurationPatchProperties'
          description: Parameters for a hostpool update.
  parameters:
    HostPoolNameParameter:
      name: hostPoolName
      in: path
      required: true
      description: The name of the host pool within the specified resource group
      x-ms-parameter-location: method
      schema:
        type: string
        maxLength: 64
        minLength: 3
  securitySchemes:
    azure_auth:
      type: oauth2
      flows:
        implicit:
          scopes:
            user_impersonation: impersonate your user account
          authorizationUrl: https://login.microsoftonline.com/common/oauth2/authorize
      description: Azure Active Directory OAuth2 Flow