Skip to content

Add REST equivalents for recall/forget plus API robustness fixes#131

Merged
rahilp merged 1 commit into
mainfrom
130-add-rest-equivalents-for-recall-and-forget-mcp-tools-plus-api-robustness-fixes
Jun 7, 2026
Merged

Add REST equivalents for recall/forget plus API robustness fixes#131
rahilp merged 1 commit into
mainfrom
130-add-rest-equivalents-for-recall-and-forget-mcp-tools-plus-api-robustness-fixes

Conversation

@rahilp

@rahilp rahilp commented Jun 7, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add GET /recall and POST /forget REST routes that mirror the existing recall/forget MCP tools (semantic search with time-decay reranking, and delete-by-id with vector cleanup)
  • Bring GET /list to filter parity with list_recent (tag, after, before)
  • Standardize all error responses to { ok: false, error } and de-duplicate the repeated auth check via a shared requireAuth helper
  • Extract shared recallEntries/forgetEntry/buildEntryFilterQuery helpers so MCP tools and REST routes share one implementation (mirrors the existing captureEntry pattern)
  • Add integration test coverage for /recall and /forget, plus extended /list and auth tests
  • Update README's endpoint list and link it to the corresponding wiki documentation (which has also been refreshed to cover the new/updated routes)

Test plan

  • npm test — full suite passes (270/270)
  • npx tsc --noEmit — no new type errors
  • Manually exercise GET /recall and POST /forget against a deployed worker with a real AUTH_TOKEN

Adds GET /recall and POST /forget REST routes that mirror the existing
MCP tools, brings GET /list to filter parity with list_recent (tag,
after, before), and standardizes error responses to { ok: false, error }
across all routes. Extracts shared recallEntries/forgetEntry/
buildEntryFilterQuery/requireAuth helpers so the MCP tools and REST
routes share one implementation, mirroring the existing captureEntry
pattern. Includes integration test coverage for both new routes plus
extended list and auth tests.

Also updates the README endpoint list and links it to the corresponding
wiki documentation.
@rahilp rahilp linked an issue Jun 7, 2026 that may be closed by this pull request
5 tasks
@github-actions

github-actions Bot commented Jun 7, 2026

Copy link
Copy Markdown

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 81.27% 547 / 673
🔵 Statements 82.08% 646 / 787
🔵 Functions 80.95% 85 / 105
🔵 Branches 75.78% 385 / 508
File Coverage
File Stmts Branches Functions Lines Uncovered Lines
Changed Files
src/index.ts 80.84% 73.63% 79.38% 80.09% 101-148, 168, 439, 446, 487, 705, 816, 822, 831, 839-859, 922-925, 951, 958, 959, 970, 992-1000, 1008-1010, 1062, 1102, 1115, 1161-1383, 1392-1396, 1409-1434, 1453, 1495, 1533, 1726-1737, 1759, 1769
Generated in workflow #125 for commit c5380c9 by the Vitest Coverage Report Action

@rahilp rahilp merged commit 87c0c3c into main Jun 7, 2026
1 check passed
@rahilp rahilp deleted the 130-add-rest-equivalents-for-recall-and-forget-mcp-tools-plus-api-robustness-fixes branch June 7, 2026 04:56
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 REST equivalents for recall and forget MCP tools, plus API robustness fixes

1 participant