feat: duration/participants/issues/gum summary endpoints (Phase 2 + 3 of #20)#26
Conversation
Five new endpoints for the remaining dashboard charts that fetch raw data:
- GET /v1/conferences/duration-summary
Returns conference counts bucketed by duration range (< 1m, 1-3m, etc.)
- GET /v1/conferences/participant-count-summary
Returns distribution of conferences by participant count
- GET /v1/issues/summary
Returns issue counts grouped by code with titles
- GET /v1/issues/gum-summary
Returns getusermedia_error issue counts grouped by error name
Also adds three new filter params to /v1/conferences for click-to-detail
modals on these charts:
- duration_gte, duration_lt (for duration chart)
- issue_code (for most-common-issues chart)
All endpoints accept appId, created_at_gte, created_at_lte and handle
both Python native ISO format and JavaScript's toISOString Z suffix.
Phases 2 and 3 of peermetrics#20 — eliminates the need for the dashboard to
download all conferences (~38MB) and all issues (~73MB).
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fbdd2ebcd4
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| 'created_at__lte': 'created_at_lte', | ||
| 'duration__gte': 'duration_gte', | ||
| 'duration__lt': 'duration_lt', | ||
| 'issues__code': 'issue_code', |
There was a problem hiding this comment.
Deduplicate conference rows for issue_code filters
When issue_code is passed, filtering on issues__code performs a reverse join to Issue and returns one Conference row per matching issue, so conferences with multiple matching issues are duplicated in /conferences responses. This causes incorrect pagination and repeated conference IDs in client results; use .distinct() (or an Exists-based predicate) when this filter is active.
Useful? React with 👍 / 👎.
Summary
Depends on #24 (already merged). Phase 4 + 5 will be a follow-up PR stacked on top of this one.
Test plan
🤖 Generated with Claude Code