## Summary
- Add admin UI at `/admin/searches` to view and manage cached audio
search results
- Allow admins to clear stale caches when flacfetch is updated with new
providers
- Fixes issue where jobs showed only YouTube results when lossless
sources should be available
## Changes
- **Backend**: New admin endpoints `GET /api/admin/audio-searches` and
`POST /api/admin/audio-searches/{job_id}/clear-cache`
- **Frontend**: New admin page with search results table, status
indicators, and cache clear action
- **Safety**: Status validation prevents clearing cache on
active/complete jobs
- **Docs**: Updated API.md, LESSONS-LEARNED.md, and README.md
## Testing
- [x] Backend module imports successfully
- [x] Frontend TypeScript compiles without errors
- [x] CodeRabbit CLI review completed and issues addressed
## Review
- [x] CodeRabbit CLI review completed locally (3 cycles)
- [x] Fixed: `has_lossless` now computed from ALL results, not just
first 10
- [x] Fixed: Added status validation before cache clear
- [x] Noted (not fixed): Scalability optimization for large-scale -
acceptable for admin tool
@coderabbitai ignore
---
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude <noreply@anthropic.com>
## Summary
Add a full admin dashboard at `/admin` for platform management with:
- **Dashboard**: Stats overview showing users, jobs by status, credits
issued
- **User Management**: Search, sort, pagination, add credits, toggle
role, enable/disable
- **Job Browser**: Filter by status/user, view details with timeline and
logs, delete jobs
- **Beta Program**: Stats and feedback list
## Changes
### Backend
- New `/api/admin/stats/overview` endpoint for dashboard metrics
- Enhanced user list with search, pagination, and sorting
- New user detail endpoint with credit history and recent jobs
### Frontend
- Admin layout with responsive sidebar navigation
- Dashboard page with stats cards and job status breakdown
- User management pages (list + detail) with all admin actions
- Job browser pages (list + detail) with filters and log viewer
- Beta program page with stats and feedback
- Query-param based routing (`/admin/users/detail?email=`) for static
export compatibility
### Documentation
- Added Admin Endpoints section to API.md
- Updated README with admin dashboard in What Works and Current State
## Testing
- [x] Backend tests pass (`make test` - 57 passed)
- [x] Frontend tests pass (`npm run test:all` - 64 passed)
- [x] Frontend build passes (`npm run build`)
- [x] Manual testing completed
## Review
- [x] CodeRabbit CLI review completed locally (2 cycles)
- [x] All important feedback addressed
@coderabbitai ignore
---
🤖 Generated with [Claude Code](https://claude.com/claude-code)
---------
Co-authored-by: Claude <noreply@anthropic.com>
- Add is_configured() method to EmailService
- Return 503 error if email service not configured (magic link, beta enrollment)
- Add email/Stripe status to /health/detailed endpoint
- Update docs to reflect merged payment flow (PR #90)
- Add lesson learned about Cloud Run secret mounting
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- README: Update status table with payment flow and beta program
- API.md: Add user auth, credits, and beta tester endpoints
- LESSONS-LEARNED.md: Add gitignore and Firestore transaction insights
- archive: Add session summary for PR #90 work
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Wrap bare URLs in angle brackets in CLAUDE.md (MD034)
- Add language specifiers to fenced code blocks (MD040):
- `text` for directory structures and ASCII diagrams
- `http` for HTTP request examples
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
## Summary
Complete documentation reorganization to make it more effective for AI agents working on this codebase.
## Changes Made
- Consolidated 88 docs into 5 active files + archive
- New structure: README.md, ARCHITECTURE.md, DEVELOPMENT.md, API.md, LESSONS-LEARNED.md
- Added Claude Code slash commands: /docs-review (pre-merge), /docs-maintain (periodic)
- Updated CLAUDE.md with documentation maintenance rules
- Moved all historical docs to docs/archive/ with YYYY-MM-DD prefixes
## New Documentation Structure
```
docs/
├── README.md # Current status + navigation
├── ARCHITECTURE.md # System design
├── DEVELOPMENT.md # Dev setup, testing, deployment
├── API.md # Backend API reference
├── LESSONS-LEARNED.md # Key insights for future agents
└── archive/ # 93 historical docs with date prefixes
```
## Testing
- All 57 backend tests pass
- No code changes, docs-only reorganization
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>