Skip to main content
Glama
stitch-native

stitch-native

init_config

Build a stitch-native.json skeleton from a screen's colors, fonts, and icons, merging over an existing config without deleting entries and returning unmapped items to fill in.

Instructions

Build a stitch-native.json skeleton from the colours, fonts and icons a screen uses, merged over an existing config (existing entries win and are never deleted). Only the keys of the requested targets are written (iOS-only: no iconsCompose, no output.compose); an explicit targets is stored in the config. Returns the JSON and the unmapped entries to fill in.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "init_config"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoHTTPS download URL of the screen HTML (a public https URL; Stitch downloadUrls need OAuth, so pass that HTML via html instead).
htmlNoStitch screen HTML (the export, including the tailwind-config script).
pathNoPath to a Stitch HTML file. Used when html is not given.
targetsNoEcosystems to emit, out of swiftui, compose, html. Overrides the config's `targets`; without either: swiftui + compose. A comma-separated string is also accepted.
existingNoCurrent config to merge into. Without it the config is discovered like for the other tools.
config_pathNoPath to a stitch-native.json. Used when config is not given.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.7.1

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the burden well: it discloses that existing entries win and are never deleted, that only keys for requested targets are written, that explicit targets are persisted, and what is returned (JSON plus unmapped entries). The main gap is whether the skeleton is written to disk or only returned, which matters for a tool named init_config.

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 the core purpose and artifact, followed by merge and target semantics. The parentheticals are dense but each carries real constraint information; nothing is redundant filler.

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?

For a six-optional-parameter tool with no annotations or output schema, the description covers merge behavior, defaults, target scoping, and return content. The persistence question and the interaction between existing and config_path are the only meaningful omissions, and the latter is partially covered by the schema.

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 schema already documents all six parameters, including the html/path/url precedence and existing/config_path. The description adds some meaning around targets (what iOS-only excludes: iconsCompose, output.compose), which pushes it slightly above the baseline but not substantially.

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 and artifact: build a stitch-native.json skeleton from colours, fonts and icons a screen uses, merged over an existing config. This clearly distinguishes it from the stitch_to_* conversion siblings, though it never names or contrasts them explicitly.

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?

Implies usage through the merge semantics and defaults (targets of swiftui + compose without either specified), but gives no explicit when-to-use guidance, no prerequisites, and no statement of when to prefer this over extract_tokens or the conversion tools.

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