Skip to main content
Glama
tradallo-reputation

tradallo-reputation

Official
by tradallo

@tradallo/reputation

npm version license MCP

用于 Tradallo 验证记录协议 的 MCP 服务器 + TypeScript 客户端 + CLI。提供三种查询经加密验证的人类和代理交易记录的方式:

# CLI — pretty terminal cards, no install required
npx @tradallo/reputation card alpha-momentum-v3 --agent

# MCP — drop into Claude Desktop / Cursor / any MCP client (config below)

# Programmatic — typed TS/JS client
import { TradalloClient } from "@tradallo/reputation";

每个响应在呈现前都会根据 Tradallo 发布在 tradallo.com/.well-known/tradallo-pubkeys.json 的公钥进行 JCS 规范化 + ed25519 验证。签名位于信封中;此客户端获取公钥注册表,解析 key_id,验证签名,然后才返回数据。通过 served_at + max_age_seconds 提供重放保护。

安装

Claude Desktop

添加到你的 claude_desktop_config.json(设置 → 开发者 → 编辑配置):

{
  "mcpServers": {
    "tradallo-reputation": {
      "command": "npx",
      "args": ["-y", "@tradallo/reputation"]
    }
  }
}

重启 Claude Desktop。Tradallo 工具应出现在工具面板中。

Cursor

添加到 ~/.cursor/mcp.json(或通过 Cursor 设置 → MCP):

{
  "mcpServers": {
    "tradallo-reputation": {
      "command": "npx",
      "args": ["-y", "@tradallo/reputation"]
    }
  }
}

通用 MCP 客户端

npx @tradallo/reputation

通过 stdio 进行 MCP 通信。

本地开发 / 测试环境

通过设置 TRADALLO_BASE_URL 指向你自己的部署:

{
  "mcpServers": {
    "tradallo-reputation": {
      "command": "npx",
      "args": ["-y", "@tradallo/reputation"],
      "env": { "TRADALLO_BASE_URL": "http://localhost:3000" }
    }
  }
}

Related MCP server: aip-identity

CLI

该二进制文件在调用子命令时也可作为终端 CLI 使用:

# Pretty card with verification status, stats, version metadata
npx @tradallo/reputation card alpha-momentum-v3 --agent

# Raw verified JSON (for piping into jq, etc.)
npx @tradallo/reputation track-record alpha-momentum-v3 --agent

# Discovery
npx @tradallo/reputation search --min-sharpe 1.5 --min-trades 200 --sort-by sharpe

# Agent version history
npx @tradallo/reputation versions alpha-momentum-v3

# Paginated UTRs
npx @tradallo/reputation utrs alpha-momentum-v3 --limit 50

# Look up a specific UTR by hash
npx @tradallo/reputation verify <sha256-hex> alpha-momentum-v3

# Help
npx @tradallo/reputation help

NO_COLOR=1 可禁用 ANSI。TRADALLO_BASE_URL 会覆盖 API 基地址。

编程客户端

将验证客户端嵌入到你自己的 TS/JS 代码中:

import { TradalloClient } from "@tradallo/reputation";

const client = new TradalloClient(); // defaults to https://tradallo.com

// Throws if signature invalid, replay window expired, or pubkey unknown.
// Returns the verified `data` payload (not the envelope wrapper).
const record = await client.getSigned<{ stats: { all_time: { sharpe_ratio: number | null } } }>(
  "/api/v1/agents/alpha-momentum-v3/track-record",
);

if ((record.stats.all_time.sharpe_ratio ?? 0) >= 1.5) {
  // ... delegate capital, copy trades, etc.
}

验证流程发生在 getSigned 内部。如果出现任何失败(签名错误、信封过期、未知密钥、模式不匹配),调用将抛出异常。你永远不会看到未经验证的数据。

工具

get_track_record(handle, principal_type?)

获取 Tradallo 个人资料或代理的已验证业绩记录。

输入:

  • handle (string, 必填) — Tradallo 句柄(例如 aaronjordan, alpha-momentum-v3)

  • principal_type ("human" | "agent", 可选, 默认 "agent") — 要查找的命名空间

返回: 完整的签名载荷(验证级别、历史总计 + 滚动 30/90/365 天统计数据,包括夏普比率、最大回撤、胜率、盈亏、期望值)。

使用示例:

"向我展示 Aaron Jordan 在 Tradallo 上的已验证交易记录。"

search_records(filters)

发现符合绩效标准的已验证记录。

输入(均为可选): min_sharpe, min_trades, max_drawdown, venue, principal_type, sort_by, limit。

返回: 带有统计数据的人类/代理摘要的排序列表。签名已验证。

verify_utr(utr_hash)

通过哈希查找通用交易收据 (UTR)。返回 Tradallo 是否已通过 Solana 备注将该哈希锚定在链上,如果是,则返回链、签名、槽位、发布时间、Solana 浏览器 URL 和公证人公钥,以便调用者可以独立进行链上验证。

返回: { found, anchored_on_chain, chain?, signature?, slot?, posted_at?, explorer_url?, notarizer_pubkey? }。

get_versions(agent_handle)

获取代理的完整版本历史(语义化版本标签、version_hash、policy_hash、每个版本的部署和被取代时间)。签名已验证。

get_utrs(agent_handle, since?, limit?)

获取代理的原始通用交易收据,按 closed_at 进行游标分页。每张收据都包含由 Tradallo 重新计算的 SHA-256 哈希,以便消费者可以抽查单条记录。

验证工作原理

每个已签名的 Tradallo API 响应都将数据封装在带有 ed25519 签名的 JCS 规范化 (RFC 8785) 信封中:

{
  "data": { ... },
  "schema_version": "1",
  "served_at": "2026-04-30T22:29:52.776Z",
  "max_age_seconds": 60,
  "signature": {
    "alg": "ed25519",
    "key_id": "tradallo-prod-2026-04",
    "sig": "<base64>"
  }
}

此 MCP 服务器:

  1. 获取 /.well-known/tradallo-pubkeys.json(缓存 5 分钟)

  2. 解析 signature.key_id → ed25519 公钥

  3. 对 {data, schema_version, served_at, max_age_seconds} 进行 JCS 规范化

  4. 根据公钥验证签名

  5. 拒绝 now > served_at + max_age_seconds 的响应(重放保护)

如果任何检查失败,工具调用将返回错误而不是数据。代理会被告知原因。

为什么这很重要

身份(代理是谁)和支付(如何支付)在 2026 年已通过 x402、MPP、Coinbase Agentic Wallets 和 ERC-8004 得到解决。声誉则不然。 当代理决定是否委托资本、复制交易或订阅来自另一方的信号时,它需要一种方式来询问:“他们的记录是真的吗?”

此 MCP 服务器是提出该问题的最低摩擦方式。

x402 — 即将推出

目前,公共 API 是匿名的且受 IP 速率限制(60 次请求/分钟)。我们正在通过 x402(HTTP 402 付费标准)推出分级访问,以便代理可以在 Base 上支付 USDC 微交易,从而绕过速率限制并解锁更高吞吐量的层级,无需任何注册或 API 密钥操作。

前向兼容的预期:

  • 匿名:60 次请求/分钟/IP(目前,免费)

  • 活跃订阅者:通过 API 密钥 600 次请求/分钟(开发中 — 阶段 4.4)

  • x402 微支付:针对单次重型查询的按调用 USDC 支付;无需账户(计划于阶段 4.5)

  • 运营商/车队层级:Webhook 订阅、自定义子域名、优先级索引

一旦促进器管道连接完毕,速率限制响应将获得一个 x402 支付选项块。此 MCP 服务器将在看到带有 x402 元数据的 402 响应时开始自动支付。在此之前,所有查询都是免费且可验证的。

参考代理

一个在委托资本前查询 Tradallo 的工作示例代理: github.com/tradallo/agent。

规范与文档

更新日志

参见 CHANGELOG.md。

许可证

MIT

Available Tools

5 tools
get_track_recordAInspect

Fetch a verified trading track record for a Tradallo profile (human) or agent. Returns cryptographically-verified statistics (Sharpe, win rate, max drawdown, PnL, trade count) computed from on-chain or in-house-sim trade history. The signature is ed25519-verified against Tradallo's published pubkey before this tool returns.

Inputs: handle (required), principal_type.

get_utrsAInspect

Fetch raw Universal Trade Receipts for an agent. Each UTR is a v2 canonical receipt with its SHA-256 hash recomputed by Tradallo so consumers can spot-check individual receipts. Paginated cursor-style on closed_at.

Inputs: agent_handle (required), since, limit.

get_versionsAInspect

Fetch the full version history of an agent (semver tags, version_hash, policy_hash, when each version was deployed and superseded). Useful for understanding which version of an agent's policy produced a given track record. The response is signature-verified.

Inputs: agent_handle (required).

search_recordsAInspect

Search verified trading records by performance filters (Sharpe, max drawdown, trade count, venue, principal type). Returns a list of summary records sorted by the chosen metric. Useful for an agent shopping for strategies that meet specific risk/return criteria. The response is signature-verified against Tradallo's published pubkey before being returned.

Inputs: min_sharpe, min_trades, max_drawdown, venue, +3 more.

verify_utrAInspect

Look up a Universal Trade Receipt by hash. Returns whether Tradallo has anchored that hash on-chain via a Solana memo transaction, and if so, returns the chain, signature, slot, posted_at, explorer URL, and notarizer pubkey so the caller can independently verify the anchor on Solana Explorer. The signed-envelope response is ed25519-verified before this tool returns.

Inputs: utr_hash (required).

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A4.3/5.0

    Scored across 5 tools

    Disambiguation5/5

    Each tool serves a clear, distinct purpose: fetching a track record, fetching raw receipts, retrieving version history, searching records by filters, and verifying a receipt's on-chain anchor. No two tools overlap in functionality, and descriptions clearly differentiate them.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun pattern (get_track_record, get_utrs, get_versions, search_records, verify_utr), using lowercase with underscores. The naming is predictable and easy to parse.

    Tool Count5/5

    Five tools is ideal for this domain: they cover the core operations (fetching individual records, listing receipts, version history, search, and verification) without unnecessary bloat. The scope is well-defined and each tool earns its place.

    Completeness5/5

    The tool set provides a complete surface for querying and verifying trading reputation data: individual track records, raw receipts, version history, search by filters, and cryptographic verification. No obvious gaps exist for a read-only verification service.

    Maintenance

    ActivityInactive
    ResponsivenessLimited data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      MCP server for AI agent identity — verify agents with Ed25519 signatures, check trust scores, sign and verify content, exchange encrypted messages. Built on the Agent Identity Protocol (AIP).
      8
      1
      MIT
    • F
      license
      A
      quality
      C
      maintenance
      Reputation and trust scoring service for AI agents, exposed as an MCP server. Evaluate counterparties, report interactions, issue portable trust certificates, and detect Sybil attacks.
      23
      70 PyPI
      -
    • A
      license
      A
      quality
      D
      maintenance
      An MCP server that bridges ERC-8004 agent identity, reputation, and validation registries into tool calls, enabling discovery, inspection, and verification of on-chain AI agents from any MCP client.
      8
      MIT