Skip to main content
Glama
sunub

Obsidian MCP Server

Organize Attachments

organize_attachments

Scan a markdown file for linked images, move them into a folder named after the document, and update all links automatically.

Instructions

Scans a specified markdown file for linked images (or other attachments), moves them to a dedicated folder named after the document's title, and updates the links within the markdown file automatically.

Use Cases:

  • When a post is finalized and you want to clean up all associated images into a neat folder.

  • To automatically organize attachments for better vault management.

Example Workflow:

  1. Specify 'my-awesome-post.md' as the fileName.

  2. The tool finds the 'title' property in the frontmatter (e.g., "My Awesome Post").

  3. It finds all image links like ![[my-image.png]].

  4. It creates a folder at '{vault}/images/My Awesome Post/'.

  5. It moves 'my-image.png' into that new folder.

  6. It updates the link in the markdown file to ![[images/My Awesome Post/my-image.png]].

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keywordYesA keyword to search for the markdown file within the vault.
destinationNoThe base folder to move attachments into. Defaults to "images".images
useTitleAsFolderNameNoIf true, creates a subfolder named after the document title. Defaults to true.
quietNoIf true, returns a minimal success message.
Behavior4/5

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

The description openly describes the tool's actions: scanning a file, moving attachments to a new folder, and updating links. This discloses its mutating behavior, aligning with the openWorldHint annotation. It doesn't elaborate on reversibility or permissions, but the core behavior is transparent.

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 concise and well-structured, starting with a clear action, followed by use cases and an example workflow. Every sentence adds meaningful information without redundancy.

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

Completeness4/5

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

Given the tool's complexity (4 parameters, no output schema), the description covers the process thoroughly, including the steps and file organization. It does not explain return values or error handling, but this is acceptable since there is no output schema. The example workflow compensates for minor gaps.

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

Parameters3/5

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

All four parameters have descriptions in the input schema, and the description adds value through an example workflow that illustrates how keyword, destination, and useTitleAsFolderName are used. The quiet parameter is not elaborated in the description beyond the schema, so the description adds limited additional semantics beyond the schema's descriptions.

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

Purpose5/5

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

The description clearly states the tool scans a markdown file for attachments, moves them to a dedicated folder, and updates links. It includes specific use cases and an example workflow, making the purpose unmistakable and distinct from sibling tools like create_document_with_properties or vault.

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

Usage Guidelines4/5

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

The description provides clear use cases, such as when a post is finalized and you want to clean up attachments. However, it does not explicitly state when not to use the tool or mention alternatives, though the sibling tools are sufficiently different to avoid confusion.

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/sunub/obsidian-mcp-server'

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