With the launch of the Signal Bot, TradingView users and signal providers can now publish and configure Signal Bots using their TradingView signals. Follow this step-by-step guide to start trading with signals on OKX.
Step 1: Access the Signal Bot
- Log in to your OKX account.
- Navigate to Trade → Trading Bot → Marketplace.
- Select the Signal Bot sub-tab and click Create.
Step 2: Create Your Signal
- Click Add Custom Signal to create a customized signal.
- Name your signal and add an optional description (up to 500 characters).
- Click Create Signal to proceed.
Quick Overview: Pine Script™ "Strategy" vs. "Indicator"
- TradingView Strategy: Uses
strategy.*()functions to simulate trades. Ideal for backtesting and live market testing. - TradingView Indicator: Focuses on calculations without trade simulation. Faster execution but not designed for backtesting.
Step 3: Configure TradingView Alerts
Method A: For Strategy Script Users (strategy.*())
- Configure Script: Save and add your strategy script to the chart.
Set Alert:
- Under Alert Condition, select "Order Execution Only".
- Paste the OKX AlertMsg template into the Message field.
- Add the OKX-generated Webhook URL under Notifications.
- Test: Ensure alerts trigger correctly.
Method B: For Indicator/Custom Script Users
- Configure Script: Save and add your indicator script to the chart.
Set Alert:
- Define a custom condition (e.g., MACD Golden Cross).
- Use one of OKX’s four predefined messages (
ENTER_LONG,EXIT_LONG,ENTER_SHORT,EXIT_SHORT). - Add the Webhook URL.
- Test: Verify alerts match your trading logic.
👉 Optimize your TradingView alerts for OKX
Step 4: Create Your Signal Bot
- Click Create Bot after setting up your signal.
Configure basics:
- Trading Pairs: Select relevant perpetual swaps.
- Leverage: Set your risk tolerance (e.g., 10x).
- Investment: Allocate funds (USDT or % of balance).
Advanced settings (optional):
- Order Type: Market or Limit.
- Take Profit/Stop Loss: Define exit strategies.
- Confirm and activate the bot.
Step 5: Monitor and Manage Your Bot
- Real-Time Tracking: View active positions and order history.
- Manual Adjustments: Add/remove margin or close positions manually.
- Stop the Bot: Halts all trading activity and returns remaining funds.
FAQ Section
Q1: Can I use free TradingView accounts for OKX Signal Bots?
A: No, a paid TradingView plan is required to access Webhook alerts.
Q2: How do I align TradingView’s "contract size" with OKX?
A: Adjust investmentType to "base" and set amount to {{strategy.order.contracts}} in your AlertMsg.
Q3: What if my third-party program uses fixed IPs?
A: Contact OKX support to whitelist your IP for external signal integration.
Q4: How do I troubleshoot failed signals?
A: Check the alert logs in TradingView and ensure your Webhook URL matches OKX’s provided link.
👉 Explore advanced Signal Bot strategies
Appendix: Sample Scripts & Templates
- Beginner RSI Strategy: TradingView Script Link