Skip to main content
Glama
ZeroTian

Aseprite MCP Tools

by ZeroTian

run_lua_script

Execute custom Lua scripts in Aseprite batch mode for operations not available through dedicated tools. Output results using print().

Instructions

Execute arbitrary Aseprite Lua code in batch mode (escape hatch).

Use this when no dedicated tool covers what you need. The full API is documented at https://www.aseprite.org/api/. Anything the curated tools do can also be done here — they are Lua underneath.

Essentials for batch-mode scripts:

  • When filename is given, it is opened first and available as app.activeSprite.

  • Changes are NOT saved automatically; call spr:saveAs(spr.filename) at the end if you modified the sprite.

  • print() is the only way to return data; a clean exit does not mean your logic succeeded, so print what you need to verify.

  • Coordinates on cel images are cel-local: offset sprite-global coordinates by cel.position before getPixel/putPixel.

WARNING: this executes unrestricted code (including io/os access) on the host running Aseprite. Only pass scripts you trust.

Args: script: Lua source code to execute filename: Optional Aseprite file to open before running

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scriptYes
filenameNo
Behavior5/5

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

No annotations exist, so description bears full burden. It discloses batch mode, filename opening behavior, no auto-save, print() as only return, coordinate offsets for cels, and unrestricted code execution risk.

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?

Front-loaded with purpose and usage rule. Essentials section is verbose but adds value. Warning is appropriately emphasized. Could trim redundant phrasing like 'they are Lua underneath'.

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

Completeness4/5

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

Given no output schema and no annotations, description covers core behaviors very well. Minor gaps: no mention of error handling, timeouts, or resource constraints. Still nearly complete for a complex tool.

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 has zero description coverage. Description adds brief meaning: 'script: Lua source code to execute', 'filename: Optional Aseprite file to open before running'. While helpful, it lacks details like script length limits or filename format.

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?

Description clearly states 'Execute arbitrary Aseprite Lua code in batch mode (escape hatch)'. It specifies verb, resource, and distinguishes from over 80 sibling tools by positioning itself as a fallback.

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?

Explicit guideline: 'Use this when no dedicated tool covers what you need.' Also notes that curated tools are Lua underneath, implying alternative use of those. Includes security warning to not pass untrusted scripts.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ZeroTian/aseprite-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server