API Reference Overview
All endpoints are rooted at https://cdp.vyg.app. Reads authenticate with a vyg_ API key
(Authorization: Bearer vyg_…); key management uses a session credential; ingest is
credential-free. See Authentication.
Profiles
Section titled “Profiles”| Method & path | Description |
|---|---|
GET /cdp/profiles | List / search profiles (customers vs anonymous bucket). |
GET /cdp/profiles/{id} | Single profile by id. |
GET /cdp/profiles/{id}/events | Profile event history. |
GET /cdp/profiles/{id}/sessions | Profile session history. |
API keys
Section titled “API keys”| Method & path | Description |
|---|---|
POST /cdp/keys | Issue a new key (plaintext returned once). |
GET /cdp/keys | List a brand’s keys (prefixes + metadata only). |
POST /cdp/keys/rotate | Rotate: revoke active key(s) and mint a replacement. |
POST /cdp/keys/revoke | Revoke a key by id or prefix (idempotent). |
DELETE /cdp/keys | Revoke via DELETE (id / prefix in query). |
The Commerce, Customers, Insights, and Integrations groups below
require the beta:cdp-commerce permission on your brand and a connected Shopify
integration. See Commerce Data for how this data is
served and Insights for how the metrics are computed.
Commerce
Section titled “Commerce”| Method & path | Description |
|---|---|
GET /cdp/commerce/orders | List local synced orders. |
GET /cdp/commerce/orders/{id} | Fetch one normalized order with line items. |
GET /cdp/commerce/products | List the live Shopify product catalog. |
GET /cdp/commerce/products/{id} | Fetch one live Shopify product. |
GET /cdp/commerce/subscriptions | List synced subscription contracts. |
GET /cdp/commerce/subscriptions/{id} | Fetch one subscription contract by id. |
Customers
Section titled “Customers”| Method & path | Description |
|---|---|
GET /cdp/customers/{identifier} | Fetch a unified customer record. |
GET /cdp/customers/{identifier}/orders | List a customer’s order history. |
GET /cdp/customers/{identifier}/insights | A customer’s LTV & spend summary. |
Insights
Section titled “Insights”| Method & path | Description |
|---|---|
GET /cdp/insights/ltv | Brand LTV aggregates and distribution. |
GET /cdp/insights/rfm | Brand RFM tier distribution and definitions. |
GET /cdp/insights/products | Product rankings and repeat-purchase rate. |
GET /cdp/insights/at-risk | Customers at churn risk (paginated). |
Integrations
Section titled “Integrations”| Method & path | Description |
|---|---|
GET /cdp/integrations | Connected integrations (no settings or credentials). |
Segments
Section titled “Segments”| Method & path | Description |
|---|---|
POST /cdp/segments | Define a scope-bound segment. |
GET /cdp/segments | List this brand’s segments. |
GET /cdp/segments/{id}/members | Read segment membership (scope-gated). |
Ingest
Section titled “Ingest”| Method & path | Description |
|---|---|
POST /cdp/ingest | Credential-free browser → CDP ingest proxy. |
Conventions
Section titled “Conventions”- Pagination: offset/pageSize envelope + opaque
nextCursor. See Pagination. - Errors:
{ error, error_description? }. See Errors. - Scope: every read is bound to your brand’s shop. See Tenant Isolation & Scope.