Skip to main content
Glama
obsidian-surface

obsidian-surface

by sespinosa

dev

Execute JavaScript in Obsidian's app context or capture screenshots of the Obsidian window to inspect and automate vault behavior.

Instructions

Developer tools for Obsidian.

Actions:

  • eval: Execute JavaScript in the Obsidian app context (code required)

  • screenshot: Take a screenshot of the Obsidian window (path optional)

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "action": "<action>"
    },
    "name": "dev"
  }
}

Input Schema

NameRequiredDescriptionDefault
codeNoJavaScript code to execute (for eval)
pathNoPath to save screenshot (for screenshot)
actionYesAction to perform

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.8/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden and does very little with it. It never warns that eval runs arbitrary JavaScript with the app's privileges, does not say what eval returns, whether it is awaited, or where the screenshot file lands by default.

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

Conciseness4/5

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

Two-line action list with no filler and the required parameter flagged inline for each action. Compact and front-loaded, though it errs toward under-specification rather than verbosity.

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

Completeness1/5

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

For a tool whose primary action executes arbitrary JavaScript in a live application, a two-bullet description with zero annotations and no output schema is far from complete. It omits execution semantics, error behavior, side effects, and the risk profile an agent must weigh before calling eval.

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?

Schema description coverage is 100%, and the description only restates the action-to-parameter mapping (code for eval, path for screenshot) that the schema already documents. Baseline 3 is appropriate since the schema does the explanatory work.

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?

States it is a developer-tool surface for Obsidian and enumerates the two concrete actions (eval executes JavaScript in app context, screenshot captures the window). An agent can tell what it does, though the umbrella name 'dev' only becomes meaningful through the action list rather than differentiating it from the many note/vault siblings.

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?

Lists the available actions but gives no guidance on when to choose this tool over siblings like note or vault, nor any exclusions. There is no indication of preconditions for eval (e.g., running inside a live Obsidian instance) or when a screenshot is preferable to reading state.

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