Skip to content

feat: admin usage by endpoint#690

Merged
greatest0fallt1me merged 1 commit into
CalloraOrg:mainfrom
Ugooweb:feature/admin-usage-endpoint
Jul 24, 2026
Merged

feat: admin usage by endpoint#690
greatest0fallt1me merged 1 commit into
CalloraOrg:mainfrom
Ugooweb:feature/admin-usage-endpoint

Conversation

@Ugooweb

@Ugooweb Ugooweb commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Closes #613

This PR addresses the backend requirement for the GrantFox FWC26 campaign by implementing the /api/admin/usage/by-endpoint cross-dev usage view. It introduces an endpoint that allows admins to view the top endpoint usage aggregated across all developers.

Changes Made

  • New Feature: Added src/routes/admin/usage/by-endpoint.ts to implement the GET /api/admin/usage/by-endpoint route.
  • Route Registration: Registered the new admin route in src/app.ts.
  • Testing: Added rigorous edge-case and functional testing in src/routes/admin/usage/by-endpoint.test.ts.

Acceptance Criteria Met

  • Implementation matches the description (Cross-dev usage view).
  • Tests added and passing (focused tests covering edge cases).
  • Adhered to repo's lint and code style.
  • Secure, efficient, tested, and documented.

Testing & Validation

  • Ran the repo's standard test suite (jest).
  • Verified database aggregations and SQL clauses correctly filter and limit the grouped endpoints without SQL injection vulnerabilities.

@greatest0fallt1me
greatest0fallt1me merged commit 6bfb406 into CalloraOrg:main Jul 24, 2026
@greatest0fallt1me

Copy link
Copy Markdown
Contributor

Nice one — clean, focused change. Merging. 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add /api/admin/usage/by-endpoint cross-dev view

2 participants