Skip to content

CLI ​

fiatless <command> [flags]

With no command, fiatless runs the server. fiatless version prints the release and the commit this binary was built from, as fiatless_build_info does.

Credentials come from API_AUTH_KEYS_JSON and nowhere else; changing or withdrawing one means editing that variable and recreating the api with the new environment. The API limits no request rate of its own: put any limit in front of it.

Operator actions (each records an audit_events row) ​

clear-halt ​

Return a halted canonical scanner to service.

FlagMeaning
-checkpoint <uuid>the halted chain_sync_checkpoints row
-operator <name>who is accountable for this change
-reason <text>why the halt is safe to clear

resolve-case ​

Close an outbound reconciliation case that automation escalated to a human. Only a case in operator_attention can be closed, and only with an audit row — the database refuses otherwise.

FlagMeaning
-case <uuid>the outbound_reconciliation_cases row
-outcome <name>resolved | cancelled
-code <text>the conclusion, e.g. confirmed_on_chain
-operator <name>who is accountable
-reason <text>what was checked, and what it showed

supersede-reorg-case ​

End an outbound reorg case whose transaction is not coming back, and lift the account freeze it holds. The payout keeps what it holds. The database refuses a settled payout's case, a transaction back on chain, and an EVM case whose nonce is not proven taken, except a settled payout's transaction back with the other outcome: that payout keeps what it settled. A settled Tron payout whose transaction can land no more (its window closed and the scanner read past it) ends failed (failed_by_operator): the reversal of its settlement stands and the merchant gets payout.failed. A sweep's or a gas top-up's case ends the same way, and no merchant hears of it.

FlagMeaning
-case <uuid>the outbound_canonical_reorg_cases row
-operator <name>who is accountable
-reason <text>what was checked, and what it showed

settle-payout ​

Rule what a payout's transaction did when the chain shows its transfer short or unclear: one whose settlement is refused, or a failed payout's that a reorg brought back. It then settles on its next cycle: delivered posts the principal and the fee, failed releases the principal and posts the fee. The database refuses a payout the chain settles by itself.

FlagMeaning
-withdrawal <uuid>the refused withdrawal
-as <outcome>delivered | failed
-operator <name>who is accountable
-reason <text>what the chain shows, and why it decides

fail-payout ​

Fail a queued payout that can never be paid: one its lane set aside, one a treasury incident's transaction already paid exactly, or one requested more than an hour ago. Its holds go back to the project and the merchant gets payout.failed with failed_by_operator. Refused while anything it signed can still land.

FlagMeaning
-withdrawal <uuid>the queued withdrawal
-operator <name>who is accountable
-reason <text>why it can never be paid

release-repeated-payout ​

Send a queued payout that a treasury incident's transaction pays exactly (its waiting_reason is set_aside): no lane claims it until this door or fail-payout, acknowledged incident or not. Check on chain first that the transaction paid something else; if it paid this payout, fail-payout fails it instead.

FlagMeaning
-withdrawal <uuid>the queued withdrawal
-operator <name>who is accountable
-reason <text>what the transaction paid, and how you checked

fail-spent-payout ​

Fail a Bitcoin payout, queued, broadcast or left signing by a claim whose lease lapsed, one of whose coins a confirmed transaction that is none of its versions spent, so none of them can land (bitcoin_signed_coins_spent_elsewhere). Check on chain first that the transaction did not pay this payout's destination. Both holds and its coins still reserved go back, its cases close, and the merchant gets payout.failed with coins_spent_elsewhere. Refused without such a transaction.

FlagMeaning
-withdrawal <uuid>the Bitcoin withdrawal
-spender-is-not-this-payoutyou checked that transaction did not pay it
-operator <name>who is accountable
-reason <text>what was checked, and what it showed

settle-spent-payout ​

Confirm a Bitcoin payout, queued, broadcast or left signing by a claim whose lease lapsed, on the confirmed transaction that is none of its versions, spent one of its coins and paid its destination the amount: a version altered in flight, or the payout made by hand. Check on chain first that it is this payout. The ledger counts that transaction's treasury movement once, so both holds go back instead of posting again; its coins no transaction spent go back, its cases close, and the merchant gets payout.confirmed. Refused without such a transaction.

FlagMeaning
-withdrawal <uuid>the Bitcoin withdrawal
-spender-is-this-payoutyou checked that transaction paid it
-operator <name>who is accountable
-reason <text>what was checked, and what it showed

fill-nonce-gap ​

Fill an empty treasury nonce below an EVM payout that waits on its own with a zero-value transfer to the treasury. The payout lane signs it once it reads the nonce still empty at the scanner's latest block, and sends it until the nonce is taken. Refused for a nonce the gateway ever signed, or one not below the payout's. A gap at a deposit address below a sweep is refused too: send that address's transaction at the nonce yourself.

FlagMeaning
-withdrawal <uuid>the payout waiting above the nonce
-nonce <n>the empty treasury nonce
-operator <name>who is accountable
-reason <text>what was checked, and what it showed

resolve-arrival ​

Decide money of an active asset that a customer address did not request (UnrequestedArrivalsOpen). accept credits it to the customer as a payment: the asset joins the address's asset_ids, each payment of it that unrequested_arrivals lists there, a dismissed one included, is posted and announced once, and sweeps take it; an asset whose deposits are off needs enable-asset-deposit first. dismiss credits nothing and leaves it there. Refused, changing nothing, once what is undecided there is not the payments you reviewed.

FlagMeaning
-incident <uuid>the unrequested_arrival_incidents row
-amount <amount>the incident's amount you reviewed
-review <hex>the incident's review you looked at
-as <decision>accept | dismiss
-operator <name>who is accountable
-reason <text>what was checked, and why

payment-arrivals ​

Show what one payment left undecided at customer addresses, per asset: the open incidents holding an undecided arrival of it, what is undecided at those addresses, any payment's, and the review resolve-payment-arrivals takes back.

FlagMeaning
-transaction <uuid>the payment's chain_transactions row

resolve-payment-arrivals ​

Decide every open incident payment-arrivals lists for one asset in one call, as resolve-arrival decides each: all of them or none. An incident that also holds another payment's arrivals (shared) decides those too. Refused, changing nothing, once what is undecided there is not what you reviewed, or wherever resolve-arrival would refuse; the refusal names the first customer refused.

FlagMeaning
-transaction <uuid>the payment's chain_transactions row
-asset <uuid>chain asset id
-incidents <n>the incidents you reviewed
-amount <amount>the amount you reviewed
-review <hex>the review you looked at
-as <decision>accept | dismiss
-operator <name>who is accountable
-reason <text>what was checked, and why

admit-asset ​

Publish an allowlist revision containing a token. The token is admitted INERT: decodable, but nothing may move it yet. It reads the contract through the network's configured node and refuses, listing nothing, when it cannot or when the contract reports other decimals.

FlagMeaning
-chain <uuid>blockchain id
-standard <name>evm_erc20 | tron_trc20 | solana_spl
-contract <address>contract address, or Solana mint
-token-program <id>Solana token program id
-decimals <n>the token's own decimals, as its contract reports them
-coin <code|uuid>the ledger coin it settles as
-operator <name>who is accountable
-reason <text>why this token is being listed

history ​

Show wallet history synchronization state per network, and the wallets whose history failed. A wallet that never reaches 'completed' is silently skipped by every consolidation query.

history-resume ​

Return a failed wallet to the history queue. The running chain module re-enqueues it at a fresh boundary and a new generation.

FlagMeaning
-wallet <uuid>a wallet id printed by history: a deposit wallet's, or a main wallet's
-operator <name>who is accountable
-reason <text>why the failure is safe to retry

approve-xrpl-issuer ​

State that this deployment will hold an XRPL issuer's paper. Required before any of that issuer's currencies can be admitted.

FlagMeaning
-chain <uuid>blockchain id
-issuer <address>the issuer's exact classic address
-requires-authorizationthe issuer sets the RequireAuth flag
-operator <name>who is accountable
-reason <text>why this issuer's paper may be held

enable-asset ​

Activate an admitted token and grant its capabilities.

FlagMeaning
-chain <uuid>blockchain id
-asset <uuid>chain asset id (printed by admit-asset)
-deposit -withdrawcapabilities to grant
-verified-by <text>how the token was verified
-operator <name>who is accountable
-reason <text>why it is safe to activate

enable-asset-deposit ​

Turn deposits on for an active asset whose deposits are off, such as a token enabled with -withdraw alone, so resolve-arrival can accept an arrival of it. enable-asset refuses an active asset.

FlagMeaning
-asset <uuid>chain asset id
-operator <name>who is accountable
-reason <text>why the asset may take deposits

enable-asset-withdraw ​

Turn payouts on for an active asset whose payouts are off, such as a token enabled with -deposit alone. enable-asset refuses an active asset.

FlagMeaning
-asset <uuid>chain asset id
-operator <name>who is accountable
-reason <text>why the asset may be paid out

bind-treasury ​

Bind a network's treasury, its seed's index-0 address, with your name and reason before the start that would bind it by itself, or check that the bound treasury is the address you expect. Binds nothing unless the address passes its checksum and is the one the seed in this environment derives. Every network, those added from the console included; the binding is immutable.

FlagMeaning
-chain <uuid>blockchain id
-address <address>the treasury your two offline tools derived
-operator <name>who is accountable
-reason <text>why this treasury is bound

set-sweep-policy ​

Sweep an active asset into the treasury: a deposit wallet that holds at least the minimum is swept, leaving the retained amount in it. A token needs its network's native asset swept first, because the native asset pays the token transfer's fee. The lane reads policies when it starts: recreate the api after this. Mainnet mounts no console door for it; this is the door there.

FlagMeaning
-asset <uuid>chain asset id
-minimum <amount>the least a wallet must hold to be swept
-retain <amount>what a sweep leaves in the wallet (0)
-operator <name>who is accountable
-reason <text>why this asset is swept

remove-sweep-policy ​

Stop sweeping an asset from the lane's next tick. Refused for a network's native asset while any of its tokens is swept.

FlagMeaning
-asset <uuid>chain asset id
-operator <name>who is accountable
-reason <text>why sweeping stops

reanchor ​

Move an EVM live scanner (Ethereum, BSC or a network added from the console) that waits on a block its node no longer keeps (evm_node_state_unavailable or evm_node_history_unavailable), or answers past the client's ceiling (evm_node_response_too_large), to a finalized block, skipping the blocks between. Refused unless the archive endpoint proves that nothing of this deployment moved in them: every tracked address has the same native balance, nonce and token balances at both ends, and no listed token's transfer touches one. Nothing in the skipped blocks is credited. Prefer a node that serves those blocks: the scanner then reads them all.

FlagMeaning
-chain <uuid>blockchain id
-anchor <block>a block the network's node has finalized; the newest, so it still keeps the next
-archive <url>an archive node of the network, not its configured node: state at any block, eth_getLogs over the gap; left out, from FIATLESS_ARCHIVE_URL or its _FILE, so a key in it stays out of the process list
-log-span <blocks>blocks per eth_getLogs call (1000)
-operator <name>who is accountable
-reason <text>why the gap may be skipped

evm-untraceable-pass ​

Let an EVM live scanner (Ethereum, BSC or a network added from the console) that waits on a block its node cannot trace (evm_node_trace_failed) read it without the block's trace. Each transaction is traced alone on the configured node; those named in -tx must fail their own trace and are read with no internal transfers, after the archive's replay of each shows what it paid tracked addresses. Refused unless every other transaction traces, and unless -uncredited names what the untraced ones paid this deployment, which is then not credited by the scanner. The scanner reads the block at its next cycle.

FlagMeaning
-chain <uuid>blockchain id
-blocks <n>a run: the block and the n-1 after it, each proven the same way (1, at most 16)
-tx <hash,...>the transactions whose own trace fails; none when each traces alone
-archive <url>an archive node of the network, not its configured node, that answers debug_traceTransaction with prestateTracer; left out, from FIATLESS_ARCHIVE_URL or its _FILE
-uncredited <wei>what a refusal named them paying tracked addresses, left uncredited
-operator <name>who is accountable
-reason <text>why the block may be passed

tron-unreadable-check ​

Check, before you pass it with TRON_CANONICAL_PASS_UNREADABLE, that a transaction the Tron scanner cannot read (tron_contract_unreadable) names no address this deployment tracks. It reads the transaction, its execution and its block's balance trace from a java-tron node's HTTP API, finds every address there, Base58 or hex (topics, ABI data, 41-prefixed values), and prints them. Refused, naming why, when one is tracked or the node lacks an answer: mainnet TronGrid keeps no balance trace. The network's configured node (TRON_NODE_ADDRESS) must record the transaction alike, with the same contract in the same block, or the pass is refused too. Read-only: it records nothing.

FlagMeaning
-tx <id>the transaction the scanner names
-block <hash>the block the scanner names
-node <url>a java-tron HTTP API of this network whose storage.balance.history.lookup was true when it processed the block; https on mainnet unless the address is private and the URL has no query; left out, from FIATLESS_TRON_TRACE_NODE_URL or its _FILE

solana-unreadable-check ​

Check, before you pass it with SOLANA_CANONICAL_PASS_UNREADABLE, that a transaction the Solana scanner cannot read (solana_transaction_unreadable) names no address this deployment tracks. It asks the network's configured node (SOLANA_NODE_URL) for the transaction in jsonParsed and for its finalized block, and compares every account key, every token balance's owner and any address anywhere in the answer with the tracked addresses. Refused, naming why, when one is tracked, when an account or owner is no address, or when the block is not the one named. Read-only: it records nothing.

FlagMeaning
-chain <uuid>the checkpoint's blockchain id
-tx <signature>the transaction the scanner names
-block <hash>the block the scanner names

reverse-gap-credit ​

Reverse an operator's deposit gap credit that a decoder later recorded again, when the ledger counts exactly that credit more than the chain holds at the address (LedgerAboveChain). A credit naming the transaction is reversed by itself as the transaction posts; this is for one that named none, or another. Refused, reversing nothing, unless the alarm is open, its reading settled and unchanged, its amount the credit's, no spend at the address names no wallet, and the asset's ledger account is active.

FlagMeaning
-incident <uuid>the open ledger_above_chain incident
-credit <uuid>the credited deposit gap it counts again
-amount <amount>what the alarm counts above the chain
-operator <name>who is accountable
-reason <text>what was checked, and what it showed

Recovery after a point-in-time restore ​

A restore forgets the payouts sent and the deposit addresses handed out after its point; the chain does not.

recovery-begin ​

Declare a restore before the api serves: payouts, sweeps and new deposit addresses wait until recovery-accept. The api opens one by itself when the database's cluster changed; an earlier point than an open recovery reaches back to widens it.

FlagMeaning
-recovery-point <time>the point restored to, RFC 3339
-operator <name>who is accountable
-reason <text>which restore, and why

recovery-status ​

Show the open recovery: the treasury transfers the restored database did not know, the payouts it would send again, the deposit index floors, and what keeps it open.

recovery-match-payout ​

Settle a restored queued payout on the transfer that paid it after the point: it holds, posts and confirms as its lane would have, and is never sent again. Every network; refused unless the transfer pays its asset, amount and destination from the treasury and moved from it exactly that, its fee and any rent (on Bitcoin, spending the treasury's coins alone).

FlagMeaning
-withdrawal <uuid>the restored queued payout
-tx <hash>the transfer that paid it
-operator <name>who is accountable
-reason <text>what you checked

recovery-record-outflow ​

Record a transfer the restored database did not know that paid no restored payout (a payout requested after the point, a gas top-up, a send by hand) as a treasury incident.

FlagMeaning
-chain <uuid>blockchain id
-tx <hash>the transfer
-pays-no-restored-payoutyou checked it paid none of the restored payouts it pays exactly
-operator <name>who is accountable
-reason <text>what it was

recovery-index-floor ​

Hand out the network's next deposit address above this index, so no address issued after the point is issued again.

FlagMeaning
-chain <uuid>blockchain id
-index <n>the highest index handed out before the failure: the old database, the logs' "deposit address issued" lines, or your merchants' records
-operator <name>who is accountable
-reason <text>where the number comes from

recovery-accept ​

Close the recovery once every scanner has read the blocks of the first 5 minutes after it opened (and on Solana 183 blocks, on XRPL 21 ledgers, made after them), every unknown transfer is decided, every network has a floor, and the EVM payout lane has checked the treasury nonce of each EVM network with a payout not yet sent, and sees no treasury transaction pending that has not landed, and each EVM treasury's stated nonce is below one this database signed or a confirmed block shows taken.

FlagMeaning
-old-evm-nonce <network id>=<n>the highest nonce the network's treasury used on the old instance or an explorer, or none if it never sent; once per EVM network with a treasury
-operator <name>who is accountable
-reason <text>what you checked

Holding payout sends for a planned backup or a drill ​

hold-payout-sends ​

No lane claims a payout until release-payout-sends, while payout requests still queue (a payout lane switched off closes the request door too). A payout already claimed finishes its send. Sweeps and gas top-ups wait too; Bitcoin's consolidation, which spends deposit coins alone, does not.

FlagMeaning
-operator <name>who is accountable
-reason <text>which backup or drill

release-payout-sends ​

End the hold: each lane claims the queued payouts on its next tick.

FlagMeaning
-operator <name>who is accountable
-reason <text>why the hold ends

The schema, as the schema owner ​

the deploy's migrate job runs this.

migrate ​

Apply each migration the database lacks, then each function, view and trigger definition whose file changed or whose object is gone, and drop a definition no longer shipped. One run at a time: a second waits for the first. A migration that fails stays dirty, and every later run refuses until force records the version the database is at. A schema newer than this binary is left as it is. After the flags: up (the default), down <n> or down -all (proofs and development; production moves forward), force <version>, or version.

FlagMeaning
-database <url>the schema owner's PostgreSQL URL; keep its password in a passfile
-path <dir>a migrations directory to apply in place of the one this binary was built with