BotEdge

Alert error guide

When an order fails, the email you receive explains in plain words what the exchange answered. Find that explanation below for the cause and the fix.

1. Insufficient funds

RejectedThe email says: “Insufficient funds”

Why: The free balance or margin is lower than the order needs. On futures the funds must be in the futures (or unified trading) account, not in spot; on spot, a sell needs the coin itself.

Fix Transfer funds to the account the connection trades, lower the order size, or check the leverage set on the exchange for that market.

2. API key rejected

RejectedThe email says: “API credentials rejected”

Why: The exchange does not accept the key: it was deleted or has expired, a value was pasted incompletely, the passphrase or memo is wrong, the key's IP restriction does not include our addresses, or a demo key is used on a Live connection (or the other way round).

Fix Create a new key and add the connection again with the matching Live or Demo setting. Some exchanges expire keys on their own: see your exchange guide.

3. The key cannot trade

RejectedThe email says: “API missing rights to trade”

Why: The key can read the account but not place orders, or trading is not enabled for the product (futures, margin) on the key or on the account.

Fix Edit the key on the exchange and enable the trading permissions listed in your exchange guide. Open the futures account first if you trade futures.

4. Ticker not recognized

RejectedThe email says: “Ticker not recognized”

Why: The ticker from the alert does not match a market on your exchange: the alert comes from a chart of another exchange, a futures chart is used with a spot connection (or the other way round), or the symbol has a typo.

Fix Create the alert from a chart of the same exchange and market type, or write the exchange's own symbol in the message, for example "ticker": "BTCUSDT".

5. Order size too small

RejectedThe email says: “Order size too small” or “Order size 0”

Why: The quantity is below the exchange's minimum order size or minimum order value, or it rounds down to zero because the market accepts fewer decimals than you sent.

Fix Raise the order size in your strategy. On futures check the contract size: some exchanges count contracts, not coins. If you send quantity_precision, make sure it does not round the size to 0.

6. Order size too big

RejectedThe email says: “Order size too big” or “Order size too large”

Why: The order is above the maximum quantity or value the exchange allows for one order, or above your position or risk limit for the market.

Fix Lower the order size, or raise the risk limit for the market on the exchange if it offers one.

7. No position to close

RejectedThe email says: “No position to exit from” or “Order size larger than position”

Why: A closing order (sent as reduce-only because of prev_position, or a closeall) found no position, or a smaller one: it was closed by hand, by a take-profit or stop-loss, or liquidated, so the account no longer matches the strategy.

Fix Bring the account back in line with the strategy (open or close the position by hand), and keep manual trades off markets a strategy is trading. If your strategy reverses from long to short in one order, see strategies that reverse.

8. Position mode mismatch

RejectedThe email says: “Hedge mode mismatch”

Why: The account's position mode on the exchange (one-way or hedge) is not the one the alert assumes: the alert sends "hedgemode": "hedge" to a one-way account, or a hedge-mode account gets alerts without it.

Fix Switch the market to one-way mode on the exchange, which suits most strategies, or keep hedge mode and add "hedgemode": "hedge" together with prev_position to the message.

9. Invalid alert message

RejectedThe email says: “Invalid request content”

Why: The message is missing pointer or ticker, the action is not buy or sell, the quantity is not a number (or more than one operation), or prev_position is not flat, long or short.

Fix Copy the alert message from your connection card again, or compare yours with the message fields. If the message is not valid JSON at all, no email can be sent: see the next section.

10. Short position not allowed

RejectedThe email says: “Short position not allowed”

Why: A sell was sent for something the account does not hold and cannot short: spot markets and some broker accounts only sell what you own.

Fix On spot, sell at most what you hold, or trade the market on a futures connection if you want to go short. On broker accounts, check that short selling is enabled for the instrument.

Nothing happened and no email arrived

BotEdge can only email you once it knows which connection an alert is for. Check, in this order:

  • The dashboard: is your subscription active, and is the connection enabled and not marked Not in plan or Over plan limit? Alerts for those connections are ignored without an email.
  • The pointer in the alert: after New pointer or after deleting a connection, the old pointer stops working. Copy the message again.
  • The message: if it is not valid JSON, the pointer cannot be read. Paste it into a JSON validator, or copy it again from the connection card.
  • TradingView: the alert's log shows whether it fired. Check that the alert has not expired, that Webhook URL is ticked with https://hooks.botedge.net, and that two-factor authentication is on.
  • Your notifications: error emails can be turned off per connection, and they may land in spam.

Other messages

  • “Market closed”: forex, CFD and stock markets only accept orders during trading hours.
  • “Opposing positions not allowed by exchange”: the broker account does not allow a long and a short on the same instrument at once. Close one side first.
  • “TP precision too high”: round the take-profit and stop-loss prices to the decimals the instrument uses.

The email says something else? Write to support@botedge.net with the time of the alert from the email.