- Discover the organizations and stores available to a key.
- Query advertising, attribution, product, customer, and cohort analytics.
- Inspect store readiness, connected accounts, assets, and tracking connections.
- Run read-only store commerce queries.
- Inspect tracking instructions, event catalogs, live traffic, and bounded test receipts.
- Synchronize supported connections and perform explicit platform actions.
- Save, review, publish, and reconcile supported advertising changes through durable drafts and jobs.
Base URL
Start every stable customer endpoint with this base URL:/v1 segment. It is part of the API contract.
Discover access first
If you do not know the organization and store, start with one request:- Call
GET /contextto get the authenticated user, accessible organizations, and each organization’s nested stores. - Copy an exact
organizations[].stores[].urlvalue into store-scoped endpoints. - Add the optional
organizationIdquery only when the identity can access multiple organizations and the workload deliberately selects one. Omit it for a store-scoped API key.
GET /me, GET /organizations, or GET /stores when your workload needs only one part of the discovery response.
Choose an analytics endpoint
Use the dedicated/ad-metrics/{resourceUrl} endpoints for advertising metrics, daily series, countries, devices, dimensions, and website views. Product, customer LTV, and cohort endpoints require a Shopify resource.
The generic SQL endpoint, POST /ad-metrics/{resourceUrl}/query, currently supports only customer_ltv and cohorts for Shopify resources. Call GET /ad-metrics/{resourceUrl}/query/catalog before composing SQL. An empty website catalog is expected; use the dedicated website analytics endpoints. Other datasets require their dedicated endpoint and return a 400 response if sent to generic SQL.
For LTV, date filters select customers by their first-order date while revenue remains lifetime revenue. Keep the default input limit when you need a population-level result; a smaller limit selects a top-revenue sample. The page compatibility field does not paginate SQL results.
Authentication
Create, store, send, and revoke an API key safely.
Scoping
Understand organization and store access boundaries.
API quickstart
Make a request and list your first store.
Errors and request IDs
Handle failures and preserve diagnostic context.
Read every response consistently
Successful responses use JSON. Resource collections use a named object when the contract needs context, such as{ "stores": [...] }. Analytics rows can use an array.
Every response includes an x-request-id header. Keep it in your logs and include it in support requests.
Bily generates the endpoint reference from its OpenAPI specification. Use that specification as the source of truth for paths, parameters, request bodies, and stable response fields.
Choose the API or MCP
Compare deterministic server workflows with interactive AI-client work.