A Utila service-account JWT for vaultId, cached until shortly before it
expires.
The cache is not an optimisation detail: every call site mints a token per
request, and under KMS that would be a kms:Sign network round trip on
every Utila API call. It is keyed by vault because the identity is — two
vaults mean two subs and therefore two tokens.
Asset balances held by a wallet, or by every wallet in the vault.
Pass walletId: "-" to query the whole vault in ONE call. Each returned
balance carries its own wallet resource name, so the rows can be grouped
back onto wallets client-side — which is what makes balances affordable on
a list page instead of an N+1 per row.
The wallet and asset fields come back as resource names
(vaults/{v}/wallets/{w}, assets/native.ethereum-mainnet); both are
split to their trailing id here so callers never parse Utila's path format.
value is the decimal amount and frozenValue the portion that cannot be
moved — they are SEPARATE figures, not a total and a subset to subtract.
Both are returned verbatim as strings: these are token amounts at chain
precision, and rounding them through a JS number loses digits.
Note there is no fiat conversion in this (default BASIC) response, so a
multi-asset wallet has no single "balance" to total.
OptionalpageSize?: numberOptionalpageToken?: stringA wallet id, or "-" for every wallet in the vault.
Un-archive a wallet — the inverse of archive, needed because restoring a soft-deleted deposit wallet has to put the custody side back too. A restored row whose Utila wallet stayed archived would be live in CFX and hidden in the vault.
Archive a wallet — the only mutation Utila exposes on an existing wallet. There is no rename or delete:
/v2/vaults/{vault_id}/wallets/{wallet_id}is GET-only, so archiving is how a retired generation is marked as retired on the custody side rather than by a display-name convention.Archived wallets drop out of
listWalletsunlessshowArchivedis set, which is what keeps a retired wallet from being offered up for re-linking.allowMissingmakes the call idempotent: re-archiving an already-gone wallet succeeds instead of raising, so a retried rotation doesn't wedge on a step that already ran.