Peer is live on iOS and Android. Get USDC on Base from your phone. See the launch →

Come build on Peer

Cash out crypto.
Ship it in one prompt.

Peer Cash is the agent-first TypeScript SDK for building a crypto offramp: it routes assets supported by Relay or NEAR Intents to Base USDC, then fiat through the Peer protocol. No hosted widget or provider custody.

No API keyNo ID upload to PeerNon-custodial

01 / Start

Any supported crypto asset

Discover live source chains and tokens through Relay and NEAR Intents.

02 / Route

Base USDC

The SDK handles the route and creates the Peer order.

03 / Receive

Fiat in your payment app

Revolut, Wise, Zelle and more, at the live oracle rate.

Agent-first onboarding

Give your agent the job. Ship faster.

Paste this into your coding agent. It follows the live integration manual and includes recovery and tests.

integration-prompt.mdReady to paste
Integrate Peer Cash into this application using the current @zkp2p/cash package.

Before changing code, read https://github.com/zkp2p/peer-cash/blob/main/AGENTS.md and inspect this repository's wallet, signing, state, and test patterns.

Requirements:
1. Install @zkp2p/cash and viem with this repository's existing package manager.
2. Use createCashClient({ environment: "production" }) and discover payment platforms and currencies with capabilities(). Discover live source assets with capabilities({ includeRelaySources: true, includeNearIntentsSources: true }); do not hardcode them.
3. Add a cash-out flow supporting Relay EVM routes and NEAR Intents 1Click external deposits into Base USDC, then create a fiat cash-out order. Start with the Base USDC path if the host cannot safely execute either source route.
4. For NEAR Intents, use quoteNearIntentsSource(), persist the signed quote, deposit address, optional memo, and deadline before funding externally exactly once. Keep the 1Click JWT server-side behind a same-origin proxy. Wait for nearIntentsStatus() SUCCESS and reconcile destination evidence before creating a Base-only cash-out. Never resend after an uncertain submission.
5. Keep signing in the existing wallet or policy boundary. If signing happens outside the process, use prepare(), submit txs in steps[] order, wait for each receipt, then call finalizePreparedCashout().
6. Persist depositId with the current user or operation. Resume with order(depositId), and drive the UI or agent from state, nextActions, and typed CashError remediation. Never infer lifecycle state.
7. Treat estimate() as an oracle estimate, never a locked quote. Respect requiresAtomicAccessPolicy and requiresIdentityAttestation from capabilities(); fail before moving funds when the host cannot satisfy them.
8. Use withdraw(depositId) as the only unwind path. Never call escrow contracts directly or resubmit an unknown transaction.
9. Add focused tests for discovery, signing boundaries, persistence, recovery, and error handling. Run the repository's relevant test, typecheck, lint, and build commands.

Finish by reporting the files changed, the exact checks run, and any platform capability the host deliberately leaves to Peer web.

Come build on Peer

Join the builders already shipping on Peer.

Andrew Wilkinson

Andrew and Davy help builders move from idea to working integration: choose the right SDK, test a flow, debug a blocker, or find the right part of the protocol. Bring a repo, leave with a working route.

QR code for the Peer Builders Club on Telegram

Questions builders ask

Peer Cash FAQs

What is Peer Cash?

Peer Cash (@zkp2p/cash) is an offramp-only TypeScript SDK. It routes assets supported by Relay or NEAR Intents through Base USDC into fiat in the user's payment app at the live oracle rate.

How does a cash-out settle?

The user deposits USDC into the protocol contracts. A buyer pays them fiat and proves it; the contract then releases the USDC.

Does Peer hold funds during a cash-out?

No. USDC stays in the protocol contracts until payment is verified; fiat goes straight to the user's payment app.

Is Peer Cash an offramp API or an SDK?

An SDK. It talks directly to Peer and discovers live platforms, currencies, and limits at runtime.

Do users have to complete KYC with Peer to cash out?

No ID is uploaded to Peer. In the normal automated flow, payment is verified privately; if that fails, the maker can confirm it independently and use an explicit, irreversible manual release.

How is Peer Cash different from hosted offramp providers?

There is no hosted widget, API key, or provider account. The SDK connects your app directly to the Peer protocol.

Can a coding agent integrate Peer Cash on its own?

Yes. The prompt links the live integration manual and makes recovery and tests part of the job.

Which payment apps and assets does Peer Cash support?

Revolut, Wise, Zelle and more, from assets supported by Relay or NEAR Intents. Call capabilities() for the live platforms, currencies, and limits.

When should I use @zkp2p/sdk instead?

Use @zkp2p/sdk for custom spreads, buyer-side proof flows, vaults, and general maker or taker operations.