Financial OS
The Financial OS combines treasury banking, capital financing, card issuing, and autonomous AI agent wallets on a double-entry ledger. These endpoints cover ledger-backed wallets, credit lines, virtual cards, and programmable agent wallets.
All Financial OS endpoints require a valid JWT or API key. Treasury and agent wallets are owned by the authenticated user.
Endpoints
/walletsCreate a ledger-backed treasury wallet/wallets/meGet the authenticated user's treasury wallet/wallets/:idGet a treasury wallet/wallets/:id/ledgerGet double-entry ledger history/merchants/:merchantId/capital/credit-linesCreate a credit line/merchants/:merchantId/capital/credit-linesList credit lines/wallets/:walletId/cardsIssue a virtual card/wallets/:walletId/cardsList virtual cards/agents/walletsCreate an AI agent wallet/agents/wallets/:agentWalletId/spendExecute an agent spend/agents/wallets/:agentWalletId/historyGet agent spending historyThe Financial OS treasury wallet routes (/wallets, /wallets/me, /wallets/:id) share path
prefixes with the blockchain Wallets module. The treasury wallet here is ledger-backed
and currency-denominated (fiat + stablecoin), distinct from the on-chain blockchain wallet.
Treasury Wallets
/walletsCreate a treasury wallet| Field | Type | Required | Description |
|---|---|---|---|
currency | string | No | Settlement currency. Defaults to USD. |
Creates a user-owned, ledger-backed treasury wallet for the authenticated user.
Ledger History
/wallets/:id/ledgerGet double-entry ledger historyReturns the wallet's double-entry ledger entries (debits and credits), most recent first.
Capital — Credit Lines
/merchants/:merchantId/capital/credit-linesCreate a credit line/merchants/:merchantId/capital/credit-linesList credit lines| Field | Type | Required | Description |
|---|---|---|---|
amount | number | Yes | Credit line principal in cents |
interestRate | number | Yes | Annualized interest rate as a decimal (e.g. 0.12 for 12%) |
Issuing — Virtual Cards
/wallets/:walletId/cardsIssue a virtual card/wallets/:walletId/cardsList virtual cards| Field | Type | Required | Description |
|---|---|---|---|
cardName | string | Yes | Human-readable card label |
spendingLimit | number | Yes | Spending limit in cents |
Cards are issued against the given treasury wallet and owned by the authenticated user.
AI Agent Wallets
Programmable wallets for autonomous agents with policy-based spending controls.
/agents/walletsCreate an AI agent wallet| Field | Type | Required | Description |
|---|---|---|---|
agentId | string | Yes | The agent the wallet belongs to |
dailyLimit | number | No | Max spend per day in cents |
maxTransaction | number | No | Max single transaction in cents |
allowedCategories | string[] | No | Permitted spend categories |
Execute a Spend
/agents/wallets/:agentWalletId/spendExecute an agent spend| Field | Type | Required | Description |
|---|---|---|---|
amount | number | Yes | Spend amount in cents |
currency | string | Yes | Settlement currency |
rail | string | Yes | Payment rail (e.g. card, stablecoin, x402) |
description | string | No | Description recorded with the spend |
Spends are checked against the wallet's policy (dailyLimit, maxTransaction, allowedCategories)
before execution. Spends exceeding limits are rejected.
Spending History
/agents/wallets/:agentWalletId/historyGet agent spending historyReturns the agent wallet's spend history, most recent first.