tpmjs/apps/web/src/app/api/tools
Ajax Davis e1bbd80f9b feat: implement user activity stream and multiple API improvements
Activity Stream:
- Add UserActivity model with ActivityType enum to track user actions
- Create activity logging service with fire-and-forget pattern
- Add /api/user/activity endpoint with cursor pagination
- Add cleanup cron job for 90-day activity retention
- Integrate activity logging into 18 mutation API routes
- Add DashboardActivityStream component with virtualized rendering

API Improvements:
- Add distributed rate limiting via Vercel KV (with in-memory fallback)
- Add rate limiting to chat endpoint (30 req/min)
- Optimize BM25 search with database-level pre-filtering
- Fix JSON parse crash in search endpoint
- Add pagination to collection tools response (toolsLimit/toolsOffset)
- Add take limits to agent detail query to prevent excessive data fetch
- Fix hardcoded tool count calculation in agents dashboard

Schema Extraction:
- Add schemaExtractionAttemptAt and schemaExtractionError fields
- Separate rate limiting for failed (1 min) vs successful (1 hour) attempts
- Allow retry of failed extractions

Standardization:
- Create api-response.ts with standardized response helpers
- Add apiSuccess, apiError, apiNotFound, apiForbidden, etc.
- Update agents routes to use standardized format

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-08 04:11:01 +10:00
..
[...slug] refactor: rename exportName to name across entire codebase 2025-12-17 17:19:21 +10:00
[id]/like feat: implement user activity stream and multiple API improvements 2026-01-08 04:11:01 +10:00
broken feat: add HN launch readiness features 2025-12-14 11:56:42 +10:00
execute/[...slug] refactor: rename exportName to name across entire codebase 2025-12-17 17:19:21 +10:00
extract-schema feat: implement user activity stream and multiple API improvements 2026-01-08 04:11:01 +10:00
parameters fix: remove Prisma internal module import in parameters route 2026-01-07 15:27:15 +10:00
report-health refactor: rename exportName to name across entire codebase 2025-12-17 17:19:21 +10:00
search feat: implement user activity stream and multiple API improvements 2026-01-08 04:11:01 +10:00
simulations/[...slug] refactor: rename exportName to name across entire codebase 2025-12-17 17:19:21 +10:00
update-schema refactor: rename exportName to name across entire codebase 2025-12-17 17:19:21 +10:00
validate feat: add HN launch readiness features 2025-12-14 11:56:42 +10:00
route.ts perf: reduce Neon compute usage with cron + caching optimizations 2025-12-31 12:14:00 +10:00