Affinity Design
Agency Guide

Dashboard Analytics

Agency and client dashboards with key metrics, trends, and activity feeds

Overview

The platform provides two dashboards: an agency dashboard for operators and a client portal dashboard for your clients. Both surface key metrics, trends, and recent activity, but with different scopes and access levels.

Agency Dashboard

Endpoint: GET /admin/dashboard

The agency dashboard provides a real-time overview of your entire platform.

Key Metrics

MetricDescription
activeClientsNumber of clients with status: "Active"
totalAgentsCount of all primary and additional agents across active clients
callsTodayTotal calls since midnight UTC
callsThisMonthTotal calls since the 1st of the month
bookingsThisMonthCalls with status: "booked_appointment" this month
conversionRatebookingsThisMonth / callsThisMonth × 100
activeCallsCalls currently in progress

Each metric includes a trend percentage comparing to the previous period:

TrendComparison
callsTodayvs. yesterday
bookingsThisMonthvs. last month
conversionRatevs. last month's rate

Trend values are calculated as ((current - previous) / previous) × 100. If there's no previous value, the trend shows 100 if current is positive, 0 otherwise.

7-Day Activity

The dailyActivity array provides a day-by-day breakdown of calls and bookings for the last 7 days:

{
  "dailyActivity": [
    { "date": "May 1", "calls": 42, "bookings": 8 },
    { "date": "May 2", "calls": 38, "bookings": 6 }
  ]
}

Missing days are filled with zeros. Use this for sparklines and mini-charts in the admin UI.

Client Dashboard Summary

Endpoint: GET /admin/reports/dashboard-summary?clientId=xxx

A focused summary of a single client's current month performance with month-over-month comparison.

Current and Last Month Totals

MetricDescription
inboundCallsTotal inbound calls
outboundCallsTotal outbound calls
totalCallsAll calls
successfulBookingsBookings from calls
totalDurationTotal seconds on calls
averageDurationAverage seconds per call
successRate(successfulBookings / totalCalls) × 100

Change Percentages

The changes object shows the percentage change between current and last month for:

  • inboundCalls
  • outboundCalls
  • totalCalls
  • successfulBookings

Per-Agent Breakdown

The agents array includes individual agent metrics for the current month, enabling drill-down from the summary to specific agent performance.

Client Portal Dashboard

Endpoint: GET /secure/dashboard (authenticated client access)

The portal dashboard gives clients a read-only view of their own data:

MetricDescription
TrafficWebsite traffic trend from GA4/Search Console (if connected)
CallsMonthly call count with month-over-month trend
BookingsMonthly booking count with trend
LeadsMonthly lead count with trend
Active AgentsNumber of currently active agents
Total MinutesLifetime call minutes
Avg DurationAverage call duration in seconds
BillingCurrent billing summary from the client's billing record

Secondary Panel

The dashboard includes a dynamic secondary panel:

  • Traffic chart — shown when a website has active GA4 and Google Search Console connections. Displays a traffic trend time series.
  • Recent calls — fallback panel when no traffic data is connected.

Global Activity Feed

An aggregated feed combining:

  • Recent calls
  • Website activity (visibility: client or both)
  • Social media posts
  • Lead events from Meta (excluding duplicates)

Portal Dashboard Control

Endpoints:

  • GET /admin/clients/:clientId/portal-dashboard-control — View dashboard configuration
  • PUT /admin/clients/:clientId/portal-dashboard-control — Customize what the client sees

This lets you control which metrics and panels are visible to each client, so you can tailor the experience to their service level.

Recent Activity

Endpoint: GET /admin/activity?days=7&limit=10

Returns recent calls across all clients, sorted by most recent first. Useful for the agency activity feed or quick monitoring.

Parameters

ParameterDefaultDescription
days7Look-back window in days
limit10Maximum results to return

Each activity record includes client name, business name, call status, duration, and outcome.

On this page