Skip to main content

Endpoint

POST https://api.ugc.inc/stats/dashboard/daily

Overview

Get pre-aggregated daily statistics with all 8 metrics combined into a single response. Returns one record per day with total changes across all filtered accounts and posts. This endpoint is optimized for rendering dashboard charts — it returns ~30-90 rows covering the entire date range instead of per-account or per-post granular data. Metrics included:
  • Followers/Following — daily changes from account statistics
  • Views/Likes/Comments/Shares/Saves — daily changes from post statistics
  • Posts — count of posts created per day

Request Body

startDate
string
required
Start date in ISO 8601 format (e.g., 2024-01-01T00:00:00Z).
endDate
string
required
End date in ISO 8601 format (e.g., 2024-01-31T23:59:59Z).
accountIds
string[]
Array of account IDs to filter by. Omit to include all accounts.
tag
string
Filter by account tag
org_group
string
Filter by organization group
user_group
string
Filter by user group
hosts
string[]
Filter by account device type (e.g., physical_iphone, physical_android, emulated_android)
postType
string
Filter by post type. One of video or slideshow.
audioIds
string[]
Filter by audio IDs. Use none to include posts without audio.

Response

data
DashboardDailyStat[]
Array of daily aggregated statistics objects
curl -X POST https://api.ugc.inc/stats/dashboard/daily \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "startDate": "2024-01-01T00:00:00Z",
    "endDate": "2024-01-31T23:59:59Z",
    "hosts": ["physical_iphone"]
  }'
import requests

response = requests.post(
    'https://api.ugc.inc/stats/dashboard/daily',
    headers={
        'Authorization': 'Bearer YOUR_API_KEY',
        'Content-Type': 'application/json'
    },
    json={
        'startDate': '2024-01-01T00:00:00Z',
        'endDate': '2024-01-31T23:59:59Z',
        'hosts': ['physical_iphone']
    }
)

data = response.json()

if data['ok']:
    for day in data['data']:
        print(f"{day['date']}: +{day['followers']} followers, +{day['views']} views")
const response = await fetch('https://api.ugc.inc/stats/dashboard/daily', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    startDate: '2024-01-01T00:00:00Z',
    endDate: '2024-01-31T23:59:59Z',
    hosts: ['physical_iphone']
  })
});

const data = await response.json();

if (data.ok) {
  data.data.forEach(day => {
    console.log(`${day.date}: +${day.followers} followers, +${day.views} views`);
  });
}
import { UGCClient } from 'ugcinc';

const client = new UGCClient({
  apiKey: 'YOUR_API_KEY'
});

const response = await client.stats.getDashboardDailyStats({
  startDate: '2024-01-01T00:00:00Z',
  endDate: '2024-01-31T23:59:59Z',
  hosts: ['physical_iphone']
});

if (response.ok) {
  response.data.forEach(day => {
    console.log(`${day.date}: +${day.followers} followers, +${day.views} views, +${day.likes} likes`);
  });
}
{
  "ok": true,
  "code": 200,
  "message": "Success",
  "data": [
    {
      "date": "2024-01-01T00:00:00.000Z",
      "followers": 245,
      "following": 12,
      "views": 18500,
      "likes": 1240,
      "comments": 89,
      "shares": 156,
      "posts": 3
    },
    {
      "date": "2024-01-02T00:00:00.000Z",
      "followers": 310,
      "following": 8,
      "views": 22100,
      "likes": 1580,
      "comments": 112,
      "shares": 198,
      "posts": 5
    }
  ]
}