Security and data
Trade runs on your own cloud server: only you can sign in, your API keys are stored there encrypted and can be bound to its IP, and every install and update checks ZML’s signature first.
Trade runs on your own cloud server, which you sign in to and manage. ZML never holds your funds: orders and transfers are sent straight to the exchange by Trade on that server, using your own keys, and ZML’s servers take no part.
API keys can be bound to your server’s IP
API keys on centralized exchanges can carry an IP allowlist. Add this server’s egress IP to it and the key works only from this server, so it can’t be used from anywhere else even if it falls into someone else’s hands. On most exchanges the IP allowlist is optional and takes effect only once you fill it in. On-chain exchanges such as Hyperliquid and Lighter have no IP allowlist; see Connect an exchange for each exchange.
Your egress IPs are on the Egress IP tab under Accounts in Trade. When you add an account, the key guide lists them too; choose Copy all egress IPs to copy them in one go. If the server has several public IPs, add every one; see Use several public IPs (Alibaba Cloud ECS, AWS EC2).
Check it yourself: open the key on the exchange’s API management page and confirm its IP allowlist holds only your Trade server’s egress IPs.
Every install and update checks ZML’s signature first
The installer and every Trade update check the package’s signature with ZML’s public key first. If the signature doesn’t match, they stop: nothing is installed and the running version stays in place. The install script is public, and the public key used for the check is written in the script. You can update whenever a new version arrives; if you don’t, it installs automatically within 7 days, after the same signature check.
Check it yourself: open https://api.zmarketlab.com/install.sh in your browser to read every step the installer takes. Both the installer’s terminal output and Trade’s update progress include a Verify signature step.
Only you can sign in
Trade has a single administrator. You set the username and password the first time you open Trade, and they exist only on this server. ZML doesn’t create or keep them, and has no way to sign in to your server.
You can turn on two-factor authentication. It’s off by default; once on, every password sign-in also asks for the code from your authenticator. A forgotten password can only be reset by running a command on this server; there is no recovery link on the web page. See Forgot your password or lost your authenticator.
When the password or username changes, or two-factor authentication is turned off or moved to a new authenticator, Trade sends a Sign-in & security notification to the Telegram or Feishu channels your alerts use. If it wasn’t you, you know at once and can act. If your alerts only show in the web page, this notification isn’t sent.
Check it yourself: in Sign-in & security under Settings, Signed-in devices lists every browser that is signed in, and you can sign out any one of them; Sign-in activity records every sign-in.
Only one inbound port
Trade opens a single inbound port on the server, port 443, which you use to open Trade in your browser. Pairing, updates and reports are all connections Trade makes outward, so no other port is needed.
Check it yourself: on the server, run the command below. Trade’s only public listener is port 443; that line usually shows docker-proxy, which passes requests to Trade’s web server. The trading app (listed as trade) listens on port 8000 only on 127.0.0.1 and Docker’s internal address.
sudo ss -tlnpYour data stays on your server
Combos, trade history, settings and exchange keys are all stored in Trade’s data volumes on this server. When Trade can’t reach ZML’s servers, it keeps trading as usual, with no lockout and no deadline.
Check it yourself: on the server, run sudo docker volume ls; the volumes whose names start with zml-trade are Trade’s. They are what you pack up when you Move to a new server.
Exchange keys
The API key, secret key and passphrase you save in Trade are encrypted per account (AES-256-GCM) and stored as files in Trade’s data directory on your server. The master key that decrypts them is generated on this server the first time you save a key and kept in Trade’s data volume, so backups of the server contain it too.
Once saved, no Trade page or API returns the full API key; only part of it is shown, and the secret key and passphrase aren’t shown again. To change them, enter them again.
Your secret key is used only on this server to sign requests to the exchange and is never sent itself. The API key, and the passphrase where the exchange requires one, go only to that exchange with each request so it knows it’s you.
OKX Wallet connects without an API key. Trade keeps the sign-in you get by logging in to OKX Wallet, encrypted on your server in the same way. That sign-in can itself sign any transaction for the wallet; Trade signs only three kinds of transaction: swaps sent to OKX’s swap router contract, approvals to OKX’s approval contract, and approvals for listed tokens. It never signs a plain transfer.
Trade has no withdrawal feature
Trade has no withdrawal or deposit features. API keys for centralized exchanges don’t need withdrawal permission; don’t enable it when you create the key.
When you add an account or replace a key, you tick a confirmation before saving: you have checked what this credential can do and turned off every withdrawal or transfer-out permission that can be turned off. You set the credential’s permissions on the exchange or wallet side and are responsible for them.
On Binance, OKX, Bybit, Bitget, HTX, Kraken (spot keys) and Aster, Trade checks once, when you save, whether the key has withdrawal permission enabled. If it does, Trade warns you to turn it off on the exchange; you can also choose to save it anyway.
Trade can’t check withdrawal permission for API keys on other exchanges or for Bybit sub-account keys. No warning doesn’t mean the permission is off.
The check runs only this once, when a new key is saved. If you enable withdrawal permission on the exchange afterwards, Trade doesn’t warn you again.
On a centralized exchange, an API key without withdrawals can’t be used to withdraw, even in someone else’s hands. Transfers in Trade only move funds between accounts and wallets in your own name; enable the transfer permission only if you transfer in Trade.
On-chain exchanges and wallets
These connect with a private key or a wallet sign-in instead of an API key with permission switches, and what each can do differs:
Lighter, Robinhood Chain, Nado, Arcus, Extended: at most, the key you enter in Trade can withdraw funds back to your own wallet or account.
Hyperliquid: you connect with an API wallet, which can’t transfer or withdraw. A Hyperliquid or Nado main wallet private key can withdraw to any address, and Trade doesn’t accept it.
OKX Wallet: turn on the transfer allowlist in OKX before adding. A wallet can’t be added while the allowlist is off or while Trade can’t get its status from OKX. The allowlist cannot stop tokens from being moved out under an approval. Keep only the funds needed for trading in the wallet.
edgeX, ApeX, Backpack: there is no withdrawal switch to turn off, so keep only the funds you need for trading in the account.
Who Trade talks to
Trade starts every connection below itself, and every connection to ZML uses HTTPS.
| Who | When | What |
|---|---|---|
| Exchanges you connect | Always | Market data, account, order and transfer requests, signed on your server |
ZML update service api.zmarketlab.com | Always | Operating and error reports (see the next section); checks for and downloads updates, and checks ZML’s signature before installing; reads product announcements |
Z Market Lab zmarketlab.com | Once paired | Receives the opportunities you send and confirms it got them, with whether a combo was created and the reason if not |
Z Market Lab zmarketlab.com | Once paired, when you open a combo’s historical chart | Sends the exchange, market and trading pair of each side of the combo to fetch the chart; nothing about your exchange accounts, positions or trades |
Z Market Lab zmarketlab.com | Once paired, every minute while a Trade page is open | Reads the public delisting list to mark combo legs that are about to be delisted; the request doesn’t carry this Trade’s installation ID |
| Public IP lookup services (below the table) | When Trade looks up its egress IPs | Finds the public address of each egress IP on this server, to list the addresses for your IP allowlist; nothing else is sent |
| Public nodes of each chain | When you trade with OKX Wallet | Looks up the result of your on-chain transactions |
| Let’s Encrypt | When the server has a public IP | Requests and renews an HTTPS certificate for that IP, so your browser opens Trade without a certificate warning |
Docker (get.docker.com, Docker Hub) | On install and update | Installs Docker if the server doesn’t have it yet; downloads the official images for the database and the web server |
| Telegram, Feishu | Once you set up a notification channel | The alerts you set up, and Sign-in & security notifications |
The request for the delisting list is like opening a public web page. Until you pair, Trade doesn’t connect to Z Market Lab.
The public IP lookup services are api.ipify.org, api64.ipify.org, ifconfig.me, 1.1.1.1 and checkip.amazonaws.com.
On AWS EC2 and Alibaba Cloud ECS, Trade also asks the cloud provider, from inside the server, for the IPs you added to this server in the cloud console, and starts using them.
Check it yourself: run the command below to list every connection the trading app has right now, and check them against the table above. Update checks and downloads and certificate requests come from other containers and aren’t listed here.
sudo ss -tnp | grep '"trade"'What Trade sends to ZML
This data goes to ZML’s update service at api.zmarketlab.com, separately from the Z Market Lab connection used for pairing.
| When | What |
|---|---|
| First start | Records this Trade: a server identifier (unchanged when the same server is reinstalled), the installation ID, the host name and the app version |
| Every 5 minutes | Status, position and PnL totals, per-exchange summaries, and how fast pages respond; itemized below the table |
| Every hour | The record of your acceptance of the terms of service and risk disclosure (time and app version); the record of each confirmation you tick when adding or replacing a key, described below the table |
| When reading product announcements | Your interface language, so announcements come in that language; ZML records the most recent one |
| When something goes wrong | Warnings and errors the app logs, page errors, exchange error codes and messages, and the last part of the log before the trading app exits unexpectedly |
Sent every 5 minutes:
Status: app version and type, host name, whether the trading engine is running, whether maintenance is on, number of combos and how many are in each state, number of exchange connections and how many are healthy, number of accounts with errors or stale data, uptime, restart count, how long this start took, memory used by Trade, share of free disk space, the size of the Trade database and of its three largest tables (table names and byte counts only, read hourly), certificate expiry, whether the clock is in sync and by how much, update progress, and pairing status with Z Market Lab.
Positions and PnL: total long and short notional across all combos, today’s PnL and volume, today’s fees and rebates, and lifetime PnL. This report carries totals only: no single combo’s coin, parameters or PnL. Combo details sent with errors are described below.
Per-exchange summaries: your number of accounts on each exchange and the cumulative volume, fees and fee rebates there, recalculated every hour.
How fast pages respond: how long switching pages, opening windows, switching tabs and expanding a row’s details take in your browser, from click to fully displayed, totaled by browser type and device type (phone, tablet, computer). Only counts and milliseconds: no page addresses, and nothing shown on the page, such as combos, accounts or coins.
ZML records the server’s public IP from the incoming connection.
Each confirmation you tick when adding or replacing a key is recorded once: the time, the exchange, and whether you were adding or replacing. The record contains no keys and no account names.
When something goes wrong, the same error is grouped together, with a count, first and last time, and the first and last message. When an error involves a combo, the first report includes that combo’s current state, its last 20 events, last 10 orders and last 5 actions; when it involves an account, it identifies the account by the name you gave it in Trade.
Never sent: API keys, secret keys, passphrases, private keys and seed phrases, withdrawal addresses, your Trade sign-in password and sign-ins, and memory dumps.
Before sending, Trade replaces every key saved on this server with [***] wherever it appears, and on-chain wallet addresses keep only their first and last 4 characters. Two things aren’t replaced value by value: values shorter than 6 characters (such as an account number entered in a key field), and the log from just before the trading app exits unexpectedly, in which only parts carrying a key name or shaped like a private key or token are masked. ZML masks the data again when it arrives.
For the report sent every 5 minutes, ZML keeps only the latest one for each Trade, plus one set of daily totals per day, kept for two years. Records of terms acceptance and key confirmations are kept long term, and error records for 30 days.
Sending this data can’t be turned off; the terms of service you accept when you first open Trade state that Trade sends operating and usage data.
Three ways to make Trade safer
Turn on two-factor authentication: it’s off by default. Once it’s on, someone who has your password still can’t sign in; see How to turn on two-factor authentication, and what to do if you lose the authenticator.
Add your egress IPs to the exchange’s IP allowlist: it’s optional on most exchanges, and once filled in, the key works only from your server; see “API keys can be bound to your server’s IP” above.
Keep backups as safe as the keys: the encrypted keys and the master key that decrypts them are on the same data volume, so a copy of the server’s disk, a backup or the package you make when moving servers can decrypt every key.
If you think a key has leaked
Delete the API key on the exchange, create a new one, then enter the new key on the account in Trade.
ZML never asks for your API keys, and never asks you to run a command by email, direct message or notification. Don’t send keys, passwords or private keys when you contact us.