Treasury & Dashboard
Dashboard endpoints require a JWT Bearer token (Authorization: Bearer <token>).
Base URL: https://rach-caas-api-dx75yvdhaq-nw.a.run.app
Treasury Management
Get Tenant USDC Balance
Returns your business's current internal USDC balance held within the Rach treasury. This is the balance that gets debited when you call POST /v1/users/fund.
GET /v1/dashboard/treasury/tenant-balance
GET /v1/dashboard/treasury/tenant-balance
Authorization: Bearer <jwt>Response 200 OK
{
"available_usdc": "1250.000000",
"reserved_usdc": "50.000000",
"total_funded_usdc": "3000.000000",
"mmo_id": "tenant_abc"
}| Field | Description |
|---|---|
available_usdc | USDC immediately available for customer funding |
reserved_usdc | USDC locked in pending operations |
total_funded_usdc | Cumulative USDC pushed to customer SCWs |
Submit Treasury Topup
Notifies Rach that fiat has been deposited into the Rach settlement account (bank transfer or HUB2 settlement) and requests a USDC credit to your internal balance.
The topup is created with status PENDING and must be confirmed by a Rach operator or the automated confirmation endpoint before your balance is credited.
POST /v1/dashboard/treasury/topup
POST /v1/dashboard/treasury/topup
Authorization: Bearer <jwt>
Content-Type: application/json
{
"amount": "500.00",
"token": "USDC",
"reference": "HUB2_SETL_20240625_001",
"note": "Monthly treasury reload — Wave settlement batch"
}| Field | Type | Required | Description |
|---|---|---|---|
amount | string | ✅ | USDC amount requested |
token | string | ✅ | "USDC" or "USDT" |
reference | string | ✅ | HUB2 settlement ID, bank reference, or on-chain tx hash |
note | string | — | Optional memo |
Response 202 Accepted
{
"topup_id": "topup_xyz123",
"status": "PENDING",
"message": "Topup submitted. Awaiting Rach confirmation."
}Confirm Topup (Rach Operator / Internal)
Marks a pending topup as CONFIRMED and immediately credits the tenant's USDC balance. Called by Rach operators after verifying fiat receipt, or by the automated HUB2 reconciliation system.
POST /v1/dashboard/treasury/topup/{id}/confirm
POST /v1/dashboard/treasury/topup/topup_xyz123/confirm
Authorization: Bearer <jwt>
Content-Type: application/json
{
"credited_by": "ops-team@rach.finance"
}| Field | Type | Required | Description |
|---|---|---|---|
id | string (path) | ✅ | Topup ID |
credited_by | string (body) | — | Operator email or system label for audit trail |
List Treasury Topups
Returns the history of all USDC credit events for your tenant.
GET /v1/dashboard/treasury/topups
GET /v1/dashboard/treasury/topups
Authorization: Bearer <jwt>Get USDC Treasury Balance (On-Chain)
Queries the live on-chain USDC balance held by the Rach treasury wallet on Polygon.
GET /v1/dashboard/treasury/usdc
GET /v1/dashboard/treasury/usdc
Authorization: Bearer <jwt>Response 200 OK
{
"treasury_address": "0xRachTreasury...",
"usdc_balance": 15420.50,
"status": "OK"
}Get Live Paymaster Gas Tank
Queries the Polygon EntryPoint contract for the live native token balance (MATIC) backing your business's ERC-4337 paymaster. Monitor this to ensure customers never experience failed UserOps due to insufficient gas.
GET /v1/dashboard/treasury/paymaster
GET /v1/dashboard/treasury/paymaster
Authorization: Bearer <jwt>Response 200 OK
{
"paymaster_address": "0xPaymaster...",
"entrypoint_address": "0xEntrypoint...",
"current_balance_eth": 1.25,
"estimated_tx_runway": 4200,
"alert_threshold_eth": 0.5,
"critical_threshold_eth": 0.1,
"status": "HEALTHY"
}| Field | Description |
|---|---|
current_balance_eth | Current MATIC balance in the paymaster |
estimated_tx_runway | Estimated number of UserOps remaining before top-up needed |
status | HEALTHY, ALERT, or CRITICAL |
Set up alerts when
statustransitions toALERTorCRITICAL.
Dashboard — Overview
Get Dashboard Metrics
Fetches aggregated operational metrics for your tenant.
GET /v1/dashboard/metrics
GET /v1/dashboard/metrics
Authorization: Bearer <jwt>Response 200 OK
{
"total_active_wallets": 1247,
"total_processing_volume_crypto": 89420.55,
"successful_user_ops_24h": 342,
"failed_user_ops_24h": 3
}List Deposits
Returns paginated fiat-to-crypto deposits for your tenant.
GET /v1/dashboard/deposits?page=1&limit=20
| Parameter | Type | Description |
|---|---|---|
page | integer | Page number (default 1) |
limit | integer | Page size (default 20, max 100) |
Get Deposit Detail
GET /v1/dashboard/deposits/{id}
List Asynchronous Ledger (Transfers)
Retrieves paginated ERC-4337 transfers for your business.
GET /v1/dashboard/transfers?limit=50&offset=0
| Parameter | Type | Default | Description |
|---|---|---|---|
limit | integer | 50 | Number of records |
offset | integer | 0 | Records to skip |
Response — array of ExtendedTransactionInstance:
[
{
"id": "txn_abc123",
"masked_sender": "+225070****001",
"recipient_address": "0xRecipient...",
"status": "SETTLED",
"tx_hash": "0xPolygonTxHash...",
"created_at": "2026-06-25T12:00:00Z",
"settled_at": "2026-06-25T12:00:08Z",
"user_index": "blind_idx_abc",
"financials": {
"local_amount": 5500.00,
"local_currency": "XOF",
"stablecoin_settled": 9.81,
"crypto_ticker": "USDC",
"fx_quote_id": "fx_b3d8a1c2...",
"applied_bps_markup": 50
},
"erc4337_context": {
"user_op_hash": "0xUserOpHash...",
"nonce": 12,
"gas_paid_eth": "0.000021"
}
}
]Get Granular Transfer Details
Fetches forensic-level details for a single transfer.
GET /v1/dashboard/transfers/{id}
List SCW User Directory
Returns all provisioned customer wallet accounts for your tenant.
GET /v1/dashboard/users
Response — array of UserAccountResponse:
[
{
"user_index": "blind_abc123",
"wallet_address": "0xCustomer...",
"account_status": "ACTIVE",
"date_provisioned": "2026-01-10T08:00:00Z"
}
]Get User Detail
GET /v1/dashboard/users/{blind_index}
Response 200 OK
{
"blind_index": "blind_abc123",
"wallet_address": "0xCustomer...",
"account_status": "ACTIVE",
"date_provisioned": "2026-01-10T08:00:00Z",
"total_transfers": 47,
"total_volume": "844.50",
"daily_limit": "500.00",
"monthly_limit": "5000.00"
}Lookup User by Wallet Address (SCW Recovery)
Finds the user record associated with an SCW address. Useful for operators recovering a user account after a phone number change.
GET /v1/dashboard/users/lookup?wallet={address}
Withdrawals
List all withdrawals for your tenant:
GET /v1/dashboard/withdrawals?page=1&limit=20Get a single withdrawal:
GET /v1/dashboard/withdrawals/{id}List all withdrawals awaiting local fiat payout (super admin only):
GET /v1/dashboard/withdrawals/pending-payoutsConfirm local fiat payout sent (super admin only):
POST /v1/dashboard/withdrawals/{id}/confirm-payoutThe withdrawal must be in
CRYPTO_RECEIVEDstatus. Marks itCOMPLETED.
