List analytics datasets
curl --request GET \
--url https://app.bily.ai/api/customer/v1/ad-metrics/{resourceUrl}/query/catalog \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://app.bily.ai/api/customer/v1/ad-metrics/{resourceUrl}/query/catalog', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.bily.ai/api/customer/v1/ad-metrics/{resourceUrl}/query/catalog"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"resourceUrl": "<string>",
"resourceType": "website",
"storeUrl": "<string>",
"adAccountScope": 1,
"datasets": [
{
"id": "ad_metrics",
"title": "<string>",
"description": "<string>",
"requiredParams": [
"<string>"
],
"optionalParams": [
"<string>"
],
"columnHints": [
"<string>"
],
"exampleSql": "<string>"
}
]
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}Analytics SQL
List analytics datasets
Lists datasets, required filters, columns and example SQL accepted by the generic query endpoint. Currently only customer_ltv and cohorts are supported for Shopify resources. Website resources return an empty catalog; use the dedicated analytics endpoints for website traffic and advertising metrics.
GET
/
ad-metrics
/
{resourceUrl}
/
query
/
catalog
List analytics datasets
curl --request GET \
--url https://app.bily.ai/api/customer/v1/ad-metrics/{resourceUrl}/query/catalog \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://app.bily.ai/api/customer/v1/ad-metrics/{resourceUrl}/query/catalog', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.bily.ai/api/customer/v1/ad-metrics/{resourceUrl}/query/catalog"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"resourceUrl": "<string>",
"resourceType": "website",
"storeUrl": "<string>",
"adAccountScope": 1,
"datasets": [
{
"id": "ad_metrics",
"title": "<string>",
"description": "<string>",
"requiredParams": [
"<string>"
],
"optionalParams": [
"<string>"
],
"columnHints": [
"<string>"
],
"exampleSql": "<string>"
}
]
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}{
"error": "Store not found",
"requestId": "<string>",
"details": "<unknown>",
"retryAfter": "<string>"
}Authorizations
ApiKeyAuthBearerAuth