Update Customer Consent

Updates the status of a customerʼs consent to allow data collection by cookies and scripts while shopping on a storefront.

Authentication

X-Auth-Tokenstring
### OAuth scopes | UI Name | Permission | Parameter | |:--------|:-----------|:----------| | Customers | modify | `store_v2_customers` | | Customers | read-only | `store_v2_customers_read_only` | | Stored Payment Instruments | modify | `store_stored_payment_instruments` | | Stored Payment Instruments | read-only | `store_stored_payment_instruments_read_only` | ### Authentication header | Header | Argument | Description | |:-------|:---------|:------------| | `X-Auth-Token` | `access_token` | For more about API accounts that generate `access_token`s, see our [Guide to API Accounts](/developer/docs/overview/api-fundamentals/api-accounts#api-accounts). | ### Further reading For example requests and more information about authenticating BigCommerce APIs, see [Authentication and Example Requests](/developer/docs/overview/api-fundamentals/api-accounts#x-auth-token-header-example-requests). For more about BigCommerce OAuth scopes, see our [Guide to API Accounts](/developer/docs/overview/api-fundamentals/api-accounts#oauth-scopes). For a list of API status codes, see [API Status Codes](/developer/api-reference/rest/overview#rest-http-status-codes).

Path parameters

customerIdintegerRequired
The ID of the customer.
store_hashstringRequired
Permanent ID of the BigCommerce store.

Request

This endpoint expects an object.
allowlist of enumsOptional
denylist of enumsOptional

Response

allowlist of enums
denylist of enums
updated_atdatetime

The date of which the customer consent was last updated.

NOTE

Currently, this field returns the time of the current API Call, not the time of last update. For PUT requests, this is typically accurate; however, it will not be accurate for GET requests.

Errors

401
Unauthorized Error
403
Forbidden Error
422
Unprocessable Entity Error