obsidian_exec
Executes any official Obsidian CLI command to search, read, create, and manage notes in your vault, returning the output.
Instructions
Execute any official Obsidian CLI command and return its output.
This tool wraps the obsidian CLI binary installed on the host machine.
Pass the sub-command and arguments as a single string (without the leading obsidian binary name).
Blocked commands (configurable): eval, restart, devtools, dev:cdp, dev:css, dev:debug, dev:dom, dev:mobile
Common examples: command="search query="meeting notes" limit=10" command="read file=MyNote" command="tasks todo" command="tags counts sort=count" command="create name=NewNote content="Hello world"" command="properties file=MyNote" command="backlinks file=MyNote" command="files folder=Projects ext=md" command="bookmarks" command="help search"
For a full list of commands, use: command="help"
Args:
command (string, required): The CLI sub-command and arguments
vault (string, optional): Target vault name
Returns: The raw stdout from the CLI. If the command fails, stderr and exit code are included.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| vault | No | Target a specific vault by name. Omit to use the active vault. | |
| command | Yes | The Obsidian CLI command to execute, e.g. "search query=hello limit=5" or "read file=MyNote". Do NOT include the leading `obsidian` binary name — just the sub-command and its arguments. |