# Method: enterprises.policies.modifyPolicyApplications

- [HTTP request](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#body.HTTP_TEMPLATE)
- [Path parameters](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#body.PATH_PARAMETERS)
- [Request body](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#body.request_body)
  - [JSON representation](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#body.response_body)
  - [JSON representation](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#body.ModifyPolicyApplicationsResponse.SCHEMA_REPRESENTATION)
- [Authorization scopes](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#body.aspect)
- [ApplicationPolicyChange](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#ApplicationPolicyChange)
  - [JSON representation](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#ApplicationPolicyChange.SCHEMA_REPRESENTATION)
- [Try it!](https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#try-it)

Updates or creates applications in a policy.

### HTTP request

`POST https://androidmanagement.googleapis.com/v1/{name=enterprises/*/policies/*}:modifyPolicyApplications`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The name of the `https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#Policy` containing the `https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#ApplicationPolicy` objects to be updated, in the form `enterprises/{enterpriseId}/policies/{policyId}`. |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "changes": [ { object (`https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#ApplicationPolicyChange`) } ] } ``` |

| Fields ||
|---|---|
| `changes[]` | ``object (`https://developers.google.com/android/management/reference/rest/v1/enterprises.policies/modifyPolicyApplications#ApplicationPolicyChange`)`` Required. The changes to be made to the ApplicationPolicy objects. There must be at least one `ApplicationPolicyChange`. |

### Response body

Response to a request to update or create ApplicationPolicy objects in the given policy.

If successful, the response body contains data with the following structure:

| JSON representation |
|---|
| ``` { "policy": { object (`https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#Policy`) } } ``` |

| Fields ||
|---|---|
| `policy` | ``object (`https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#Policy`)`` The updated policy. |

### Authorization scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/androidmanagement`

For more information, see the [OAuth 2.0 Overview](https://developers.google.com/identity/protocols/OAuth2).

## ApplicationPolicyChange

A change to be made to a single ApplicationPolicy object.

| JSON representation |
|---|
| ``` { "application": { object (`https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#ApplicationPolicy`) }, "updateMask": string } ``` |

| Fields ||
|---|---|
| `application` | ``object (`https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#ApplicationPolicy`)`` If `https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#ApplicationPolicy.FIELDS.package_name` matches an existing ApplicationPolicy object within the `https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#Policy` being modified, then that object will be updated. Otherwise, it will be added to the end of the `https://developers.google.com/android/management/reference/rest/v1/enterprises.policies#Policy.FIELDS.applications`. |
| `updateMask` | ``string (`https://protobuf.dev/reference/protobuf/google.protobuf#field-mask` format)`` The field mask indicating the fields to update. If omitted, all modifiable fields are updated. This is a comma-separated list of fully qualified names of fields. Example: `"user.displayName,photo"`. |