Skip to main content
Glama

Insert an image

insert_image

Add an inline image to a Google Doc from a public URL, positioned at a specified index or at the document's end. Specify display size in points for precise layout.

Instructions

Inserts an inline image fetched from a PUBLIC URL at an index (or at the end of the body when index is omitted). The URL must be reachable by Google without auth, at most 50 MB and 25 megapixels, in PNG, JPEG or GIF; there is no upload channel — a local file must be hosted somewhere public first. width_pt/height_pt set the displayed size in points (omit both for natural size capped to the page width; when only one is given the API scales the other to keep the aspect ratio). Returns the created objectId in the reply — keep it for replace_image. Delete an image by deleting its range with delete_range (it occupies one index).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
uriYesPublic image URL (PNG/JPEG/GIF, <=50 MB, <=25 MP; fetched by Google, not this server).
indexNoInsertion index (from read_document_text). Omit to append at the end.
tab_idNoTab to target (from list_tabs). Omit for the first/only tab.
width_ptNoDisplayed width in points.
height_ptNoDisplayed height in points.
segment_idNoHeader/footer/footnote segment id (from get_document). Omit for the document body.
document_idYesThe document id — the long id from the document URL (docs.google.com/document/d/<documentId>/edit) or from create_document output.
Behavior5/5

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

Annotations only state readOnly=false and non-destructive; the description adds substantial behavioral detail: Google fetches the image, 50 MB/25 MP constraints, natural size capped to page width, aspect-ratio scaling when one dimension is given, and that the image occupies one index. It even explains deletion via delete_range, which goes beyond annotation coverage.

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 front-loaded with the main action and uses four dense but purposeful sentences. Constraints, defaults, return value, and deletion workflow each earn their place without redundancies or filler.

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 7-parameter tool with no output schema, the description covers what an agent needs: insertion behavior, required URL properties, size semantics, the returned objectId, and how to delete/replace. Remaining parameter details are already in the schema, so no critical context is missing.

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

Parameters5/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, but the description meaningfully enriches several parameters. It explains the width_pt/height_pt aspect-ratio behavior and natural-size default, clarifies 'no upload channel' for the uri, and states that a returned objectId is intended for replace_image — none of which are in the schema.

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 opens with a specific verb and resource: 'Inserts an inline image fetched from a PUBLIC URL at an index', clearly distinguishing it from insert_text, insert_table, and insert_break. It also clarifies the end-of-body default when index is omitted, so the tool's core behavior is unambiguous.

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 gives clear preconditions and operating context: the URL must be publicly reachable by Google, within size/format limits, and there is no upload channel, so local files must be hosted first. It points to replace_image and delete_range for follow-up actions, though it does not explicitly state conditions for choosing insert_image over a sibling tool.

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/A1-x-Tech/mcp-google-docs'

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