Skip to content

refactor(dashboard): remove dead hooks/utils and update API docs - #349

Merged
Lakes41 merged 1 commit into
Adamantine-guild:mainfrom
AgilityB:Add-basic-SIWE-message-construction-helper
Aug 19, 2026
Merged

refactor(dashboard): remove dead hooks/utils and update API docs#349
Lakes41 merged 1 commit into
Adamantine-guild:mainfrom
AgilityB:Add-basic-SIWE-message-construction-helper

Conversation

@AgilityB

Copy link
Copy Markdown
Contributor

Description
Removes two dead library files from the dashboard that had no consumers anywhere in the codebase, and rewrites the stale API route documentation to accurately reflect the current state of the app.

Type of Change
🐛 Bug fix
✨ New feature / enhancement
📝 Documentation update
🔧 Chore / refactor
🧪 Tests only

Changes Made

  • Deleted useApiList.ts
    — a client-side fetch hook that was never imported by any page, component, or utility. It was an earlier abstraction superseded by the inline fetch pattern used across pages today.

  • Deleted fetch-list.ts
    — a lower-level fetch helper that useApiList was built on. Also never imported externally. Confirmed zero consumers via codebase-wide search before deletion.

  • Rewrote README.md
    — the previous version documented only 5 of the 20 existing API routes and contained a "Adding Webhook Support" tutorial describing a route (/api/webhooks) that already exists and is fully implemented. The updated doc covers all routes in a structured reference table and accurately describes the real webhook endpoint behaviour, including its rate limiting, size guards, and response codes.

Test Evidence
No logic was changed — only dead files removed and docs corrected. Existing tests are unaffected.

pnpm typecheck # passes — no imports of deleted files existed
pnpm test # all existing tests pass

Checklist

  • I have read CONTRIBUTING.md
  • This PR is linked to an open issue
  • pnpm typecheck passes with no errors
  • pnpm lint passes (or issues are pre-existing and documented)
  • pnpm test passes (all existing tests still pass)
  • The dashboard starts and renders correctly (if UI or API code changed)
  • The Discord bot still starts and responds to commands (if bot code changed)
  • Docs site renders correctly (if docs changed): pnpm dev:docs
  • No secrets, tokens, or API keys are included in this PR
  • Environment variable changes are reflected in .env.example
  • I have updated documentation if new behaviour was introduced

Additional Notes
The deleted files were identified by tracing imports across the entire codebase. No active code paths were modified. This is a noise-reduction change only.

Closes #324

- Delete lib/hooks/useApiList.ts — unused hook with no consumers
- Delete lib/fetch-list.ts — unused fetch helper with no consumers
- Rewrite app/api/README.md to cover all 20 routes (was missing 15+)
  and remove the stale "Adding Webhook Support" tutorial for the
  endpoint that already exists at /api/webhooks
@Lakes41
Lakes41 merged commit 928b563 into Adamantine-guild:main Aug 19, 2026
1 check passed
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 basic SIWE message construction helper

2 participants