Skip to main content
Glama
PyAEDT-MCP
by yuxuan6426

Display Html

display_html
Read-only

Render self-contained HTML inline or in a detached window to view reports, dashboards, or visual outputs without an AEDT connection.

Instructions

Display self-contained HTML inline or in a detached window.

No AEDT connection is required. Inline scripts and styles are supported, but network requests, external assets, forms, popups, and access to the MCP host are blocked. Embed images as data URLs. This does not execute Python.

In "auto" mode the HTML is shown inline when the client supports MCP Apps. Otherwise it opens in a lightweight detached window (a chromeless Edge/Chrome app window, or the default browser) on the machine running the MCP server. The detached window adjusts to the size of the rendered HTML unless width or height are given.

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": {
      "html": "<html>"
    },
    "name": "display_html"
  }
}

Input Schema

NameRequiredDescriptionDefault
htmlYesHTML document or fragment, up to one million characters.
titleNoAccessible name and window title for the displayed document.Custom HTML
widthNoWindow content width in pixels, between 200 and 3840. By default, the detached window fits the HTML width. Inline viewers use the host width.
heightNoViewer height in pixels, between 200 and 1200. By default, the detached window fits the HTML height and the inline viewer uses 480.
display_modeNo``"auto"`` (default), ``"inline"`` to never open a window, or ``"window"`` to always open a detached window.auto

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

Goes well beyond the readOnlyHint/openWorldHint annotations by enumerating the sandbox restrictions (no network requests, external assets, forms, popups, or host access), prescribing data URLs for images, and explaining exactly how 'auto' mode resolves on clients with and without MCP Apps support. This is the kind of constraint detail an agent cannot infer from structured fields.

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?

Three short paragraphs, each front-loaded with its point: what it does, what is blocked, then how display modes resolve. Nothing is wasted, and the constraint list is compact enough to scan quickly.

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

Completeness5/5

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

For a five-parameter display tool with no output schema, the definition covers purpose, security boundaries, sizing behavior, and mode resolution, leaving no decision an agent needs in order to call it correctly unresolved.

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?

Schema coverage is 100%, so the baseline is 3; the description earns above that by explaining why 'auto' exists (client MCP Apps support) and that the detached window self-sizes unless width/height are supplied, adding rationale the schema does not carry. It does repeat some sizing facts already in the schema, which keeps it from a 5.

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?

States a specific verb and resource ('Display self-contained HTML inline or in a detached window') and immediately scopes it against siblings by clarifying it requires no AEDT connection and does not execute Python, which separates it from run_python_code and the AEDT lifecycle tools.

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?

Gives clear context for use: no AEDT connection needed, self-contained HTML only, with a negative exclusion ('This does not execute Python') that routes the agent elsewhere for code execution. It does not explicitly name run_python_code or screenshot as alternatives, so it stops short of full when/when-not routing.

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