Skip to main content
Glama

trash_note

Move a note to trash in Bear Notes using its unique identifier. This tool helps users manage notes by removing unwanted items from their workspace.

Instructions

Move a note to trash

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
note_idYesThe unique identifier of the note (ZUNIQUEIDENTIFIER)

Implementation Reference

  • The core implementation of the trash_note tool, which constructs a Bear x-callback-url and opens it.
    def trash_note(note_id: str) -> dict[str, str]:
        """
        Move a note to trash.
    
        Args:
            note_id: The unique identifier of the note (ZUNIQUEIDENTIFIER)
    
        Returns:
            Dictionary with operation result
        """
        params = {"id": note_id}
    
        query_string = urllib.parse.urlencode(params)
        url = f"bear://x-callback-url/trash?{query_string}"
    
        return _open_bear_url(url)
  • Registration of the trash_note tool in the MCP server list.
        name="trash_note",
        description="Move a note to trash",
        inputSchema={
            "type": "object",
            "properties": {
                "note_id": {
                    "type": "string",
                    "description": "The unique identifier of the note (ZUNIQUEIDENTIFIER)",
                },
            },
            "required": ["note_id"],
        },
    ),
  • Tool call handler logic for trash_note in the MCP server.
    elif name == "trash_note":
        if not isinstance(arguments, dict) or "note_id" not in arguments:
            raise ValueError("Missing required argument: note_id")
    
        result = trash_note(note_id=arguments["note_id"])
        return [TextContent(type="text", text=str(result))]

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/maxim-ist/mcp-bear'

If you have feedback or need assistance with the MCP directory API, please join our Discord server