Skip to main content
Glama
runapi-ai

@runapi.ai/gpt-image-2-mcp

Official
by runapi-ai

text_to_image

Generate images from text prompts by creating a GPT Image 2 task on RunAPI, returning a task ID, status, and output URLs.

Instructions

Create a GPT Image 2 task on RunAPI (text to image). Returns a task id, status, and output URLs.

Input Schema

NameRequiredDescriptionDefault
waitNoPoll until the task reaches a terminal status.
modelNoRunAPI model slug for this model line.
promptYesDeclared type: string.
backgroundNoDeclared type: string. Known values: "transparent", "opaque", "auto".
timeout_msNo
aspect_ratioNoDeclared type: string. Known values: "auto", "1:1", "3:2", "2:3", "4:3", "3:4", "5:4", "4:5", "16:9", "9:16", "2:1", "1:2", "3:1", "1:3", "21:9", "9:21".
callback_urlNoDeclared type: string.
poll_interval_msNo
output_resolutionNoDeclared type: string. Known values: "1k", "2k", "4k".

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.3.0
    • addedInput schema / properties / background
      Added value: +{
      +  "description": "Declared type: string. Known values: \"transparent\", \"opaque\", \"auto\".",
      +  "type": "string"
      +}
  2. Changed12 schema fields changedv0.2.0
    • changedInput schema / additionalProperties
      Previous value: -falseNew value: +{}
    • addedInput schema / properties / aspect_ratio / description
      Added value: +"Declared type: string. Known values: \"auto\", \"1:1\", \"3:2\", \"2:3\", \"4:3\", \"3:4\", \"5:4\", \"4:5\", \"16:9\", \"9:16\", \"2:1\", \"1:2\", \"3:1\", \"1:3\", \"21:9\", \"9:21\"."
    • removedInput schema / properties / aspect_ratio / enum
      Removed value: -[
      -  "auto",
      -  "1:1",
      -  "3:2",
      -  "2:3",
      -  "4:3",
      -  "3:4",
      -  "5:4",
      -  "4:5",
      -  "16:9",
      -  "9:16",
      -  "2:1",
      -  "1:2",
      -  "3:1",
      -  "1:3",
      -  "21:9",
      -  "9:21"
      -]
    • addedInput schema / properties / callback_url
      Added value: +{
      +  "description": "Declared type: string.",
      +  "type": "string"
      +}
    • removedInput schema / properties / model / enum
      Removed value: -[
      -  "gpt-image-2"
      -]
    • addedInput schema / properties / output_resolution / description
      Added value: +"Declared type: string. Known values: \"1k\", \"2k\", \"4k\"."
    • removedInput schema / properties / output_resolution / enum
      Removed value: -[
      -  "1k",
      -  "2k",
      -  "4k"
      -]
    • addedInput schema / properties / poll_interval_ms / maximum
      Added value: +9007199254740991
    • addedInput schema / properties / prompt / description
      Added value: +"Declared type: string."
    • addedInput schema / properties / prompt / type
      Added value: +"string"
    • addedInput schema / properties / timeout_ms / maximum
      Added value: +9007199254740991
    • addedInput schema / required
      Added value: +[
      +  "prompt"
      +]
  3. First observedv0.1.0

TDQS

B3.2/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, but it does add real value by disclosing the return shape ('task id, status, and output URLs') and implying an async task model. However it omits auth/cost/rate-limit context, whether generation is billed, and how the wait parameter changes behavior — gaps that matter for a 9-param generation tool.

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?

Two short, front-loaded sentences with zero filler. Purpose comes first, return shape second, and nothing is redundant.

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

Completeness2/5

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

For a 9-parameter tool with no annotations and no output schema, the description is thin: it never explains the async task/polling workflow, the role of wait/timeout_ms/poll_interval_ms, or the relationship to the get_task sibling. It covers only what the tool is and roughly what it returns.

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 78%, near the high band, and the description contributes no parameter-level detail at all — nothing about prompt, aspect_ratio, output_resolution, background, timeout_ms, or the polling controls. Baseline 3 is appropriate since the schema does most of the work.

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 ('Create a GPT Image 2 task'), and the parenthetical '(text to image)' distinguishes it from the edit_image sibling. It is clear what the tool does, though it never explicitly names edit_image as the alternative for image-editing workflows.

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

Usage Guidelines2/5

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

No when-to-use guidance beyond the parenthetical 'text to image' label. It does not say when to prefer this over edit_image, when to set wait=true vs polling via get_task, or any prerequisites. Usage is only weakly implied.

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