bear_archive_note
Archive notes in Bear App by specifying a note ID or search term. Manage and organize your notes effectively with this tool, and optionally display the Bear window for direct interaction.
Instructions
Archive a note
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | Note unique identifier | |
| search | No | Search term to find notes to archive | |
| show_window | No | Show Bear window |
Implementation Reference
- src/index.ts:931-948 (handler)The handler function for bear_archive_note. It constructs a Bear URL for the 'archive' action using provided id, search, or show_window parameters, executes the URL via executeURL, and returns a success message describing the action taken.private async archiveNote(args: any) { const params: Record<string, string | boolean> = {}; if (args.id) params.id = args.id; if (args.search) params.search = args.search; if (args.show_window) params.show_window = "yes"; const url = this.buildBearURL("archive", params); await this.executeURL(url); return { content: [ { type: "text", text: `Archived note(s)${args.id ? ` with ID: ${args.id}` : args.search ? ` matching: ${args.search}` : ""}` } ] };
- src/index.ts:532-547 (schema)Input schema defining parameters for the bear_archive_note tool: id (string), search (string), show_window (boolean).inputSchema: { type: "object", properties: { id: { type: "string", description: "Note unique identifier" }, search: { type: "string", description: "Search term to find notes to archive" }, show_window: { type: "boolean", description: "Show Bear window" } }
- src/index.ts:529-549 (registration)Tool registration in the list of tools returned by ListToolsRequestSchema, including name, description, and inputSchema.{ name: "bear_archive_note", description: "Archive a note", inputSchema: { type: "object", properties: { id: { type: "string", description: "Note unique identifier" }, search: { type: "string", description: "Search term to find notes to archive" }, show_window: { type: "boolean", description: "Show Bear window" } } } },
- src/index.ts:721-722 (registration)Switch case in CallToolRequestSchema handler that routes calls to bear_archive_note to the archiveNote method.case "bear_archive_note": return await this.archiveNote(args);