Token导航 LogoToken导航TokenDH.com
研究检索external-servicegithub未标认证来源可访问许可证需确认审计提醒

paymentspayments 搜索

Agent Skill

payments 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

599

周安装

24

GitHub Stars

2

下载量

194
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:payments(payments 搜索)
来源仓库:https://github.com/contextvm/cvmi
仓库路径:skills/payments
安装命令:
npx skills add https://github.com/contextvm/cvmi --skill payments
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/contextvm/cvmi --skill payments

简介

payments 实现基于 CEP-8 标准的计费中间件,支持按能力收费与自动支付。

  • 适用于希望 monetize MCP 服务的企业级部署场景,提供 SDK 集成指引。
  • 客户端与服务端均需配置支付处理器,确保请求经授权后才继续执行。
  • 生产使用前应测试沙箱环境,确认签名与通知机制稳定可靠。
  • payments 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

ContextVM Payments (CEP-8)

Use this skill when you want ContextVM servers to charge for specific capabilities and clients to pay automatically using the TypeScript SDK payments layer.

Payments are implemented as middleware around transports:

  • Server-side middleware gates priced requests: it must not forward to the underlying MCP server until payment is verified.
  • Client-side middleware listens for payment notifications, executes a handler, then continues the original request.

This skill documents *how to use* the SDK payments layer. For transport setup (signers, relays, encryption), see:

Quick start: charge for one tool (server + client)

Server: price a capability and attach payments

import type { PricedCapability } from '@contextvm/sdk/payments';
import { LnBolt11NwcPaymentProcessor, withServerPayments } from '@contextvm/sdk/payments';

const pricedCapabilities: PricedCapability[] = [
  {
    method: 'tools/call',
    name: 'my-tool',
    amount: 10,
    currencyUnit: 'sats',
    description: 'Example paid tool',
  },
];

const processor = new LnBolt11NwcPaymentProcessor({
  nwcConnectionString: process.env.NWC_SERVER_CONNECTION!,
});

const paidTransport = withServerPayments(baseTransport, {
  processors: [processor],
  pricedCapabilities,
});

Client: attach a handler and pay automatically

import { LnBolt11NwcPaymentHandler, withClientPayments } from '@contextvm/sdk/payments';

const handler = new LnBolt11NwcPaymentHandler({
  nwcConnectionString: process.env.NWC_CLIENT_CONNECTION!,
});

const paidTransport = withClientPayments(baseTransport, {
  handlers: [handler],
});

Core concepts (what to understand once)

Notifications and correlation

CEP-8 payments are expressed as correlated JSON-RPC notifications:

  • notifications/payment_required
  • notifications/payment_accepted
  • notifications/payment_rejected (reject without charging)

They are correlated to the original request via an e tag (request event id). Your app should treat these as notifications, not responses.

PMI (Payment Method Identifier)

Each payment rail is identified by a PMI string (example: bitcoin-lightning-bolt11).

  • Server processors advertise which PMIs they can accept.
  • Client handlers advertise which PMIs they can pay.
  • A payment only works if there is an intersection.

Amounts: advertise vs settle

pricedCapabilities[].amount + currencyUnit are what you *advertise* (discovery). The selected PMI determines how you *settle*.

If you use dynamic pricing via resolvePrice, the amount you return must match the unit expected by your chosen processor.

Server patterns

  • Fixed pricing via pricedCapabilities
  • Dynamic pricing via resolvePrice
  • Reject without charging via resolvePrice → {reject: true, message?}
  • Waive payment (prepaid/subscription) via resolvePrice → {waive: true}

Read: references/server-setup.md

Client patterns

  • Multiple handlers (multiple rails)
  • Handling payment_rejected outcomes
  • PMI advertisement via pmi tags (automatic when wrapping with withClientPayments)

Read: references/client-setup.md

Built-in rails (provided by the SDK)

The SDK currently ships multiple built-in payment rails under the same PMI:

  • PMI: bitcoin-lightning-bolt11

Rails:

  • Lightning over NWC (NIP-47)

- Server: LnBolt11NwcPaymentProcessor - Client: LnBolt11NwcPaymentHandler - Read: references/lightning-nwc.md

  • Lightning via LNbits (REST API)

- Server: LnBolt11LnbitsPaymentProcessor - Client: LnBolt11LnbitsPaymentHandler - Read: references/lightning-lnbits.md

More rails may be added over time (new PMIs and/or additional implementations under existing PMIs). Prefer selecting rails based on PMI compatibility and operational needs.

Build your own rail (custom PMI)

Implement:

  • a server-side PaymentProcessor (issue + verify)
  • a client-side PaymentHandler (pay)

Read: references/custom-rails.md

Troubleshooting pointers

  • No payment_required: verify request matches method + name in pricedCapabilities.
  • Payment succeeds but no payment_accepted: verify server relay connectivity and processor verification settings.
  • Immediate rejection: handle notifications/payment_rejected and surface the optional message.

For general relay/encryption/connection issues, see ../troubleshooting/SKILL.md.

Reference index

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

35.61%
按下载量换算69

Claude

28.04%
按下载量换算54

Cursor

19.92%
按下载量换算39

Gemini CLI

9.31%
按下载量换算18

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

external-service

该 Skill 可能调用第三方服务、云服务或外部模型 API,使用前需要确认账号、额度、数据发送范围和服务条款。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills