search_notes
Search your NotePlan notes using natural language queries to quickly find specific information within your note collection.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The search query |
Implementation Reference
- src/services/noteService.ts:219-226 (handler)Core handler function implementing note search by filtering cached notes where the query matches title or content case-insensitively.function searchNotes(query: string): Note[] { const notes = getAllNotes(); const lowerQuery = query.toLowerCase(); return notes.filter(note => note.title.toLowerCase().includes(lowerQuery) || note.content.toLowerCase().includes(lowerQuery) ); }
- src/index.ts:56-58 (schema)Zod input schema for the search_notes tool defining the 'query' parameter.{ query: z.string().describe('The search query'), },
- src/index.ts:54-70 (registration)Registration of the 'search_notes' MCP tool, including schema and thin handler that delegates to noteService.searchNotes and formats response.server.tool( 'search_notes', { query: z.string().describe('The search query'), }, async ({ query }) => { const results = noteService.searchNotes(query); return { content: [ { type: 'text', text: JSON.stringify(results, null, 2), }, ], }; } );