Invalid Order Book (b=) parameter: what the error means and how to fix it

Autoview · Guide · Updated October 5, 2026

You sent an alert, Autoview logged it, and instead of an order you got this line:

Invalid Order Book (b=) parameter. https://autoview.com/guides/command-reference/

It means the trade command had no side. Autoview needs to know whether to buy or sell, and that answer lives in the b= parameter. When b= is missing or empty, the exchange connector stops before it sends anything to the exchange. No order goes out, so there is nothing to undo. Searchers also type this as "command book parameter is invalid," and older connector code worded it "Book (b) parameter is required." Same problem, same fix.

When the error fires

Every exchange connector runs the same check at the start of its trade step: if the command has no b= value, it throws this error. That is the whole test. It does not look at what the value says, only whether there is one.

So you will see it when:

  • The command leaves out b= entirely, as in e=binance s=btcusdt q=100% t=market.
  • The command has b= with nothing after it. An empty value counts as missing.
  • A placeholder after b= resolved to nothing by the time the alert was sent.

Which values b= accepts

Autoview lowercases b= when it reads the command, so b=BUY and b=buy are the same thing. Then it sorts the value into a side:

  • buy or bid: the buy side.
  • sell or ask: the sell side.
  • long: the buy side, also marked as a margin trade.
  • short: the sell side, also marked as a margin trade.

On a spot account, use buy and sell. Save long and short for venues where your exchange guide tells you to use them.

The trap: a typo does not trigger this error

Slow down on this part. Because the check only asks whether b= has a value, a misspelled value gets past it. b=buyy is not empty, so you get no Invalid Order Book error. But Autoview also does not read it as a buy. On Binance spot, for example, the connector sends any order that is not marked as a buy as a sell.

So the error is the friendly case. A wrong value that slips through is the one that costs money. Test every new alert with d=1 first. That runs the command as a dry run and shows you in the log which side Autoview resolved, without placing an order.

How to fix it

  1. Add the side. Put b=buy or b=sell in the command: e=binance s=btcusdt b=buy q=100% t=market. The command reference lists every parameter.
  2. Check the spelling. Make sure the value is one of the six words above, with nothing extra around it.
  3. Match your venue. If your exchange guide uses long and short, use those. On a spot market, use buy and sell.
  4. Check what actually arrived. Open your log and read the command as Autoview received it. Reading your log shows where to find it on each surface. If b= is blank there, the problem is in the alert, not in Autoview.

If the side comes from a placeholder

Many people fill b= from their alert source instead of typing it. On TradingView, a strategy alert can write b={{strategy.order.action}}. TradingView documents that placeholder as returning "buy" or "sell" for the executed order (TradingView's variable guide, checked October 5, 2026). Autoview accepts both of those values.

The placeholder belongs to TradingView, not Autoview. Autoview only sees the text that lands after b=. If your log shows b= blank, or shows the raw placeholder text instead of buy or sell, fix it on the sending side. The Pine Script tutorial walks through building strategy alerts. A script or any other webhook sender writes the side its own way and only needs to send the plain word.

Invalid Symbol (s=) parameter is the same kind of check for the symbol. For the rest of the strings people hit most, see common error messages.

Open the command reference