Armory is a TypeScript toolkit for x402 v2 payments that lets APIs require wallet-based payment over standard HTTP flows.Documentation Index
Fetch the complete documentation index at: https://armory.sh/llms.txt
Use this file to discover all available pages before exploring further.
Armory targets x402 v2 wire compatibility so Armory clients and middleware can interoperate with Coinbase x402 SDK implementations.
What You Can Build
- Paid API endpoints using middleware in Express, Hono, Bun, Elysia, and Next.js.
- Wallet-based API clients using Viem, Ethers.js, and Web3.js.
- Multi-network and multi-token payment flows with shared base logic.
How Armory Works
- A protected endpoint returns
402withPAYMENT-REQUIRED. - The client selects one option from
accepts[]and signs a payment payload. - The retried request sends
PAYMENT-SIGNATURE. - The server verifies/settles and returns data with
PAYMENT-RESPONSE.
Start Here
Core Packages
@armory-sh/base: shared protocol types, encoding, and payment flow logic.- Middleware packages: route protection and payment verification.
- Client packages: wallet integration and payment retries.
@armory-sh/extensions: optional protocol extensions.@armory-sh/client-hooks: optional selection/logging hooks.