GET /events/ endpoint as the Lookout Events list, but presents events
as “campaigns” with a Wave KPI strip — total / running / open / closed
campaigns. Clicking a row opens the Campaign detail
page.
What you’ll build
- A KPI strip at the top (4 tiles).
- The same filterable, paginated table as Lookout — but click navigates
to
/campaigns/{eid}instead of/events/{eid}. - Permission gating: rows only clickable if the user has Wave permission.
Prerequisites
- An authenticated user.
X-Preferred-Partner-Idset.- Optional:
Permissions.wavecontrols clickability.
The call chain
On mount (parallel):| # | Method | Path | Purpose |
|---|---|---|---|
| 1 | GET | /campaigns/statistics | KPI strip: { total, running, open, closed, ignored }. |
| 2 | GET | /events/?... | First page of events with the URL-driven filter set. Note: exclude_products is not forced to true here, unlike the Lookout list. |
?drawer-open=true&event-id=...:
| # | Method | Path | Purpose |
|---|---|---|---|
| 3 | GET | /events/{eid} | Selected event for drawer highlight (legacy; v3 navigates instead of drawer). |
Filter parameters
Same set as Events list, minus the forcedexclude_products=true. Common Wave-specific defaults:
Reference implementation
useEventsList hook is the same one you wrote for the Lookout
Events list. Reuse it.
Gotchas
Don't force `exclude_products=true`
Don't force `exclude_products=true`
Lookout sends
exclude_products=true; Wave doesn’t. Sending it on Wave
hides product events the user can run campaigns against.Permission gates clickability, not visibility
Permission gates clickability, not visibility
Users without
Permissions.wave still see the list (because they may
have Lookout) — they just can’t click into the campaign detail. Show
a disabled state rather than hiding rows.Drawer state still honoured from URL
Drawer state still honoured from URL
The reference webapp’s v3 removed the inline drawer but still respects
?drawer-open=true&event-id= from deep links. Mirror that for
backwards-compat with bookmarks.Campaign statistics shape
Campaign statistics shape
{ total, running, open, closed, ignored }. The hero subtitle uses
running / open / closed. ignored is rendered in the “Total” tile.Related
- Campaign detail — the click target.
- Lookout — Events list — same endpoint.
- Pagination cookbook.