Skip to main content
Fetch view, lead, and link click counts for a specific video.

Endpoint

GET /v1/videos/:id/stats

Authentication

Pass your API key as a Bearer token in the Authorization header.
Authorization
string
required
Your API key. Format: Bearer <api_key>.

Path parameters

id
number
required
The ID of the video to retrieve stats for.

Response

data
object
required
leads and link_clicks are mutually exclusive based on your CTA type. A video with a form CTA will always have link_clicks: 0, and a video with an external link CTA will always have leads: 0.

Error responses

StatusDescription
400The provided id is not a valid number.
404No video found with the given ID in your account.

Examples

curl --request GET \
  --url https://api.demomatic.tech/v1/videos/123/stats \
  --header 'Authorization: Bearer YOUR_API_KEY'

Response

200
{
  "data": {
    "views": 142,
    "leads": 17,
    "link_clicks": 0
  }
}