> ## Documentation Index
> Fetch the complete documentation index at: https://uncoded.ch/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Error Codes — Per-Venue Reference

> Common exchange error codes you'll encounter, what they mean, and how to fix them. Binance, Bybit, OKX, Kraken, Coinbase.

<Info>
  **Each exchange has its own error catalogue.** When the bot logs `error: -2015`, knowing what `-2015` means saves debugging time. This page is the operator's quick reference for the codes you'll most commonly encounter.
</Info>

## Binance error codes

<AccordionGroup>
  <Accordion title="-2015 — 'Invalid API-key, IP, or permissions'" icon="circle-exclamation">
    **Most common cause**: IP allowlist mismatch — your VPS's IP doesn't match the API key's allowlist at Binance.

    **Other causes**:

    * API key revoked at Binance.
    * API key permissions don't include spot trading.
    * Wrong API key/secret pasted.

    **Fix**:

    1. Verify VPS IP: `curl -s https://api.ipify.org`.
    2. Compare against Binance API key's allowlist.
    3. Update if different. Wait `30–60` seconds for propagation.
    4. Verify spot trading is enabled.
    5. If still failing, regenerate API key.
  </Accordion>

  <Accordion title="-1013 — 'Filter failure: MIN_NOTIONAL'" icon="weight-scale">
    The order's notional value (price × quantity) is below the symbol's minimum.

    **Cause**: per-split sizing too small. Most often: BasicMode (7 splits) at low capital produces splits below the `$10` floor.

    **Fix**: increase capital allocation, or switch to a fewer-split mode (LowMoney, MinimalMoney, Tsl2Sell).
  </Accordion>

  <Accordion title="-2010 — 'Account has insufficient balance'" icon="circle-exclamation">
    Account doesn't have enough quote asset to cover the order.

    **Causes**:

    * Capital was withdrawn while bot was running.
    * Another bot/manual trade consumed the same balance.
    * Mode's investment-per-buy higher than free quote.

    **Fix**: top up balance, adjust investment-per-buy, or close other positions.
  </Accordion>

  <Accordion title="-1021 — 'Timestamp for this request is outside of the recvWindow'" icon="clock">
    Clock drift between VPS and Binance servers exceeds `recvWindow` (`60000` ms default).

    **Fix**:

    * Verify NTP: `timedatectl status` should show synchronized.
    * If not, install/start NTP service.
    * Don't reduce `recvWindow` below `60000`.
  </Accordion>

  <Accordion title="-1003 — 'Too many requests'" icon="gauge">
    Rate limit hit. Binance: `50` orders / `10s` per IP, plus other request-type ceilings.

    **Fix**:

    * Bot auto-cools-down. Persistent hits indicate over-aggressive configuration.
    * Reduce active pair count or split across multiple TradingBot containers.
  </Accordion>

  <Accordion title="-1100 — 'Illegal characters found in a parameter'" icon="font">
    Invalid symbol format or other malformed parameter.

    **Fix**: verify symbol naming uses unhyphenated form (`BTCUSDT`, not `BTC-USDT`).
  </Accordion>

  <Accordion title="-2011 — 'Unknown order sent'" icon="circle-question">
    Order ID not recognized by Binance — usually a stale order ID after restart or partial fill.

    **Fix**: typically auto-resolves on next reconciliation. If persistent, restart TradingBot.
  </Accordion>

  <Accordion title="-1102 — 'A mandatory parameter was not sent'" icon="ban">
    API call missing a required field. Usually a TradingBot internal issue.

    **Fix**: capture the full request from logs and report to support.
  </Accordion>
</AccordionGroup>

## Bybit error codes

<AccordionGroup>
  <Accordion title="10003 — Auth invalid (equivalent to Binance -2015)" icon="circle-exclamation">
    Invalid API key, IP mismatch, or permissions issue.

    **Fix**:

    * Verify VPS IP matches Bybit allowlist.
    * Confirm spot trading permission enabled.
    * Wait `30–60` seconds for allowlist propagation after change.
  </Accordion>

  <Accordion title="10006 — Rate limit (equivalent to Binance -1003)" icon="gauge">
    Bot auto-cools-down. Persistent hits indicate too-aggressive configuration.
  </Accordion>

  <Accordion title="10001 — Invalid parameter" icon="ban">
    Malformed request. Usually a TradingBot internal issue or symbol format.
  </Accordion>

  <Accordion title="10002 — Invalid timestamp" icon="clock">
    Equivalent to Binance's clock-drift error. Check NTP sync.
  </Accordion>

  <Accordion title="10009 — Insufficient balance" icon="circle-exclamation">
    Same fix as Binance `-2010`.
  </Accordion>
</AccordionGroup>

## OKX error codes

<AccordionGroup>
  <Accordion title="50113 — 'Invalid API key, secret key, or passphrase'" icon="lock">
    Authentication failure on OKX. Most common: passphrase mistyped.

    **Fix**:

    1. Re-paste passphrase from password manager.
    2. Watch for trailing whitespace.
    3. If lost: revoke key at OKX, generate new with new passphrase.
  </Accordion>

  <Accordion title="50104 — IP whitelist mismatch" icon="circle-exclamation">
    OKX's equivalent of Binance `-2015`. Verify VPS IP on the API key's allowlist.
  </Accordion>

  <Accordion title="51008 — Insufficient balance" icon="circle-exclamation">
    Same fix as other venues.
  </Accordion>

  <Accordion title="50011 — Rate limit" icon="gauge">
    Bot auto-cools-down. OKX's published limit: `60` requests / `2` seconds.
  </Accordion>

  <Accordion title="50026 — Invalid parameter (often symbol format)" icon="font">
    OKX uses dash-separated symbols (`BTC-USDT`), not unhyphenated.

    **Fix**: in Dashboard, use OKX's native symbol format.
  </Accordion>
</AccordionGroup>

## Kraken error codes

<AccordionGroup>
  <Accordion title="EAPI:Invalid key" icon="circle-exclamation">
    Equivalent to Binance `-2015`. IP mismatch, wrong key, insufficient permissions.

    **Fix**:

    * Verify VPS IP matches Kraken allowlist.
    * Confirm Modify Orders + Cancel/Close Orders permissions enabled.
    * Wait `30–60` seconds for any recent allowlist change.
  </Accordion>

  <Accordion title="EGeneral:Invalid nonce" icon="clock">
    Nonce ordering issue. Kraken signs requests with incrementing nonce; mis-ordered or duplicate nonce fails.

    **Causes**:

    * Two processes sharing the same API key.
    * Clock drift on VPS.
    * Concurrent racing.

    **Fix**:

    * One API key per TradingBot.
    * Verify NTP.
    * If recurring without obvious cause, contact support.
  </Accordion>

  <Accordion title="EOrder:Insufficient funds" icon="circle-exclamation">
    Same as `-2010` on Binance. Top up or adjust investment.
  </Accordion>

  <Accordion title="EAPI:Rate limit exceeded" icon="gauge">
    Kraken uses rolling-window counter. Bot handles auto-cooldown. Persistent hits indicate over-aggressive config.
  </Accordion>

  <Accordion title="EQuery:Unknown asset pair" icon="font">
    Symbol not recognized. Kraken uses idiosyncratic naming for some assets:

    * `XBT` for Bitcoin (not `BTC`).
    * `XDG` for Dogecoin.
    * Some assets prefixed with `X`.

    **Fix**: use Kraken's native naming, or rely on the bot's normalization.
  </Accordion>
</AccordionGroup>

## Coinbase Advanced error codes

<AccordionGroup>
  <Accordion title="UNAUTHORIZED — Invalid signature or API key" icon="circle-exclamation">
    Authentication failure.

    **Causes**:

    * Whitespace in pasted secret.
    * Wrong portfolio binding.
    * Key permissions missing.

    **Fix**:

    * Re-paste secret carefully.
    * Verify portfolio matches intended account.
    * Confirm Trade permission enabled.
    * Wait `30–60` seconds for allowlist propagation.
  </Accordion>

  <Accordion title="INSUFFICIENT_FUND" icon="circle-exclamation">
    Equivalent to `-2010` on Binance.
  </Accordion>

  <Accordion title="RATE_LIMIT_EXCEEDED" icon="gauge">
    Bot handles cooldown automatically.
  </Accordion>

  <Accordion title="INVALID_PRODUCT_ID" icon="font">
    Symbol format issue. Coinbase uses dashes (`BTC-USD`, not `BTCUSD`).
  </Accordion>

  <Accordion title="ORDER_SIZE_TOO_SMALL" icon="weight-scale">
    Coinbase's equivalent of MIN\_NOTIONAL. Increase per-split sizing or switch modes.
  </Accordion>
</AccordionGroup>

## Universal patterns across venues

<AccordionGroup>
  <Accordion title="Authentication failures (`-2015` family)" icon="key">
    Across all venues, authentication failures usually mean one of:

    * IP allowlist mismatch.
    * Wrong key/secret pasted.
    * Insufficient permissions.
    * Key revoked at venue.

    Always: verify VPS IP, check permissions, retry after allowlist propagation, regenerate key if all else fails.
  </Accordion>

  <Accordion title="Rate-limit errors (`-1003` family)" icon="gauge">
    Bot auto-cools-down. Persistent hits → over-aggressive configuration. Reduce active pairs or split across multiple TradingBot containers.
  </Accordion>

  <Accordion title="Insufficient balance (`-2010` family)" icon="circle-exclamation">
    Capital issue. Top up, reduce per-buy investment, or close existing positions to free capital.
  </Accordion>

  <Accordion title="Min-notional rejections" icon="weight-scale">
    Per-split sizing too small. Switch to mode with fewer splits, or increase capital.
  </Accordion>

  <Accordion title="Symbol format errors" icon="font">
    Each venue has its own symbol convention:

    * Binance/Bybit/MEXC/Binance.US/Bybit EU: `BTCUSDT`.
    * OKX/KuCoin/BingX/Coinbase: `BTC-USDT`.
    * Gate.io/Poloniex: `BTC_USDT`.
    * HTX: `btcusdt` (lowercase).
    * Bitfinex: `tBTCUSD`.
    * Kraken: `XBTUSDT` for Bitcoin, etc.

    Verify symbol naming matches venue convention.
  </Accordion>

  <Accordion title="Timestamp / clock errors" icon="clock">
    All signed requests have timestamp validation. Clock drift on VPS triggers rejections.

    Universal fix: ensure NTP is running and synchronized.
  </Accordion>
</AccordionGroup>

## Best practices for error code investigation

<Tip>
  * ✅ **Read the full error message** — most errors have descriptive text alongside the code.
  * ✅ **Check Dashboard logs first** — every refusal includes the venue's response.
  * ✅ **Cross-reference this page** for the specific code.
  * ✅ **Try the simple cause first** — IP allowlist before deep investigation.
  * ✅ **Wait `30–60` seconds after allowlist changes** — propagation delays are real.
  * ✅ **Check NTP sync** for any timestamp-related error.
  * ✅ **One change at a time during fixing** — multiple simultaneous changes obscure root cause.
  * ✅ **Document the fix** in operator log — pattern recognition over time.
  * ✅ **Don't disable safeguards** to "fix" errors — IP allowlist, withdrawal-disabled, etc. exist for reasons.
  * ✅ **Escalate to support** for unrecognized error codes after self-investigation.
</Tip>

## What's next

<CardGroup cols={2}>
  <Card title="Common issues" icon="circle-exclamation" href="/troubleshooting/common-issues">
    The full common-issues catalog.
  </Card>

  <Card title="Connection problems" icon="wifi" href="/troubleshooting/connection-problems">
    Connectivity-focused troubleshooting.
  </Card>

  <Card title="Escalation" icon="forward" href="/troubleshooting/escalation">
    When self-help isn't enough.
  </Card>

  <Card title="API Key Security" icon="shield" href="/exchanges/api-key-security">
    The discipline that prevents many error codes.
  </Card>

  <Card title="Per-venue setup" icon="building-columns" href="/exchanges/overview">
    Setup walkthroughs for each venue.
  </Card>

  <Card title="Support" icon="life-ring" href="/operations/support">
    Direct help for unresolved issues.
  </Card>
</CardGroup>
