Create depOnboardingSetting

Important: APIs under the /beta version in Microsoft Graph are in preview and are subject to change. Use of these APIs in production applications is not supported.

Note: Using the Microsoft Graph APIs to configure Intune controls and policies still requires that the Intune service is correctly licensed by the customer.

Create a new depOnboardingSetting object.

Prerequisites

One of the following permission scopes is required to execute this API:

DeviceManagementServiceConfig.ReadWrite.All

HTTP Request

POST /organization/{organizationId}/depOnboardingSettings

Request headers

Header Value
Authorization Bearer <token> Required.
Accept application/json

Request body

In the request body, supply a JSON representation of a depOnboardingSetting object. The following table shows the properties that are required when you create a depOnboardingSetting.

Property Type Description
id String UUID for the object
appleIdentifier String The Apple ID used to obtain the current token.
tokenExpirationDateTime DateTimeOffset When the token will expire.
lastModifiedDateTime DateTimeOffset When the service was onboarded.
lastSuccessfulSyncDateTime DateTimeOffset When the service last syned with Intune
lastSyncTriggeredDateTime DateTimeOffset When Intune last requested a sync.
shareTokenWithSchoolDataSyncService Boolean Whether or not the Dep token sharing is enabled with the School Data Sync service.
lastSyncErrorCode Int32 Error code reported by Apple during last dep sync.

Response

If successful, this method returns a 201 Created response code and a depOnboardingSetting object in the response body.

Example

Request

Here is an example of the request.

POST https://graph.microsoft.com/beta/organization/{organizationId}/depOnboardingSettings
Content-type: application/json
Content-length: 454

{
  "@odata.type": "#microsoft.graph.depOnboardingSetting",
  "appleIdentifier": "Apple Identifier value",
  "tokenExpirationDateTime": "2016-12-31T23:59:54.0590989-08:00",
  "lastModifiedDateTime": "2017-01-01T00:00:35.1329464-08:00",
  "lastSuccessfulSyncDateTime": "2017-01-01T00:03:28.120883-08:00",
  "lastSyncTriggeredDateTime": "2017-01-01T00:00:02.0916369-08:00",
  "shareTokenWithSchoolDataSyncService": true,
  "lastSyncErrorCode": 1
}

Response

Here is an example of the response. Note: The response object shown here may be truncated for brevity. All of the properties will be returned from an actual call.

HTTP/1.1 201 Created
Content-Type: application/json
Content-Length: 503

{
  "@odata.type": "#microsoft.graph.depOnboardingSetting",
  "id": "40342229-2229-4034-2922-344029223440",
  "appleIdentifier": "Apple Identifier value",
  "tokenExpirationDateTime": "2016-12-31T23:59:54.0590989-08:00",
  "lastModifiedDateTime": "2017-01-01T00:00:35.1329464-08:00",
  "lastSuccessfulSyncDateTime": "2017-01-01T00:03:28.120883-08:00",
  "lastSyncTriggeredDateTime": "2017-01-01T00:00:02.0916369-08:00",
  "shareTokenWithSchoolDataSyncService": true,
  "lastSyncErrorCode": 1
}