mirror of
https://github.com/NoFxAiOS/nofx.git
synced 2025-12-06 13:54:41 +08:00
- Mark Bybit, OKX as supported in CEX section - Mark Lighter as supported in Perp-DEX section - Add Bybit API setup guide - Add OKX API setup guide - Add Lighter agent wallet setup guide - Update all READMEs (EN, ZH-CN, JA, KO)
1.9 KiB
1.9 KiB
OKX API Setup Guide
This guide explains how to create and configure OKX API keys for use with NOFX.
Create API Key
- Log in to your OKX account
- Go to Account → API
- Click Create API Key
- Select Trade as the purpose
- Complete 2FA verification
- Name your API key (e.g., "NOFX Trading")
Configure API Permissions
Enable the following permissions:
- ✅ Read - Required
- ✅ Trade - Required for trading
- ❌ Withdraw - Keep disabled for security
Passphrase
OKX requires a passphrase in addition to API Key and Secret:
- Create a strong passphrase during API creation
- Save it securely - you'll need it for configuration
IP Whitelist (Recommended)
For enhanced security:
- Click Edit on your API key
- Enable IP Whitelist
- Add your server's IP address
- Save changes
Save Your Keys
After creation, you'll have:
- API Key:
xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx - Secret Key:
xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx - Passphrase: Your created passphrase
⚠️ Important: Save the Secret Key immediately - it's only shown once!
Configure in NOFX
Add your API credentials through the NOFX web interface:
- Open NOFX dashboard (http://localhost:3000)
- Go to Exchange Configuration
- Enable OKX
- Enter:
- API Key
- Secret Key
- Passphrase
- Save configuration
Troubleshooting
| Error | Solution |
|---|---|
Invalid API key |
Check if API key is correct |
Invalid signature |
Check if Secret key and Passphrase are correct |
IP not whitelisted |
Add your IP to whitelist or disable IP restriction |
Permission denied |
Enable Trade permission in API settings |
Security Best Practices
- Never share your API keys or passphrase
- Use IP whitelisting
- Don't enable withdrawal permissions
- Create separate API keys for different applications
- Regularly rotate your API keys