Skip to main content

A command-line tool for analyzing MCP servers.

Project description

mcpry

mcpry is a command-line tool for analyzing MCP servers. It does the following:

  1. Discovers MCP Servers: It automatically searches for MCP server configuration files in well-known locations on the host system.
  2. Analyzes Tools and Resources: It connects to each discovered server to fetch the list of available tools and resources.
  3. Security Scanning with Pangea AI Guard: It uses the Pangea AI Guard service to scan the tools for malicious entities and prompts.
  4. Generates Reports: It creates a JSON report (default mcpry.json) containing the analysis results.
  5. Detects Changes: It can compare the current state of a server's tools with a previous report and display a diff if any changes are detected.
  6. Finds Similar Tools: It can identify tools with similar functionality.

Installation

pip install -U mcpry

Configuration

Before using mcpry, you need to set the PANGEA_AI_GUARD_TOKEN environment variable to a Pangea API token that has access to the Pangea AI Guard service.

export PANGEA_AI_GUARD_TOKEN="pts_your_token_here"

Usage

The primary command is scan, which runs the analysis.

mcpry scan

Options

Parameter Description Default
--input <PATH> The input file containing a previous report to compare against. mcpry.json
--output <PATH> The file where the new report will be saved. mcpry.json
--list-tools If set, the names of all tools for each MCP server will be listed in the output. False
--mcp-config-files <FILES> A list of files to discover MCP servers from. A list of well-known paths for different operating systems.
--similarity-threshold <FLOAT> The threshold (between 0.0 and 1.0) for two tools to be considered similar. 0.96
--syntax-theme <THEME> The syntax theme to use for displaying JSON diffs. github-dark

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mcpry-0.1.0.tar.gz (6.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mcpry-0.1.0-py3-none-any.whl (7.1 kB view details)

Uploaded Python 3

File details

Details for the file mcpry-0.1.0.tar.gz.

File metadata

  • Download URL: mcpry-0.1.0.tar.gz
  • Upload date:
  • Size: 6.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mcpry-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6afb8ecd6a28703884ec8504c4af60a59aed3ab2568130564ae94e0153b783f3
MD5 ffd29b0754334b96af6a3440b180f090
BLAKE2b-256 f79a394ab3c4f3000f7714aa070beb8441f65a236e72f214a8cdf6d28fab732e

See more details on using hashes here.

File details

Details for the file mcpry-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: mcpry-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 7.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for mcpry-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c29a55049aa8ea1821001bd7564c441231c559b93e1cab27544a9fc850cf8d4a
MD5 997e87b963e700537e2ddde44ef6d647
BLAKE2b-256 43a2bb2dcc9e8ce895c0c9b84781a19ec81e22766bd5745da1429c8f958c059d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page