# codes.onv/onv-mcp

> 量化策略回测、组合配置与多交易所执行（14 家通道）

- name: codes.onv/onv-mcp
- version: 1.0.4
- connection class: R0 (autonomous)
- trust: 93/100
- quality: 76/100 (good)
- owner: not claimed
- descriptor: https://api.protogrid.dev/v1/servers/codes.onv%2Fonv-mcp
- tools: https://api.protogrid.dev/v1/servers/codes.onv%2Fonv-mcp/tools

**An agent can connect right now, no human step.** Remote endpoint, no authentication, reachable on the last probe.

## Connection (mcpServers)

```json
{
  "mcpServers": {
    "onv-mcp": {
      "type": "http",
      "url": "https://onv.codes/mcp"
    }
  }
}
```


## Trust

- hygiene: 100
- liveness: 97
- freshness: 100
- provenance: 80
- drivers: +repository +dns-namespace +website -thin-description +reachable +uptime-93% +updated-15d-ago
- Derived from observable signals (official registry feed and our own credential-free probes); no code audit performed.

## Quality 76/100 (good)

### protocol: 75 (weight 25)

- warn `protocol.modern`: newest supported version is 2025-11-25; 2026-07-28 not supported, older versions are deprecated until 2027-07-28
- n/a `protocol.stateless`: only applies to 2026-07-28 servers
- pass `protocol.transport`: streamable HTTP
- n/a `protocol.list_ttl`: only applies to 2026-07-28 servers

### authorization: n/a (weight 15)

- n/a `auth.prm`, `auth.as_metadata`, `auth.cimd`: no remote uses OAuth
- n/a `auth.secret_in_url`: no templated URL

### tool hygiene: 89 (weight 30)

- pass `tools.descriptions`: every tool has a description
- pass `tools.description_length`: descriptions are concise
- pass `tools.schemas`: every tool has an object input schema
- pass `tools.annotations`: 50 of 50 tools declare readOnlyHint or destructiveHint
- fail `tools.directory_hints`: no tool declares all four of readOnlyHint, destructiveHint, idempotentHint and openWorldHint; missing: platform_market_quote (idempotentHint, openWorldHint); platform_market_overview (idempotentHint, openWorldHint); platform_market_ticker (idempotentHint, openWorldHint); …
- pass `tools.token_cost`: about 6,200 tokens to load every tool
- pass `tools.api_dump`: tools are not a one-to-one API dump
- pass `tools.hidden_text`: no hidden text in tool names, descriptions, schemas or annotations
- pass `tools.poisoning`: no instructions aimed at the model in tool definitions

### stability: 50 (weight 15)

- warn `stability.changes`: 24 tool changes in 30 days
- fail `stability.rug_pull`: 2 tools kept their name but changed most of their description in 30 days; review before trusting them
- pass `stability.new_links`: no tool change named a new site

### dependencies: n/a (weight 15)

- n/a `deps.known_vulns`, `deps.mcp_sdk_version`, `deps.resolvable`: deps.dev does not know @onvcodes/mcp-server@1.0.4

- tools: 50, about 6,200 tokens to load them all
- tool set hash: 3dbb3126be26cf30e803f47e0c809f48
- tools last changed: 2026-11-15T05:50:46.208Z
- badge: [![protogrid quality](https://protogrid.dev/badge/codes.onv/onv-mcp.svg)](https://protogrid.dev/servers/codes.onv/onv-mcp)
- Checks run on what our credential-free, read-only probes observe; tools are never called and no code audit is performed.

### Definition changes

- 2026-11-15 `platform_publish_strategy` changed (description, inputSchema) **meaning changed**
  - before: 【策略】发布策略（写操作，需用户确认）。name 必填、category 为 dex/defi；code 为策略代码（可选）；subscription_price 订阅价格；strategy_id 可指定已有草稿发布。发布为公开上架。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
  - after: 【策略】提交策略审核（提交后进入 pending_review，不会直接上架）。name / category / agentCategory / code 必填；同时必须披露样本外结果 oos、搜索尝试次数 n_trials、经济解释 economicRationale（≥10 字）。live_observation_days 为实盘观察天数（可选；source=factory 来源时后端要求达到上架门槛）。strategy_id 可指定已有草稿提交。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- 2026-11-14 `platform_agent_performance` changed (title, description, annotations)
  - before: 【行情】查询**已订阅策略**的绩效（需本人有效订阅，或本人创建该策略）：订阅人数、样本内外指标、OOS 验证状态与实盘观察天数。参数 strategyId 必填。（cost: free）
  - after: 【策略】查询**已订阅策略**的绩效（需本人有效订阅，或本人创建该策略）：订阅人数、样本内外指标、OOS 验证状态与实盘观察天数。参数 strategyId 必填。（cost: free）
- 2026-11-14 `platform_agent_signal` changed (title, description, annotations)
  - before: 【行情】查询**已订阅策略**的最新交易信号（需本人有效订阅，或本人创建该策略）。返回最近信号列表（动作/标的/价格/时间等）；不包含下单执行。参数 strategyId 必填，limit 可选（默认 10，最大 50）。（cost: free）
  - after: 【策略】查询**已订阅策略**的最新交易信号（需本人有效订阅，或本人创建该策略）。返回最近信号列表（动作/标的/价格/时间等）；不包含下单执行。参数 strategyId 必填，limit 可选（默认 10，最大 50）。（cost: free）
- 2026-11-13 `platform_subscribe_plan` changed (title, annotations)
- 2026-11-13 `platform_unsubscribe` added
  - 【账户与额度】退订策略（写操作，需用户确认）：停止后续信号执行并释放订阅名额，不支持退款。subscriptionId 与 strategyId 二选一——只给 strategyId 时自动匹配本人当前有效订阅。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- 2026-11-13 `platform_subscribe_strategy` added
  - 【账户与额度】订阅策略市场里的 AI 助理 / 策略（写操作，需用户确认）：免费策略提交即生效；付费策略创建收款单并返回订单号与支付信息，支付确认后自动激活（不会重复扣费）。参数 strategyId 必填（来自 platform_list_agents），period 可选 monthly/quarterly/yearly。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- 2026-11-13 `platform_subscribe_guide` changed (description, inputSchema)
  - before: 【账户与额度】订阅引导（写操作，需用户确认）：为指定 AI 助理生成订阅引导信息（周期可选 day/week/month/year），确认后返回订阅链接与支付信息，不自动扣费。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
  - after: 【账户与额度】订阅引导（写操作，需用户确认）：为指定 AI 助理生成订阅引导信息（周期可选 day/week/month/year），确认后返回订阅链接与支付信息，不自动扣费。参数 strategyId 必填（agentId 为等价别名）。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- 2026-11-13 `platform_subscription_list` changed (description) **meaning changed**
  - before: 【账户与额度】查询我的订阅列表。无需参数。（cost: free）
  - after: 【账户与额度】查询我的策略订阅列表（含状态 status/running_status、到期时间 expires_at、最近执行错误 last_error/last_error_at）。退订用 platform_unsubscribe。无需参数。（cost: free）
- 2026-11-13 `platform_agent_performance` added
  - 【行情】查询**已订阅策略**的绩效（需本人有效订阅，或本人创建该策略）：订阅人数、样本内外指标、OOS 验证状态与实盘观察天数。参数 strategyId 必填。（cost: free）
- 2026-11-13 `platform_agent_signal` added
  - 【行情】查询**已订阅策略**的最新交易信号（需本人有效订阅，或本人创建该策略）。返回最近信号列表（动作/标的/价格/时间等）；不包含下单执行。参数 strategyId 必填，limit 可选（默认 10，最大 50）。（cost: free）

Full history: https://api.protogrid.dev/v1/servers/codes.onv%2Fonv-mcp/changes

## Dependencies

- npm @onvcodes/mcp-server@1.0.4: unknown

Dependency graphs from deps.dev; advisories from OSV.dev, including the GitHub Advisory Database and the PyPI Advisory Database; all CC BY 4.0.

## Remotes

- https://onv.codes/mcp (streamable-http, auth none, reachable true, uptime30d 0.9354839)

## Packages

- npm @onvcodes/mcp-server@1.0.4

## Tools (50)

- `platform_account_overview`: 【持仓与执行】我的跨所账户总览：各交易所余额、持仓与币种归并（无凭证返回空）。（cost: free）
- `platform_agent_performance`: 【策略】查询**已订阅策略**的绩效（需本人有效订阅，或本人创建该策略）：订阅人数、样本内外指标、OOS 验证状态与实盘观察天数。参数 strategyId 必填。（cost: free）
- `platform_agent_signal`: 【策略】查询**已订阅策略**的最新交易信号（需本人有效订阅，或本人创建该策略）。返回最近信号列表（动作/标的/价格/时间等）；不包含下单执行。参数 strategyId 必填，limit 可选（默认 10，最大 50）。（cost: free）
- `platform_ai_generate`: 【策略】AI 生成策略代码（写操作，需用户确认）：输入自然语言 prompt（可选 context 传入研究流水线结构化学徒上下文），返回策略代码与解释。（cost: ≈ 36–48 credits/次（按实际 tokens 结算））（写操作，外部调用将以 apikey 身份直接执行）
- `platform_ai_optimize`: 【策略】AI 多轮优化策略（写操作，需用户确认）：输入 prompt 描述策略目标，自动生成→回测→分析→改进（最多 maxRounds 轮，1-5，默认 3）。耗时较长。给了 initialCode 时第 1 轮不生成：直接回测这份既有代码作基线，第 2 轮起在其上改进（A3）。strategyParams 为指标参数覆盖（对齐 /api/cex/indicator/backtest 的 params）。context 为可选结构化学徒上下文（B2-a，失败因子/评审结论/目标指标），独立注入 LLM。每轮回传 rounds[].params（本轮实际生效参数）与 rounds[].errorCode（失败原因可判定）；全轮未产出代码时返回 502/429 + errorCode，不再返回空 finalCode。（cost: ≈ 34–38 credits/轮（按实际 tokens 结算））（写操作，外部调用将以 apikey 身份直接执行）
- `platform_backtest_history`: 【策略】查询回测历史（可指定策略 ID 过滤）。参数 strategyId 可选。（cost: free）
- `platform_backtest_result`: 【策略】查询回测任务结果。参数 jobId 为 run_backtest 返回的任务 ID。（cost: free）
- `platform_cancel_order`: 【持仓与执行】撤销未成交挂单（写操作，需确认）：exchangeOrderId 与 clientOrderId 二选一。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_close_position`: 【持仓与执行】平仓（写操作，需确认）：按 credentialId + symbol 平掉持仓；closeScope=full 全平，传 size 时部分平。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_close_preview`: 【持仓与执行】一键全平预演（dry-run，不会下单）：列出将被平仓的合约持仓 / 现货余额目标与合计盈亏。可按凭证或交易对过滤。（cost: free）
- `platform_credentials`: 【账户与额度】查询我绑定的交易所凭证（脱敏，不含密钥）。返回凭证 ID/交易所/名称，供下单、平仓、查询使用。（cost: free）
- `platform_dex_quote`: 【行情】链上 DEX 报价（只读）：chain 如 ETH/BSC/BASE/SOL，fromToken/toToken 为代币地址或符号，amount 为最小单位字符串。（cost: free）
- `platform_dex_swap`: 【持仓与执行】链上 DEX 兑换（写操作，需确认，动用真实资金）：钱包地址自动取本人智能账户，不接受任意地址；大额授权需 approvalToken（由平台签发）。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_explain_backtest`: 【行情】解释一次回测「为什么亏 / 为什么没成交」。返回结构化卡片（数据区间、样本内外、最大回撤、数据缺失）与逐条原因。参数 runId / jobId / strategyId 至少给一个，三选一即可。（cost: free）
- `platform_explain_factors`: 【行情】解释一次回测里各因子对收益的贡献：同一指标代码 / 区间 / 参数，逐个剔除一个因子列重跑，用指标差分（基准 − 剔除后）给出边际贡献，并把每个数字的 source 写明（基准结果 / ablate(id)）。参数 runId / jobId 至少给一个，maxFactors 可选（默认 3，最大 5）。（cost: free）
- `platform_explain_portfolio`: 【行情】解释我的持仓与账户风控：逐仓名义价值 / 未实现盈亏 / 杠杆，以及账户敞口、当日盈亏、保证金使用率、熔断状态。返回结构化卡片，每个数字带 source（来源接口 + 字段），narrative.traces 写明口径公式；不做收益预测。（cost: free）
- `platform_factory_run`: 【策略】发起策略工厂运行（写操作，需确认）：sourceType=llm（描述生成）/search（条件扫描）/optimize（优化现有策略，需 strategyId）。同一用户同时只允许一个运行。（cost: base 5 + 10/1k bars（>10000 部分 5/1k） + 1/1k tokens credits）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_factory_runs`: 【策略】查询我的策略工厂运行记录；传 runId 时返回该次运行详情。（cost: free）
- `platform_flat_all`: 【持仓与执行】一键全平（写操作，需确认）：默认 dryRun=true 只预演；确认执行须显式 dryRun=false。可按凭证/交易对/市场类型限定，marketType=spot 时清现货余额。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_get_agent`: 【策略】获取单个已发布的公开 AI 助理（策略）详情。参数 agentId 为策略 ID。（cost: free）
- `platform_list_agents`: 【策略】列出平台上已发布的公开 AI 助理（策略），可按能力过滤与分页。参数 capabilities 可选（如 dex/defi）。（cost: free）
- `platform_manage_strategy`: 【策略】管理自己的策略（写操作，需用户确认）。action 为 create / update / delete；update/delete 需要 strategyId；create/update 用 data 传策略数据（data.name 必填，data.strategy_category 为 dex/defi）。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_market_factors`: 【行情】查询标的的市场因子数据（技术/宏观因子）。参数 symbol 为交易标的。（cost: free）
- `platform_market_overview`: 【行情】市场总览：主流币种快照、涨跌幅、成交量等市场状态概览。（cost: free）
- `platform_market_quote`: 【行情】查询平台行情 K 线。参数 symbol 为交易标的（如 BTCUSDT / ETHUSDT），timeframe 可选 1m/5m/15m/30m/1H/4H/1D，limit 最大 299。返回该标的的 K 线数组。（cost: free）
- `platform_market_ticker`: 【行情】查询标的实时行情 ticker。参数 symbol 为交易标的（如 BTCUSDT，可选，缺省返回全部）。（cost: free）
- `platform_my_strategies`: 【策略】查询我创建的**策略市场/订阅域**策略列表（onv-backend `strategies` 表，按钱包地址归属，邮箱注册账号回退按数字 userId）。⚠️ 不含实盘策略——实盘策略在 `qd_strategies_trading`，请用 REST `GET /api/cex/strategies`（该端点不支持 status 过滤，返回全部状态）。status 可选 draft/published/archived（缺省三者全取）。（cost: free）
- `platform_place_order`: 【持仓与执行】真实下单（写操作，需确认，动用真实资金）：credentialId 来自 platform_credentials，amount 为 USDT 名义金额；orderType=market|limit，限价单必填 price。执行前校验账号级「AI 实盘授权」，未开启一律拒绝。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_plans`: 【账户与额度】查询平台订阅套餐列表（免费/付费 tier 与价格）。无需参数。（cost: free）
- `platform_positions`: 【持仓与执行】我的全部持仓（跨交易所扁平化，含方向/数量/开仓价/未实现盈亏）。可按交易所或交易对过滤。（cost: free）
- `platform_publish_strategy`: 【策略】提交策略审核（提交后进入 pending_review，不会直接上架）。name / category / agentCategory / code 必填；同时必须披露样本外结果 oos、搜索尝试次数 n_trials、经济解释 economicRationale（≥10 字）。live_observation_days 为实盘观察天数（可选；source=factory 来源时后端要求达到上架门槛）。strategy_id 可指定已有草稿提交。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_quick_analysis`: 【行情】对指定标的进行快速 AI 技术分析（拉取行情并生成分析结论）。参数 symbol 为交易标的，如 BTCUSDT。（cost: ≈ 22–28 credits/次（按实际 tokens 结算））
- `platform_reset_breaker`: 【账户与额度】人工解除熔断（写操作，需确认）：须提供 recoveryCode；解除后策略恢复实盘执行。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_risk_config`: 【账户与额度】查询我的账户级风控面板：配置、熔断状态、聚合风险与策略风险。（cost: free）
- `platform_run_backtest`: 【策略】提交回测任务（写操作，需用户确认）。strategy 为策略代码字符串或已有策略 ID（纯数字），symbol 为交易标的如 BTCUSDT，timeframe 可选 1m/5m/15m/30m/1H/4H/1D。params 为指标参数覆盖（可选，写入引擎 indicator_params，与代码内 # @param 默认值合并、此处优先），与同步链 /api/cex/indicator/backtest 的 params 同口径。（cost: ≈ 27 credits/次（90d·1H））（写操作，外部调用将以 apikey 身份直接执行）
- `platform_set_breaker`: 【账户与额度】更新账户熔断配置（写操作，需确认）：enabled 开关，可设日亏损上限、连续失败次数、gas 尖峰上限。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_set_risk_config`: 【账户与额度】更新账户级风控配置（写操作，需确认）：config 为要修改的字段对象（如日亏损上限、单笔上限）。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_strategy_performance`: 【持仓与执行】查询**实盘策略**的绩效（策略级，按实盘策略 ID）：权益曲线、最新权益、区间收益与点数。ID 取自 `qd_strategies_trading`。（cost: free）
- `platform_strategy_positions`: 【持仓与执行】查询**实盘策略**的持仓（策略级，按实盘策略 ID）。⚠️ ID 取自 `qd_strategies_trading`（REST `GET /api/cex/strategies`），不是策略市场/订阅域的 `strategies` 表 ID。返回方向/数量/开仓价/未实现盈亏。（cost: free）
- `platform_strategy_trades`: 【持仓与执行】查询**实盘策略**的成交记录（策略级，按实盘策略 ID；含平仓原因与模拟盘标记）。ID 取自 `qd_strategies_trading`。（cost: free）
- `platform_subscribe_guide`: 【账户与额度】订阅引导（写操作，需用户确认）：为指定 AI 助理生成订阅引导信息（周期可选 day/week/month/year），确认后返回订阅链接与支付信息，不自动扣费。参数 strategyId 必填（agentId 为等价别名）。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_subscribe_plan`: 【账户与额度】购买平台套餐（写操作，需用户确认）：plan_id 必填（来自 platform_plans），period 可选 day/week/month/year，payment_method 可选 chain/x402。创建支付订单，支付在平台完成。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_subscribe_strategy`: 【账户与额度】订阅策略市场里的 AI 助理 / 策略（写操作，需用户确认）：免费策略提交即生效；付费策略创建收款单并返回订单号与支付信息，支付确认后自动激活（不会重复扣费）。参数 strategyId 必填（来自 platform_list_agents），period 可选 monthly/quarterly/yearly。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_subscription_list`: 【账户与额度】查询我的策略订阅列表（含状态 status/running_status、到期时间 expires_at、最近执行错误 last_error/last_error_at）。退订用 platform_unsubscribe。无需参数。（cost: free）
- `platform_subscription_status`: 【账户与额度】查询对某 AI 助理的订阅状态。参数 strategyId 或 agentId。（cost: free）
- `platform_symbol_search`: 【行情】搜索平台支持的交易标的（币种/交易对）。参数 query 为关键词如 BTC。（cost: free）
- `platform_trade_history`: 【持仓与执行】查询我的最近成交记录（默认 50 条，最多 200）。（cost: free）
- `platform_unsubscribe`: 【账户与额度】退订策略（写操作，需用户确认）：停止后续信号执行并释放订阅名额，不支持退款。subscriptionId 与 strategyId 二选一——只给 strategyId 时自动匹配本人当前有效订阅。（cost: free）（写操作，外部调用将以 apikey 身份直接执行）
- `platform_user_subscription`: 【账户与额度】查询我的平台套餐订阅状态（当前套餐/到期时间）。无需参数。（cost: free）
- `platform_user_usage`: 【账户与额度】查询我的平台用量汇总（今日 bars / 本月 tokens / 剩余配额）。无需参数。（cost: free）
