Lab Plans - Get

Retrieves a Lab Plan resource.
Retrieves the properties of a Lab Plan.

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.LabServices/labPlans/{labPlanName}?api-version=2023-06-07

URI Parameters

Name In Required Type Description
labPlanName
path True

string

The name of the lab plan that uniquely identifies it within containing resource group. Used in resource URIs and in UI.

resourceGroupName
path True

string

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

subscriptionId
path True

string

The ID of the target subscription.

api-version
query True

string

The API version to use for this operation.

Responses

Name Type Description
200 OK

LabPlan

The request was successful; response contains the Lab Plan.

Other Status Codes

ErrorResponse

The default error response.

Examples

getLabPlan

Sample Request

GET https://management.azure.com/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.LabServices/labPlans/testlabplan?api-version=2023-06-07

Sample Response

{
  "id": "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.LabServices/labPlans/testlabplan",
  "name": "testlabplan",
  "type": "Microsoft.LabServices/LabPlan",
  "location": "westus",
  "systemData": {
    "createdBy": "identity123",
    "createdByType": "User",
    "createdAt": "2020-05-01T10:00:00Z",
    "lastModifiedBy": "identity123",
    "lastModifiedByType": "User",
    "lastModifiedAt": "2020-06-01T09:12:28Z"
  },
  "properties": {
    "provisioningState": "Succeeded",
    "defaultConnectionProfile": {
      "webSshAccess": "None",
      "webRdpAccess": "None",
      "clientSshAccess": "Public",
      "clientRdpAccess": "Public"
    },
    "defaultAutoShutdownProfile": {
      "shutdownOnDisconnect": "Enabled",
      "shutdownWhenNotConnected": "Enabled",
      "shutdownOnIdle": "UserAbsence",
      "disconnectDelay": "PT5M",
      "noConnectDelay": "PT5M",
      "idleDelay": "PT5M"
    },
    "defaultNetworkProfile": {
      "subnetId": "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Network/virtualNetworks/test-vnet/subnets/default"
    },
    "sharedGalleryId": "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourceGroups/testrg123/providers/Microsoft.Compute/galleries/testsig",
    "supportInfo": {
      "url": "help.contoso.com",
      "email": "help@contoso.com",
      "phone": "+1-202-555-0123",
      "instructions": "Contact support for help."
    }
  },
  "identity": {
    "type": "SystemAssigned",
    "principalId": "a799d834-d3c9-4554-ba5d-3771a995aa6a",
    "tenantId": "8c33e124-0581-45e0-84d4-f80d59de7806"
  }
}

Definitions

Name Description
AutoShutdownProfile

Profile for how to handle shutting down virtual machines.

ConnectionProfile

Connection profile for how users connect to lab virtual machines.

ConnectionType

The enabled access level for Web Access over SSH.

createdByType

The type of identity that created the resource.

EnableState

Whether shutdown on disconnect is enabled

ErrorAdditionalInfo

The resource management error additional info.

ErrorDetail

The error detail.

ErrorResponse

Error response

Identity

Identity for the resource.

LabPlan

Lab Plans act as a permission container for creating labs via labs.azure.com. Additionally, they can provide a set of default configurations that will apply at the time of creating a lab, but these defaults can still be overwritten.

LabPlanNetworkProfile

Profile for how to handle networking for Lab Plans.

ProvisioningState

Current provisioning state of the lab plan.

ResourceIdentityType

The identity type.

ResourceOperationError

Error details of the latest operation failure on this resource

shutdownOnIdleMode

Defines whether to shut down VM on idle and the criteria for idle detection.

SupportInfo

Support contact information and instructions.

systemData

Metadata pertaining to creation and last modification of the resource.

AutoShutdownProfile

Profile for how to handle shutting down virtual machines.

Name Type Default Value Description
disconnectDelay

string

The amount of time a VM will stay running after a user disconnects if this behavior is enabled.

idleDelay

string

The amount of time a VM will idle before it is shutdown if this behavior is enabled.

noConnectDelay

string

The amount of time a VM will stay running before it is shutdown if no connection is made and this behavior is enabled.

shutdownOnDisconnect

EnableState

Disabled

Whether shutdown on disconnect is enabled

shutdownOnIdle

shutdownOnIdleMode

None

Whether a VM will get shutdown when it has idled for a period of time.

shutdownWhenNotConnected

EnableState

Disabled

Whether a VM will get shutdown when it hasn't been connected to after a period of time.

ConnectionProfile

Connection profile for how users connect to lab virtual machines.

Name Type Default Value Description
clientRdpAccess

ConnectionType

None

The enabled access level for Client Access over RDP.

clientSshAccess

ConnectionType

None

The enabled access level for Client Access over SSH.

webRdpAccess

ConnectionType

None

The enabled access level for Web Access over RDP.

webSshAccess

ConnectionType

None

The enabled access level for Web Access over SSH.

ConnectionType

The enabled access level for Web Access over SSH.

Name Type Description
None

string

Private

string

Public

string

createdByType

The type of identity that created the resource.

Name Type Description
Application

string

Key

string

ManagedIdentity

string

User

string

EnableState

Whether shutdown on disconnect is enabled

Name Type Description
Disabled

string

Enabled

string

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.

Identity

Identity for the resource.

Name Type Description
principalId

string

The principal ID of resource identity.

tenantId

string

The tenant ID of resource.

type

ResourceIdentityType

The identity type.

LabPlan

Lab Plans act as a permission container for creating labs via labs.azure.com. Additionally, they can provide a set of default configurations that will apply at the time of creating a lab, but these defaults can still be overwritten.

Name Type Description
id

string

Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}

identity

Identity

Managed Identity Information

location

string

The geo-location where the resource lives

name

string

The name of the resource

properties.allowedRegions

string[]

The allowed regions for the lab creator to use when creating labs using this lab plan.

properties.defaultAutoShutdownProfile

AutoShutdownProfile

The default lab shutdown profile. This can be changed on a lab resource and only provides a default profile.

properties.defaultConnectionProfile

ConnectionProfile

The default lab connection profile. This can be changed on a lab resource and only provides a default profile.

properties.defaultNetworkProfile

LabPlanNetworkProfile

The lab plan network profile. To enforce lab network policies they must be defined here and cannot be changed when there are existing labs associated with this lab plan.

properties.linkedLmsInstance

string

Base Url of the lms instance this lab plan can link lab rosters against.

properties.provisioningState

ProvisioningState

Current provisioning state of the lab plan.

properties.resourceOperationError

ResourceOperationError

Error details of last operation done on lab plan.

properties.sharedGalleryId

string

Resource ID of the Shared Image Gallery attached to this lab plan. When saving a lab template virtual machine image it will be persisted in this gallery. Shared images from the gallery can be made available to use when creating new labs.

properties.supportInfo

SupportInfo

Support contact information and instructions for users of the lab plan. This information is displayed to lab owners and virtual machine users for all labs in the lab plan.

systemData

systemData

Metadata pertaining to creation and last modification of the lab plan.

tags

object

Resource tags.

type

string

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

LabPlanNetworkProfile

Profile for how to handle networking for Lab Plans.

Name Type Description
subnetId

string

The external subnet resource id

ProvisioningState

Current provisioning state of the lab plan.

Name Type Description
Creating

string

Resource is in the process of being created.

Deleting

string

Resource is in the process of being deleted.

Failed

string

Previous operation on the resource has failed leaving resource in unhealthy state.

Locked

string

The resource is locked and changes are currently blocked. This could be due to maintenance or a scheduled operation. The state will go back to succeeded once the locking operation has finished.

Succeeded

string

Resource is in healthy state after creation or update operation.

Updating

string

New property values are being applied to the resource.

ResourceIdentityType

The identity type.

Name Type Description
SystemAssigned

string

ResourceOperationError

Error details of the latest operation failure on this resource

Name Type Description
action

string

The operation action that failed

code

string

The code that corresponds to the type of operation failure

message

string

The operation failure message

timestamp

string

The datetime of when the error occured

shutdownOnIdleMode

Defines whether to shut down VM on idle and the criteria for idle detection.

Name Type Description
LowUsage

string

The VM will be considered as idle when user is absent and the resource (CPU and disk) consumption is low.

None

string

The VM won't be shut down when it is idle.

UserAbsence

string

The VM will be considered as idle when there is no keyboard or mouse input.

SupportInfo

Support contact information and instructions.

Name Type Description
email

string

Support contact email address.

instructions

string

Support instructions.

phone

string

Support contact phone number.

url

string

Support web address.

systemData

Metadata pertaining to creation and last modification of the resource.

Name Type Description
createdAt

string

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

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.