Skip to main content
Glama
Dependency MCP Server

Dependency MCP Server

by narekntm

Dependency MCP server

A small TypeScript demo of evidence-backed dependency impact analysis.

All repositories and source references in the fixture are fictional. This is a new educational implementation, not a release of an employer's system. The server reads an in-memory fixture; it does not scan repositories, call a model, access Jira or change code.

Try it

Requires Node.js 22 or newer and npm.

git clone https://github.com/narekntm/dependency-mcp-server.git
cd dependency-mcp-server
npm ci
npm run check
npm run demo

The demo asks what may be affected if catalog-api changes product.price.

catalog-api
  ├─ checkout      direct consumer, evidence E1
  │   └─ analytics transitive consumer, evidence E1 → E3
  └─ storefront    direct consumer, evidence E2

status-page        unrelated in the fixture

The JSON report includes each path, its illustrative file/line evidence, review priority and coverage limits. Fixture paths describe fictional evidence and do not point to source files in this repository.

Related MCP server: clew

Connect an MCP host

First run npm run build. Add the following to your host's MCP server configuration, replacing the path with your absolute checkout path:

{
  "mcpServers": {
    "dependency-demo": {
      "command": "node",
      "args": ["/absolute/path/dependency-mcp-server/dist/src/index.js"]
    }
  }
}

On Windows, use an absolute path such as C:/Projects/dependency-mcp-server/dist/src/index.js. No API key is needed. The client starts the stdio server; do not run a second server separately.

Tools:

Tool

Purpose

dependency_list_repositories

List the fictional repositories

dependency_analyze_impact

Trace downstream consumers of a provider's changed contract

Example arguments:

{ "repository": "catalog-api", "contract": "product.price", "maxDepth": 3 }

Design

flowchart LR
  F[Validated synthetic graph] --> A[Bounded impact traversal]
  I[Validated tool arguments] --> A
  A --> R[Cited paths and coverage limits]
  R --> M[Read-only MCP response]
  • A consumer depends on a provider. Analysis walks the reverse direction from the changed provider to downstream consumers.

  • The first hop must match the changed contract; subsequent hops flag potential downstream exposure.

  • Traversal retains multiple paths and prevents cycles within each path.

  • Limits on graph size, path exploration and depth bound the work. The result reports truncation.

  • Direct consumers receive higher review priority. Priority is a distance heuristic, not proof of severity or breakage.

  • The MCP adapter stays separate from the graph algorithm. Both are exercised in tests.

  • No network access, file writes or external credentials are used by the server. The MCP transport is stdio only.

Validation

npm run check compiles strict TypeScript and runs graph behavior tests plus an actual stdio client/server test. Tests cover direct/transitive evidence, unrelated contracts, depth limits, cycles, multiple paths, malformed inputs and protocol errors.

GitHub Actions runs the checks on Linux and Windows with Node 22 and 24.

Deliberate limits

A static dependency is a reason to investigate. This demo cannot determine runtime breakage, discover undocumented consumers or prove compatibility. A production implementation would also need real extraction, freshness/provenance handling, authentication, access control and scale testing.

Context and authorship

Created by Narek Ter-Martirosyan using AI-assisted development, with architecture, review and validation as part of the work. Engineering case studies explain the broader experience that motivated this demonstration.

MIT license applies to the code in this repository.

Available Tools

2 tools
dependency_analyze_impactExplain possible downstream impactA
Read-onlyIdempotent

Trace consumers of a changed contract in a synthetic dependency graph. Returns cited fixture evidence, direct/transitive paths and coverage limits. Does not scan real repositories or prove breakage.

Inputs: contract (required), repository (required), maxDepth.

dependency_list_repositoriesList synthetic repositoriesA
Read-onlyIdempotent

List the fictional repositories available in this offline demonstration.

Inputs: no named parameters.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.8/5.0

    Scored across 2 tools

    Disambiguation5/5

    The two tools do clearly different things: one enumerates repositories, the other traces impact paths through a dependency graph. There is no plausible overlap in selection, and the descriptions reinforce the boundary (listing vs. impact tracing).

    Naming Consistency5/5

    Both names follow the same server-prefixed verb_noun convention (dependency_list_repositories, dependency_analyze_impact). The pattern is predictable and readable.

    Tool Count3/5

    Two tools is thin even for a deliberately offline demo server; a single entry point plus one analysis operation leaves little to compose. It is not excessive, but the surface feels under-built for a 'dependency analysis' purpose.

    Completeness3/5

    Listing repositories and tracing impact covers discovery and one analysis mode, but there is no way to inspect a repository's direct dependency set, list dependents of an artifact, or compare graphs. Agents can do the headline workflow but will hit dead ends for anything beyond impact tracing.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers