Available data types
| Data Type | Sync Endpoint | Async Endpoint | Description |
|---|---|---|---|
| Search History | /v1/sync/get_search | /v1/search | Google search queries |
| Browsing History | /v1/sync/get_browsing | /v1/browsing | Chrome browser history |
| YouTube History | /v1/sync/get_youtube | /v1/youtube | Watched videos |
| Ad Interactions | /v1/sync/get_ads | /v1/ads | Ad clicks and views |
| Receipts | /v1/sync/get_receipts | /v1/receipts | Purchase receipts with items and brands |
Sync vs Async
- Sync (Immediate)
- Async (Job-based)
Best for: Real-time needs, single users, simple integrationsCharacteristics:
- Single
uidparameter - Response includes data directly as JSON
- 30-second timeout
- Supports pagination with
cursor - Supports delta queries with
ingested_begin/ingested_end
When to use each
| Use Case | Recommendation |
|---|---|
| User-facing dashboard | Sync - immediate JSON response |
| Background data processing | Async - batch multiple users |
| Real-time personalization | Sync - low latency |
| Batch analytics | Async - Parquet format for big data tools |
| Mobile app | Sync - simpler error handling |
| Multi-user reports | Async - query up to 25 users at once |
Authentication
All Query API endpoints require a Bearer token:Categories and schema
- Categories are Google Topics taxonomy paths (for example
/Shopping/Apparel/Footwear). - Use
GET /v1/sync/categories?table=searches(orbrowsing,youtube,ads,receipts) to list available category paths.
Sync response format
Sync endpoints return JSON directly:| Field | Description |
|---|---|
data | Array of records |
event_id | Unique identifier for deduplication |
ingested_at | When record was added to Emerge |
count | Number of records in this response |
has_more | Whether more records exist |
next_cursor | Pagination token for next page |
applied_ingested_end | Actual end time used (for delta sync) |
Async response format
Async endpoints return a job reference:Error responses
| Status | Code | Description |
|---|---|---|
| 401 | unauthorized | Invalid or missing API token |
| 404 | user_not_found | No consent for this user |
| 429 | rate_limited | Too many requests |
| 500 | internal_error | Server error (retry with backoff) |
Next steps
Pagination
Handle large datasets with cursors and delta queries
Event Categories
First-level category list and filter patterns
Data Schema
Field-level schema for all Query event types