Manages (inserts, updates, or removes) a customer's loyalty tier information.
This method serves as a single interface for all changes to a customer's loyalty status. The specific action (insert, update, or remove) is determined by the current state of the merchant-to-customer association and the loyaltyTier value provided in the request.
Operation Logic:
- Upsert (Insert/Update): Providing any valid tier other than
NON_MEMBERwill associate the customer with that tier. If an association already exists, it will be updated; otherwise, a new one will be created. - Removal: Setting
loyaltyTiertoNON_MEMBERwill remove any existing loyalty association for the customer.
Privacy Note: To protect user privacy, this method consistently returns a 200 OK status with a default LoyaltyCustomer response if the customer's identifier cannot be matched to a Google account or if the user has not opted into loyalty personalization.
HTTP request
POST https://merchantapi.googleapis.com/loyaltyCustomers/v1alpha/{parent=accounts/*}/loyaltyCustomers:manage
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
parent |
Required. The parent account where this loyalty customer will be handled. Format: |
Request body
The request body contains data with the following structure:
| JSON representation |
|---|
{
"loyaltyCustomer": {
object ( |
| Fields | |
|---|---|
loyaltyCustomer |
Required. The loyalty customer to insert, update, or remove. |
Response body
Response message for the loyaltyCustomers.manage method.
If successful, the response body contains data with the following structure:
| JSON representation |
|---|
{
"loyaltyCustomer": {
object ( |
| Fields | |
|---|---|
loyaltyCustomer |
The loyalty customer that was inserted, updated, or removed. If the customer's identifier cannot be matched to a Google account or if the user has not opted into loyalty personalization, this field will contain a default |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/content
For more information, see the OAuth 2.0 Overview.