Stats API: https://stats.shortid.me
Capture API: https://api.shortid.me
All endpoints accept these query parameters:
domainYour domain (required)period7d | 30d | 90d | todaylimitNumber of results (default: 10)https://stats.shortid.me/api/stats/overview?domain=example.comTotal pageviews, unique visitors, and events
{"pageviews": 316, "unique_visitors": 16, "events": 667}https://stats.shortid.me/api/stats/pages?domain=example.comMost visited pages on your site
[{"name": "/", "count": 55}, {"name": "/dashboard/", "count": 76}]https://stats.shortid.me/api/stats/sources?domain=example.comWhere your visitors come from
[{"name": "Direct", "count": 128}, {"name": "google.com", "count": 45}]https://stats.shortid.me/api/stats/devices?domain=example.comBrowser and device breakdown
{"browsers": [{"name": "Chrome", "count": 659}], "devices": [{"name": "desktop", "count": 663}]}https://stats.shortid.me/api/stats/geo?domain=example.comVisitor locations by country
[{"name": "US", "count": 120}, {"name": "DE", "count": 45}]https://stats.shortid.me/api/stats/pageviews?domain=example.comPageviews over time (hourly/daily)
[{"time": "2024-01-15T10:00:00Z", "count": 25}]https://stats.shortid.me/api/stats/event-breakdown?domain=example.comEvents grouped by type
[{"name": "pageview", "count": 316}, {"name": "click", "count": 284}]https://stats.shortid.me/api/stats/funnel?domain=example.com&steps=/,/signup/,/dashboard/Conversion funnel analysis
[{"step": "/", "visitors": 100}, {"step": "/signup/", "visitors": 45}]/api/queryRun custom SQL queries on your data. Only SELECT allowed. Max 10,000 rows, 30s timeout.
POST /api/query
Content-Type: application/json
{
"sql": "SELECT pathname, COUNT(*) as views FROM events GROUP BY pathname",
"domain": "example.com"
}