Google Retail
Sync product catalog data and user behavioral events to Google Cloud Retail (Vertex AI Search for Commerce). Power search results, personalized recommendations, and merchandising insights with enriched product and event data from your warehouse.
Prerequisites
- A Google Cloud project with the Retail API (Vertex AI Search for Commerce) enabled
- A catalog created in the Retail API (a
default_catalogis created automatically when the API is enabled) - A Google Cloud service account or OAuth credentials with the following IAM permissions:
retail.products.import(for product syncs)retail.userEvents.import(for user event syncs)retail.catalogs.get(for connection testing)
Authentication
Google OAuth 2.0
- In Zeotap, click Add Destination and select Google Retail
- Click Connect with Google
- Sign in with a Google account that has access to the target GCP project
- Grant the requested
cloud-platformscope - Zeotap securely stores the OAuth tokens and automatically refreshes them
Service Account Bearer Token
- In the Google Cloud Console , navigate to IAM & Admin > Service Accounts
- Create or select a service account with the required Retail API permissions
- Generate a bearer token using the Google Cloud CLI:
gcloud auth print-access-token --impersonate-service-account=SA_EMAIL - Paste the token into the Access Token field in Zeotap
Note: Service account bearer tokens expire after 1 hour. For production syncs, use OAuth 2.0 with a refresh token for automatic renewal.
Configuration
| Field | Type | Required | Description |
|---|---|---|---|
| GCP Project ID | Text | Yes | The Google Cloud project ID with the Retail API enabled |
| Location | Text | No | The Google Cloud location for the catalog. Defaults to global |
| Catalog ID | Text | No | The Retail API catalog identifier. Defaults to default_catalog |
| Branch ID | Text | No | The catalog branch for product data. Defaults to default_branch. Use numbered branches (0, 1, 2) for A/B testing |
Target Settings
| Field | Type | Required | Description |
|---|---|---|---|
| Object Type | Select | Yes | The type of data to sync: Products or User Events |
| Reconciliation Mode | Select | No | For products only. Incremental inserts or updates products; Full replaces the entire catalog branch. Defaults to Incremental |
Supported Operations
Sync Modes
| Mode | Supported |
|---|---|
| Upsert | Yes |
| Insert | Yes |
| Update | — |
| Mirror | — |
- Upsert uses the
INCREMENTALreconciliation mode, which inserts new products or updates existing ones matched by product ID. - Insert also uses
INCREMENTALmode — the Retail import API is idempotent, so inserting a product that already exists will update it.
Audience Sync Modes
| Mode | Supported |
|---|---|
| Add | — |
| Remove | — |
| Mirror | — |
| Upsert | — |
Google Retail does not have a list or audience membership concept. Use standard sync modes to send product and event data.
Features
- Field Mapping: Yes
- Schema Introspection: No
Required Mapping Fields
| Object | Required Fields |
|---|---|
| Products | id (unique product identifier) |
| User Events | id (used as visitor_id), or map both visitor_id and event_type |
Default Destination Fields
Product Fields
| Field | Type | Description |
|---|---|---|
id | string | Unique product identifier (max 128 characters) |
title | string | Product title (max 1,000 characters) |
description | string | Product description (max 5,000 characters) |
uri | string | Canonical URL to the product detail page |
categories | string | Product categories, pipe-separated for hierarchy (e.g., Electronics > Phones) |
brands | string | Brand names, comma-separated |
tags | string | Custom tags for filtering, comma-separated |
price | number | Current selling price |
original_price | number | Original price before discounts |
currency_code | string | ISO 4217 currency code (e.g., USD, EUR) |
availability | string | Stock status: IN_STOCK, OUT_OF_STOCK, PREORDER, or BACKORDER |
User Event Fields
| Field | Type | Description |
|---|---|---|
event_type | string | Event type: detail-page-view, add-to-cart, purchase-complete, search, home-page-view, category-page-view, shopping-cart-page-view |
visitor_id | string | Anonymous visitor identifier |
event_time | string | Event timestamp in RFC 3339 format |
product_id | string | Product ID for the event context (required for detail-page-view, add-to-cart, purchase-complete) |
search_query | string | Search query text (required for search events) |
revenue | number | Purchase revenue (required for purchase-complete events) |
user_id | string | Authenticated user ID (optional, for personalization) |
How It Works
-
Product Sync: Zeotap sends product data to the Retail API
products:importendpoint in batches of up to 100 products. The import operation runs asynchronously on Google’s side. In Incremental mode, existing products are updated by ID and new products are created. In Full mode, the entire catalog branch is replaced. -
User Event Sync: Zeotap sends behavioral events to the
userEvents:importendpoint in batches of up to 10,000 events. Events must include anevent_typeandvisitor_id. The Retail API uses these events to train recommendation models, improve search ranking, and power personalization. -
Authentication: Zeotap uses OAuth 2.0 bearer tokens with the
cloud-platformscope. Tokens are automatically refreshed before they expire. -
Error Handling: Each batch chunk is processed independently. Failed chunks are reported with the HTTP status and error message from the API. Transient errors (rate limits, server errors) are retried with exponential backoff.
Rate Limits
| Operation | Quota |
|---|---|
| Product write (UpdateProduct) | 12,000 requests/minute |
| Product import (batch) | Varies by project quota |
| User event write (single) | Standard API quota |
| User event import (batch) | Varies by project quota |
| Inventory updates (setInventory) | 300,000 requests/minute |
The batch import endpoints (products:import and userEvents:import) are the recommended approach for high-volume data sync and are subject to project-level quotas. Zeotap automatically handles rate limiting with exponential backoff.
Best Practices
- Use Incremental mode for regular product syncs to avoid replacing the entire catalog
- Include all required fields for events —
detail-page-viewandadd-to-cartevents must include aproduct_id;purchase-completeevents must includerevenue - Use consistent visitor IDs across all event types for accurate behavioral modeling
- Include at least 100 unique visitor IDs per event type for model training quality
- Upload events within 24 hours of occurrence for optimal recommendation freshness
- Map
currency_codewhen syncing products with pricing to ensure proper price display and filtering
Troubleshooting
Authentication failed: invalid or expired token
Verify your OAuth connection is active or regenerate the service account bearer token. Bearer tokens expire after 1 hour. For production use, connect with OAuth 2.0 which automatically refreshes tokens.
Catalog not found (404)
Verify the GCP Project ID and Catalog ID are correct. The Retail API must be enabled on the project. Check that the default catalog exists by visiting the Retail console .
Permission denied (403)
The authenticated account needs the following IAM roles:
roles/retail.editor(or specificretail.products.importandretail.userEvents.importpermissions)- Verify the service account or user has been granted access in IAM & Admin for the target project.
Product import fails with INVALID_ARGUMENT
Ensure every product row has a valid id field (UTF-8 encoded, max 128 characters). Verify that availability values use the exact enum strings: IN_STOCK, OUT_OF_STOCK, PREORDER, or BACKORDER.
User events not appearing in recommendations
Events require at minimum: eventType, visitorId, and eventTime. For search-related events, include searchQuery or pageCategories. For purchase events, revenue and currencyCode are required. Also verify you meet the minimum event volume thresholds (250,000 search events in 90 days for search optimization).
Events rejected as stale
The Retail API rejects events with timestamps that are too old. Ensure event_time is in RFC 3339 format and within the acceptable time window (typically within the last 24 hours for real-time ingestion).
Products not showing in search results
Product imports are processed asynchronously. There may be a delay of several minutes before products appear in search results. Also verify that the products have the required title field and are imported to the correct catalog branch.
Rate limiting (429 errors)
Zeotap automatically retries rate-limited requests. If you see persistent rate limit errors, check your project quotas in the Google Cloud Console under APIs & Services > Quotas. Consider requesting a quota increase for high-volume syncs.