user: activateServicePlan (deprecated)

Namespace: microsoft.graph

Important

APIs under the /beta version in Microsoft Graph are subject to change. Use of these APIs in production applications is not supported. To determine whether an API is available in v1.0, use the Version selector.

Caution

The activateServicePlan API is deprecated and will stop returning data on June 30, 2022.

Activate a service plan with a given servicePlanId and skuId for a given user.

Permissions

One of the following permissions is required to call this API. To learn more, including how to choose permissions, see Permissions.

Permission type Permissions (from most to least privileged)
Delegated (work or school account) Directory.ReadWrite.All
Delegated (personal Microsoft account) Not Supported.
Application Directory.ReadWrite.All

HTTP request

POST /users/{id | userPrincipalName}/activateServicePlan

Request headers

Name Description
Authorization Bearer {token}. Required.
Content-Type application/json. Required.

Request body

In the request body, provide a JSON object with the following parameter:

Parameter Type Description
servicePlanId Guid PlanId of the ServicePlan to activate.
skuId Guid SkuId of SKU the service plan is on.

Response

If successful, this action returns a 204 No Content response code.

Examples

Request

POST https://graph.microsoft.com/beta/me/activateServicePlan
Content-type: application/json

{
  "servicePlanId": "28f42d6f-8034-4a0f-9d8a-a218a63b3299",
  "skuId": "465a2a90-5e59-456d-a7b8-127b9fb2e484"
}

Response

HTTP/1.1 204 No Content