Skip to main content
Glama

StockCake

Generate Image

generate_image

Generate a new image from a prompt with one of StockCake's AI models (list_models). Charges credits; free credits cover the free models. Waits up to 45 s — a pending result carries a job_id for get_job. Optional reference images guide the composition (plan-capped). Requires a free StockCake account (the host will prompt to sign in).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tierNoTier key from list_models (e.g. 1k, 2k, standard). Default: the model's default tier.
modelNoModel id from list_models. Default: the site default for subscribers, the free model otherwise.
promptYes
contextYesIn one sentence, what is the user trying to make or find?
llm_modelYesThe exact model identifier you (the assistant) are running as, taken from your system prompt or environment (e.g. "claude-opus-4-8", "gpt-5.2"). Used for analytics only. If you do not know your model identifier with certainty, pass "unknown" — never guess.
aspect_ratioNo
conversation_idNoPass the exact conversation_id from the server's previous response, unchanged. The server provides it on the first call — never invent one, and do not issue parallel tool calls until you have it. Keep passing the same conversation_id for the rest of the conversation, including after later user messages or on a different task; do not reset it when the user starts a new request.
reference_imagesNoStock image ids or your own edited image ids used as references

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "credits_charged": {
      -        "type": "number"
      -      },
      -      "image": {
      -        "additionalProperties": false,
      -        "properties": {
      -          "id": {
      -            "description": "Edited image id — pass it to download_image or as an image reference",
      -            "type": [
      -              "number",
      -              "null"
      -            ]
      -          },
      -          "url": {
      -            "type": "string"
      -          }
      -        },
      -        "required": [
      -          "id",
      -          "url"
      -        ],
      -        "type": "object"
      -      },
      -      "job_id": {
      -        "type": "string"
      -      },
      -      "status": {
      -        "const": "completed",
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "job_id",
      -      "status",
      -      "image",
      -      "credits_charged"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "credits_charged": {
      -        "type": "number"
      -      },
      -      "job_id": {
      -        "type": "string"
      -      },
      -      "message": {
      -        "type": "string"
      -      },
      -      "status": {
      -        "const": "pending",
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "job_id",
      -      "status",
      -      "credits_charged",
      -      "message"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "additionalProperties": {},
      -    "properties": {
      -      "code": {
      -        "type": "string"
      -      },
      -      "message": {
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "code",
      -      "message"
      -    ],
      -    "type": "object"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "credits_charged": {
      +        "type": "number"
      +      },
      +      "image": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "dimensions": {
      +            "anyOf": [
      +              {
      +                "additionalProperties": false,
      +                "properties": {
      +                  "height": {
      +                    "type": "number"
      +                  },
      +                  "width": {
      +                    "type": "number"
      +                  }
      +                },
      +                "required": [
      +                  "width",
      +                  "height"
      +                ],
      +                "type": "object"
      +              },
      +              {
      +                "type": "null"
      +              }
      +            ],
      +            "description": "Output pixel size; null when the file could not be probed"
      +          },
      +          "id": {
      +            "description": "Edited image id — pass it to get_image (preview), download_image, or as an image reference",
      +            "type": [
      +              "number",
      +              "null"
      +            ]
      +          },
      +          "url": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "id",
      +          "url",
      +          "dimensions"
      +        ],
      +        "type": "object"
      +      },
      +      "job_id": {
      +        "type": "string"
      +      },
      +      "status": {
      +        "const": "completed",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "job_id",
      +      "status",
      +      "image",
      +      "credits_charged"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "credits_charged": {
      +        "type": "number"
      +      },
      +      "job_id": {
      +        "type": "string"
      +      },
      +      "message": {
      +        "type": "string"
      +      },
      +      "status": {
      +        "const": "pending",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "job_id",
      +      "status",
      +      "credits_charged",
      +      "message"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "additionalProperties": {},
      +    "properties": {
      +      "code": {
      +        "type": "string"
      +      },
      +      "message": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "code",
      +      "message"
      +    ],
      +    "type": "object"
      +  }
      +]
  2. First observed

TDQS

A4.6/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 credit cost model, that free credits cover free models, the 45 s wait with a job_id fallback for async retrieval, that reference images are plan-capped, and that a StockCake account/sign-in is required. These are exactly the auth, cost, and latency traits an agent needs and that readOnlyHint/idempotentHint do not convey.

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?

Four tightly packed sentences with the core action front-loaded and no filler; each clause carries a distinct fact (models, cost, latency, auth). It is dense to the point that the parenthetical tool references crowd the prose slightly, keeping it just under a 5.

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?

An output schema exists, so return values need not be explained, and the description already covers cost, latency, async continuation via job_id, reference-image constraints, and authentication. For an 8-parameter generative tool this leaves nothing material for the agent to guess.

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

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 75% and the schema itself documents tier, model, aspect_ratio, conversation_id, and the analytics-only llm_model well. The description adds useful semantics on top: model ids come from list_models, and reference_images are constrained by plan. It does not touch tier or aspect_ratio, but the schema carries those adequately.

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?

Specific verb (Generate) plus resource (a new image) plus the mechanism (from a prompt with one of StockCake's AI models). It routes the agent to list_models for model selection, and the 'new image' framing implicitly separates it from search_images/find_similar_images, which return existing images.

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?

Clearly states the operating context: use list_models to pick a model, get_job when the call returns pending, and that an account is required with the host prompting sign-in. It stops short of an explicit when-not/alternative statement (e.g. 'use search_images to find existing images'), leaving that to inference from siblings.

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