Skip to main content
Glama

add-note

Create and store notes with name and content in MCPilot's unified AI toolchain environment.

Instructions

Add a new note

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
contentYes

Implementation Reference

  • The `handle_call_tool` function executes the `add-note` tool by validating arguments, updating the global `notes` dictionary with the new note, notifying clients of resource changes, and returning a confirmation message.
    @server.call_tool()
    async def handle_call_tool(
        name: str, arguments: dict | None
    ) -> list[types.TextContent | types.ImageContent | types.EmbeddedResource]:
        """
        Handle tool execution requests.
        Tools can modify server state and notify clients of changes.
        """
        if name != "add-note":
            raise ValueError(f"Unknown tool: {name}")
    
        if not arguments:
            raise ValueError("Missing arguments")
    
        note_name = arguments.get("name")
        content = arguments.get("content")
    
        if not note_name or not content:
            raise ValueError("Missing name or content")
    
        # Update server state
        notes[note_name] = content
    
        # Notify clients that resources have changed
        await server.request_context.session.send_resource_list_changed()
    
        return [
            types.TextContent(
                type="text",
                text=f"Added note '{note_name}' with content: {content}",
            )
        ]
  • The `add-note` tool is registered in the `handle_list_tools` function, which returns a list containing this tool definition.
        types.Tool(
            name="add-note",
            description="Add a new note",
            inputSchema={
                "type": "object",
                "properties": {
                    "name": {"type": "string"},
                    "content": {"type": "string"},
                },
                "required": ["name", "content"],
            },
        )
    ]
  • JSON schema defining the input arguments for the `add-note` tool: required `name` and `content` strings.
    inputSchema={
        "type": "object",
        "properties": {
            "name": {"type": "string"},
            "content": {"type": "string"},
        },
        "required": ["name", "content"],
    },
  • Global `notes` dictionary used to store note state, modified by the `add-note` tool.
    # Store notes as a simple key-value dict to demonstrate state management
    notes: dict[str, str] = {}
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Add a new note' implies a write operation but doesn't specify permissions, side effects, error handling, or response format. This leaves critical behavioral traits like mutation impact and authentication needs unaddressed, which is inadequate for a tool with no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is extremely concise with a single sentence, 'Add a new note', which is front-loaded and wastes no words. However, this conciseness comes at the cost of under-specification, but structurally, it's efficient and to the point.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (a write operation with 2 parameters), lack of annotations, and no output schema, the description is incomplete. It doesn't explain what the tool returns, how errors are handled, or provide enough context for safe and effective use, making it insufficient for the agent's needs.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate for undocumented parameters. It adds no information about the two required parameters ('name' and 'content'), such as their meaning, format, or constraints. This fails to provide value beyond the bare schema, leaving parameters semantically unclear.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose2/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Add a new note' restates the tool name 'add-note' with minimal elaboration, making it tautological. It specifies the verb 'add' and resource 'note' but lacks details like where notes are added or what distinguishes this from other note operations. Without sibling tools, differentiation isn't needed, but the purpose remains vague beyond the name.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool, such as prerequisites, alternatives, or context. The description doesn't mention any constraints or scenarios for usage, leaving the agent with no direction beyond the basic action implied by the name.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/ferrary7/MCPilot'

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