Skip to main content
Glama

generate_embed

Generates an iframe embed code for sharing a Plotly chart on websites or blogs. Returns the HTML snippet, width, height, and accessibility note.

Instructions

Generate iframe embed code for sharing a chart in websites/blogs.

Self-contained embed snippet pasteable into any website or CMS. Renders via Plotly.js CDN.

Returns: {iframe_code, width, height, note}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
titleNoAccessible title for the iframeChart
widthNoEmbed width in pixels
figureYesPlotly figure dict from create_chart()
heightNoEmbed height in pixels

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior3/5

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

No annotations are provided, so the description must disclose behavioral traits. It notes the output structure (iframe_code, width, height, note) and that it renders via Plotly.js CDN. However, it does not mention any dependencies, limitations (e.g., requires internet access for CDN), or side effects. The transparency is adequate but not comprehensive.

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 very concise: four sentences with no fluff. It front-loads the purpose in the first sentence, then describes the output and return structure. Every sentence earns its place, and the length is appropriate for the tool's simplicity.

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?

For a simple tool with high schema coverage and an output schema, the description covers the essential input (figure from create_chart()) and output structure. It implies a prerequisite (a chart must be created first). One could argue it could mention the embed code's reliance on the Plotly CDN, but overall it is sufficiently complete for an agent to use correctly.

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 coverage is 100%, so the baseline is 3. The description adds minimal extra meaning beyond the schema: it notes that 'figure' is a Plotly figure dict from create_chart(), which is already in the parameter description. The description does not elaborate on parameter usage or constraints, so it scores at baseline.

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 generates iframe embed code for sharing a chart. It specifies the resource (embed code) and the action (generate for sharing). Among sibling tools like export_chart_pdf or export_visualization, this one uniquely focuses on embedding, so it is well-differentiated.

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

Usage Guidelines3/5

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

The description indicates the embed snippet is for websites/blogs and is self-contained, giving a sense of when to use. However, it does not explicitly compare to alternatives (e.g., export tools) or state when not to use it. The guidance is implied but not explicit enough for an agent to easily decide between this and similar export tools.

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/acailic/serbian-data-mcp'

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