Skip to main content
Glama

generate_image

Create new images from text prompts or edit and combine reference images; saves the result as a file for design, social posts, and presentations.

Instructions

Generate a new image from a text prompt or edit and combine reference images using inputImagePaths. Saves the result and returns a file resource. Prompt enhancement expands these arguments into the final image prompt without seeing the conversation, filling in the details they leave open, so pass the user's intent as they gave it; anything you add is expanded too. When a guess at the image's purpose or style would likely miss what the user needs, ask them first.

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": {
      "prompt": "<prompt>"
    },
    "name": "generate_image"
  }
}

Input Schema

NameRequiredDescriptionDefault
promptYesThe user's request, in English. Put text that should appear in the image in quotes, exactly and in its original language; no other text is added.
purposeNoWhat the image is for, such as a cookbook cover, social media post, or presentation slide. Prompt enhancement decides the medium, composition, tone, and finish from it, so set it whenever the user has stated or implied it.
qualityNoSet only when the user requests a quality level; otherwise omit to use the server default. fast prioritizes speed, balanced trades speed for detail, and quality prioritizes fidelity.
categoryNoSet when the kind of image is clear from the request, so prompt enhancement uses only that kind's guidance: photo, illustration, asset (icon, logo, sticker, or isolated object), ui-screen (app or web interface screen), graphic-design (poster, banner, thumbnail, or other graphic with text), diagram (diagram or infographic), pattern-texture. Omit when unsure.
fileNameNoUse .png, .jpg, or .jpeg to request that output format from OpenAI or Seedream. Other or absent suffixes use the provider default; the saved filename is corrected to the actual image extension.
providerNoSet only when the user requests a specific image provider; otherwise omit to use the server default. The provider must have its API key configured on the server.
imageSizeNoSet the requested output size to 1K, 2K, or 4K. Omit to use the selected provider and quality preset's default. With Seedream, use 1K or 2K.
aspectRatioNoSet the requested output aspect ratio. Omit to use the provider default. OpenAI does not support 1:4, 1:8, 4:1, or 8:1.
blendImagesNoEnable when the prompt combines multiple visual elements that need coherent spatial relationships, lighting, or composition.
inputImagePathsNoAbsolute paths to reference images in prompt order. Use a one-element array for one image. Limits: Gemini 14, OpenAI 16, Seedream 10. Omit for text-only generation.
useGoogleSearchNoEnable when using Gemini and the image requires current or time-sensitive web information. With OpenAI or Seedream, omit this option or set it to false.
useWorldKnowledgeNoEnable when accurate real-world details matter, such as historical figures, landmarks, cultures, or factual settings.
maintainCharacterConsistencyNoEnable when the same character must retain a recognizable appearance across poses or scenes.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.19.0
    • addedInput schema / properties / category
      Added value: +{
      +  "description": "Set when the kind of image is clear from the request, so prompt enhancement uses only that kind's guidance: photo, illustration, asset (icon, logo, sticker, or isolated object), ui-screen (app or web interface screen), graphic-design (poster, banner, thumbnail, or other graphic with text), diagram (diagram or infographic), pattern-texture. Omit when unsure.",
      +  "enum": [
      +    "photo",
      +    "illustration",
      +    "asset",
      +    "ui-screen",
      +    "graphic-design",
      +    "diagram",
      +    "pattern-texture"
      +  ],
      +  "type": "string"
      +}
    • removedInput schema / properties / inputImagePath
      Removed value: -{
      -  "description": "Provide an absolute path to a source image when editing, creating a variation, or transferring style.",
      -  "type": "string"
      -}
    • addedInput schema / properties / inputImagePaths
      Added value: +{
      +  "description": "Absolute paths to reference images in prompt order. Use a one-element array for one image. Limits: Gemini 14, OpenAI 16, Seedream 10. Omit for text-only generation.",
      +  "items": {
      +    "minLength": 1,
      +    "type": "string"
      +  },
      +  "maxItems": 16,
      +  "minItems": 1,
      +  "type": "array"
      +}
    • changedInput schema / properties / prompt / description
      Previous value: -"Describe the image to generate or the edit to apply. Include the subject, context, and visual style; English is recommended for prompt enhancement."New value: +"The user's request, in English. Put text that should appear in the image in quotes, exactly and in its original language; no other text is added."
    • changedInput schema / properties / purpose / description
      Previous value: -"Describe the image's intended use, such as a cookbook cover, social media post, or presentation slide, so prompt enhancement can adapt composition and detail."New value: +"What the image is for, such as a cookbook cover, social media post, or presentation slide. Prompt enhancement decides the medium, composition, tone, and finish from it, so set it whenever the user has stated or implied it."
  2. Changed2 schema fields changedv0.13.2
    • changedInput schema / properties / aspectRatio / description
      Previous value: -"Set the requested output aspect ratio. Omit to use the provider default."New value: +"Set the requested output aspect ratio. Omit to use the provider default. OpenAI does not support 1:4, 1:8, 4:1, or 8:1."
    • addedInput schema / properties / provider
      Added value: +{
      +  "description": "Set only when the user requests a specific image provider; otherwise omit to use the server default. The provider must have its API key configured on the server.",
      +  "enum": [
      +    "gemini",
      +    "openai",
      +    "seedream"
      +  ],
      +  "type": "string"
      +}
  3. Changed11 schema fields changedv0.12.1
    • changedInput schema / properties / aspectRatio / description
      Previous value: -"Aspect ratio for the generated image"New value: +"Set the requested output aspect ratio. Omit to use the provider default."
    • changedInput schema / properties / blendImages / description
      Previous value: -"Enable multi-image blending for combining multiple visual elements naturally. Use when prompt mentions multiple subjects or composite scenes"New value: +"Enable when the prompt combines multiple visual elements that need coherent spatial relationships, lighting, or composition."
    • changedInput schema / properties / fileName / description
      Previous value: -"Custom file name for the output image. Auto-generated if not specified."New value: +"Use .png, .jpg, or .jpeg to request that output format from OpenAI or Seedream. Other or absent suffixes use the provider default; the saved filename is corrected to the actual image extension."
    • changedInput schema / properties / imageSize / description
      Previous value: -"Image resolution for high-quality output. Specify \"1K\", \"2K\", or \"4K\" when you need specific resolution. Leave unspecified for standard quality."New value: +"Set the requested output size to 1K, 2K, or 4K. Omit to use the selected provider and quality preset's default. With Seedream, use 1K or 2K."
    • changedInput schema / properties / inputImagePath / description
      Previous value: -"Optional absolute path to source image for image-to-image generation. Use when generating variations, style transfers, or similar images based on an existing image (must be an absolute path)"New value: +"Provide an absolute path to a source image when editing, creating a variation, or transferring style."
    • changedInput schema / properties / maintainCharacterConsistency / description
      Previous value: -"Maintain character appearance consistency. Enable when generating same character in different poses/scenes"New value: +"Enable when the same character must retain a recognizable appearance across poses or scenes."
    • changedInput schema / properties / prompt / description
      Previous value: -"The prompt for image generation (English recommended for optimal structured prompt enhancement)"New value: +"Describe the image to generate or the edit to apply. Include the subject, context, and visual style; English is recommended for prompt enhancement."
    • changedInput schema / properties / purpose / description
      Previous value: -"Intended use for the image (e.g., cookbook cover, social media post, presentation slide). Influences lighting, composition, and detail level to match the context."New value: +"Describe the image's intended use, such as a cookbook cover, social media post, or presentation slide, so prompt enhancement can adapt composition and detail."
    • changedInput schema / properties / quality / description
      Previous value: -"Quality preset controlling speed/fidelity tradeoff. Only specify when the user explicitly requests a specific quality level; omit to use the server's configured default. \"fast\": best for drafts and rapid iteration. \"balanced\": better detail and coherence, moderate latency. \"quality\": highest fidelity, use for final deliverables where quality matters most."New value: +"Set only when the user requests a quality level; otherwise omit to use the server default. fast prioritizes speed, balanced trades speed for detail, and quality prioritizes fidelity."
    • changedInput schema / properties / useGoogleSearch / description
      Previous value: -"Enable Google Search grounding to access real-time web information for factually accurate image generation. Use when prompt requires current or time-sensitive data that may have changed since the model's knowledge cutoff. Leave disabled for creative, fictional, historical, or timeless content."New value: +"Enable when using Gemini and the image requires current or time-sensitive web information. With OpenAI or Seedream, omit this option or set it to false."
    • changedInput schema / properties / useWorldKnowledge / description
      Previous value: -"Use real-world knowledge for accurate context. Enable for historical figures, landmarks, or factual scenarios"New value: +"Enable when accurate real-world details matter, such as historical figures, landmarks, cultures, or factual settings."
  4. Addedv0.11.0
  5. Removedv0.6.0
  6. Changed4 schema fields changedv1.0.0
    • addedInput schema / properties / aspectRatio
      Added value: +{
      +  "description": "Aspect ratio for the generated image",
      +  "enum": [
      +    "1:1",
      +    "2:3",
      +    "3:2",
      +    "3:4",
      +    "4:3",
      +    "4:5",
      +    "5:4",
      +    "9:16",
      +    "16:9",
      +    "21:9"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / imageSize
      Added value: +{
      +  "description": "Image resolution for high-quality output. Specify \"2K\" or \"4K\" when you need higher resolution images with better text rendering and fine details. Leave unspecified for standard quality.",
      +  "enum": [
      +    "2K",
      +    "4K"
      +  ],
      +  "type": "string"
      +}
    • addedInput schema / properties / purpose
      Added value: +{
      +  "description": "Intended use for the image (e.g., cookbook cover, social media post, presentation slide). Helps tailor visual style, quality level, and details to match the purpose.",
      +  "type": "string"
      +}
    • addedInput schema / properties / useGoogleSearch
      Added value: +{
      +  "description": "Enable Google Search grounding to access real-time web information for factually accurate image generation. Use when prompt requires current or time-sensitive data that may have changed since the model's knowledge cutoff. Leave disabled for creative, fictional, historical, or timeless content.",
      +  "type": "boolean"
      +}
  7. First observed

TDQS

A3.9/5.0
Behavior3/5

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

Annotations are absent, so the description carries the full burden. It discloses the side effect (result is saved and returned as a file resource) and the non-obvious enhancement step that rewrites the arguments without conversation context, which is valuable. It does not cover latency, cost, or failure behavior for a missing provider API key (that detail lives only in the schema), leaving meaningful behavioral gaps.

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?

Front-loaded with what the tool does and what it returns, then caveats. The prompt-enhancement sentence is long and slightly convoluted ('expands these arguments into the final image prompt without seeing the conversation'), but every sentence carries operative information, so little is wasted.

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 13-parameter generation tool with no output schema and no annotations, the description covers the action, the file output, and the prompt-enhancement mental model. Provider limits and format constraints are handled in the rich schema, so what remains missing is mostly operational (latency, cost, error modes) rather than selection-critical.

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%, so the schema already documents every parameter in detail and the baseline is 3. The description adds one genuine point beyond the schema: how prompt and purpose text is consumed by prompt enhancement and why verbatim user intent matters, but it says nothing extra about the other eleven parameters.

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 concrete verb and resource ('Generate a new image') plus a second mode ('edit and combine reference images using inputImagePaths'), and names the return artifact ('returns a file resource'). There are no siblings to disambiguate against, so this is as precise as the definition needs to be.

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 real usage guidance: pass the user's intent verbatim because enhancement expands whatever is written, and ask the user first when a style/purpose guess would likely miss. No alternatives are named, but none exist among siblings, so the only gap is the absence of explicit when-not-to-use conditions (e.g. trivial edits vs new generation).

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

Deploy Server

Other Tools