Peer

io.github.zkp2p由 GitHub 帳號 zkp2p 發布v0.4.1更新於 Oct 27, 2026

Read Peer protocol, market, checkout, and Peer Cash data through one MCP server.

已驗證Streamable HTTP可網頁執行資料庫金融

概覽

AI 產生的概覽

Peer 協定的遠端 MCP 伺服器,讓助理讀取法幣兌 USDC 報價、存款、intent、金庫與 Peer Cash 資料。

可以做什麼
  • 取得法幣兌 USDC 匯率報價,並從鏈上存款資料解析收款方雜湊
  • 列出並檢視存款,包含 ProtocolViewer 與索引器版本、資金活動與每日快照
  • 列出並檢視 intent、履約輸入、鉤子、履約事件與金額
  • 讀取金庫詳情、委託存款、快照、利率更新、管理費與有效利率
  • 驗證預言機資料來源並檢查是否支援內嵌預言機設定
  • 對索引器執行原始 GraphQL 查詢
適用情境
適合助理需要查詢 Peer 協定狀態(報價、存款、intent、金庫或 Peer Cash 訂單)而不想執行本機工具的情境。託管端點僅提供唯讀設定,適合研究、監控與對帳,而非簽章或廣播交易。
執行需求
使用 mcp.peer.xyz 的託管端點無需安裝任何東西,透過 Streamable HTTP 連線。本機 CLI 方案需要 Node.js 22 或更新版本及 peer-protocol-cli 套件;選用憑證包括 PEER_API_KEY、PEER_INDEXER_API_KEY、PEER_MARKET_API_KEY 與 PEER_PAY_API_KEY。
安裝前請注意
託管伺服器只開放唯讀設定,但本機 CLI 可執行 cash 與 full 設定並準備交易;寫入類工具預設先預覽,除非以 --yes 啟動。簽章資料來自 PEER_PRIVATE_KEY 或錢包檔案,在命令列傳入私鑰會出現在行程清單中。原始 GraphQL 查詢可能耗費較高。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Peer,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/io.github.zkp2p%2Fpeer/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。

{
  "mcpServers": {
    "peer": {
      "type": "http",
      "url": "https://mcp.peer.xyz/mcp"
    }
  }
}

README

peer-cli

The canonical agent interface for Peer: one JSON-first CLI, local and hosted MCP servers, and one generated contract for protocol, indexer, market, checkout, and Peer Cash workflows.

The generated files come from the runtime registries. Do not hand-maintain a second command list in documentation.

Install

Node.js 22 or newer is required.

The package is peer-protocol-cli; do not install the unrelated unscoped peer-cli package.

bash
npm install --global [email protected]peer --help

Run without a global install:

bash
npx -y [email protected] quote --from USD --amount 100 --platform wise

Successful output is JSON by default. Errors always use the canonical JSON error envelope on stderr. --format table changes successful human-facing output only.

Safety model

Read commands execute immediately. Commands that can mutate state return a transaction or API preview first and execute only when the process receives --yes.

Signer material resolves from PEER_PRIVATE_KEY or --wallet-path. Passing a private key on the command line is supported but visible in process listings; prefer the environment or an owner-readable wallet file. Persistent config and checkout caches are written with owner-only permissions.

Never start a write-capable MCP process with --yes unless every write tool in that process is intentionally allowed to broadcast without a second CLI preview.

MCP profiles

peer mcp requires one of three explicit profiles:

  • read-only — default protocol reads plus Peer Cash reads. No signing or broadcasting.
  • cash — the complete custody-separated peer_cash_* surface. It prepares unsigned transaction plans but never accepts a private key, signs, or broadcasts.
  • full — every generic CLI-backed MCP tool plus Peer Cash. Generic write tools still preview unless the MCP process was started with global --yes.

The current tool counts are generated in agents/runtime-manifest.json.

json
{  "mcpServers": {    "peer": {      "command": "npx",      "args": [        "-y",        "[email protected]",        "mcp",        "--profile",        "read-only"      ]    }  }}

Use --profile cash for the portable Peer Cash workflow or --profile full for the complete operator surface.

The hosted MCP server exposes only the read-only profile over Streamable HTTP:

text
https://mcp.peer.xyz/mcp

Run the same transport yourself with peer mcp --transport http. HTTP refuses the cash and full profiles; those authority-bearing profiles remain local stdio processes.

Peer Cash

The retired standalone peer-cash-mcp server now lives here. Its tool names and custody boundary are unchanged:

  1. peer_cash_capabilities / peer_cash_source_capabilities — fetch live payout rails and Relay-supported source chains and tokens.
  2. peer_cash_fill_stats / peer_cash_buyer — inspect historical fill evidence and buyer protocol history.
  3. peer_cash_quote_source / peer_cash_relay_status — quote and track a cross-chain route into Base USDC without granting signer authority.
  4. peer_cash_estimate — estimate fiat received at the current oracle rate.
  5. peer_cash_prepare — return ordered unsigned approval and deposit transactions.
  6. peer_cash_finalize — resolve a confirmed receipt into a durable depositId.
  7. peer_cash_order / peer_cash_orders — resume and inspect orders.
  8. peer_cash_prepare_access_policy, peer_cash_prepare_withdraw, and peer_cash_prepare_top_up — prepare follow-up transactions.

Base USDC amounts are decimal strings in 6-decimal base units: 100 USDC is 100000000. Estimates are not locked quotes; the binding Chainlink rate resolves when a buyer fills.

Install the packaged portable skill from skills/peer-cash/SKILL.md when the agent host supports Agent Skills.

Configuration

Configuration resolves in this order:

  1. CLI flags
  2. environment variables
  3. ~/.peer/config.json
  4. runtime defaults

Common settings:

  • PEER_ENV: production, preproduction, or staging
  • PEER_PRIVATE_KEY / PEER_WALLET_PATH: signer material for generic write commands
  • PEER_RPC_URL: Base RPC override
  • PEER_API_KEY: Curator API key when required
  • PEER_INDEXER_API_KEY / PEER_INDEXER_URL: indexer overrides
  • PEER_MARKET_API_KEY / PEER_MARKET_BASE_URL: Peerlytics access
  • PEER_PAY_API_KEY / PEER_PAY_BASE_URL: hosted checkout access
  • PEER_BASE_API_URL: Curator override. Defaults follow PEER_ENV: api.zkp2p.xyz, api-preprod.zkp2p.xyz, or api-staging.zkp2p.xyz.
  • PEER_CASH_RPC_URL, PEER_CASH_API_KEY, PEER_CASH_REFERRAL_CODE, and PEER_CASH_REFERRER: cash-profile overrides

Use peer config show, set, unset, and reset for persistent local settings. peer config show masks secret values. Prefer environment variables for credentials.

Command families

The CLI covers:

  • quotes, payee registration, and payee-hash resolution
  • deposit lifecycle, payment methods, currencies, oracle configuration, and batch updates
  • intents, pre-intent hooks, fulfillment, release, and cleanup
  • StakeVault deposits, withdrawals, authorization, indexed freshness, and matured chargeback releases
  • IntentGuardian policy, live extension quotes, payer funding, and preview-first intent extension
  • ProtocolViewer and indexer reads, including a raw GraphQL escape hatch
  • vaults, rate managers, delegation, fees, and snapshots
  • Peerlytics market, explorer, history, attribution, and API-key operations
  • USDC balances and transfers
  • hosted checkout creation, reads, cancellation, and local resume cache
  • local config and environment inspection

Run peer --help, peer <family> --help, or inspect the generated tool catalog for the exact current paths, flags, schemas, auth requirements, and danger markers.

Every command also accepts --params <json> and --params-file <path>. Typed flags override raw values.

Development

This repository uses npm and its committed package-lock.json.

bash
npm installnpm run dev -- quote --from USD --amount 100 --platform wisenpm run check

npm run build regenerates all agent catalogs before bundling peer and the public MCP library entry point. Run npm run test:e2e after changing networked flows or checkout behavior.

The documentation application for agents.peer.xyz is owned by zkp2p/zkp2p-clients at clients/agents; this repository owns the executable runtime, package manifests, portable skill, and generated contracts it documents.

UPI

UPI/INR is available in production, preproduction and staging, matching the @zkp2p/sdk catalog. peer config platforms lists it alongside the other rails, and peer quote --from INR --amount 100 --platform upi requests a quote. Deposit creation, payee registration and intent previews accept the same platform.

來源:README.md,提交 5abfb3e

工具

97

peer_quote

Get fiat-to-USDC exchange quotes.

輸入參數tofromuseramountparamsplatformrecipienttokenAmountquotesToReturndestinationChainId

peer_payee_resolve_hash

Resolve a payee hash from on-chain deposit data.

輸入參數paramsdepositId必填paymentMethodHash必填

peer_deposit_list

List deposits owned by the configured wallet or explicit owner.

輸入參數ownerparams

peer_deposit_show

Show a single deposit by deposit ID.

輸入參數paramsdepositId必填

peer_deposit_show_many

Show multiple deposits by ID.

輸入參數idsparams

peer_pv_deposit_show

Fetch a deposit directly from ProtocolViewer.

輸入參數paramsdepositId必填

peer_pv_deposit_show_many

Fetch multiple deposits directly from ProtocolViewer.

輸入參數idsparams

peer_pv_deposit_list_owner

Fetch deposits for an owner directly from ProtocolViewer.

輸入參數ownerparams

peer_indexer_deposits_list

List deposits via the indexer.

輸入參數filterparamspagination

peer_indexer_deposits_list_relations

List deposits with related entities via the indexer.

輸入參數filterparamsoptionspagination

peer_indexer_deposits_show

Fetch a deposit by composite ID via the indexer.

輸入參數paramsoptionscompositeId必填

peer_indexer_deposits_by_ids

Fetch multiple deposits by composite ID.

輸入參數idsparams

peer_indexer_deposits_by_ids_relations

Fetch multiple deposits with relations by composite ID.

輸入參數idsparamsoptions

peer_indexer_deposits_fund_activities

Fetch fund activities for a deposit.

輸入參數paramsdepositId必填

peer_indexer_makers_fund_activities

Fetch maker-level fund activities.

輸入參數limitmaker必填params

peer_indexer_deposits_snapshots

Fetch deposit daily snapshots.

輸入參數limitparamsdepositId必填

peer_indexer_query

Perform a raw GraphQL query against the indexer. Use sparingly; arbitrary queries can be expensive.

輸入參數queryparamsvariables

peer_intent_list

List intents for the configured wallet or explicit owner.

輸入參數ownerparams

peer_intent_show

Show a single intent by hash.

輸入參數paramsintentHash必填

peer_intent_fulfill_inputs

Inspect fulfill routing inputs for an intent.

輸入參數paramsintentHash必填

peer_intent_hook_pre_get

Get the pre-intent hook for a deposit.

輸入參數paramsdepositId必填

peer_pv_intent_list_owner

Fetch intents for an owner directly from ProtocolViewer.

輸入參數ownerparams

peer_pv_intent_show

Fetch a single intent directly from ProtocolViewer.

輸入參數paramsintentHash必填

peer_indexer_intents_by_deposit_ids

Fetch intents for multiple deposits via the indexer.

輸入參數paramsstatusesdepositIds

peer_indexer_intents_by_owner

Fetch intents by owner via the indexer.

輸入參數owner必填paramsstatuses

peer_indexer_intents_show

Fetch a single intent via the indexer.

輸入參數paramsintentHash必填

peer_indexer_intents_expired

Fetch expired intents via the indexer.

輸入參數nowlimitparamsdepositIds

peer_indexer_intents_fulfilled_events

Fetch fulfillment events for intents.

輸入參數hashesparams

peer_indexer_intents_fulfillment_amounts

Fetch fulfillment amounts for an intent.

輸入參數paramsintentHash必填

peer_indexer_intents_fulfillment_and_payment

Fetch fulfillment and payment records for an intent.

輸入參數paramsintentHash必填

peer_vault_list

List vaults via the indexer.

輸入參數limitfilteroffsetparamsmanagerpagination

peer_vault_show

Show vault details by rateManagerId.

輸入參數paramsrateManagerId必填

peer_vault_delegates

List delegated deposits for a vault.

輸入參數limitoffsetparamspaginationrateManagerId必填

peer_vault_snapshots

Fetch daily snapshots for a vault.

輸入參數limitparamsoptionsrateManagerId必填

peer_vault_manual_rate_updates

Fetch manual rate updates for a vault.

輸入參數limitparamsoptionsrateManagerId必填

peer_vault_oracle_config_updates

Fetch oracle config updates for a vault.

輸入參數limitparamsoptionsrateManagerId必填

peer_vault_manager_fee

Read the effective manager fee for a delegated deposit.

輸入參數escrowparamsdepositId

peer_vault_effective_rate

Read the effective rate for a delegated deposit pair.

輸入參數escrowparamscurrencyplatformdepositId

peer_oracle_supports_inline

Check whether the current escrow deployment supports inline oracle configs.

輸入參數paramsescrowAddress

peer_oracle_validate_feeds

Validate bundled oracle feeds on-chain.

輸入參數params

peer_delegate_show

Show current controller-based delegation for a deposit.

輸入參數escrowparamsdeposit

peer_indexer_delegations_by_deposit

Fetch the delegation record for a composite deposit ID via the indexer.

輸入參數paramsoptionsdepositId必填

peer_market_spreads

Fetch current market spreads from Peerlytics.

輸入參數limitparamscurrencyplatformincludeRates

peer_market_orderbook

Fetch the live P2P orderbook from Peerlytics.

輸入參數paramsminSizecurrencyplatform

peer_market_compare

Compare live quote availability across platforms using the published SDK quote route.

輸入參數fromamountparamsplatformrecipientquotesToReturn

peer_market_volume

Fetch Peerlytics protocol volume and analytics for a time range.

輸入參數rangeparamscurrencyplatform

peer_market_leaderboard

Fetch maker and taker leaderboard data from Peerlytics.

輸入參數limitoffsetparams

peer_market_protocol_stats

Fetch aggregate Peerlytics protocol statistics.

輸入參數params

peer_market_vaults

Fetch Peerlytics vault analytics.

輸入參數limitoffsetparams

peer_market_explorer_address

Look up a wallet address profile on Peerlytics.

輸入參數limitoffsetparamsaddress必填

peer_market_explorer_deposit

Look up a deposit on Peerlytics.

輸入參數id必填limitoffsetparams

peer_market_explorer_intent

Look up an intent on Peerlytics.

輸入參數hash必填params

peer_market_explorer_maker

Look up a maker profile on Peerlytics.

輸入參數paramsaddress必填

peer_market_explorer_verifier

Look up a verifier profile on Peerlytics.

輸入參數paramsaddress必填

peer_market_explorer_vault

Look up a vault on Peerlytics.

輸入參數id必填params

peer_market_deposits

Query deposits from Peerlytics with filtering.

輸入參數limitoffsetparamsstatuscurrencydelegateplatformacceptingdepositor

peer_market_intents

Query intents from Peerlytics with filtering.

輸入參數limitowneroffsetparamsstatusdepositIdrecipient

peer_market_activity

Fetch recent protocol activity from Peerlytics.

輸入參數typelimitsinceparams

peer_market_taker_history

Fetch taker activity history for an address from Peerlytics.

輸入參數paramsaddress必填

peer_market_maker_history

Fetch maker activity history for an address from Peerlytics.

輸入參數paramsaddress必填

peer_market_meta_platforms

List supported payment platforms from Peerlytics with method hashes.

輸入參數params

peer_market_meta_currencies

List supported currencies from Peerlytics.

輸入參數params

peer_market_api_key_list

List Peerlytics API keys for the authenticated account.

輸入參數params

peer_market_credits

Check Peerlytics API credit balance and usage.

輸入參數params

peer_balance

Read the current USDC balance for an address.

輸入參數tokenparamsaddress

peer_checkout_list

List checkout sessions from the Pay API, with a local cache fallback.

輸入參數pageparamsstatuspageSize

peer_checkout_show

Show a single checkout session or poll its latest status.

輸入參數paramssessionId必填

peer_config_show

Show the stored Peer CLI config merged with current global flags.

輸入參數params

peer_config_platforms

List supported payment platforms.

輸入參數params

peer_config_currencies

List supported fiat currencies.

輸入參數params

peer_stake_state

Read the authoritative StakeVault state for a staker and optional taker.

輸入參數takerparamsstaker必填

peer_stake_indexed_state

Read indexed staking, authorization, claim, and risk-window state with freshness metadata.

輸入參數taker必填params

peer_stake_balance

Read total stake owned by an address.

輸入參數owner必填params

peer_stake_locked

Read stake locked behind active chargeback windows.

輸入參數owner必填params

peer_stake_free

Read stake available for withdrawal or a new lock.

輸入參數owner必填params

peer_stake_claimable

Read non-stake USDC claimable by a beneficiary.

輸入參數paramsbeneficiary必填

peer_stake_owner

Resolve the effective stake owner backing a taker.

輸入參數taker必填params

peer_stake_selected_owner

Read the stake owner selected by a taker before authorization checks.

輸入參數taker必填params

peer_stake_authorization

Read whether a stake owner authorizes a taker.

輸入參數owner必填taker必填params

peer_stake_admissions_paused

Read whether chargebackable intent admissions are paused.

輸入參數params

peer_stake_risk_window

Read the minimum collateral lock window for a payment method.

輸入參數paramspaymentMethodHash必填

peer_stake_dispute_protection_enabled

Read whether a deposit has dispute protection enabled for a payment method.

輸入參數escrow必填paramsdepositId必填paymentMethod必填

peer_guardian_available

Check whether the selected environment has an IntentGuardian deployment.

輸入參數params

peer_guardian_policy

Read the live IntentGuardian fee and extension policy.

輸入參數params

peer_guardian_quote_extension

Quote the authoritative on-chain cost to extend an intent.

輸入參數paramsintentAmount必填additionalSeconds必填

peer_guardian_payer_funding

Read payer token balance and allowance available to IntentGuardian.

輸入參數payer必填token必填params

peer_cash_capabilities

Discover Peer Cash capabilities

Return live Base USDC destinations, payout platforms, fiat currencies, payee hints, amount bounds, and pricing. Call this before naming a rail or currency.

輸入參數includeRelaySources

peer_cash_fill_stats

Read Peer Cash fill statistics

Return trailing 30-day fill counts and first-fill timing by payout platform and currency. Use this as historical routing evidence, never as a guarantee.

無需輸入參數。

peer_cash_source_capabilities

Discover cross-chain source assets

Return live Relay-supported EVM source chains and tokens that can route into Base USDC before a Peer Cash order.

無需輸入參數。

peer_cash_quote_source

Quote a source asset into Base USDC

Quote a live Relay route from an EVM source asset into Base USDC. The response contains unsigned transaction data; this tool never signs or submits it.

輸入參數user必填amount必填recipienttradeTypesourceChainId必填sourceCurrency必填

peer_cash_relay_status

Read Relay execution status

Track a previously submitted cross-chain source route by Relay request ID. Retry this read; never resubmit from an unknown status.

輸入參數requestId必填

peer_cash_estimate

Estimate fiat received

Estimate fiat received for Base USDC at the live Chainlink oracle rate. This is not a locked quote; the binding rate resolves when a buyer fills.

輸入參數amount必填currency必填platform

peer_cash_finalize

Finalize a confirmed cash-out deposit

Read a confirmed Base createDeposit receipt and resolve the resumable Peer deposit id. Call only after the host confirms the createDeposit transaction.

輸入參數transactionHash必填

peer_cash_buyer

Read a Peer Cash buyer profile

Return protocol history for the buyer that matched an order so an automation can assess delivery context without trusting display identity.

輸入參數address必填

peer_cash_order

Read a Peer Cash order

Return one order state, amounts, fills, and next actions from its deposit id. Brief ORDER_NOT_FOUND responses after finalization may be indexer lag; retry this read, never the deposit transaction.

輸入參數depositId必填

peer_cash_orders

List Peer Cash orders

List orders owned by a maker wallet, optionally limited to orders that still need attention.

輸入參數limitowner必填inFlight

版本歷史

2
  1. v0.4.1最新Sep 21, 2026
  2. v0.4.0Sep 16, 2026

評分

已滿足適用檢查項的 100%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具必需15 分
  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分