Ast Impact Mapper MCP logo

Ast Impact Mapper MCP

Maps TypeScript and JavaScript dependencies to affected tests, code risks, API changes, and project health issues.

Install Ast Impact Mapper MCP

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "ast-impact-mapper-mcp": {
      "command": "npx",
      "args": [
        "--",
        "-y",
        "ast-impact-mapper-mcp"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

We couldn’t confirm it starts correctly

We ran the install command but it didn't respond within our test window — this can mean a slow first-time install rather than a real problem.

npx -- -y ast-impact-mapper-mcp

Process exited before answering initialize.

This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked .

Overview

ast-impact-mapper-mcp MCP server analyzes TypeScript and JavaScript projects with ts-morph AST parsing and bidirectional dependency graphs. It identifies tests affected by changed files, explains import paths, generates commands for Jest, Vitest, or Playwright, and distinguishes type-only changes from runtime changes. Use it when an agent needs targeted test selection or codebase dependency analysis instead of running every test.

Use cases

  • Select tests affected by changed source files
  • Explain transitive import paths between tests and code
  • Skip tests for type-only changes
  • Find circular dependencies and unreachable modules
  • Generate targeted Jest, Vitest, or Playwright commands

Key features

  • AST-based TypeScript and JavaScript analysis
  • Bidirectional dependency graph tracing
  • Rename-aware branch impact analysis
  • Type-only versus runtime impact detection
  • API surface and symbol dependency analysis
  • Coverage gaps and architectural cycle reports

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

17/17 checks healthy over the last 83d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 13d ago via OSV.dev · ast-impact-mapper-mcp (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

npm downloads244Package downloads in the last 30 days.
Last commit6mo agoMost recent push to the default branch.
Install checkInconclusiveDidn't respond in our test window — often a slow first install.
Directory activity1 viewsConfig copies, upvotes, and views on AllMCPs.

How Ast Impact Mapper MCP works

What ast-impact-mapper-mcp MCP server does

ast-impact-mapper-mcp MCP server examines a TypeScript or JavaScript project and maps relationships between source files, tests, imports, and declarations. Its primary use is impact analysis: given changed files, it finds tests that transitively depend on them and can explain the import chain connecting a test to a modified source file.

The server also provides codebase analysis beyond test selection. It can identify files with no incoming imports, locate circular dependency paths, report direct imports and importers, inspect declaration-level dependencies, and summarize test coverage gaps and high-risk modules. Additional analysis checks whether a change affects the public API or is limited to internal implementation details.

How it works

The project is parsed through the TypeScript AST using ts-morph. The server builds cached dependency information in both directions, allowing it to move from a changed file to affected tests or from a file to its importers and dependencies. explain_impact returns an import chain for a selected source/test pair, while get_dependency_graph can return JSON or a Mermaid flowchart.

Git-based tools can compare the current project with a base branch. get_affected_tests_by_branch uses a branch comparison, and get_rename_aware_diff tracks renames with a similarity threshold while ignoring formatting-only changes. After changing branches or pulling updates, refresh_project invalidates the cached AST and dependency graphs.

For TypeScript-specific review, differentiate_type_impact examines types, interfaces, and type-only imports to indicate whether a change has runtime impact. analyze_api_surface_mutation compares a file with its HEAD version to classify public API changes versus internal refactors.

Tools and capabilities

The ast-impact-mapper-mcp MCP server exposes tools in four main areas:

  • Impact mapping: Find affected tests, explain import paths, compare branches, and produce commands for Jest, Vitest, or Playwright.
  • TypeScript analysis: Separate type-only changes from runtime changes, inspect API mutations, generate signature-focused skeletons, and trace symbol dependencies.
  • Graph health: Find unreachable modules, detect architectural cycles, inspect dependency graphs, and identify files without test import coverage.
  • Project reporting: Produce test summaries and clear cached project analysis.

generate_skeleton_view removes function and method bodies while retaining signatures, line numbers, and optionally JSDoc. get_symbol_dependency_graph can trace a named symbol or a complete file, with forward, reverse, or bidirectional traversal.

Setup and configuration

Install the package globally with npm install -g ast-impact-mapper-mcp, or configure a client to launch it through npx -y ast-impact-mapper-mcp. The documented client configuration uses the server name ast-impact-mapper and starts the package as a command-line MCP process.

Each analysis call supplies an absolute project_root. Other arguments identify changed files, source directories, entry points, test runners, branch names, or individual files and symbols. Most options have documented defaults, including main as the comparison branch, Vitest as the default runner, JSON as the dependency graph format, and a limit of 50 results for selected reports.

Limitations and notes

Results depend on the project’s TypeScript/JavaScript import structure and the accuracy of the parsed project. A file with no incoming imports may still be a legitimate entry point, so unreachable-module analysis accepts explicit entry points to exclude from warnings. Cached graphs should be refreshed after branch changes or remote updates.

The test-command generator produces commands for supported runners only: Jest, Vitest, and Playwright.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Ast Impact Mapper MCP

ast-impact-mapper-mcp is an MCP server that connects AI agents to TypeScript and JavaScript project analysis through ts-morph AST parsing and dependency graphs. Its main tools find affected tests, explain import chains, detect type-only changes, generate test commands, inspect API mutations, and report dependency or coverage issues.

Install it globally with `npm install -g ast-impact-mapper-mcp`, or configure an MCP client to run `npx -y ast-impact-mapper-mcp`. The documented setup includes JSON configuration for Cursor or VS Code and a `claude mcp add` command for Claude Code.

Yes, ast-impact-mapper-mcp works with Cursor through a `.cursor/mcp.json` configuration. Add an MCP server entry that launches `npx` with `-y ast-impact-mapper-mcp`, then provide an absolute `project_root` when calling analysis tools.

Yes, `differentiate_type_impact` analyzes changed files and identifies type-only changes such as interfaces, types, or `import type` usage. It reports whether the files have runtime impact, helping an agent decide whether affected tests may be skipped.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewAst Impact Mapper MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/ast-impact-mapper-mcp?style=directory)](https://allmcps.com/mcp/ast-impact-mapper-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/ast-impact-mapper-mcp"><img src="https://allmcps.com/api/badge/ast-impact-mapper-mcp?style=directory" alt="Ast Impact Mapper MCP on AllMCPs" /></a>