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 🙏

© 2025 – Pkg Stats / Ryan Hefner

human-in-the-loop-mcp

v0.1.0

Published

Micro-manage your agentic LLM promptly with your favorite messaging App, and more.

Readme

Human In The Loop MCP

Human-In-The-Loop MCP

What is this?

A Model Context Protocol (MCP) server that enables human oversight for AI assistants through Discord or HTTP. When your AI needs clarification or approval, it can reach out to you directly.

Usage

Discord Transport

Connect your AI to Discord for real-time human feedback:

bunx human-in-the-loop-mcp discord \
  --token YOUR_DISCORD_BOT_TOKEN \
  --user-id YOUR_DISCORD_USER_ID

Run bunx human-in-the-loop-mcp discord --help to see all available options.

HTTP Transport

Integrate with your own HTTP endpoint:

bunx human-in-the-loop-mcp http \
  --url https://your-endpoint.com/questions

Run bunx human-in-the-loop-mcp http --help to see all available options.

Telegram Transport

Connect your AI to Telegram for real-time human feedback:

bunx human-in-the-loop-mcp telegram \
  --token YOUR_TELEGRAM_BOT_TOKEN \
  --user-id YOUR_TELEGRAM_USER_ID

Run bunx human-in-the-loop-mcp telegram --help to see all available options.

Slack Transport

Under development

stdio Transport

Under development

🛠️ Installation

Requirements

  • Node.js >= v20.0.0 or Bun >= 1.2.20
  • Discord Bot Token or HTTP endpoint
  • An MCP Client (Claude Desktop, Cursor, VSCode, etc.)

Go to: Settings -> Cursor Settings -> MCP -> Add new global MCP server

Pasting the following configuration into your Cursor ~/.cursor/mcp.json file is the recommended approach. You may also install in a specific project by creating .cursor/mcp.json in your project folder. See Cursor MCP docs for more info.

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Run this command. See Claude Code MCP docs for more info.

claude mcp add human-in-the-loop -- bunx -y human-in-the-loop-mcp discord --token YOUR_DISCORD_BOT_TOKEN --user-id YOUR_DISCORD_USER_ID

Add this to your Windsurf MCP config file. See Windsurf MCP docs for more info.

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Add this to your VS Code MCP config file. See VS Code MCP docs for more info.

"mcp": {
  "servers": {
    "human-in-the-loop": {
      "type": "stdio",
      "command": "bunx",
      "args": ["-y", "human-in-the-loop-mcp", "discord", "--token", "YOUR_DISCORD_BOT_TOKEN", "--user-id", "YOUR_DISCORD_USER_ID"]
    }
  }
}

You can easily install Human-In-The-Loop through the Cline MCP Server Marketplace by following these instructions:

  1. Open Cline.
  2. Click the hamburger menu icon (☰) to enter the MCP Servers section.
  3. Use the search bar within the Marketplace tab to find Human-In-The-Loop.
  4. Click the Install button.

Or you can directly edit MCP servers configuration:

  1. Open Cline.
  2. Click the hamburger menu icon (☰) to enter the MCP Servers section.
  3. Choose Local Servers tab.
  4. Click the Edit Configuration button.
  5. Add human-in-the-loop to mcpServers:
{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Add this to your Zed settings.json. See Zed Context Server docs for more info.

{
  "context_servers": {
    "human-in-the-loop": {
      "command": {
        "path": "bunx",
        "args": [
          "-y",
          "human-in-the-loop-mcp",
          "discord",
          "--token",
          "YOUR_DISCORD_BOT_TOKEN",
          "--user-id",
          "YOUR_DISCORD_USER_ID"
        ]
      },
      "settings": {}
    }
  }
}

To configure Human-In-The-Loop MCP in Augment Code, you can use either the graphical interface or manual configuration.

A. Using the Augment Code UI

  1. Click the hamburger menu.

  2. Select Settings.

  3. Navigate to the Tools section.

  4. Click the + Add MCP button.

  5. Enter the following command:

    bunx -y human-in-the-loop-mcp discord --token YOUR_DISCORD_BOT_TOKEN --user-id YOUR_DISCORD_USER_ID
  6. Name the MCP: Human-In-The-Loop.

  7. Click the Add button.

Once the MCP server is added, you can start using Human-In-The-Loop's features directly within Augment Code.


B. Manual Configuration

  1. Press Cmd/Ctrl Shift P or go to the hamburger menu in the Augment panel
  2. Select Edit Settings
  3. Under Advanced, click Edit in settings.json
  4. Add the server configuration to the mcpServers array in the augment.advanced object
"augment.advanced": {
  "mcpServers": [
    {
      "name": "human-in-the-loop",
      "command": "bunx",
      "args": ["-y", "human-in-the-loop-mcp", "discord", "--token", "YOUR_DISCORD_BOT_TOKEN", "--user-id", "YOUR_DISCORD_USER_ID"]
    }
  ]
}

Once the MCP server is added, restart your editor. If you receive any errors, check the syntax to make sure closing brackets or commas are not missing.

Add this to your Roo Code MCP configuration file. See Roo Code MCP docs for more info.

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

See Gemini CLI Configuration for details.

  1. Open the Gemini CLI settings file. The location is ~/.gemini/settings.json (where ~ is your home directory).
  2. Add the following to the mcpServers object in your settings.json file:
{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

If the mcpServers object does not exist, create it.

Open Claude Desktop developer settings and edit your claude_desktop_config.json file to add the following configuration. See Claude Desktop MCP docs for more info.

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Add this to your Opencode configuration file. See Opencode MCP docs for more info.

{
  "mcp": {
    "human-in-the-loop": {
      "type": "local",
      "command": [
        "bunx",
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ],
      "enabled": true
    }
  }
}

See OpenAI Codex for more information.

Add the following configuration to your OpenAI Codex MCP server settings:

[mcp_servers.human-in-the-loop]
args = ["-y", "human-in-the-loop-mcp", "discord", "--token", "YOUR_DISCORD_BOT_TOKEN", "--user-id", "YOUR_DISCORD_USER_ID"]
command = "bunx"

See JetBrains AI Assistant Documentation for more details.

  1. In JetBrains IDEs, go to Settings -> Tools -> AI Assistant -> Model Context Protocol (MCP)
  2. Click + Add.
  3. Click on Command in the top-left corner of the dialog and select the As JSON option from the list
  4. Add this configuration and click OK
{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}
  1. Click Apply to save changes.
  2. The same way human-in-the-loop could be added for JetBrains Junie in Settings -> Tools -> Junie -> MCP Settings

See Kiro Model Context Protocol Documentation for details.

  1. Navigate Kiro > MCP Servers
  2. Add a new MCP server by clicking the + Add button.
  3. Paste the configuration given below:
{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ],
      "env": {},
      "disabled": false,
      "autoApprove": []
    }
  }
}
  1. Click Save to apply the changes.

Use the Add manually feature and fill in the JSON configuration information for that MCP server. For more details, visit the Trae documentation.

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Use these alternatives to run the local Human-In-The-Loop MCP server with other runtimes. These examples work for any client that supports launching a local MCP server via command + args.

Bun

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Deno

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "deno",
      "args": [
        "run",
        "--allow-env=NO_DEPRECATION,TRACE_DEPRECATION",
        "--allow-net",
        "npm:human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Install the human-in-the-loop.dxt file from the dxt folder and add it to your client. For more information, please check out the desktop extensions docs.

The configuration on Windows is slightly different compared to Linux or macOS (Cline is used in the example). The same principle applies to other editors; refer to the configuration of command and args.

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "cmd",
      "args": [
        "/c",
        "bunx",
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ],
      "disabled": false,
      "autoApprove": []
    }
  }
}

Add this to your Amazon Q Developer CLI configuration file. See Amazon Q Developer CLI docs for more details.

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

See Warp Model Context Protocol Documentation for details.

  1. Navigate Settings > AI > Manage MCP servers.
  2. Add a new MCP server by clicking the + Add button.
  3. Paste the configuration given below:
{
  "human-in-the-loop": {
    "command": "bunx",
    "args": [
      "-y",
      "human-in-the-loop-mcp",
      "discord",
      "--token",
      "YOUR_DISCORD_BOT_TOKEN",
      "--user-id",
      "YOUR_DISCORD_USER_ID"
    ],
    "env": {},
    "working_directory": null,
    "start_on_launch": true
  }
}
  1. Click Save to apply the changes.

Using Human-In-The-Loop with Copilot Coding Agent

Add the following configuration to the mcp section of your Copilot Coding Agent configuration file Repository->Settings->Copilot->Coding agent->MCP configuration:

{
  "mcpServers": {
    "human-in-the-loop": {
      "type": "stdio",
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ],
      "tools": ["AskQuestion"]
    }
  }
}

For more information, see the official GitHub documentation.

See LM Studio MCP Support for more information.

Manual set-up:

  1. Navigate to Program (right side) > Install > Edit mcp.json.
  2. Paste the configuration given below:
{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}
  1. Click Save to apply the changes.
  2. Toggle the MCP server on/off from the right hand side, under Program, or by clicking the plug icon at the bottom of the chat box.

You can configure Human-In-The-Loop MCP in Visual Studio 2022 by following the Visual Studio MCP Servers documentation.

Add this to your Visual Studio MCP config file (see the Visual Studio docs for details):

{
  "mcp": {
    "servers": {
      "human-in-the-loop": {
        "type": "stdio",
        "command": "bunx",
        "args": [
          "-y",
          "human-in-the-loop-mcp",
          "discord",
          "--token",
          "YOUR_DISCORD_BOT_TOKEN",
          "--user-id",
          "YOUR_DISCORD_USER_ID"
        ]
      }
    }
  }
}

For more information and troubleshooting, refer to the Visual Studio MCP Servers documentation.

Add this to your Crush configuration file. See Crush MCP docs for more info.

{
  "$schema": "https://charm.land/crush.json",
  "mcp": {
    "human-in-the-loop": {
      "type": "stdio",
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Open the "Settings" page of the app, navigate to "Plugins," and enter the following JSON:

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

Once saved, enter in the chat AskQuestion followed by your question. More information is available on BoltAI's Documentation site. For BoltAI on iOS, see this guide.

Edit your Rovo Dev CLI MCP config by running the command below -

acli rovodev mcp

Example config -

{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

To configure Human-In-The-Loop MCP in Zencoder, follow these steps:

  1. Go to the Zencoder menu (...)
  2. From the dropdown menu, select Agent tools
  3. Click on the Add custom MCP
  4. Add the name and server configuration from below, and make sure to hit the Install button
{
  "command": "bunx",
  "args": [
    "-y",
    "human-in-the-loop-mcp",
    "discord",
    "--token",
    "YOUR_DISCORD_BOT_TOKEN",
    "--user-id",
    "YOUR_DISCORD_USER_ID"
  ]
}

Once the MCP server is added, you can easily continue using it.

See Qodo Gen docs for more details.

  1. Open Qodo Gen chat panel in VSCode or IntelliJ.
  2. Click Connect more tools.
  3. Click + Add new MCP.
  4. Add the following configuration:
{
  "mcpServers": {
    "human-in-the-loop": {
      "command": "bunx",
      "args": [
        "-y",
        "human-in-the-loop-mcp",
        "discord",
        "--token",
        "YOUR_DISCORD_BOT_TOKEN",
        "--user-id",
        "YOUR_DISCORD_USER_ID"
      ]
    }
  }
}

See Local and Remote MCPs for Perplexity for more information.

  1. Navigate Perplexity > Settings
  2. Select Connectors.
  3. Click Add Connector.
  4. Select Advanced.
  5. Enter Server Name: Human-In-The-Loop
  6. Paste the following JSON in the text area:
{
  "args": [
    "-y",
    "human-in-the-loop-mcp",
    "discord",
    "--token",
    "YOUR_DISCORD_BOT_TOKEN",
    "--user-id",
    "YOUR_DISCORD_USER_ID"
  ],
  "command": "bunx",
  "env": {}
}
  1. Click Save.
git clone https://github.com/AndyRightNow/human-in-the-loop-mcp.git
cd human-in-the-loop-mcp
bun install
bun run build
bun start discord --token YOUR_DISCORD_BOT_TOKEN --user-id YOUR_DISCORD_USER_ID

How It Works

  1. Your AI encounters a decision point requiring human input
  2. It uses the AskQuestion tool to request guidance
  3. You receive a notification through your chosen transport (Discord DM or HTTP webhook)
  4. You provide your response
  5. The AI continues with your feedback
  6. The process repeats as needed

API

HTTP Endpoint Requirements

Your endpoint must accept POST requests with this payload:

{
  questions: string; // Questions from the AI
}

Expected response:

{
  answers: string; // Your response
}

Status codes:

  • 200: Success
  • 4xx: Client error
  • 5xx: Server error

Examples

Discord Setup

  1. Create a Discord bot and get its token
  2. Get your Discord user ID
  3. Run the command with your credentials
  4. The bot will DM you when the AI needs input

HTTP Webhook

Simple Express.js endpoint example:

app.post('/questions', (req, res) => {
  console.log('Questions received:', req.body.questions);
  // Implement your response logic
  res.json({ answers: 'Your response here' });
});

Troubleshooting

Q: The bot isn't sending me messages

A: Ensure you have DMs enabled from server members in your Discord privacy settings.

Q: Timeout errors

A: Increase the timeout value with the --timeout flag (in milliseconds).

Q: HTTP endpoint not working

A: Verify your endpoint URL, check any required headers, and ensure the endpoint is accessible.

Contributing

Bug reports and feature requests are welcome. Please open an issue on GitHub.

License

MIT