balances(7): balances, locks and expiry
Deposits, withdrawals, the lock while an order is open, and what happens if the room is down.
Options
- deposit(asset, amount)
- USDG, WETH or the token of any listed market. Any time.
- depositETH()
- ETH, wrapped and credited as WETH.
- depositWithPermit(...)
- USDG with one signature.
- withdraw(asset, amount)
- your balance, unless an order of yours is open.
- withdrawETH(amount)
- WETH balance paid out as ETH.
- cancel(batchId)
- your order, before the cutoff. The slot stays, empty, and your lock lifts.
The lock
no order ──seal──> sealed ──cutoff──> closed ──settle──> free ^ │ │ └─────cancel───────┘ └──close + 30 min──> expired: free
While an address has an order in a batch that is neither settled nor expired, it cannot withdraw, and it cannot seal into a later batch. That way the balance the room sees at settlement is the balance at the close. Deposits stay open at all times.
If the room is down
No settlement happens, so each batch expires 30 minutes after its close and every balance is withdrawable. Funds never wait on the operator. The status block on the home page shows the room offline when its heartbeat is older than 60 seconds.
/ search · [ ] previous and next page