Skip to main content
GET
/
ad-metrics
/
{storeUrl}
/
devices
Get device metrics
curl --request GET \
  --url https://app.bily.ai/api/customer/v1/ad-metrics/{storeUrl}/devices \
  --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/{storeUrl}/devices', 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/{storeUrl}/devices"

headers = {"x-api-key": "<api-key>"}

response = requests.get(url, headers=headers)

print(response.text)
[
  {
    "shop": "<string>",
    "date": "2023-12-25",
    "time": "<string>",
    "channel": "<string>",
    "device_type": "<string>",
    "os": "<string>",
    "browser": "<string>",
    "conversions": 123,
    "conv_value": 123,
    "currency": "<string>",
    "visitors": 123,
    "sessions": 123,
    "customers": 123
  }
]
{
"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

x-api-key
string
header
required

A server-side Bily API key created under Settings > MCP > Access key fallback. Select the intended store before creating it.

Headers

x-bily-organization-id
string

An organization ID returned by GET /context or GET /organizations. Required for GET /stores and optional for store-scoped paths.

Example:

"org_01J8W7T9G3E6ZQ4M2K5N8P1R0S"

Path Parameters

storeUrl
string
required

The exact store URL returned by GET /context or GET /stores.

Example:

"store.example.com"

Query Parameters

startDate
string<date>
required

First date to include, in YYYY-MM-DD format.

endDate
string<date>
required

Last date to include, in YYYY-MM-DD format.

channel
string

Optional normalized channel, such as facebook or google.

adId
string

Filter to one ad ID.

filterCountry
string

Comma-separated country codes.

filterDeviceType
string

Comma-separated device types.

filterOS
string

Comma-separated operating systems.

filterBrowser
string

Comma-separated browser names.

filterProductId
string

Comma-separated product IDs.

dimension_source
enum<string>

Dimension attribution context.

Available options:
conversion,
first_touch
includeOS
boolean
default:false

Include operating system detail.

includeBrowser
boolean
default:false

Include browser detail.

Response

Request completed successfully.

shop
string
required
date
string<date>
required
time
string
required
channel
string
required
device_type
string
required
os
string
required
browser
string
required
conversions
number
required
conv_value
number
required
currency
string | null
visitors
number
sessions
number
customers
number