Symbol Management Configuration
MagicTradeBot provides flexible symbol management through two important configuration settings:
BaseCurrencySyncSymbolsOnStartup
Together, these settings control which trading pairs are loaded and how exchange symbol data is initialized and maintained.
1️⃣ BaseCurrency
BaseCurrency defines which quote currency pairs the bot will load from the exchange.
What It Does
Exchanges support hundreds or thousands of trading pairs. For example:
- BTC/USDT
- ETH/USDT
- SOL/USDT
- BTC/USDC
- ETH/BTC
- XRP/BUSD
When you set:
BaseCurrency = USDT
The bot will:
- Fetch exchange symbols
- Filter only trading pairs ending with USDT
- Ignore all other quote currencies
Loaded:
- ✔ BTC/USDT
- ✔ ETH/USDT
- ✔ SOL/USDT
Ignored:
- ✖ BTC/USDC
- ✖ ETH/BTC
- ✖ XRP/BUSD
If instead you set:
BaseCurrency = USDC
Then only USDC-based pairs will be loaded.
Why This Matters
- Ensures clean market scope
- Prevents accidental trading on the wrong quote currency
- Improves capital allocation control
- Maintains strategy consistency
2️⃣ SyncSymbolsOnStartup
SyncSymbolsOnStartup controls whether the bot automatically synchronizes exchange symbol metadata at startup.
What Happens When Enabled?
When:
SyncSymbolsOnStartup = true
The bot will:
- Fetch all supported trading symbols from the exchange.
- Initialize each symbol with critical trading parameters:
- Minimum Quantity
- Step Size
- Tick Size
- Price Precision
- Quantity Precision
- Store the processed symbols into:
symbols.json
These parameters are critical because exchanges reject orders that violate:
- Incorrect quantity precision
- Invalid price increments
- Minimum order size rules
Without proper initialization, order placement would fail.
🚀 First-Time Setup Recommendation
If you are running the bot for the first time:
SyncSymbolsOnStartup = true
Expected Behavior
- All filtered symbols (based on
BaseCurrency) will be fetched. - They will be initialized and saved into
symbols.json.
After this process completes:
- Stop the bot.
- Review the
symbols.jsonfile.
🎯 Running the Bot for Specific Pairs Only
If you want to trade only specific pairs, for example:
- BTC
- ETH
- SOL
- XRP
Step 1 – Edit symbols.json
Remove all unwanted symbols and leave only your preferred ones.
[
"BTCUSDT",
"ETHUSDT",
"SOLUSDT",
"XRPUSDT"
]
Step 2 – Disable Symbol Sync
Set:
SyncSymbolsOnStartup = false
Why This Is Important
If SyncSymbolsOnStartup remains true, the bot will:
- Re-fetch all symbols
- Overwrite your manual filtering
- Restore the full symbol list
By setting it to false, you effectively lock your symbol selection.
🧠 Summary
| Setting | Purpose |
|---|---|
BaseCurrency |
Filters which quote currency pairs are loaded |
SyncSymbolsOnStartup = true |
Fetches and initializes all exchange symbols |
SyncSymbolsOnStartup = false |
Prevents re-sync and preserves your custom symbol list |
🔧 Typical Workflow
First Run
BaseCurrency = USDT
SyncSymbolsOnStartup = true
Run → symbols.json created → Stop bot
Production Mode (Selected Pairs Only)
Edit symbols.json
SyncSymbolsOnStartup = false
Run bot with locked symbols.
Benefits of This Design
- Full automatic exchange synchronization
- Precision-safe order placement
- Manual control when needed
- Production-grade symbol locking