Overview
Analytics endpoints require READ_ANALYTICS and return data for servers owned by the authenticated account. The current local handlers do not include sub-user analytics in API-key mode.
- Endpoint
GET /api/v3/servers/analytics- Purpose
- Dashboard member analytics by query type.
- Endpoint
GET /api/v3/servers/firewall/analytics- Purpose
- Firewall analytics across all owned servers or one internal
serverId.
- Endpoint
GET /api/v3/servers/{serverId}/firewall/analytics- Purpose
- Firewall analytics for one internal RestoreCord server ID.
- Endpoint
GET /api/v3/servers/members/events- Purpose
- Verified/joined/deauthorized/left event timeline.
- Endpoint
GET /api/v3/servers/migrations/stats- Purpose
- Migration performance and retention metrics.
Some analytics are backed by ClickHouse. If that service is unavailable, the API may return a service-style error rather than an empty dataset.
Member Analytics
Auth: API key with READ_ANALYTICS or full session.
/api/v3/servers/analyticsGet Member Analytics
Returns one analytics query or a batched response for comma-separated query names.
qRequired- Location
- query
- Type
- string
timeOptional- Location
- query
- Type
- string
- Default
- 30d
limitOptional- Location
- query
- Type
- number
serverIdOptional- Location
- query
- Type
- string
- Query
graph- Description
- Verification counts over the requested time range.
- Query
recent- Description
- Recently verified members.
- Query
server- Description
- Per-server member counts and metadata.
- Query
country- Description
- Members grouped by country.
- Query
device- Description
- Members grouped by operating system/device data.
- Query
browser- Description
- Members grouped by browser.
- Query
map- Description
- Country distribution suitable for map views.
- Query
referrer- Description
- Verification referrer distribution.
- Query
integrity- Description
- Account quality/integrity summary.
- Query
isp- Description
- ISP breakdown. The handler includes plan checks internally.
- Query
state- Description
- Region/state breakdown where data is available.
- Query
city- Description
- City breakdown where data is available.
{
"success": true,
"batch": true,
"results": {
"graph": { "success": true, "data": [] },
"recent": { "success": true, "members": [] }
}
}Firewall Analytics: All Servers
Auth: API key with READ_ANALYTICS or full session.
/api/v3/servers/firewall/analyticsGet Firewall Analytics
Returns firewall totals, time series, top blocked sources, and recent logs for owned servers.
daysOptional- Location
- query
- Type
- number
- Default
- 30
serverIdOptional- Location
- query
- Type
- string
{
"success": true,
"statistics": {
"total": 120,
"allowed": 80,
"denied": 30,
"passwordUsed": 4,
"passwordInvalid": 1,
"rateLimited": 2,
"bypassUsed": 3,
"verificationOverTime": [],
"hourlyData": [],
"topBlockedIPs": [{ "ip": "203.0.113.10", "count": 6 }],
"topBlockedCountries": [{ "country": "US", "count": 10 }],
"ruleEffectiveness": [],
"recentLogs": []
},
"period": { "days": 30, "startDate": "...", "endDate": "..." },
"servers": [{ "guildId": "123456789012345678", "name": "Main Server" }]
}Firewall Analytics: Single Server
Auth: API key with READ_ANALYTICS or full session. serverId is the internal RestoreCord server ID.
/api/v3/servers/{serverId}/firewall/analyticsGet Server Firewall Analytics
Returns firewall analytics for one owned server.
serverIdRequired- Location
- path
- Type
- string
daysOptional- Location
- query
- Type
- number
- Default
- 30
Top blocked IPs are only included when the server has IP logging enabled and the account plan can access IP logging.
Member Events
Auth: API key with READ_ANALYTICS or full session.
/api/v3/servers/members/eventsGet Member Events
Returns verified members plus Discord member event counts over time.
daysOptional- Location
- query
- Type
- number
- Default
- 30
serverIdOptional- Location
- query
- Type
- string
- Plan
- Free/Premium
- Included event fields
verified,joined,deauthorized
- Plan
- Business
- Included event fields
- Adds
left.
- Plan
- Enterprise
- Included event fields
- Adds
massPing.
The response also includes migrationSeries for migration line metadata. Each data[] row may include matching dynamic migration_<id> values, set to null before the migration start date and successCount from the start date onward.
{
"success": true,
"data": [
{
"date": "2026-06-30",
"verified": 4,
"joined": 6,
"left": 1,
"massPing": 0,
"deauthorized": 2,
"migration_42": 128
}
],
"migrationSeries": [
{
"key": "migration_42",
"id": 42,
"startedAt": "2026-06-30T10:00:00.000Z",
"status": "COMPLETED",
"successCount": 128,
"totalCount": 150,
"sourceGuildId": "111111111111111111",
"targetGuildId": "222222222222222222"
}
]
}Migration Stats
Auth: API key with READ_ANALYTICS or full session.
/api/v3/servers/migrations/statsGet Migration Stats
Returns migration totals, success rates, flow breakdowns, and retention data.
daysOptional- Location
- query
- Type
- number
- Default
- 30
serverIdOptional- Location
- query
- Type
- string
{
"success": true,
"statistics": {
"totalMigrations": 4,
"successfulMigrations": 3,
"failedMigrations": 1,
"averageSuccessRate": 92.5,
"totalMembersMigrated": 1200,
"totalMembersJoined": 1200,
"totalMembersLeft": 45,
"memberRetentionRate": 96.3,
"avgMigrationDuration": 180
},
"recentMigrations": [],
"successRateOverTime": [],
"memberFlowBreakdown": [],
"memberMovementOverTime": [],
"ratioDistribution": [],
"total": 4
}Errors and Access
- Status
- 400
- Code
INVALID_INPUT- When
- Unknown analytics query, invalid
limit, invaliddays, or malformed internal server ID.
- Status
- 401
- Code
UNAUTHORIZED- When
- Missing or invalid auth.
- Status
- 403
- Code
INSUFFICIENT_PERMISSIONS- When
- API key lacks
READ_ANALYTICSor the plan does not allow a specific breakdown.
- Status
- 404
- Code
NOT_FOUND- When
serverIdwas supplied but is not owned by the account.
- Status
- 503
- Code
SERVICE_UNAVAILABLE- When
- ClickHouse-backed analytics are temporarily unavailable.