- [HTTP request](https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers/cancel#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers/cancel#body.PATH_PARAMETERS)
- [Request body](https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers/cancel#body.request_body)
  - [JSON representation](https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers/cancel#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers/cancel#body.response_body)
- [Authorization scopes](https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers/cancel#body.aspect)
- [IAM Permissions](https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers/cancel#body.aspect_1)

Cancels the target PrivateOffer.

### HTTP request

`POST https://commerceproducer.googleapis.com/v1beta/{name=projects/*/locations/*/privateOffers/*}:cancel`

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

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. Name of the resource |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "cancellationNote": string } ``` |

| Fields ||
|---|---|
| `cancellationNote` | `string` Optional. Internal note relating to the cancellation. Stored on the cancelled offer. Not visible to customers. |

### Response body

If successful, the response body contains an instance of `https://docs.cloud.google.com/marketplace/docs/partners/commerce-producer-api/reference/rest/v1beta/projects.locations.privateOffers#PrivateOffer`.

### Authorization scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/cloud-platform`

For more information, see the [Authentication Overview](https://docs.cloud.google.com/docs/authentication#authorization-gcp).

### IAM Permissions

Requires the following [IAM](https://cloud.google.com/iam/docs) permission on the `name` resource:

- `commerceproducer.privateOffers.cancel`

For more information, see the [IAM documentation](https://cloud.google.com/iam/docs).