JSPM

newman-mcp

1.0.1
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 5
  • Score
    100M100P100Q24871F
  • License ISC

MCP server for running Postman collections with Newman

Package Exports

    This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (newman-mcp) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

    Readme

    Newman MCP Server

    A Model Context Protocol (MCP) server that enables running Postman collections using Newman from within MCP-compatible applications.

    Features

    • Run Postman collections programmatically
    • Support for environment variables and iteration data
    • JSON-based output for easy integration
    • Compatible with MCP clients like Claude Desktop

    Installation

    Global Installation

    npm install -g newman-mcp

    No installation required - use directly with npx:

    npx newman-mcp

    Usage

    In Cursor IDE

    1. Open Cursor settings (Cmd/Ctrl + ,)
    2. Go to "Features" → "Model Context Protocol"
    3. Add a new MCP server with the following configuration:
    {
      "mcpServers": {
        "newman-mcp": {
          "command": "npx",
          "args": ["newman-mcp"]
        }
      }
    }

    In Other MCP Clients (Claude Desktop, etc.)

    Configure this server in your MCP client by adding it to your MCP configuration:

    {
      "mcpServers": {
        "newman-mcp": {
          "command": "newman-mcp",
          "args": []
        }
      }
    }

    Available Tools

    runCollection

    Runs a Postman collection using Newman.

    Parameters:

    • collection (required): Either a path to a Postman collection JSON file or raw JSON string
    • environment (optional): Path to Postman environment JSON file or raw JSON string
    • iterationData (optional): Path to iteration data JSON file or raw JSON string

    Example Usage:

    // Using file paths
    {
      "collection": "./my-collection.json",
      "environment": "./my-environment.json"
    }
    
    // Using raw JSON
    {
      "collection": "{\"info\":{\"name\":\"My Collection\"},\"item\":[]}",
      "environment": "{\"name\":\"My Environment\",\"values\":[]}"
    }

    Response:

    The tool returns a JSON object containing:

    • stats: Collection run statistics (requests, assertions, etc.)
    • failures: Array of failed tests
    • executions: Array of request executions with details

    Development

    Prerequisites

    • Node.js 18.0.0 or higher
    • pnpm (recommended) or npm

    Setup

    # Clone the repository
    git clone https://github.com/sangdth/newman-mcp.git
    cd newman-mcp
    
    # Install dependencies
    pnpm install
    
    # Start the server
    pnpm start

    Project Structure

    newman-mcp/
    ├── server.js          # Main MCP server implementation
    ├── package.json       # Package configuration
    └── README.md          # This file

    License

    ISC

    Contributing

    1. Fork the repository
    2. Create a feature branch
    3. Make your changes
    4. Submit a pull request

    Issues

    Report issues and feature requests on GitHub Issues.