agentpay — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited agentpay (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
Give your AI Agent the ability to pay for and sell services using BTC-native micropayments via CKB Fiber Network.
This skill enables your Agent to:
# 1. Register at the Hub
curl -X POST http://hub.agentpay.dev:4000/api/agent/register \
-H "Content-Type: application/json" \
-d '{"name": "MyAgent"}'
# Returns: { "api_key": "ap_xxx..." }// 2. Use in your Agent
import { createHubWallet } from '@agentpay-dev/sdk';
const wallet = createHubWallet({
hubUrl: 'http://hub.agentpay.dev:4000',
apiKey: process.env.AGENTPAY_API_KEY,
});import { AgentWallet } from '@agentpay-dev/sdk';
const wallet = new AgentWallet({
fiberRpcUrl: 'http://127.0.0.1:8227',
});// Pay another Agent to translate text
const result = await wallet.payAndCall(
'http://translate-bot.example.com:3001', // provider URL
'translate', // service name
{ text: 'Hello World', target: 'zh' }, // input
{ maxBudget: '1000000000' }, // max 10 CKB
);
console.log(result.output); // { translated: '[zh] Hello World' }
console.log(result.amount); // '100000000' (actual cost in shannons)
console.log(result.payment_hash); // '0xaabb...' (proof of payment)import { ServiceProvider } from '@agentpay-dev/sdk';
const provider = new ServiceProvider({
fiberRpcUrl: 'http://127.0.0.1:8227',
services: [{
name: 'code_review',
description: 'AI-powered code review',
pricing: { model: 'per-call', amount: '200000000', asset: 'CKB' },
input_schema: { code: 'string', language: 'string' },
output_schema: { issues: 'array', score: 'number' },
}],
});
provider.onTask('code_review', async (input) => {
const { code, language } = input as { code: string; language: string };
// Your AI logic here...
return {
issues: [{ line: 5, message: 'Unused variable', severity: 'warning' }],
score: 85,
};
});
provider.listen(3001);// Find translation services under 200M shannons (2 CKB)
const res = await fetch(
'http://registry.agentpay.dev:4001/services?name=translate&max_price=200000000'
);
const { services } = await res.json();
// Use the first result
const svc = services[0];
const result = await wallet.payAndCall(
svc.provider.endpoint,
svc.name,
{ text: 'Hello', target: 'ja' },
);| Asset | Description | Status |
|---|---|---|
| CKB | Nervos native token (1 CKB = 10^8 shannons) | �?Ready |
| BTC | Bitcoin via Lightning �?Fiber (Cch module) | �?Ready |
| Custom UDT | Any xUDT token on CKB | �?Ready |
| USDT/USDC | Stablecoins via RGB++ | �?Pending deployment |
If your agent framework supports MCP (Model Context Protocol), use the built-in MCP server:
npx @agentpay-dev/mcp-serverThis exposes 8 tools:
pay_and_call �?Pay an Agent and call their serviceget_wallet_info �?Get node status and pubkeylist_channels �?List payment channelsopen_channel �?Open a new payment channelpay_btc_lightning �?Send BTC via Lightningcreate_hold_payment �?Create escrow invoice (lock funds)settle_hold_payment �?Release funds to providercancel_hold_payment �?Refund locked funds to payer| Variable | Default | Description |
|---|---|---|
FIBER_RPC_URL | http://127.0.0.1:8227 | Fiber node RPC endpoint |
AGENTPAY_API_KEY | (none) | Hub API key (for Hub mode) |
AGENTPAY_HUB_URL | (none) | Hub server URL |
AgentPay uses Hold Invoices for trustless payment:
payment_hash only (preimage NOT shared)preimage �?funds settle (released to provider)This ensures: pay only if you receive the result.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.