Skip to main content
Glama

Generate Image

generate_image
Destructive

Start generating an image from a prompt with AdaptlyPost AI. This is asynchronous: it returns { jobId, sessionId, status } right away with status queued, not the image. Poll get_image_job with the jobId every few seconds until status is completed or failed (usually 10 to 40 seconds), or wait for the image.completed or image.failed webhook if the workspace has one. A completed job carries imageUrl, a public URL you can pass straight into mediaUrls of create_post, so there is no need to run it through upload_media. The image is also saved to the member's AI image studio in AdaptlyPost; reuse sessionId to group related images. Needs the ai.generate permission, which Admin, Editor and Contributor hold and Viewer does not (403 permission_denied). Charges the member's AI credits when generation starts (2 for standard, 4 for premium) unless the member has their own image provider key connected in AdaptlyPost, and refunds them if generation fails. With no credits left the job ends as failed and its error says so: explain that generation is unavailable with the current credit balance and do not retry automatically.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modelNostandard (default, 2 credits) or premium (higher fidelity, 4 credits)
promptYesWhat the image should show, including style and composition (max 2000 characters)
qualityNoLOW, MEDIUM or HIGH rendering quality
sessionIdNoImage studio session to add the image to, as returned by an earlier generate_image. Omit to start a new session
aspectRatioNoImage shape (default 1:1). Pick one that suits the target platform, e.g. 9:16 for stories and reels, 4:5 for Instagram feed, 16:9 for YouTube and X
workspaceIdNoWorkspace to act in: an id from list_workspaces. Omit to act in the workspace list_workspaces marks current. Use the same workspaceId for every call about the same workspace, since ids from one workspace (accounts, posts, uploads) do not exist in another
referenceImagesNoUp to 5 public image URLs that steer the style or subject of the result

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultNoAn object with jobId (pass it to get_image_job), sessionId, and status (queued).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • removedOutput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
  2. Added

TDQS

A4.6/5.0
Behavior5/5

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

With annotations covering mutation/safety hints, the description adds substantial operational context: asynchronous job semantics, returned { jobId, sessionId, status }, polling vs webhook, 10-40 second typical duration, permission requirement (ai.generate, with role exclusions and 403), credit cost and refund behavior, no-credit failure mode, and explicit advice not to retry. This far exceeds what the annotations disclose.

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?

The description is front-loaded with the core action and async behavior, and every sentence carries information useful for correct invocation or integration. It is necessarily long given the async job, credit, permission, webhook, and integration details, though a bulleted structure could improve scanability.

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 complex asynchronous, credit-consuming, permission-gated tool, the description covers all agent-relevant behavior: return shape, polling/webhook options, timing, integration with create_post, permission errors, credit costs, refunds, and no-credit guidance. The presence of an output schema does not leave gaps, and the description is complete for correct use.

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 parameter descriptions already document prompt, model, quality, aspectRatio, sessionId, workspaceId, and referenceImages thoroughly. The description adds only marginal parameter meaning, such as reusing sessionId to group related images; baseline 3 is appropriate when the schema does the heavy lifting.

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 specific verb and resource ('Start generating an image from a prompt') and immediately distinguishes the tool from siblings by naming get_image_job for polling, create_post for using the result, and upload_media as unnecessary. An agent can identify exactly what this tool does and how it differs from adjacent tools.

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

Usage Guidelines5/5

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

Gives explicit post-call workflow (poll get_image_job every few seconds until completed/failed, or wait for image.completed/image.failed webhook) and routes the result into create_post's mediaUrls instead of upload_media. It also states when not to retry automatically after a no-credit failure, covering both how and when to use the tool versus alternatives.

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