Binance icon

Binance

Consume Binance API

Actions7

Overview

This node allows you to place spot market orders on the Binance cryptocurrency exchange directly from your n8n workflows. It is useful for automating trading strategies, executing buy or sell orders based on signals, or integrating Binance trading with other business processes. For example, you could automatically buy a cryptocurrency when a certain price threshold is met, or clear open orders as part of a portfolio rebalancing workflow.

Properties

Name Type Meaning
Side options Specifies the type of order: BUY, SELL, or CLEAR (to remove/cancel orders).
Symbol Name or ID options The trading pair symbol (e.g., BTCUSDT) to trade. Can be selected from a list or specified via expression.
Quantity number The amount of the asset to buy or sell. Not required if Side is CLEAR.
Price number The price at which to buy or sell. Not required if Side is CLEAR.

Output

The output will contain the result of the order operation in the json field. This typically includes details such as:

  • Order ID
  • Status (e.g., filled, pending)
  • Executed quantity
  • Symbol
  • Price
  • Side (BUY/SELL)
  • Any error messages if the order fails

If the operation is CLEAR, the output may include confirmation of canceled orders.

Dependencies

  • Binance API Key and Secret: You must configure valid Binance API credentials in n8n under the name binanceApi.
  • Network Access: The node requires internet access to communicate with the Binance API.

Troubleshooting

  • Invalid API Key/Secret: If your credentials are incorrect, you may receive authentication errors. Double-check your API key and secret.
  • Insufficient Balance: Attempting to buy or sell more than your available balance will result in an error from Binance.
  • Invalid Symbol: If the symbol is not recognized by Binance, the order will fail. Use the provided dropdown or verify the symbol string.
  • Order Parameter Errors: Missing or invalid values for required fields (like Quantity or Price for BUY/SELL) will cause validation errors.
  • Common Error Messages:
    • "API-key format invalid": Check your API credentials.
    • "Account has insufficient balance for requested action": Adjust your order size or deposit more funds.
    • "Invalid symbol": Ensure the symbol matches Binance's supported trading pairs.

Links and References

Discussion