# MasterPlayspots/motionspec [Health: Active]

**Category:** 💻 Developer Tools  
**Repository:** https://github.com/MasterPlayspots/motionspec  
**GitHub Stars:** 2  
**npm Downloads (last month):** 1039  
**Views:** 1  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/masterplayspots-motionspec

## Description
Reduced-motion / WCAG 2.2.2+2.3.3 verification for web animation: agents author validated specs; a deterministic compiler emits reduced-motion-safe, on-budget CSS. Keyless hosted endpoint (motioncatalog, motionvalidate).

## Tools
Capabilities this server exposes over MCP:

- **motion_catalog** — Returns the catalog of verified motion primitives (names, purpose, parameter schemas, defaults) plus the authoring rules for writing a MotionSpec. Call this FIRST, then write the spec yourself and validate it with motion_validate (motion_compile runs in the CLI or with a key on the hosted endpoint). Free motion check: motionspec.dev/motion-check · keys for the hosted endpoint: motionspec.dev/pricing?src=mcp.
- **motion_validate** — Checks a MotionSpec against the schema, the primitive allow-list, parameter bounds and injection rules. Fail-closed: returns ok=false with precise errors. Returns {ok, errors, warnings, deprecations, catalogVersion}. IMPORTANT: warnings[] carries the WCAG 2.2.2 / reduced-motion findings and can be non-empty while ok=true — a spec that compiles is not automatically accessible. Use to pre-check a spec before compiling.
- **motion_compile** — Validates (fail-closed) and deterministically compiles a MotionSpec into production-ready vanilla-GSAP JavaScript and CSS, with enforced prefers-reduced-motion fallbacks and a performance-budget report. Same spec always yields identical code. Returns {ok, js, css, report} or {ok:false, errors}.
- **motion_audit** — Static motion-a11y checker: fetches a URL's HTML + linked stylesheets and scans the CSS for (1) animation/transition that moves without an effective (cascade-aware) prefers-reduced-motion guard, (2) animated non-transform/opacity properties, (3) infinite animations with no pause path, (4) <marquee>/autoplay >5s. Colour/opacity-only transitions are not motion (WCAG 2.3.3). Same engine and scoring as the free site check at motionspec.dev/motion-check. Returns {ok, score|null, status, findings, groups, summary, badge, disclosures, coverage, markdown}; pages without CSS motion return status 'not-measurable' with score null (runtime motion such as WAAPI/GSAP/WebGL is not audited); loading indicators (spinners, skeletons) are reported as 'review', not as violations. A clean, measurable page earns the badge 'reduced-motion-safe'. Does network I/O (openWorldHint).
- **motion_stats** — Summary of routing/compile telemetry (counts per outcome). Escalation clusters indicate which new primitive the catalog needs next.

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "motionspec": {
    "command": "npx",
    "args": ["-y","motionspec"]
  }
}
```

## Documentation

## What MasterPlayspots/motionspec does

MasterPlayspots/motionspec supports an authoring workflow for accessible web animation. The catalog describes verified motion primitives, their purposes, parameter schemas, defaults, and the rules required for a valid MotionSpec. A model or developer writes the JSON specification; the server then checks it against the approved catalog and compiles it without asking a model to generate the final animation code.

Compilation produces vanilla-GSAP JavaScript and CSS. The generated output includes enforced `prefers-reduced-motion` handling and a performance-budget report. Continuous-loop primitives also receive pause controls by construction. The compiler rejects unapproved primitives, invalid parameters, unsafe selectors or strings, and other failed trust-boundary checks rather than attempting to repair them silently.

The audit side examines motion already present on a web page. It retrieves the page HTML and linked stylesheets, then checks CSS for motion without an effective reduced-motion guard, animated properties beyond transform and opacity, endless animations without a pause path, and obsolete `<marquee>` or autoplay content lasting more than five seconds. Findings support review of WCAG 2.2.2 and WCAG 2.3.3 concerns, but a clean scan is not a complete accessibility assessment.

## How it works

Call `motion_catalog` first when authoring a spec. Pass the resulting design to `motion_validate`, which returns an explicit success state along with errors, warnings, deprecations, and the catalog version. Warnings can contain reduced-motion or WCAG findings even when validation succeeds, so `ok: true` does not by itself mean the animation is accessible.

`motion_compile` validates again and deterministically emits the JavaScript, CSS, and report. Identical specifications produce identical output. `motion_audit` uses the same checking and scoring engine as the public motion check; pages with no measurable CSS motion receive a `not-measurable` status and no score. Runtime animation implemented with WAAPI, GSAP, WebGL, or other JavaScript execution is outside this static audit. Loading indicators are classified for review rather than automatically treated as violations.

## Setup and configuration

Run the local MCP server with Node.js and `npx`:

```bash
npx -y motionspec
```

The local stdio process exposes all five tools and requires no API key. The package can also be installed globally for the CLI workflow:

```bash
npm install -g motionspec
motion compile spec.json
```

The hosted MCP endpoint is available at `https://api.motionspec.dev/mcp` over streamable HTTP. Its keyless tools are `motion_catalog`, `motion_validate`, `motion_compile`, and `motion_audit`. `motion_stats` is restricted to the hosted service operator. The hosted audit performs network requests and applies a public-URL policy that excludes private and loopback targets.

## Tools and capabilities

- `motion_catalog`: Lists verified primitives and MotionSpec authoring rules.
- `motion_validate`: Performs schema, allow-list, bounds, and injection checks.
- `motion_compile`: Emits deterministic GSAP JavaScript, CSS, and a budget report.
- `motion_audit`: Scans fetched HTML and linked CSS for motion-accessibility candidates.
- `motion_stats`: Reports routing and compilation telemetry for operator use.

The repository also includes a Claude Code plugin with motion-authoring and URL-audit skills. CI users can compare audit findings with an explicitly accepted baseline to detect regressions.

_Full upstream README: https://allmcps.com/mcp/masterplayspots-motionspec/readme_

