Skip to main content
Glama
sayranovv
by sayranovv

create_note

Create a new Markdown note with a title, content, and optional tags to organize information in the Notes MCP Server.

Instructions

Create a new Markdown note

Args: title: Note title content: Note content tags: Optional comma-separated list of tags

Returns: Confirmation message of note creation

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
titleYes
contentYes
tagsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The handler function for the 'create_note' tool. Decorated with @mcp.tool(), it creates a new Markdown note file with timestamped filename, adds metadata like creation date and tags, writes the content, and returns a confirmation.
    def create_note(title: str, content: str, tags: str = "") -> str:
        """
        Create a new Markdown note
        
        Args:
            title: Note title
            content: Note content
            tags: Optional comma-separated list of tags
        
        Returns:
            Confirmation message of note creation
        """
        ensure_notes_dir()
        
        timestamp = datetime.now().strftime("%Y%m%d_%H%M%S")
        filename = f"{timestamp}_{sanitize_filename(title)}.md"
        filepath = os.path.join(NOTES_DIR, filename)
        
        note_content = f"# {title}\n\n"
        note_content += f"**Created:** {datetime.now().strftime('%Y-%m-%d %H:%M:%S')}\n"
        if tags:
            note_content += f"**Tags:** {tags}\n"
        note_content += f"\n---\n\n{content}\n"
        
        with open(filepath, "w", encoding="utf-8") as f:
            f.write(note_content)
        
        return f"Note '{title}' created: {filename}"
  • Helper function to sanitize note titles for safe filenames, used in create_note.
    def sanitize_filename(title: str) -> str:
        """Converts a note title into a safe filename"""
        safe_title = re.sub(r'[^\w\s-]', '', title)
        safe_title = re.sub(r'\s+', '_', safe_title)
        return safe_title.lower()[:100]
  • Helper function to ensure the notes directory exists, called by create_note.
    def ensure_notes_dir():
        """Creates the notes directory if it does not exist"""
        Path(NOTES_DIR).mkdir(exist_ok=True)
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. It states the tool creates a note and returns a confirmation message, but it doesn't cover critical aspects like whether this requires specific permissions, if it's idempotent, what happens on duplicate titles, or any rate limits. For a mutation tool with zero annotation coverage, this is inadequate.

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 highly concise and well-structured. It starts with a clear purpose statement, followed by bullet points for arguments and returns, with no wasted words. Every sentence earns its place by providing essential information in a readable format.

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

Completeness3/5

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

Given that there is an output schema (though not provided here), the description doesn't need to detail return values. However, as a mutation tool with no annotations and incomplete behavioral transparency, it should do more to explain side effects or constraints. The parameter semantics are well-covered, but overall completeness is only adequate.

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

Parameters4/5

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

The description adds meaningful context beyond the input schema, which has 0% description coverage. It explains that 'title' is the note title, 'content' is the note content, and 'tags' is an optional comma-separated list. This clarifies the purpose and format of each parameter, compensating well for the schema's lack of descriptions.

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

Purpose4/5

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

The description clearly states the tool's purpose: 'Create a new Markdown note.' It specifies the verb ('Create') and resource ('Markdown note'), making it easy to understand what the tool does. However, it doesn't explicitly differentiate from sibling tools like 'update_note' or 'delete_note' beyond the creation aspect, which prevents a perfect score.

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?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites, such as needing authentication or specific contexts, or when not to use it (e.g., for updating existing notes). With sibling tools like 'update_note' and 'delete_note' available, this lack of differentiation is a significant gap.

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/sayranovv/notes-mcp-server'

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