Evaluates HIP-3 and trade.xyz orders against local trade policies to provide deterministic allow, review, or deny decisions.
Also known as base-buzz/paystage, trade-preflight, @paystage/trade-preflight
- Stars
- 5
- Tools
- 4
- Downloads, 30 days
- —
- Latest version
- 0.2.0
- Last commit
- Nov 14, 2026
- License
- MIT
What is PayStage Trade Preflight MCP?
PayStage Trade Preflight evaluates HIP-3 and trade.xyz orders against local trade policies to provide deterministic allow, review, or deny decisions. It exposes 4 tools, such as order, policy, decision.
Summary generated from the project's README
About PayStage Trade Preflight MCP server
Evaluating HIP-3 and trade.xyz orders against local trade policies is the primary function of this MCP server. It acts as a deterministic gate for developers who want to validate proposed orders before they enter an order flow. By using the evaluate_hip3_trade tool, users can check market, side, size, and price details against a specific TradePolicy object to receive an immediate decision.
This server runs locally via npx or npm and communicates through stdio. It does not require environment variables or API keys to function, though it may perform a single read-only POST request to a specific endpoint if a market snapshot is not provided. The tool provides three distinct outcomes: allow, review, or do_not_trade, along with a list of reasons explaining the result. It is designed strictly for policy evaluation and does not place orders, route trades, or sign transactions.
What you can do with it
- 1Flag suspicious trades for manual reviewIdentify orders that do not violate hard rules but require a human check before proceeding.
- 2Enforce strict trading limitsAutomatically block any trade that violates a hard rule defined in your local policy file.
Written from the project's README. Every use case is checked against a quote from it.
How to install PayStage Trade Preflight MCP
Formats verified 10 Nov 2026Add to CursorAdd to GooseInstall PayStage Trade Preflight MCP in Claude Code
$ claude mcp add trade-preflight -- npx -y @paystage/trade-preflightInstall PayStage Trade Preflight MCP in Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"trade-preflight": {
"command": "npx",
"args": [
"-y",
"@paystage/trade-preflight"
]
}
}
}Install PayStage Trade Preflight MCP in VS Code
.vscode/mcp.json
{
"servers": {
"trade-preflight": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@paystage/trade-preflight"
]
}
}
}Install PayStage Trade Preflight MCP in VS Code CLI
$ code --add-mcp '{"name":"trade-preflight","type":"stdio","command":"npx","args":["-y","@paystage/trade-preflight"]}'Install PayStage Trade Preflight MCP in Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"trade-preflight": {
"command": "npx",
"args": [
"-y",
"@paystage/trade-preflight"
]
}
}
}Install PayStage Trade Preflight MCP in Codex
$ codex mcp add trade-preflight -- npx -y @paystage/trade-preflightInstall PayStage Trade Preflight MCP in Codex config.toml
~/.codex/config.toml
[mcp_servers.trade-preflight] command = "npx" args = ["-y", "@paystage/trade-preflight"]
Install PayStage Trade Preflight MCP in Gemini CLI
$ gemini mcp add -s user trade-preflight npx -- -y @paystage/trade-preflightInstall PayStage Trade Preflight MCP in Gemini settings.json
~/.gemini/settings.json
{
"mcpServers": {
"trade-preflight": {
"command": "npx",
"args": [
"-y",
"@paystage/trade-preflight"
]
}
}
}PayStage Trade Preflight MCP tools 4
Detected from the READMEorderpolicydecisionreasons
| order | — | |
| policy | — | |
| decision | — | |
| reasons | — |
Automated checks
Ran Nov 13, 2026Full report →Passed our automated checks. That is not a security audit: read the code and give the server the narrowest access it needs. How checks work
- Source repository linked and reachablePass
- Open source license (OSI)Pass
- Commit or release in the last yearPass
- Package name not close to a popular packagePass
- Remote endpoint uses HTTPSNot checked
- Destructive tools are labelledPass
- No hidden instructions to the modelPass
- No critical advisory in the package or its dependenciesPass
README
View on GitHub@paystage/trade-preflight
MCP tool: evaluate HIP-3 / trade.xyz orders against a local TradePolicy before trading.
Not financial advice. This is a local policy gate only — it does not place orders, route orders, or recommend trades. It evaluates a proposed order against rules you define and returns a decision.
Published on npm as @paystage/trade-preflight.
What it does
Given a proposed HIP-3 / trade.xyz order and a local policy file, the server returns one of:
allow— the order satisfies every rule in the policyreview— the order needs a human or higher-level check before proceedingdo_not_trade— the order violates a hard rule in the policy
The decision is deterministic and local. No network calls are required to evaluate a policy; the tool is a gate you put in front of your own order flow.
Install
Run directly with npx:
npx -y @paystage/trade-preflight
Or install it:
npm install @paystage/trade-preflight
The package exposes a stdio MCP server (bin: paystage-trade-preflight).
MCP configuration
{
"mcpServers": {
"paystage-trade-preflight": {
"command": "npx",
"args": ["-y", "@paystage/trade-preflight"]
}
}
}
No environment variables are required. The policy is passed as a tool argument.
Tool
evaluate_hip3_trade
Evaluates a proposed HIP-3 / trade.xyz order against a local TradePolicy.
Inputs (shape):
order— the proposed order (market, side, size, price/limit, etc.)policy— the localTradePolicyobject (or a path to it, depending on your setup)
Output:
decision—allow|review|do_not_tradereasons— list of rule results explaining the decision
Example policy shape:
{
"version": 1,
"max_notional": { "value": "100.00", "asset": "USDC", "decimals": 6 },
"allowed_markets": ["BTC-USD", "ETH-USD"],
"allowed_sides": ["buy", "sell"],
"max_leverage": 1,
"unknown_market": "review"
}
Decisions
| Decision | Meaning |
|---|---|
allow |
Order satisfies all policy rules. |
review |
Order needs a human or higher-level check. |
do_not_trade |
Order violates a hard policy rule. |
Supply chain and access
| Flag | Why it is there |
|---|---|
| Network access | One read-only POST to https://api.hyperliquid.xyz/info (metaAndAssetCtxs) when the caller does not pass a market snapshot. |
| URL strings | That endpoint. |
| Filesystem access | Indirect, through the policy file for TradePolicy. |
It never places an order and never signs. Not financial advice. Full table: SECURITY.md.
Links
- Website: paystage.xyz
- HIP-3 context: docs.trade.xyz
- Source: github.com/base-buzz/paystage (
packages/trade-preflight) - X: x.com/paystage_xyz
License
MIT
PayStage Trade Preflight MCP questions
How do I add PayStage Trade Preflight MCP to Claude Code?
Run claude mcp add trade-preflight -- npx -y @paystage/trade-preflight in your terminal. Add --scope user to make it available in every project.
How do I add PayStage Trade Preflight MCP to Cursor?
Open ~/.cursor/mcp.json and add the server under mcpServers, using the Cursor config shown in the install section above.
What tools does PayStage Trade Preflight MCP provide?
It exposes 4 tools, including order, policy, decision, reasons.
Does this tool place or route trades?
No, it is a local policy gate only and does not place, route, or recommend trades.
Does the evaluation require a network connection?
The decision is deterministic and local, requiring no network calls to evaluate a policy, though it may make one read-only POST request to fetch market metadata if not provided.