Packagelens MCP Server

PackageLens MCP: a server exposing tools to search package registries (npm today) and fetch READMEs.

Local serverstdioPython

What is the Packagelens MCP MCP server?

If you already use Packagelens MCP, the packagelens mcp mcp server is the piece that lets your assistant work with it directly. PackageLens MCP: a server exposing tools to search package registries (npm today) and fetch READMEs.

What the server does

packagelens-mcp lets your coding agent (such as Claude, Cursor, Copilot, Gemini or Codex) search package registries across multiple ecosystems (npm, PyPI, RubyGems, Crates.io, Packagist, Hex) and fetch package context (README, downloads, GitHub info, usage snippets). It features smart ecosystem auto-detection, so your AI can find packages without needing to specify which ecosystem to search. It acts as a Model‑Context‑Protocol (MCP) server, giving your AI assistant a structured way to discover libraries and integrate them quickly.

  • 🌟 Smart ecosystem auto-detection - Ask "Find HTTP clients"
  • 🔍 Multi-ecosystem support: npm, PyPI, RubyGems, Crates.io,
  • 📦 Structured package search with optional ranking weights
  • 📄 Direct README fetch (optionally truncated)
  • 📊 Enriched package info (downloads + GitHub details)
  • 🔖 Version listing and dependency analysis

Available tools

The toolset is worth reading before you wire it up, because it tells you what the integration is really for:

  • smart_package_info — Get detailed package info
  • Args — packageName, ecosystem?, context?, includeReadme?
  • Example — "Tell me about react" → detects npm
  • smart_get_readme — Fetch package README
  • smart_get_usage_snippet — Extract code examples from README
  • smart_get_versions — List package versions
  • smart_get_dependencies — Get package dependencies
  • smart_get_downloads — Get download statistics
  • compare_packages — Compare packages across ecosystems

Installation

packagelens-mcp on npm is all you need. Most clients run it directly, so configuration is a few lines and a restart.

Credentials and setup notes

Configuration is passed through the environment: GITHUB_TOKEN. Treat anything key-shaped as a real credential — scope it to the minimum the server needs, and rotate it if it ever lands in a shared config.

  • Node.js v18.17 or newer - npm (or pnpm)

Where it fits

Plenty of developer tooling servers cover similar ground. The differences that matter in practice are scope of access and how much setup stands between you and a working tool call. Packagelens MCP's toolset — smart_package_info, Args, Example and 6 more — is a fair guide to whether it matches your workflow. It is maintained by rakeshmenon; worth a glance at recent repository activity before you build anything load-bearing on it.

We check each listing at SyncDev against the project's documentation before it goes live — if something here drifts out of date, it is a bug worth reporting.

Worth knowing first

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • With 9 tools registered it takes up a noticeable share of the context window; turn it off in projects that never touch Packagelens MCP.
  • Missing credentials fail quietly in some clients — if no tools show up, check the environment block first.
  • Keep per-call confirmation enabled while you learn its behaviour; it is the cheapest safeguard you have.

Available tools

ToolWhat it does
smart_package_infoGet detailed package info
ArgspackageName, ecosystem?, context?, includeReadme?
Example"Tell me about react" → detects npm
smart_get_readmeFetch package README
smart_get_usage_snippetExtract code examples from README
smart_get_versionsList package versions
smart_get_dependenciesGet package dependencies
smart_get_downloadsGet download statistics
compare_packagesCompare packages across ecosystems

How to install the Packagelens MCP MCP server

{
  "mcpServers": {
    "packagelens": {
      "command": "npx",
      "args": ["-y", "packagelens-mcp@latest"]
    }
  }
}

Configuration as documented by the project. Restart the client after saving.

Configuration

  • Node.js v18.17 or newer - npm (or pnpm)
VariableDescriptionRequired
GITHUB_TOKENCredential the server authenticates with.Yes

Example prompts to try

  • Use Packagelens MCP to smart package info.
  • Use Packagelens MCP to Args.
  • Use Packagelens MCP to Example.

Frequently asked questions

It connects Packagelens MCP to MCP-compatible AI assistants such as Claude and Cursor, exposing 9 tools (smart_package_info, Args, Example, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Packagelens MCP directly.