Table of Contents

Tradebot — Broker model

For a side-by-side comparison of the broker and custodian models, see Tradebot overview.

Trading philosophy

The broker model enables customers to buy and sell crypto through on-chain transactions from and to their own private wallet.

The aim is to minimise crypto price-risk exposure. To achieve this, a hot wallet reserve is maintained to serve customers with instant crypto buy transactions. The target value to hold in this reserve should match the maximum volume of the customers' net buy transactions, also taking into account the time needed to restore the reserve either from a crypto exchange or other external sources (typically between 30 and 60 minutes).

It is possible to allow a customer to create a buy transaction larger than the reserve in the hot wallet, if the payment methods are set up to do so. In this case, the buy amount will first be sourced on the exchange and then sent to the hot wallet, before it finally reaches the customer. This workflow should take up to one hour or more, and therefore delay the delivery to the final customer compared to the near-instant experience with normal transaction amounts. However, the price will be fixed at the value it had when the crypto is sourced on the exchange.

A deviation range called wobble can be set around the target value to prevent excessive trading and unnecessary spread losses when customers buy and sell in the same period. Both target and wobble are defined in the configured client base currency to adapt automatically to changes in crypto price.

Trading rules

  • Keep the amount of crypto on the exchange reserve near to zero. If the hot wallet reserve is below the target, allow a limited crypto amount on the exchange which is lower than the maximum trading amount.
  • Keep the total value (confirmed and unconfirmed) in the hot wallet between lower and upper target boundaries, including the pending withdraw actions on the exchange.
  • Avoid sending crypto to the exchange either when the confirmed hot wallet reserve is below the specified balance alert level (even when the unconfirmed amount is above target) or when the exchange is not responsive.

Note: Check cash reserves on the exchange daily. If they exceed operational limits, deposit or withdraw amounts via bank transfer.

Typical reserve targets

These are generic recommendations and should be tailored to your business needs.

  • Hot wallet reserve: the target should be at least equal to the max amount of expected net buy transactions of customers in 1 hour that require instant delivery. However, it should also be as low as the business processes allow depending on the acceptable price-risk of an open crypto position (and the limits reported in the Nexus agreement).
  • Wobble amount: it should match the typical net expected crypto buy/sell value in 30–60 minutes.
  • Min/max trade value: the maximum value should at least be equal to the wobble value.
  • Min/max transfer value: the minimum transfer value should be smaller than the wobble one, but large enough to limit the relative size of the fixed costs of the blockchain transaction.

Setup

To configure the Tradebot for each crypto:

  1. Navigate to Traderoom > Tradebot settings
  2. You will see a list of all supported crypto-currencies
  3. Click the edit icon next to each crypto to configure its parameters
  4. Set the values described in the Settings reference section below

For UI screenshots, see Tradebot overview.

Tip: Configure one crypto fully before moving to the next. Start with conservative values (higher wobble, lower trading limits), then optimize for your trading patterns.

Settings reference

Configure the following parameters for each crypto-currency:

Note: Fiat values use the client's configured base currency. EUR is an example only.

Setting Description
Exchange/currency tradepair The exchange and fiat currency (typically the client's base currency) that the Tradebot uses for this crypto.
Balance target value The target amount in the client's base currency you aim to hold in your hot wallet. This is typically equal to the expected aggregate buy transaction value in one day. This value represents your open market position and is exposed to price fluctuation risk.
Balance wobble value The acceptable deviation range around the target (for example, `+/-10` around a `100` target in base currency). This allows buy and sell transactions to offset internally without triggering exchange trades, helping you monetize the spread. The Tradebot only trades on the exchange when balances exceed the wobble boundaries.
Min/max trading value The minimum and maximum amounts in the client's base currency per exchange order. The minimum should match your exchange's minimum order size.
Min/max transfer value The minimum and maximum amounts in the client's base currency per transfer between hot wallet and exchange. Use this to optimize blockchain fees.

Automated behavior

The Tradebot executes up to four automated actions (in sequence) to keep your reserves balanced. This section explains when and how each action triggers.

Definitions

Before reading the action descriptions, familiarize yourself with these terms:

  • Balance target value (base currency)Balance target crypto value: the target amount converted to crypto units based on current price
  • Wobble value (base currency)Wobble crypto value: the wobble amount converted to crypto units
  • Min/max trading values (base currency)Min/max trading crypto values: converted to crypto units
  • Min/max transfer values (base currency)Min/max transfer crypto values: converted to crypto units
  • Confirmed hot wallet balance: the administrative balance of the hot wallet (without unconfirmed transactions)
  • Total hot wallet balance: the administrative balance plus incoming unconfirmed sells and transfers
  • Confirmed hot wallet reserve: the measured/confirmed reserve visible in the Traderoom
  • Delayed crypto: the amount of crypto already subtracted from the administrative balance (sold to a customer) but not yet transferred from the hot wallet
  • Total exchange reserve: available + locked crypto on the exchange
  • Available exchange reserve: the immediately available crypto on the exchange

Note: If wobble is lower than minimum trading value, Tradebot automatically uses minimum trading value.

Action 1: Hot wallet balance is too high

TRANSFER from hot wallet to exchange

Condition: The total hot wallet balance exceeds target + wobble AND the confirmed balance is at or above target AND the confirmed balance minus delayed crypto is above a safety threshold.

Action: Transfer excess crypto from the hot wallet to the exchange.

Calculation:

  1. Start with: total balance - target value
  2. If this would drop confirmed balance below the safety threshold, reduce the transfer to protect the minimum balance
  3. Cap at the max transfer value
  4. Only execute if >= min transfer value

Action 2: Hot wallet balance is too low

TRANSFER from exchange to hot wallet

Condition: The total hot wallet balance falls below target - wobble OR the confirmed balance minus delayed crypto is below a safety threshold.

Action: Transfer crypto from the exchange to the hot wallet to restore reserves.

Calculation:

  1. Start with: target value - total balance
  2. Adjust if delayed crypto would impact the balance significantly
  3. Cap at the max transfer value
  4. Only execute if >= min transfer value

Action 3: Total reserves are too high

SELL exchange order

Condition: The sum of total hot wallet balance + total exchange reserve exceeds target + wobble AND the confirmed balance minus delayed crypto is above a safety threshold.

Action: Sell crypto on the exchange to reduce total reserves.

Calculation:

  1. Start with: hot wallet + exchange - target value
  2. Cap at the available exchange reserve
  3. Cap at the max trade value
  4. Only execute if >= min trade value

Action 4: Total reserves are too low

BUY exchange order

Condition: The sum of total hot wallet balance + total exchange reserve falls below target - wobble.

Action: Buy crypto on the exchange to replenish total reserves.

Calculation:

  1. Start with: target value - (hot wallet + exchange)
  2. Cap at 99% of available exchange fiat (reserve 1% for fees)
  3. Cap at the max trade value
  4. Only execute if >= min trade value

Troubleshooting

Possible reasons why the Tradebot is not executing actions

The Tradebot pauses automated actions if any of these conditions are detected:

Configuration or state issues:

  • Tradebot is not set to active for this crypto
  • Bad parameters: Max trading value = 0, or max < min
  • Bad parameters: Max transfer value = 0, or max < min

Recent activity:

  • There are still open active orders or pending withdrawals in Nexus
  • The previous exchange order finished less than 1 minute ago (cooldown period)
  • There are missing deposits: crypto withdrawn from the exchange but not yet deposited in the hot wallet

Price or data issues:

  • Exchange price is unknown or zero
  • Internal price is unknown or zero
  • Exchange price and internal price differ by more than 25%

Wallet inconsistencies (indicates a data sync issue):

  • Confirmed reserve, confirmed balance, total balance, or delayed crypto amount is negative
  • Total administrative balance is less than confirmed balance
  • Confirmed reserve is less than 99% of the confirmed balance
  • Exchange reserve or exchange currency reserve is negative or out of date