Check pool balances and availability
For approved 0Pools partners, use partner-safe availability signals without exposing liquidity or treasury internals.
Pool availability tells an approved partner whether a pool-backed path can be used now. It is not a public reserve dashboard and should not expose liquidity sources, balances, treasury operations, or route diagnostics.
Availability is not a balance sheet
Show partner-safe availability and next actions. Do not publish real reserves, provider balances, funding instructions, internal thresholds, or operational runbooks.
Availability path
What to show
| Field category | Public-safe handling |
|---|---|
| Pool id or pair | Show only values returned for the entitled partner. |
| Availability | Use it to decide whether quoting is possible. |
| Tier and entitled pools | The balance view carries the partner's tier and allowedPools. Show only where approved for that partner. |
| Balance detail | The optional pre-funded balance is nullable; keep generic unless product explicitly approves a partner-specific view. |
| Unavailable reason | Use broad categories, not internal operational causes. |
Balance does not echo access or KYC state
GET /pools/:id/balance returns availability plus the partner's tier and allowedPools (and an optional, nullable pre-funded balance). It does not echo access or KYC status — those surface only as 403 denial codes on a call, not as a field here. Read GET /pools/:id/capabilities for supported networks, fees, and limits instead of inferring them from balance.
Server pattern
async function readPoolAvailability(input: { accountId: string; poolId: string }) {
const approval = await partnerApprovals.require('0pools_headless_liquidity');
if (!approval.allowed) return { view: 'use_0gate' };
const availability = await poolsClient.poolAvailability(input.poolId);
await poolAvailabilitySnapshots.record({
accountId: input.accountId,
poolId: input.poolId,
available: availability.available,
checkedAt: new Date().toISOString(),
});
return availability.available ? { view: 'can_quote' } : { view: 'pool_unavailable' };
}UI behavior
| Availability | UI behavior |
|---|---|
| Available | Allow the user or operator to request a quote. |
| Unavailable | Show a fallback, retry later, or route back to 0Gate if appropriate. |
| Unknown | Keep the quote button disabled and ask the backend to refresh. |
| Approval missing | Hide 0Pools and use the hosted 0Gate path. |
Guardrails
- Do not show reserve amounts, treasury balances, provider balances, or bank details.
- Do not expose internal switches, alert thresholds, or operational reason codes.
- Do not treat availability as a quote. Request a quote before showing executable terms.
- Do not cache availability so long that users see stale quote options.
Related pages
Discover entitled pools
Start from partner entitlement before checking a specific pool.
Lock a pool quote
Use availability to decide whether a quote can be requested.
Track pool trades
Reconcile execution after a pool-backed quote is used.
Use approved product surfaces
Keep approval-gated liquidity surfaces account-safe.