Creating an API key#
Use a dedicated sub-account#
HookTrader assumes every position on the exchange was opened by HookTrader. It does not know about — and will not protect — positions you opened manually or with another bot in the same account.
The clean way to set this up:
- In your main Binance account, open Sub-account management and create a new sub-account labelled something like
hooktrader. - Transfer in only the capital you want HookTrader to manage. Treat the sub-account as ring-fenced.
- Don't trade manually or run other bots in that sub-account while a HookTrader strategy is active.
- Generate the API key from the sub-account, not from your main account.
Mixing manual positions with HookTrader-managed positions causes:
- Incorrect PnL on the dashboard.
- Confusing trail-SL moves (HookTrader sees a bigger position than it remembers and may resize stops you didn't expect).
- Orphan-position alerts that HookTrader can't reliably distinguish from real positions.
Generate the key#
On the sub-account:
- Open API Management and create a new API key labelled e.g.
hooktrader-live(or-demo). - Pick System-generated — Ed25519 keys are not currently supported.
- Set the required permissions per Permissions and IP whitelist. At minimum: Enable Reading and Enable Futures. Do not enable withdrawals.
- Copy the API key and the secret immediately. Binance only shows the secret once.
Save it in HookTrader#
On the Exchanges page, click + Add API key and fill:
| Field | Notes |
|---|---|
| Exchange | Binance. |
| Mode | demo for testnet, live for mainnet. |
| Label | Free-text — shown alongside the key everywhere it appears. |
| API key | From Binance. |
| API secret | From Binance. Stored encrypted; never returned after save. |
Saving triggers an automatic verify step — a test call to your Binance account. If the verify fails, the key is not saved.
You can hold both a demo and a live key on the same exchange. They appear as separate rows and bind to separate webhooks.