bear_grab_url
Extract web page content to create notes in Bear App, enabling users to save online information directly into their note-taking workflow.
Instructions
Create a note from web page content
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | URL to grab content from | |
| tags | No | Comma-separated list of tags | |
| pin | No | Pin note to top of list | |
| wait | No | Wait for content to load |
Implementation Reference
- src/index.ts:630-655 (registration)Registration of the 'bear_grab_url' tool in the ListTools response, including name, description, and input schema.{ name: "bear_grab_url", description: "Create a note from web page content", inputSchema: { type: "object", properties: { url: { type: "string", description: "URL to grab content from" }, tags: { type: "string", description: "Comma-separated list of tags" }, pin: { type: "boolean", description: "Pin note to top of list" }, wait: { type: "boolean", description: "Wait for content to load" } }, required: ["url"] } },
- src/index.ts:731-732 (registration)Dispatch/registration case in the CallToolRequestSchema switch statement that routes to the grabUrl handler.case "bear_grab_url": return await this.grabUrl(args);
- src/index.ts:1064-1084 (handler)The handler function 'grabUrl' that constructs Bear 'grab-url' parameters, executes via callback, and formats response with created note data.private async grabUrl(args: any) { const params: Record<string, string | boolean> = { url: args.url }; if (args.tags) params.tags = args.tags; if (args.pin) params.pin = "yes"; if (args.wait) params.wait = "yes"; const grabData = await this.executeWithCallback("grab-url", params); return { content: [ { type: "text", text: JSON.stringify({ message: `Created note from URL: ${args.url}`, note: grabData }, null, 2) } ] }; }