Description
Implement GET /api/v1/admin/dashboard, aggregating platform-wide stats: total users by role, total campaigns by status, total donations/distributions volume, and pending KYC count.
Acceptance Criteria
- Restricted to ADMIN role only.
- Returns counts for: users by role, campaigns by status, sum of confirmed donation amounts, sum of confirmed distribution amounts, pending KYC submissions count.
- Queries are efficient (aggregate DB queries, not loading full tables into memory and counting in JS).
- Response shape is documented with a concrete example in openapi.yaml.
- At least one test verifies the shape and correctness of the aggregation against seeded data.
Suggested reward: $25-$35
Description
Implement GET /api/v1/admin/dashboard, aggregating platform-wide stats: total users by role, total campaigns by status, total donations/distributions volume, and pending KYC count.
Acceptance Criteria
Suggested reward: $25-$35