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.
In the request body, supply the values for fields listed below that should be updated. Note: You cannot use PATCH operation for appliesTo with the other properties.
Property
Type
Description
appliesTo
policyScope
Determines the groups this policy setting applies to. Possible values are: none, all, selectedImportant:selected cannot be used when specifying this property. Use includedGroups to add specific groups.
complianceUrl
String
Compliance URL of the mobility management application
discoveryUrl
String
Discovery URL of the mobility management application
termsOfUseUrl
String
Terms of Use URL of the mobility management application
Response
If successful, this method returns a 200 OK response code and an updated mobilityManagementPolicy object in the response body.
// Code snippets are only available for the latest version. Current version is 5.x
var graphClient = new GraphServiceClient(requestAdapter);
var requestBody = new MobilityManagementPolicy
{
OdataType = "#microsoft.graph.mobilityManagementPolicy",
ComplianceUrl = "https://portal.mg.contoso.com/?portalAction=Compliance",
DiscoveryUrl = "https://enrollment.mg.contoso.com/enrollmentserver/discovery.svc",
TermsOfUseUrl = "https://portal.mg.contoso.com/TermsofUse.aspx",
};
var result = await graphClient.Policies.MobileAppManagementPolicies["{mobilityManagementPolicy-id}"].PatchAsync(requestBody);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// THE CLI IS IN PREVIEW. NON-PRODUCTION USE ONLY
mgc-beta policies mobile-app-management-policies patch --mobility-management-policy-id {mobilityManagementPolicy-id} --body '{\
"@odata.type": "#microsoft.graph.mobilityManagementPolicy",\
"complianceUrl": "https://portal.mg.contoso.com/?portalAction=Compliance",\
"discoveryUrl": "https://enrollment.mg.contoso.com/enrollmentserver/discovery.svc",\
"termsOfUseUrl": "https://portal.mg.contoso.com/TermsofUse.aspx"\
}\
'
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
<?php
// THIS SNIPPET IS A PREVIEW VERSION OF THE SDK. NON-PRODUCTION USE ONLY
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new MobilityManagementPolicy();
$requestBody->setOdataType('#microsoft.graph.mobilityManagementPolicy');
$requestBody->setComplianceUrl('https://portal.mg.contoso.com/?portalAction=Compliance');
$requestBody->setDiscoveryUrl('https://enrollment.mg.contoso.com/enrollmentserver/discovery.svc');
$requestBody->setTermsOfUseUrl('https://portal.mg.contoso.com/TermsofUse.aspx');
$result = $graphServiceClient->policies()->mobileAppManagementPolicies()->byMobilityManagementPolicyId('mobilityManagementPolicy-id')->patch($requestBody)->wait();
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
# THE PYTHON SDK IS IN PREVIEW. FOR NON-PRODUCTION USE ONLY
graph_client = GraphServiceClient(request_adapter)
request_body = MobilityManagementPolicy(
odata_type = "#microsoft.graph.mobilityManagementPolicy",
compliance_url = "https://portal.mg.contoso.com/?portalAction=Compliance",
discovery_url = "https://enrollment.mg.contoso.com/enrollmentserver/discovery.svc",
terms_of_use_url = "https://portal.mg.contoso.com/TermsofUse.aspx",
)
result = await graph_client.policies.mobile_app_management_policies.by_mobile_app_management_policie_id('mobilityManagementPolicy-id').patch(body = request_body)
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.