Skip to main content
Glama

Generate an image from a text prompt

image
Read-only

Generate an image from a text prompt (FLUX.1 schnell). Returns a base64 JPEG. Fast, 1024x1024. Price: $0.005 in USDC per successful call, paid with x402 (Base, Solana or Arc); failed calls are not charged.

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": "image"
  }
}

Input Schema

NameRequiredDescriptionDefault
stepsNo1-8, default 4
promptYesUp to 2048 chars

Output Schema

NameRequiredDescriptionDefault
mimeNo
modelNo
image_base64No

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "image_base64": {},
      +    "mime": {},
      +    "model": {}
      +  },
      +  "type": "object"
      +}
  2. First observed

TDQS

A4.1/5.0
Behavior5/5

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

Goes well beyond the annotations: it discloses the returned format (base64 JPEG), fixed 1024x1024 output, the specific model, the per-call price ($0.005 USDC), the x402 payment rails (Base, Solana, Arc), and that failed calls are not charged. That payment precondition is critical context an agent cannot get from readOnlyHint/openWorldHint alone.

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?

A single dense sentence, front-loaded with the action and resource, then model, return format, and cost. Every clause carries decision-relevant information with no 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 two-parameter generation tool with an output schema, the description covers output format, pricing, payment mechanics, and billing failure behavior — everything needed to call it correctly. Return-value detail is appropriately left to the output schema.

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%, with both prompt (up to 2048 chars) and steps (1-8, default 4) already documented in the schema. The description adds no further meaning about how these parameters affect output, so the baseline 3 applies.

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 a specific verb and resource ("Generate an image from a text prompt") plus the concrete model (FLUX.1 schnell) and output form (base64 JPEG). An agent can immediately distinguish this from describe_image, though the description never explicitly contrasts the two directions.

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?

Usage is only implied by the purpose statement — generate when you want a new image. There is no explicit when-to-use/when-not guidance, no mention of the inverse sibling (describe_image) for analyzing existing images, and no note on prompt-shaping expectations.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources