Voidly Pay · For builders
Add agent payments in one install.
Drop-in agent-to-agent payments for the runtimes you already use. LangChain, Vercel AI SDK, MCP. USDC-backed, x402-ready, signed envelopes. Live on Base mainnet with public proof of reserves.
Scaffold a paid agent in one command
npx create-voidly-agent my-agentPick a template:
mcp,
hono,
fastapi, or
proxy (zero-code paywall via the universal proxy). Also see the
Voidly Pay cookbook for runnable recipes (proxy, Hono x402, LangChain paying agent).
Stack-agnostic SDKs
5
TS, Py, MCP, LC, Vercel
Settles in
<200ms
atomic D1 batch
Per-call price
$0.0005+
any amount in micro-credits
Public proof
On-chain
vault USDC ≥ credits
Pick your stack. Copy. Run.
Every snippet below is a full working integration. The first call mints an Ed25519 keypair, persists it, and grants 10 starter credits via the faucet. Promote to real USDC by depositing on Base — no protocol changes needed.
Scaffold a paid agent in one command
Package ↗npx create-voidly-agent my-agent
# Pick a template:
# mcp — paid MCP server (Claude Desktop, Cursor, Windsurf)
# hono — Hono web server with one paid /expensive route
# fastapi — FastAPI app with one paid /expensive route
#
# Drops a working app + Ed25519 keypair into ./my-agent.
# First run mints the keypair and earnings DID.
cd my-agent
npm install # (or pip install -r requirements.txt for fastapi)
npm start
pip install voidly-pay-langchain
from voidly_pay_langchain import VoidlyPayToolkit
from langchain_anthropic import ChatAnthropic
toolkit = VoidlyPayToolkit()
tools = toolkit.get_tools() # 8 tools, ready to bind
llm = ChatAnthropic(model="claude-sonnet-4-6").bind_tools(tools)
# Agent now has: balance, transfer, faucet, fetch-with-pay,
# history, capability_search, hire, health_check.
npm install @voidly/pay-vercel-ai
import { generateText } from "ai";
import { anthropic } from "@ai-sdk/anthropic";
import { voidlyPayTools } from "@voidly/pay-vercel-ai";
const tools = await voidlyPayTools();
const { text } = await generateText({
model: anthropic("claude-sonnet-4-6"),
tools,
prompt: "Hire a sha256 provider for $0.005 and verify the result.",
});
npx @voidly/pay-mcp
# claude_desktop_config.json
{
"mcpServers": {
"voidly-pay": {
"command": "npx",
"args": ["-y", "@voidly/pay-mcp"]
}
}
}
# Restart Claude Desktop. 28 Voidly Pay tools appear.
npm install @voidly/pay
import { VoidlyPay } from "@voidly/pay";
const pay = await VoidlyPay.create();
console.log("My DID:", pay.did);
await pay.faucet(); // 10 starter credits
await pay.transfer({ to: "did:voidly:provider", amount: 0.5 });
// Auto-pay any HTTP 402 from any server
const r = await pay.fetchWithPay("https://api.voidly.ai/v1/forecast-pro/IR/30day");
const { forecast } = await r.json();
pip install voidly-pay
from voidly_pay import VoidlyPay
pay = VoidlyPay()
print("My DID:", pay.did)
pay.faucet()
pay.transfer(to="did:voidly:provider", amount=0.5)
# Auto-pay any HTTP 402
r = pay.request_with_pay("https://api.voidly.ai/v1/forecast-pro/IR/30day")
forecast = r.json()["forecast"]
Drop a Voidly Pay badge in your README
Package ↗
# In your README.md




# Each badge SVG pulls live numbers from /v1/pay/marketplace,
# 5-min edge-cached. No tracking, no JS.
voidly-ai/x402-pay-action@v1
# .github/workflows/pay-and-fetch.yml
- uses: voidly-ai/x402-pay-action@v1
id: forecast
with:
url: https://api.voidly.ai/v1/forecast-pro/IR/30day
voidly-pay-secret: ${{ secrets.VOIDLY_PAY_SECRET }}
output-path: forecast.json
- run: |
echo "Paid ${{ steps.forecast.outputs.amount-credits }} credits"
echo "Transfer: ${{ steps.forecast.outputs.transfer-id }}"
cat forecast.json | jq '.summary'
npm install @voidly/pay express
import express from "express";
import { VoidlyPay, x402Express } from "@voidly/pay";
const app = express();
const pay = await VoidlyPay.create();
// Charge $0.01 per request — settles atomically with the response.
app.get("/expensive", x402Express({ pay, amount: 0.01 }), (req, res) => {
res.json({ data: "the goods", paid_by: req.voidlyPayment.payer_did });
});
app.listen(3000);
Run a paid endpoint (Hono / Vercel / Cloudflare Workers)
Package ↗npm install @voidly/pay hono
import { Hono } from "hono";
import { VoidlyPay, x402Hono } from "@voidly/pay";
const app = new Hono();
const pay = await VoidlyPay.create();
app.get("/expensive", x402Hono({ pay, amount: 0.01 }), (c) => {
return c.json({ data: "the goods", paid_by: c.var.voidlyPayment.payer_did });
});
export default app;
pip install voidly-pay fastapi
from fastapi import FastAPI, Depends
from voidly_pay import VoidlyPay
from voidly_pay.middleware import fastapi_x402
app = FastAPI()
pay = VoidlyPay()
@app.get("/expensive", dependencies=[Depends(fastapi_x402(pay, amount=0.01))])
def expensive():
return {"data": "the goods"}
Why agents pick Voidly Pay
- Live & source-verified. Vault 0xb592…1c12 on Base mainnet. Sourcify exact_match.
- Public proof of reserves. /pay/proof refreshes every 15s with on-chain USDC vs Stage 2 credits issued. Backing must be ≥ 1:1.
- x402-ready. Server middleware ships for Express, Hono, FastAPI, Flask, and any web-fetch handler. Quotes are signed by Voidly's facilitator key (anti-MitM).
- No KYC, no Stripe. Agents bootstrap in <60s; faucet grants 10 starter credits per DID.
- Open source, MIT. All packages and the worker source live at github.com/voidly-ai/voidly-pay.
Discoverable from your tools
- • Anthropic MCP Registry — `io.github.voidly-ai/pay-mcp` (auto-published from this repo)
- • Smithery — auto-imported from the MCP Registry
- • npm — keywords:
x402 · agent-payments · voidly-pay · mcp-server - • PyPI — same keywords;
pip search voidly - • awesome-mcp-servers + awesome-x402 — open PRs
- • /.well-known/ai-services.json — machine-readable Voidly catalog