Skip to main content

Overview

The Dashboard API provides aggregated analytics and metrics across your entire link portfolio or filtered by client or campaign. These endpoints return summary data optimized for dashboard views.
All endpoints require authentication via Bearer token in the Authorization header.

Get Overview

Response

summary
object
High-level summary metrics.
charts
object
Detailed breakdown data for charts.
meta
object
Metadata about the response.

Example Request

curl -X GET https://api.example.com/dashboard/overview \
  -H "Authorization: Bearer YOUR_TOKEN"

Example Response

{
  "summary": {
    "totalClicks": 1547,
    "activeLinks": 42,
    "period": "Last 30 days"
  },
  "charts": {
    "clicksByDate": [
      {
        "date": "2026-03-09",
        "count": 67
      },
      {
        "date": "2026-03-08",
        "count": 54
      }
    ],
    "topBrowsers": [
      {
        "browser": "Chrome",
        "count": 892
      },
      {
        "browser": "Safari",
        "count": 431
      },
      {
        "browser": "Firefox",
        "count": 224
      }
    ],
    "topCountries": [
      {
        "country": "United States",
        "count": 745
      },
      {
        "country": "United Kingdom",
        "count": 298
      },
      {
        "country": "Canada",
        "count": 187
      }
    ],
    "topCities": [
      {
        "city": "New York",
        "count": 312
      },
      {
        "city": "London",
        "count": 245
      },
      {
        "city": "Toronto",
        "count": 178
      }
    ]
  },
  "meta": {
    "hasData": true
  }
}

Get Top Clients

Response

Returns an array of client objects sorted by click count in descending order.
name
string
Name of the client.
clicks
number
Total number of clicks for all links associated with this client.

Example Request

curl -X GET https://api.example.com/dashboard/top-clients \
  -H "Authorization: Bearer YOUR_TOKEN"

Example Response

[
  {
    "name": "Acme Corp",
    "clicks": 5432
  },
  {
    "name": "Tech Startup Inc",
    "clicks": 3210
  },
  {
    "name": "Retail Brand Ltd",
    "clicks": 2876
  },
  {
    "name": "Services Co",
    "clicks": 1954
  },
  {
    "name": "Media Group",
    "clicks": 1432
  }
]

Get Client Overview

Path Parameters

clientId
string
required
UUID of the client to get metrics for.

Response

Returns the same structure as the Get Overview endpoint, but filtered to the specified client.

Example Request

curl -X GET https://api.example.com/dashboard/clients/123e4567-e89b-12d3-a456-426614174000/overview \
  -H "Authorization: Bearer YOUR_TOKEN"

Example Response

{
  "summary": {
    "totalClicks": 432,
    "activeLinks": 15,
    "period": "Last 30 days"
  },
  "charts": {
    "clicksByDate": [
      {
        "date": "2026-03-09",
        "count": 18
      },
      {
        "date": "2026-03-08",
        "count": 15
      }
    ],
    "topBrowsers": [
      {
        "browser": "Chrome",
        "count": 245
      },
      {
        "browser": "Safari",
        "count": 132
      },
      {
        "browser": "Firefox",
        "count": 55
      }
    ],
    "topCountries": [
      {
        "country": "United States",
        "count": 312
      },
      {
        "country": "Canada",
        "count": 87
      },
      {
        "country": "United Kingdom",
        "count": 33
      }
    ],
    "topCities": [
      {
        "city": "New York",
        "count": 145
      },
      {
        "city": "Los Angeles",
        "count": 89
      },
      {
        "city": "Toronto",
        "count": 76
      }
    ]
  },
  "meta": {
    "hasData": true
  }
}

Get Campaign Overview

Path Parameters

campaignId
string
required
UUID of the campaign to get metrics for.

Response

Returns the same structure as the Get Overview endpoint, but filtered to the specified campaign.

Example Request

curl -X GET https://api.example.com/dashboard/campaigns/987fcdeb-51a2-43d7-b890-123456789abc/overview \
  -H "Authorization: Bearer YOUR_TOKEN"

Example Response

{
  "summary": {
    "totalClicks": 287,
    "activeLinks": 8,
    "period": "Last 30 days"
  },
  "charts": {
    "clicksByDate": [
      {
        "date": "2026-03-09",
        "count": 12
      },
      {
        "date": "2026-03-08",
        "count": 9
      }
    ],
    "topBrowsers": [
      {
        "browser": "Chrome",
        "count": 167
      },
      {
        "browser": "Safari",
        "count": 78
      },
      {
        "browser": "Edge",
        "count": 42
      }
    ],
    "topCountries": [
      {
        "country": "United States",
        "count": 198
      },
      {
        "country": "United Kingdom",
        "count": 54
      },
      {
        "country": "Australia",
        "count": 35
      }
    ],
    "topCities": [
      {
        "city": "San Francisco",
        "count": 87
      },
      {
        "city": "London",
        "count": 45
      },
      {
        "city": "Sydney",
        "count": 32
      }
    ]
  },
  "meta": {
    "hasData": true
  }
}

Error Responses

403
object
User does not have access to this campaign.
{
  "message": "You do not have permission to access this campaign"
}
The campaign overview endpoint verifies that the authenticated user has access to links in the specified campaign before returning data.

Build docs developers (and LLMs) love