mcp-animation-inspector
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-animation-inspector how does the scroll animation on stripe.com work?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
mcp-animation-inspector
MCP server that helps AI assistants understand website animations
What It Does
AI assistants are blind to animations. They can read HTML and CSS, but they cannot see a GSAP timeline play, a Lottie animation loop, or a scroll-triggered reveal. When asked "how does this animation work?", they can only guess from static source code.
mcp-animation-inspector solves this by running a real browser via Playwright, detecting all animation systems on the page, capturing frame sequences at key scroll positions, extracting the relevant source code, and optionally generating Claude Vision descriptions of what was captured — all exposed as MCP tools that any AI assistant can call.
Pipeline: Navigate → Discover → Capture → Extract → Describe → Report
Related MCP server: Playwright Vision MCP Server
Quick Start
Run with npx (once published)
npx mcp-animation-inspectorClaude Code integration
Add to your ~/.claude.json or project .mcp.json:
{
"mcpServers": {
"animation-inspector": {
"command": "npx",
"args": ["mcp-animation-inspector"]
}
}
}Local development
git clone https://github.com/Ak0096/mcp-animation-inspector
cd mcp-animation-inspector
npm install
npx playwright install chromium
npm run build
node dist/index.jsAvailable Tools
Tool | Description | Key Parameters |
| Full pipeline: discover, capture, extract, and describe all animations on a page |
|
| Run detectors only — returns an inventory of animation systems found |
|
| Take screenshots at specified scroll positions |
|
| Pull relevant source code snippets for detected animations |
|
| Generate Claude Vision descriptions of captured frames (requires |
|
| Return a simplified DOM outline of the page |
|
Built-in Detectors
Detector | What It Detects |
CSS |
|
GSAP |
|
Framer Motion |
|
Lottie |
|
WebGL |
|
Scroll Libraries | Lenis, Locomotive Scroll smooth-scroll instances |
Custom Cursors |
|
Page Transitions | View Transitions API usage, Barba.js, Swup |
Configuration
All options can be passed as environment variables or as JSON config. When running via npx, set environment variables before the command.
Option | Default | Description |
|
| Run browser in headless mode |
|
| Browser viewport width × height |
|
| Page load timeout in milliseconds |
|
| Scroll percentages at which to capture frames |
|
| Maximum frames captured per detected animation |
|
| Hard cap on total frames across all animations |
|
| Frame image format ( |
|
| JPEG quality (1–100) |
|
| Comma-separated list of detectors to run, or |
|
| MCP transport: |
|
| Port used when |
|
| Automatically run Vision descriptions after capture |
|
| Anthropic model used for Vision descriptions |
| — | Required only for |
Architecture
┌─────────────────────────────────────────────────────────┐
│ MCP Tool Request │
└────────────────────────┬────────────────────────────────┘
│
┌──────────▼──────────┐
│ BrowserSession │ Playwright Chromium
│ (Navigate + Wait) │
└──────────┬──────────┘
│
┌──────────▼──────────┐
│ DetectorRegistry │ 8 pluggable detectors
│ (Discover) │ run in parallel
└──────────┬──────────┘
│ AnimationInventory
┌──────────▼──────────┐
│ FrameCapture │ scroll + screenshot
│ (Capture) │ per scroll position
└──────────┬──────────┘
│ Base64 frames
┌──────────▼──────────┐
│ CodeExtractor │ pulls CSS/JS snippets
│ (Extract) │ relevant to detections
└──────────┬──────────┘
│
┌──────────▼──────────┐
│ VisionDescriber │ optional Claude Vision
│ (Describe) │ pass (needs API key)
└──────────┬──────────┘
│
┌──────────▼──────────┐
│ MCP Response │ structured JSON report
└─────────────────────┘Each stage is independent. You can call discover_animations without capturing frames, or capture_frames with a pre-built inventory to skip re-detection.
Contributing
Adding a New Detector
Create the detector file
src/detectors/your-detector.tsImplement the
AnimationDetectorinterface:import type { AnimationDetector, DetectionResult } from './types.js'; export const yourDetector: AnimationDetector = { name: 'your-detector', detect(page): Promise<DetectionResult> { return page.evaluate(() => { // run inside the browser context const found = /* your detection logic */; return { detected: found, details: [] }; }); }, };Register the detector
Add it to
ALL_DETECTORSinsrc/detectors/index.ts:import { yourDetector } from './your-detector.js'; export const ALL_DETECTORS = [ cssDetector, gsapDetector, // ...existing detectors... yourDetector, // add here ];Add a test
Create a fixture HTML file under
tests/fixtures/and a test file undertests/. The test should assert that your detector returnsdetected: truefor the fixture anddetected: falsefor an unrelated page.
Running Tests
npm testBuild
npm run buildLicense
MIT — see LICENSE
Available Tools
7 toolscapture_framesB
Capture screenshots at scroll positions and animation states. Default scroll positions: [0, 25, 50, 75, 100]%. Pass inventory from discover_animations to skip re-detection.
Inputs: url (required), inventory, scroll_positions.
describe_animationsB
Generate natural language descriptions of animations. Returns string[] of descriptions. Requires ANTHROPIC_API_KEY env var.
Inputs: url (required).
discover_animationsB
Detect all animations on a page — returns { inventory: AnimationInventory[], techStack: string[] }
Inputs: url (required).
extract_animation_codeB
Extract CSS rules, JS animation configs, and timing data. Returns AnimationCode[] with css, js, and timing data. Pass inventory from discover_animations to skip re-detection.
Inputs: url (required), filter, inventory.
get_page_contentA
Fetch the text and/or HTML content of a webpage. Returns { url, title, html?, text?, meta }. Use format to choose output: "text" (readable content), "html" (raw HTML), or "both". Optionally pass a CSS selector to extract content from a specific element.
Inputs: url (required), format, selector, max_length.
get_page_structureB
Get semantic DOM structure, interactive elements (max 50), and landmarks of a page. Returns { title, sections, interactiveElements, landmarks }
Inputs: url (required).
inspect_animationB
Full animation inspection pipeline — discovers, captures frames, extracts code, and optionally describes all animations on a page. Returns { schemaVersion, url, techStack, inventory, frames, code, descriptions, meta }
Inputs: url (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 7 tools
Each tool has a distinct job: discovery, description, frame capture, code extraction, and page structure/content. The only blur is inspect_animation, which is a full pipeline composing the others, so an agent must decide between the one-shot pipeline and the composable sub-tools; descriptions hint at this ('Pass inventory from discover_animations to skip re-detection') but the boundary isn't explicit.
All tools use snake_case verb_noun naming (inspect_animation, discover_animations, capture_frames, get_page_structure), which is predictable and readable. Minor deviation: singular vs plural object names (inspect_animation vs discover_animations/describe_animations, capture_frames) makes the object noun inconsistent.
Seven tools sit squarely in the well-scoped range for a focused animation-inspection server. Each tool maps to a real capability of the pipeline (detect, describe, capture, extract, structure, content) plus one orchestration entry point.
The surface covers the full lifecycle of inspection: discovery, semantic structure, frame capture, code extraction, natural-language description, and a one-shot pipeline, with no obvious dead ends. Gaps are minor—there's no way to trigger or replay interactions that fire animations, and no diff/compare across runs.
Maintenance
Related MCP Connectors
Run reusable browser automations from your AI assistant: scrape sites, extract data, fill forms.
Hosted browser for AI agents: screenshots, post-JS DOM, console, WCAG. No install, no API key.
Cloud browser, web extraction, screenshots, and remote CDP tools for AI agents.
Web data extraction and browser workflows for AI assistants.
Related MCP Servers
- AlicenseBqualityDmaintenanceAnalyzes scroll-triggered animations on any webpage using Playwright, extracting GSAP, ScrollTrigger, Lenis, and CSS code via AST and runtime detection.16MIT
- AlicenseAqualityDmaintenanceEnables AI assistants to perform browser automation using Playwright, including navigation, content extraction, screenshot analysis, and custom script execution.5MIT
- AlicenseNot gradedqualityAmaintenanceEnables an AI agent to inspect live browser scene graphs, materials, shaders, lights, textures, animation, performance and memory, preview changes without touching project code, and convert the approved ones into vanilla or React Three Fiber source. It also provides website audits, smooth video frame capture, and Playwright/Puppeteer helpers.6,808 npmMIT
- AlicenseNot gradedqualityAmaintenanceEnables AI agents to inspect and modify Three.js scenes live in the browser—objects, materials, shaders, textures, animation, lights and performance—then turn those previewed changes into code. Also supports website audits, video frame capture with Playwright and Puppeteer.6,808 npmMIT