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

redline-mcp-server

v1.2.0

Published

MCP server for Redline — enforcement, violation detection, trade logging, and discipline scoring for AI trading agents

Readme

redline-mcp-server

MCP (Model Context Protocol) server for the Redline Trading OS. Exposes enforcement, violation detection, trade logging, discipline scoring, and session management as native MCP tools so any Claude-powered agent can call them without custom integration.


Installation

npm install -g redline-mcp-server
# or use npx without installing
npx redline-mcp-server --key rl_live_xxxxx

Configuration

Environment Variables

| Variable | Required | Default | Description | |---|---|---|---| | REDLINE_API_KEY | Yes (if not passed via --key) | — | Your Redline API key (rl_live_…). | | REDLINE_API_BASE | No | https://tradeintelx.com | Override the API base URL. Use this to point the server at a staging or self-hosted environment. |

Staging / Custom Environments

REDLINE_API_BASE=https://staging.tradeintelx.com \
REDLINE_API_KEY=rl_live_xxxxx \
npx redline-mcp-server

Or with the --key flag:

REDLINE_API_BASE=https://staging.tradeintelx.com npx redline-mcp-server --key rl_live_xxxxx

MCP Client Setup

Claude Desktop

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "redline": {
      "command": "npx",
      "args": ["redline-mcp-server", "--key", "rl_live_xxxxx"]
    }
  }
}

For staging:

{
  "mcpServers": {
    "redline-staging": {
      "command": "npx",
      "args": ["redline-mcp-server", "--key", "rl_live_xxxxx"],
      "env": {
        "REDLINE_API_BASE": "https://staging.tradeintelx.com"
      }
    }
  }
}

Cursor / Other MCP Hosts

{
  "mcpServers": {
    "redline": {
      "command": "node",
      "args": ["/path/to/redline-mcp/index.js"],
      "env": {
        "REDLINE_API_KEY": "rl_live_xxxxx"
      }
    }
  }
}

Available Tools

| Tool | Description | |---|---| | check_enforcement_state | Account state, canTrade flag, discipline score, and active violations. Call before every trade. | | get_discipline_score | Discipline score (0–100), band (elite/disciplined/developing/at-risk), 7-day trend, and 10 most recent violations. | | get_analytics_summary | Performance analytics for a period (7d / 30d / 90d / 1y): win rate, profit factor, avg R:R, P&L, drawdown, top setups. | | get_violation_risk | Stateless pre-trade violation check — returns clear, riskScore, and specific violations without writing data. | | log_trade | Log a completed trade (triggers violation analysis and score update). | | get_fingerprint | Trader DNA fingerprint: inferred style, top setups, session peaks, strengths, and leaks. Use to calibrate agent behaviour. | | get_bot_config | Bot configuration and cumulative feedback summary (approval rate, decision counts). | | push_bot_signal | Push a trade signal into the trader's Pending Signals Panel (1-hour TTL). | | submit_bot_feedback | Record the trader's decision (approved / rejected / modified) on a signal. | | start_session | Start a trading session with optional contract terms. | | end_session | End a session and retrieve the P&L, win rate, and violation summary. |


Requirements

  • Node.js 18+ (uses native fetch)
  • A valid Redline API key (rl_live_…)