Skip to main content
Glama
PreReason

PreReason-mcp

@prereason/mcp

npm version npm downloads node version License: MIT Glama Score

MCP server for PreReason - the Context API for financial agents.

Give your agent market context, not raw price feeds. 18 briefings covering BTC, macro, cross-asset regimes, and liquidity - each with trend signals, confidence scores, and causal narratives.

Quick Start

Option 1: One-Click Connect (Claude.ai, ChatGPT, Cursor, Codex, Windsurf, VS Code Copilot)

Clients that support MCP OAuth can connect with no API key setup required. Add the server URL and the client handles the rest - you'll be prompted to sign in or create a free account, and your API key is provisioned automatically.

{
  "mcpServers": {
    "prereason": {
      "type": "http",
      "url": "https://api.prereason.com/api/mcp"
    }
  }
}

No Authorization header needed - OAuth handles it.

Option 2: Direct HTTP with API Key (Claude Code, scripts, cron jobs)

For CLI tools or when you want to use an existing API key:

# Claude Code (CLI one-liner)
claude mcp add prereason --transport http https://api.prereason.com/api/mcp

Or with an explicit key in your MCP config:

{
  "mcpServers": {
    "prereason": {
      "type": "http",
      "url": "https://api.prereason.com/api/mcp",
      "headers": {
        "Authorization": "Bearer YOUR_API_KEY"
      }
    }
  }
}

Option 3: stdio bridge (Claude Desktop and other stdio-only clients)

Requires Node.js 18+

Add to your MCP client config (e.g. claude_desktop_config.json):

{
  "mcpServers": {
    "prereason": {
      "command": "npx",
      "args": ["-y", "@prereason/mcp"],
      "env": {
        "PREREASON_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Claude Desktop config file location:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Restart your MCP client after editing the config. PreReason should appear with 5 tools.

Related MCP server: signaldaemon-mcp

Get an API Key

  1. Sign up at prereason.com/signup

  2. Go to Dashboard > Settings > API Keys

  3. Copy your key (starts with pr_live_)

5 MCP Tools

Tool

Auth

Description

list_briefings

Open

List all 18 pre-reasoned market briefings with tier requirements

list_metrics

Open

List all 30 available metrics across bitcoin, macro, and calculated categories

get_health

Open

API health check, version, account tier

get_context

Required

Fetch a pre-reasoned market briefing (markdown or JSON)

get_metric

Required

Fetch a single metric with trend/signal/percentile

18 Market Briefings

Free (6 briefings)

Briefing

Description

btc.quick-check

Minimal fast context: BTC + Net Liquidity + correlation

btc.context

BTC + liquidity + hash ribbon + difficulty + momentum

macro.snapshot

Fed balance, M2, treasury yields, VIX, net liquidity

cross.correlations

BTC correlation matrix vs macro indicators

btc.pulse

Volume, fees, mempool analysis

btc.grid-stress

Epoch pace and difficulty adjustment forecast

Basic - $19.99/mo (6 briefings)

Briefing

Description

btc.momentum

200D MA support/resistance with 7d/30d/90d momentum and YTD percentiles

macro.liquidity

Liquidity indicators with momentum analysis

btc.on-chain

Hash rate, difficulty, fees, mempool health

cross.breadth

Cross-asset breadth with SPY, DXY, VIX

btc.miner-survival

Hashprice thermometer with miner stress scoring

btc.etf-flows

Spot BTC ETF net daily flows, aggregate AUM, and per-issuer breakdown

Pro - $49.99/mo (6 briefings)

Briefing

Description

btc.full

Complete market intelligence with all metrics and analysis

btc.factors

Multi-factor attribution for BTC price movements

cross.regime

Regime classification (risk-on/risk-off/transition) with USDT.D risk sentiment

fx.liquidity

FX environment with DXY, treasury, and global liquidity

btc.energy

Production cost model with gas input pressure

btc.treasury

Corporate Bitcoin treasury intelligence from SEC filings

Example Prompts

Once connected, try prompts like:

  • "What's the current BTC regime?"

  • "Show me the macro snapshot"

  • "What does the full context briefing say about market conditions?"

  • "Get the bitcoin price metric with trend analysis"

  • "What's the hash ribbon signal right now?"

  • "List available briefings"

Troubleshooting

"Server disconnected" error

  • Ensure Node.js 18+ is installed: node --version

  • Check your API key starts with pr_live_

  • Fully quit Claude Desktop (system tray > Quit) and reopen

Tools not appearing

  • Restart Claude Desktop after editing config

  • Verify JSON syntax: node -e "JSON.parse(require('fs').readFileSync('path/to/config','utf8'))"

Windows: "'C:\Program' is not recognized"

If you still see this error, ensure you're using the env block (not --header args) as shown in Quick Start above. If the issue persists, install globally and use node:

  1. Run: npm install -g @prereason/mcp

  2. Use this config (replace YOUR_USER with your Windows username):

{
  "mcpServers": {
    "prereason": {
      "command": "node",
      "args": [
        "C:\\Users\\YOUR_USER\\AppData\\Roaming\\npm\\node_modules\\@prereason\\mcp\\bin\\cli.js"
      ],
      "env": {
        "PREREASON_API_KEY": "YOUR_API_KEY"
      }
    }
  }
}

Auth errors on get_context / get_metric

  • list_briefings, list_metrics, and get_health work without a key

  • get_context and get_metric require a valid API key

  • Get a free key at prereason.com/signup

Other MCP Clients

If your client supports remote HTTP servers, use Quick Start Option 1 above. The stdio bridge package is only needed for clients that require stdio transport (e.g. Claude Desktop).

CLI Usage

# Using environment variable (recommended)
PREREASON_API_KEY=pr_live_... npx @prereason/mcp

# Using --header flag (backward compatible)
npx @prereason/mcp --header "Authorization:Bearer YOUR_API_KEY"

# Custom URL
PREREASON_URL=https://custom.endpoint/mcp npx @prereason/mcp

# Help
npx @prereason/mcp --help

Privacy Policy

See prereason.com/privacy for data handling practices.

License

MIT

Available Tools

5 tools
get_contextGet Market BriefingA
Read-only
Inspect

Get a pre-reasoned market briefing with trend signals, confidence scores, regime classification, and causal narratives for the requested domain (Bitcoin, macro, cross-asset, FX). Includes crypto, macro financial data, and cross-asset correlations (indices, bonds, volatility as BTC relationship signals). Output is decision-ready — designed to be consumed directly by reasoning agents, not parsed for individual values. Briefings are tier-gated: Free (btc.quick-check, btc.context, macro.snapshot, cross.correlations, btc.pulse, btc.grid-stress), Basic (btc.momentum, macro.liquidity, btc.on-chain, cross.breadth, btc.miner-survival), Pro (btc.full, btc.factors, cross.regime, fx.liquidity, btc.energy, btc.treasury). Requires API key authentication via Authorization header.

ParametersJSON Schema
NameRequiredDescriptionDefault
briefingYesBriefing ID to fetch
formatNoResponse format: markdown (human-readable, default) or json (structured data)markdown
dateNoHistorical date in YYYY-MM-DD format (tier-gated: Free=30d, Basic=from Jan 2025, Pro=all)

TDQS

A4.1/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate readOnlyHint=true. The description adds useful behavioral context: output is pre-reasoned and not for individual value parsing, tier-gating, and authentication. It does not disclose potential errors or rate limits, but does not contradict annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the main purpose and then provides additional details on output, tier-gating, and authentication. It is well-structured but includes a full list of briefing IDs that is also in the schema; some repetition could be trimmed, but the tier grouping justifies the length.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool has no output schema, so the description must cover output characteristics. It mentions trend signals, confidence scores, regime classification, and causal narratives, and states that output is decision-ready. This is sufficient for an agent to understand the nature of the response. Authentication and tier constraints are also covered.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so each parameter is already documented. The description adds value by grouping briefing IDs into tiers (Free, Basic, Pro), which provides semantic grouping not present in the enum descriptions. This helps agents choose appropriate briefings based on access level.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it retrieves a pre-reasoned market briefing with specific elements (trend signals, confidence scores, etc.) and lists domains. It distinguishes from sibling tools like get_metric and list_metrics by focusing on composite, reasoning-ready output.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explains when to use (for decision-ready briefing), how output should be consumed (not parsed), and authentication/tier requirements. However, it does not explicitly state when NOT to use or mention alternatives like get_metric for specific data points.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_healthHealth CheckA
Read-only
Inspect

Check API health status, version, and available endpoints. No authentication required.

ParametersJSON Schema
NameRequiredDescriptionDefault
verboseNoInclude detailed endpoint descriptions, pricing tiers, and data coverage info. Defaults to false.

TDQS

A4.3/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The annotations already declare readOnlyHint=true, and the description adds valuable behavioral context: no authentication needed and the specific data returned (status, version, endpoints). This goes beyond the minimal read-only flag without contradicting it.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, front-loaded sentence that communicates the purpose, scope, and access requirement with zero filler. Every phrase earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple read-only health check tool with one optional parameter and no output schema, the description covers the essential context: what it checks, what it returns, and authentication requirements. This is complete for an agent to select and invoke it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage for the single parameter 'verbose', which fully documents its effect (detailed endpoint descriptions, pricing tiers, data coverage, default false). The description does not need to add parameter details, and the baseline score of 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb ('Check') and clearly identifies the resource ('API health status, version, and available endpoints'). This distinguishes it from sibling tools like get_context and get_metric, which serve different purposes.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context for when to use the tool (checking API health, version, and endpoints) and adds an important usage note ('No authentication required'). While it does not explicitly name alternatives, the distinct purpose and sibling names make the use case evident.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_metricGet Metric AnalysisA
Read-only
Inspect

Get a single metric with pre-reasoned signal interpretation, trend analysis (7d/30d/90d), confidence score with factor breakdown, momentum, and percentile ranking. Available metrics: bitcoin-price, bitcoin-market-cap, bitcoin-volume-24h, bitcoin-change-24h, bitcoin-dominance, bitcoin-hash-rate, bitcoin-difficulty, bitcoin-tx-count, bitcoin-tx-volume, bitcoin-active-addresses, fed-balance, m2-supply, treasury-10y, rrp, eur-usd, cny-usd, yield-curve, tga, treasury-3mo, treasury-2y, treasury-5y, treasury-30y, breakeven-5y, breakeven-10y, t5yifr, mortgage-30y, t10y3m-spread, auction-bid-to-cover-10y, auction-bid-to-cover-30y, indirect-bidder-pct, dealer-takedown-pct, next-treasury-auction-days, fed-funds-rate, ecb-deposit-rate, boj-policy-rate, fed-ecb-spread, fed-boj-spread, carry-trade-returns-proxy, carry-trade-velocity-1d, mortgage-treasury-spread, iwm-spy-credit-spread, spy-vxx-correlation-30d, regime-stability-flag, net-liquidity, hash-ribbon, mvrv-proxy, etf-spy, etf-qqq, etf-iwm, etf-vxx, etf-uup, usdt-market-cap, usdt-dominance, btc-price-200d-ma, btc-price-200d-distance, btc-etf-net-flow, btc-etf-cumulative-flow, btc-etf-aum, btc-etf-ibit-flow, btc-etf-fbtc-flow, btc-etf-gbtc-flow, btc-etf-other-flow, btc-etf-ibit-aum, btc-etf-fbtc-aum, btc-etf-bitb-aum, btc-etf-arkb-aum, btc-etf-btco-aum, btc-etf-ezbc-aum, btc-etf-brrr-aum, btc-etf-hodl-aum, btc-etf-btcw-aum, btc-etf-gbtc-aum, btc-etf-btc-aum, bitcoin-price-1h-change-pct, raw-hashprice-tick, on-chain-velocity-30d, bitcoin-volume-zscore-30d. Requires API key authentication. Returns analyzed context (signal, trend direction, momentum, 90d percentile), not raw values. Use when you need to understand what a metric means for decision-making, not just its number.

ParametersJSON Schema
NameRequiredDescriptionDefault
metricYesMetric name to fetch
formatNoResponse format: markdown (default) or jsonmarkdown

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description discloses that authentication is required ('Requires API key authentication'), and specifies that the return value is analyzed context, not raw values. Annotations already indicate readOnlyHint=true, which is consistent. No contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long due to the exhaustive list of metrics, which could be referenced from the schema enum instead. The core functionality is front-loaded, but the list inflates the length unnecessarily. Still, it is well-structured and informative.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (multiple analysis components and a large set of metrics) and the absence of an output schema, the description provides sufficient context about return values (signal, trend direction, momentum, 90d percentile) and usage scenarios. No gaps are apparent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema has 100% coverage for both parameters, so the baseline is 3. The description adds value by listing all possible metric values (beyond the enum in the schema) and clarifying the default for the format parameter ('markdown (default)'). This is helpful.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool fetches a single metric with analyzed context (signal, trend, momentum, percentile). The list of available metrics is exhaustive, and the verb 'get' combined with 'metric' clearly distinguishes it from siblings like 'list_metrics' or 'get_context'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly advises when to use: 'Use when you need to understand what a metric means for decision-making, not just its number.' It contrasts with raw data retrieval, but doesn't explicitly mention alternative tools (e.g., list_metrics for listing all metrics). This is good but not perfect.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_briefingsList BriefingsA
Read-only
Inspect

List all available pre-reasoned market briefings with tier requirements. Returns 18 briefings across Free (6), Basic (6), and Pro (6) tiers. Covers Bitcoin, macro, FX, and cross-asset financial data categories. No authentication required.

ParametersJSON Schema
NameRequiredDescriptionDefault
tierNoFilter briefings by subscription tier (free, basic, or pro). Returns all tiers if omitted.

TDQS

A4.3/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, and the description adds useful behavioral context about tier distribution and categories without contradicting annotations. No destructive behavior is implied or omitted.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three sentences, each earning its place: purpose, specifics (counts per tier), and categories/auth. Front-loaded and no wasted words.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (one optional parameter, no output schema), the description fully covers what the tool does, what it returns, and key constraints (no auth). Complete for the intended use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Input schema has one optional parameter 'tier' with enum and description, and schema description coverage is 100%. The description mentions 'tier requirements' but adds little beyond what the schema provides, so baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'list' and resource 'market briefings', specifies tier requirements, and distinguishes from sibling tools (get_context, get_health, etc.) which perform different operations.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides context on what the tool returns (18 briefings across tiers, categories) and notes no authentication, implicitly guiding usage. However, it lacks explicit when-to-use vs alternatives, though sibling differentiation is clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_metricsList MetricsA
Read-only
Inspect

List all available individual metrics (30 metrics across bitcoin, macro, and calculated categories). Includes Bitcoin price, hash rate, Fed balance sheet, M2 supply, Treasury 10Y yield, net liquidity, and cross-asset indices (SPY, QQQ, VXX, UUP) used as BTC correlation signals. Optionally filter by category or search term. No authentication required.

ParametersJSON Schema
NameRequiredDescriptionDefault
categoryNoFilter by metric category
searchNoSearch term to filter metrics by name or description

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the readOnlyHint annotation, the description discloses that no authentication is required, lists specific metric categories and examples (Bitcoin price, hash rate, etc.), and clarifies the scope (30 metrics). This adds useful behavioral context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences with no wasted words. It front-loads the core purpose ('List all available individual metrics') and efficiently provides scope, examples, filter options, and authentication status.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity (list with optional filters, no output schema), the description covers purpose, scope, filtering, and authentication. It could optionally specify the return format (e.g., array of metric objects) but is largely complete for typical use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Both parameters (search, category) have clear descriptions in the input schema (100% coverage). The description reiterates filtering capability but adds no new semantic detail about parameter syntax or constraints beyond what the schema provides.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses the specific verb 'list' with the resource 'all available individual metrics' and provides concrete examples (30 metrics across bitcoin, macro, calculated categories). It clearly distinguishes from siblings like get_metric (single metric) and list_briefings (briefings).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description states the tool lists all metrics and allows optional filtering by category or search term, and notes no authentication required. It implies use for browsing available metrics, but does not explicitly contrast with get_metric for retrieving a specific metric's data.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 5 tool updatesv0.1.8
    • Addedget_context
    • Addedget_health
    • Addedget_metric
    • Addedlist_briefings
    • Addedlist_metrics
  2. 5 tool updatesv0.2.1
    • Removedget_context
    • Removedget_health
    • Removedget_metric
    • Removedlist_briefings
    • Removedlist_metrics
  3. 5 tool updatesv0.2.0
    • First observedget_context
    • First observedget_health
    • First observedget_metric
    • First observedlist_briefings
    • First observedlist_metrics

TDQS

A4.2/5.0

Scored across 5 tools

Disambiguation5/5

Each tool targets a distinct function: get_context retrieves briefings, get_metric analyzes a single metric, get_health checks API status, list_briefings and list_metrics enumerate available options. No ambiguity.

Naming Consistency5/5

All tools follow a consistent verb_noun pattern (get_context, get_health, get_metric, list_briefings, list_metrics) with clear and predictable naming.

Tool Count5/5

With 5 tools, the server is well-scoped for its purpose of providing pre-reasoned market briefings and metric analyses. Each tool earns its place without being too few or too many.

Completeness5/5

The tool surface covers the full lifecycle: listing available briefings and metrics, retrieving detailed analyses, and checking API health. No obvious gaps for the stated domain.

Maintenance

ActivitySlowing
ResponsivenessUnresponsive

Related MCP Connectors

Related MCP Servers