Skip to main content
Glama

Estimate Cost (Free)

estimate_inference_cost
Read-onlyIdempotent

Estimate generation cost using the public /v1/inferences endpoint with check_cost=true.

Use input_image for the main source image, reference_images for extra per-inference guidance, and style_reference_images only on create_user_style/update_user_style.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
widthYesOutput width in pixels. Each style enforces its own limits; check list_available_styles or get_style_usage. Genre-native sizes per item: Minecraft 16; items/icons/props 32-64; character sprites 16-48 retro or 96-128 showcase; tiles 16-32; portraits 96-128; full scenes 256 (RD Pro's max; 16:9 scenes = 256x144 — pixel art integer-upscales losslessly).
heightYesOutput height in pixels. Each style enforces its own limits; check list_available_styles or get_style_usage.
promptYesDescribe the SUBJECT only, richly and concretely ('a squat round flask of glowing crimson liquid, cork stopper, bright highlight on the upper-left rim' beats 'a potion'). Never write 'pixel art' — the selected style handles all rendering. For standalone assets, state a flat background color that contrasts the subject (default 'on a plain white background') and pair with remove_bg=true; never write 'transparent background' (that is remove_bg's job), and never leave the background unstated (it drifts to drab dark gray). Scenes instead describe their real environment.
strengthNoHow strongly to change input_image, 0-1 (default 0.75). Lower values keep more of the original.
num_imagesNoHow many images to generate in one batch; a batch produces varied takes of one prompt (the right way to get N distinct items as individually usable images — never pack N items into a single sheet/grid image unless a sheet IS the deliverable). Style-specific maximums apply.
rd_api_keyNoRetroDiffusion API key (rdpk-...) for this call only; overrides session or header auth.
input_imageNoBase64 PNG used as the main source image for edits, variations, tilesets, animations, or styles that require a starting frame. Raw base64 or a data URL. Send the NATIVE-resolution image: an upscaled display copy (e.g. a 96px sprite exported at 4x = 384px) exceeds style ranges and gets rejected — downscale to the true pixel grid first. For advanced animations the frame's dimensions must equal width/height, and sprites whose opaque pixels touch the canvas edge animate badly (pad onto a larger transparent canvas first, e.g. 48x48 content onto 64x64).
extra_promptNoSecondary prompt for styles that use one (e.g. the transition texture in advanced tilesets).
prompt_styleYesStyle id from list_available_styles (e.g. 'rd_fast__default', 'rd_pro__isometric', or a custom 'user__...' style).
input_paletteNoBase64 image of a color palette; output colors are constrained to it.
frames_durationNoAnimation frame count for animation styles: 4, 6, 8, 10, 12, or 16. Pick deliberately: 8 is the sweet spot for loops (walking, idle), 6 for a snappy single action, 10-12 for flowing ambient motion.
timeout_secondsNoRead-timeout override in seconds for this call; increase for animations or large batches.
reference_imagesNoExtra per-inference guidance images (base64), only for styles where supports_reference_images is true. Not for defining custom styles.
extra_input_imageNoSecond base64 input image for styles that use one (e.g. the second texture in rd_tile__tileset_advanced).
return_pre_paletteNoAlso return the render from before palette constraints were applied.
return_spritesheetNoFor animation styles: return a PNG sprite sheet instead of a GIF.
return_non_bg_removedNoAlso return the render from before background removal was applied.
upscale_output_factorNoInteger upscale factor for the output image; 1 returns the native pixel size.
bypass_prompt_expansionNoSkip the automatic LLM prompt enrichment and use the prompt verbatim.
include_downloadable_dataNoInclude extra structured assets when available (e.g. tileset atlas JSON, animation frame data).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

TDQS

B3.4/5.0
Behavior3/5

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

No contradiction with annotations (readOnlyHint/idempotentHint/destructiveHint=false all align with an estimation tool). The description adds the check_cost=true mechanism and confirms it is a read-only public endpoint. But it does not say what the estimate contains (credit cost vs token count) or confirm no image is produced beyond the implicit read-only nature — annotations already carry the safety profile, so the additional behavioral value is modest.

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?

Two sentences, front-loaded with the core purpose and endpoint, followed by a tight parameter-routing note. No filler or repetition of annotation/schema data. Minor loss: it could afford one more sentence on when to use it versus the create tools.

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

Completeness3/5

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

With an output schema present and 100% parameter coverage, the description need not enumerate returns. Yet for a 20-parameter tool it is thin: it does not tie the tool into the create workflow (estimate before commit) nor explicitly distinguish it from estimate_edit_tool_cost, leaving the agent to infer the main use case from the title.

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 baseline is 3 and the schema does the heavy lifting on all 20 parameters. The description adds value by routing image-parameter usage (reference_images for per-inference guidance; style_reference_images never here), but it does not go beyond that into semantics that the schema already documents.

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+resource ('Estimate generation cost using the public /v1/inferences endpoint with check_cost=true') that clearly differentiates from the sibling estimate_edit_tool_cost (which estimates edit-tool cost). The distinction from create_inference is implicit rather than named, so it loses the top score.

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?

The parameter-routing sentence does disambiguate image inputs (input_image/reference_images here; style_reference_images belongs on create_user_style/update_user_style), which is useful routing. However, it never states when to choose this tool versus create_inference/start_inference_job, e.g. 'call this to preview the credit cost before generating' — the free/dry-run nature is left to the title and convention rather than explicit guidance.

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.

TDQS

A4.1/5.0
Disambiguation5/5

Each tool targets a distinct operation: authentication, inference (sync/async/edit), style management, listing, and utility. Even similar tools like create_inference and start_inference_job are clearly differentiated by synchronous vs async execution.

Naming Consistency5/5

All tool names follow the same verb_noun snake_case pattern (e.g., create_inference, get_balance, list_available_styles). No mixed conventions or inconsistent verb forms.

Tool Count4/5

With 19 tools, the count is slightly above the typical 3-15 range, but each tool serves a specific and necessary function for pixel art generation, editing, and management, so it remains well-scoped.

Completeness5/5

The tool set covers the full workflow: authentication, cost estimation, synchronous and async generation, style CRUD, edit tools, pixel fixing, and system status. No obvious gaps for the intended domain.