npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@general-analysis/mcp-guard

v1.1.0

Published

An MCP guardrail with built-in AI-powered moderation that aggregates multiple MCP servers into one secure interface

Readme

MCP Guardrail

MCP Guardrail

An MCP (Model Context Protocol) guardrail with built-in AI-powered moderation that aggregates multiple MCP servers into one secure interface.

Overview

The MCP Guardrail provides AI-powered security and easy configuration for your MCP (Model Context Protocol) setup. It automatically detects your existing MCP configuration files and adds a protective layer with intelligent moderation capabilities.

Key features:

  • AI-powered moderation to prevent prompt injection attacks
  • Automatic configuration - CLI tool detects and updates MCP config files for Cursor, Claude Desktop, and Claude Code
  • Dual connectivity - supports both local and remote MCP servers
  • Transparent proxying - tools, prompts, and resources are automatically prefixed and made available

Quick Start

The easiest way to get started is using the General Analysis CLI tool:

# Install the CLI tool
pip3 install generalanalysis

# Login to your account
ga login

# Configure MCP settings for Cursor, Claude Desktop, and Claude Code
ga configure

This will automatically update your MCP configuration files with the guardrail setup.

Usage

Direct Usage with npx

No installation required! Use directly in your Cursor or Claude Desktop MCP configuration:

{
  "mcpServers": {
    "protected_server": {
      "command": "npx",
      "args": [
        "-y",
        "@general-analysis/mcp-guard",
        "[{\"name\":\"server1\",\"command\":\"path/to/server\",\"args\":[\"arg1\"]}]"
      ]
    }
  }
}

Standalone Usage

npx -y @general-analysis/mcp-guard '[{"name":"server1","command":"path/to/server","args":["arg1"]}]'

Configuration

Local Servers (Stdio)

For local MCP servers that communicate via stdio:

{
  "mcpServers": {
    "protected_server": {
      "command": "npx",
      "args": [
        "-y",
        "@general-analysis/mcp-guard",
        "[{\"name\":\"my-local-server\",\"command\":\"node\",\"args\":[\"path/to/server.js\"]}]"
      ],
      "env": {
        "API_KEY": "your-general-analysis-api-key",
        "ENABLE_GUARD_API": "true"
      }
    }
  }
}

Remote Servers (HTTP/SSE)

For remote MCP servers accessible via HTTP or Server-Sent Events:

{
  "mcpServers": {
    "protected_server": {
      "command": "npx",
      "args": [
        "-y",
        "@general-analysis/mcp-guard",
        "[{\"name\":\"my-remote-server\",\"url\":\"https://api.example.com/mcp\"}]"
      ],
      "env": {
        "API_KEY": "your-general-analysis-api-key",
        "ENABLE_GUARD_API": "true"
      }
    }
  }
}

Environment Variables

  • API_KEY - Your General Analysis API key for the moderation service
  • ENABLE_GUARD_API - Set to "true" to enable AI-powered moderation (requires API_KEY)

Complete Example for Cursor/Claude Desktop

Add this to your MCP configuration file:

{
  "mcpServers": {
    "guardrail": {
      "command": "npx",
      "args": [
        "-y",
        "@general-analysis/mcp-guard",
        "[{\"name\":\"local-filesystem\",\"command\":\"npx\",\"args\":[\"@modelcontextprotocol/server-filesystem\",\"/path/to/files\"]},{\"name\":\"remote-api\",\"url\":\"https://api.example.com/mcp\"}]"
      ],
      "env": {
        "API_KEY": "your-general-analysis-api-key",
        "ENABLE_GUARD_API": "true"
      }
    }
  }
}

Standalone Command Line Example

# Set environment variables
export API_KEY="your-general-analysis-api-key"
export ENABLE_GUARD_API="true"

# Run with mixed local and remote servers
npx -y @general-analysis/mcp-guard '[
  {
    "name": "local-filesystem",
    "command": "npx",
    "args": ["@modelcontextprotocol/server-filesystem", "/path/to/files"]
  },
  {
    "name": "remote-api",
    "url": "https://api.example.com/mcp"
  }
]'

Requirements

  • Node.js >= 18.0.0
  • Valid General Analysis API key (when moderation is enabled)

License

MIT