{"_id":"@agentmoney/seller-sdk","_rev":"2-520e7f7901c9f63a9cdde0f97a7e3a14","name":"@agentmoney/seller-sdk","dist-tags":{"latest":"0.14.0"},"versions":{"0.13.0":{"name":"@agentmoney/seller-sdk","version":"0.13.0","keywords":["agent-payments","paywall","hono","x402","http-402","ai-agents"],"author":{"name":"Maxwell Calkin"},"license":"Apache-2.0","_id":"@agentmoney/seller-sdk@0.13.0","maintainers":[{"name":"isthisreality","email":"Mcalkinmusic@gmail.com"}],"homepage":"https://github.com/MaxwellCalkin/money#readme","bugs":{"url":"https://github.com/MaxwellCalkin/money/issues"},"dist":{"shasum":"cdd17d3f577d958f094cca23bc3e724c0f2b58ed","tarball":"https://registry.npmjs.org/@agentmoney/seller-sdk/-/seller-sdk-0.13.0.tgz","fileCount":5,"integrity":"sha512-bOMF6n0DX8BU8ZjSLY1gnD2yHbXegscedYrwMY1ALcDYxFDyJoaylgPpq5pSQ+rYorRQpXOV2dciPpLiD171bQ==","signatures":[{"sig":"MEQCIByc0UNZfSSUehKHPq1fBlSwXN0/LMMCOUE6d0jdwEBjAiBW7udFFQ1EIzHtMH4jLAOQbYG4d7ahQNrCyq9yrc9vzg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":23777},"type":"module","types":"./index.d.ts","engines":{"node":">=20"},"exports":{".":{"types":"./index.d.ts","default":"./dist/index.js"}},"gitHead":"4348da7626e548dd1146680131d499f75dc132ad","scripts":{"prepack":"node ../../scripts/build-packages.mjs"},"_npmUser":{"name":"isthisreality","email":"Mcalkinmusic@gmail.com"},"repository":{"url":"git+https://github.com/MaxwellCalkin/money.git","type":"git","directory":"packages/seller-sdk"},"_npmVersion":"12.0.2","description":"Seller SDK for the money agent-payment network: a Hono paywall middleware plus a signed client for challenges, receipt redemption, and refunds.","directories":{},"_nodeVersion":"24.19.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"peerDependencies":{"hono":"^4.12.30"},"peerDependenciesMeta":{"hono":{"optional":true}},"_npmOperationalInternal":{"tmp":"tmp/seller-sdk_0.13.0_1786048310431_0.7813308497805265","host":"s3://npm-registry-packages-npm-production"}},"0.14.0":{"_id":"@agentmoney/seller-sdk@0.14.0","bugs":{"url":"https://github.com/MaxwellCalkin/money/issues"},"dist":{"shasum":"a5c8748a800bbcd09106c9a997b6a18484390c7a","tarball":"https://registry.npmjs.org/@agentmoney/seller-sdk/-/seller-sdk-0.14.0.tgz","fileCount":5,"integrity":"sha512-gurAL26yOwJLifloFAkmeo9Rr4Neyn7YRCrxf2kGDqhHJIwMnt8LV8NvyDNvDJC8VdYYI9jgKNgTStHtSPfqCg==","signatures":[{"sig":"MEUCICxXLORMQvsX67JHu9uOAqg5B+BTpURZLSUm0LLe9vRgAiEA/h+JM5Ma0jhi8Vfhy1JRXsjwbsWF2kovjCIyxpOGwe0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQD6CGG+NS2kIiwHmT/jGxr2gr7fwjJ8IgQ1bZyy30i3CgIgdguT13zdypyAGfYwopUklz/9/YVUhcHJLOOj/EXGpGI="}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@agentmoney%2fseller-sdk@0.14.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":23777},"name":"@agentmoney/seller-sdk","type":"module","types":"./index.d.ts","author":{"name":"Maxwell Calkin"},"engines":{"node":">=20"},"exports":{".":{"types":"./index.d.ts","default":"./dist/index.js"}},"gitHead":"0f766590968cc956d6cd789d94d90282e80435fa","license":"Apache-2.0","scripts":{"prepack":"node ../../scripts/build-packages.mjs"},"version":"0.14.0","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:002ed183-fb18-478a-8cf5-6a1044a8e604"}},"homepage":"https://github.com/MaxwellCalkin/money#readme","keywords":["agent-payments","paywall","hono","x402","http-402","ai-agents"],"repository":{"url":"git+https://github.com/MaxwellCalkin/money.git","type":"git","directory":"packages/seller-sdk"},"_npmVersion":"11.16.0","description":"Seller SDK for the money agent-payment network: a Hono paywall middleware plus a signed client for challenges, receipt redemption, and refunds.","directories":{},"maintainers":[{"name":"isthisreality","email":"Mcalkinmusic@gmail.com"}],"_nodeVersion":"24.18.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"peerDependencies":{"hono":"^4.12.30"},"peerDependenciesMeta":{"hono":{"optional":true}},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/seller-sdk_0.14.0_1787951645885_0.9874903360614524"}}},"time":{"created":"2026-08-06T20:31:50.182Z","modified":"2026-08-28T21:14:06.294Z","0.13.0":"2026-08-06T20:31:50.581Z","0.14.0":"2026-08-28T21:14:05.972Z"},"bugs":{"url":"https://github.com/MaxwellCalkin/money/issues"},"author":{"name":"Maxwell Calkin"},"license":"Apache-2.0","homepage":"https://github.com/MaxwellCalkin/money#readme","keywords":["agent-payments","paywall","hono","x402","http-402","ai-agents"],"repository":{"url":"git+https://github.com/MaxwellCalkin/money.git","type":"git","directory":"packages/seller-sdk"},"description":"Seller SDK for the money agent-payment network: a Hono paywall middleware plus a signed client for challenges, receipt redemption, and refunds.","maintainers":[{"name":"isthisreality","email":"Mcalkinmusic@gmail.com"}],"readme":"# @agentmoney/seller-sdk\n\nCharge AI agents for your API. This is the seller SDK for a\n[money](https://github.com/MaxwellCalkin/money) network: a\n[Hono](https://hono.dev) paywall middleware plus a signed client for\nchallenges, receipt redemption, and refunds. Prices come from your registered\nservice — the network is authoritative, so a compromised route can never\ninvent one.\n\n## Quickstart (10 minutes)\n\n1. **Register as a provider.** Your network operator (or the repo's\n   `npm run onboard:seller`) registers your `@handle`, your service, and its\n   price, and gives you `MONEY_API`, `MONEY_PROVIDER_ID`, `MONEY_SERVICE_ID`,\n   and a provider key file for `MONEY_PROVIDER_KEY_FILE`.\n\n2. **Mount the paywall:**\n\n```ts\nimport { Hono } from \"hono\";\nimport { createMoneySellerClient, moneyPaid, secretFromEnv } from \"@agentmoney/seller-sdk\";\n\nconst providerKey = secretFromEnv(\"MONEY_PROVIDER_KEY\")!; // reads MONEY_PROVIDER_KEY_FILE or the inline var\n\nconst app = new Hono();\napp.get(\"/report\", moneyPaid({\n  networkUrl: process.env.MONEY_API!,\n  providerId: process.env.MONEY_PROVIDER_ID!,\n  providerKey,\n  serviceId: process.env.MONEY_SERVICE_ID!,\n}), (c) => c.json({ report: \"valuable machine-readable result\" }));\n```\n\nUnpaid requests receive a 402 challenge issued by the network from your\nregistered price; the middleware redeems the agent's receipt (pay-once,\nredeem-once) before your handler runs.\n\n3. **Refund when you should** — partial or full, idempotent, capped at the\n   original purchase:\n\n```ts\nconst seller = createMoneySellerClient({\n  networkUrl: process.env.MONEY_API!,\n  providerId: process.env.MONEY_PROVIDER_ID!,\n  providerKey,\n});\n\nawait seller.refund({\n  receiptId: \"rcpt_...\",\n  amountMicros: 10_000, // $0.01 = 10,000 micros\n  memo: \"service credit\",\n  idempotencyKey: \"refund-order-123-v1\",\n});\n```\n\n## Notes\n\n- Zero runtime dependencies. `hono` is an optional peer used only for the\n  middleware's types — `createMoneySellerClient` works in any Node app.\n- Amounts are integer micro-dollars (1,000,000 micros = $1).\n- Every call to the network is Ed25519-signed with your provider key and\n  bound to method, path, body, timestamp, and a nonce.\n\n## License\n\nApache-2.0 — see [LICENSE](./LICENSE).\n","readmeFilename":"README.md"}