Skip to main content

Developers

SafeBank is an infrastructure API for money. You get programmable multisig wallets, a sandbox faucet, and stablecoin (USDC) payments to @handles, email, or raw addresses — behind one REST API, a typed @safebank/sdk, and the sb CLI.

If you have shipped against Stripe or Twilio, this will feel familiar: get a key, make a call, get a predictable JSON response. The difference is that the money settles on-chain (Base) through a Safe multisig you control.

Mental model

Everything hangs off three primitives:

Tenant  ─┬─►  API key  ─┬─►  Wallets      (Safe multisigs you own)
│ ├─► Funding (sandbox faucet → USDC / ETH)
│ ├─► Payments (propose → sign → execute)
│ └─► Cards (issuing — spend from a wallet)
PrimitiveWhat it is
TenantYour organization. Owns keys, wallets, payments, and the team. Created once (from the dashboard, or POST /v1/tenants).
API keyA scoped credential (sb_test_… / sb_live_…) that authenticates every request. See Authentication.
WalletA Safe multisig deployed on Base, owned by one or more signer addresses. See Wallets.
FundingIn sandbox, a rate-limited faucet that drips test USDC / ETH into a wallet.
PaymentA USDC transfer from a wallet to a @handle, email, or address — proposed, signed, and executed. See Payments.
CardIssued cards that spend from a wallet balance (issuing surface: POST /v1/cards).

Start here

  • Quickstart — key → wallet → faucet → first payment, in under 30 minutes.
  • Environments — sandbox vs live, key formats, base URLs, and the Base Sepolia test chain.
  • Authentication — API keys, scopes, and the PrincipalGuard.

Three ways to call every endpoint

The docs give you curl, the TypeScript SDK, and the CLI side by side. Pick one:

ToolBest for
REST (curl)Any language; the REST reference is the full surface.
@safebank/sdkTypeScript/Node apps — typed, auto-retries, auto-idempotency, and signSafeTxHash.
sb CLIScripting, CI, and exploring from your terminal (sb demo).

Reference

  • REST reference — every endpoint, rendered from the OpenAPI spec.
  • Errors — the canonical error envelope and how the SDK surfaces it.
  • Idempotency — safe retries on every POST.
tip

Never used the API before? Run sb demo --dry-run — it walks the whole create-wallet → fund → pay choreography against an in-memory stub, no key required. See the CLI guide.