Skip to Content
MeowKit
Skills

mk:stitch

Generates a new UI design from a text prompt with Stitch AI and exports HTML, a screenshot and a DESIGN.md handoff.

Source.claude/skills/stitch/SKILL.md
Ownerutility
Runtimeclaude-code
Riskmedium
Phaseon-demand

What it does

mk:stitch generates a high-fidelity UI design from a text prompt through the Stitch service, then exports Tailwind HTML, a PNG screenshot and a DESIGN.md that mk:frontend-design implements. It is for a new design with no source to start from. It is disabled without a Stitch API key.

When not to use it

NeedUse
A design already exists in Figmamk:figma
Designing or building from text without Stitchmk:frontend-design

Setup

Set STITCH_API_KEY (an sk_... key from the Stitch settings page) in the project env file, then install the scripts once:

cd ${CLAUDE_SKILL_DIR}/scripts && npm install

The scripts need tsx. Each one stops with exit 1 before any network request if the key or tsx is missing. references/stitch-setup.md covers optional variables and MCP setup.

Usage

TaskCommand
Check quotanpx tsx ${CLAUDE_SKILL_DIR}/scripts/stitch-quota.ts check
Generatenpx tsx ${CLAUDE_SKILL_DIR}/scripts/stitch-api-call.ts generate "<prompt>"
Export and writenpx tsx ${CLAUDE_SKILL_DIR}/scripts/stitch-api-call.ts export <screen-id> | npx tsx ${CLAUDE_SKILL_DIR}/scripts/stitch-write-output.ts

Generate returns screenId, projectId, imageUrl and quota data. The skill shows you the imageUrl and asks for your approval before exporting.

Steps

  1. Check quota. Exit code 2 means it is exhausted, and the skill routes to mk:frontend-design.
  2. Generate, review the screenshot with the user, then export and write.
  3. Hand DESIGN.md to mk:frontend-design.

Outputs go under tasks/designs/. See references/stitch-operations.md for the exact paths and references/design-to-code-pipeline.md for variants and iteration.

Limits

The export is HTML and Tailwind only, with no React, Vue or Svelte. Layouts are not responsive and there are no animations. Quota is tracked locally and can differ from real usage.

Gotchas

  • If you hit RATE_LIMITED while the tracker shows credits, run stitch-quota.ts reset. Quota limits and paid tiers change, so read references/quota-management.md before deciding on quota.
  • The optional MCP setup goes in your runtime's MCP config (.mcp.json at the project root on Claude Code). Reference the key as ${STITCH_API_KEY} there and never paste the raw key into the file.
  • stitch-write-output.ts accepts only Google CDN domains. If Stitch changes domains, update ALLOWED_CDN_SUFFIXES in that script.

On this page