Navigation

Troubleshooting

API Connection Errors

Diagnose and fix exchange API errors including authentication failures, IP restrictions, permission issues, rate limits, and connection timeouts.

TradingForge connects to your exchange via the exchange's REST API. When something goes wrong with this connection, an error is logged in the Activity log and (if configured) an alert notification is sent. This article covers every common API error and how to resolve it.

API errors appear in the TradingForge Activity log (accessible from the dashboard) and in the console window. If you receive an error notification, the full error message will be in the Activity log.

Invalid API Key / Authentication Failed

Error message
Invalid API key
Authentication failed
API-key format invalid

Cause

The API key or secret entered in TradingForge does not match what the exchange has on record. This is usually caused by a typo, a copy-paste error (extra space or missing character), or a key that was deleted or regenerated on the exchange.

Fix

1

Delete the existing credentials in TradingForge

Go to Settings → Exchange. Clear both the API Key and Secret fields completely.
2

Re-copy the API key and secret from the exchange

Log in to your exchange, navigate to API Management, and copy the key and secret fresh. If the secret is no longer visible (many exchanges only show it once), generate a new key pair.
3

Paste without extra spaces and save

Paste each value carefully. Many copy operations accidentally include a trailing space. Save and test the connection.

IP Restricted / Access Denied — IP Not Whitelisted

Error message
Restricted location
Access denied, IP not in whitelist
This IP is not allowed

Cause

When you created the API key on the exchange, you specified one or more allowed IP addresses. Your current internet IP address is different from the whitelisted IP — this commonly happens if your ISP assigns a dynamic IP that changes periodically.

Fix

  • Log in to your exchange, navigate to API Management, and edit the API key. Update the IP whitelist to include your current public IP address (search "what is my IP" in a browser to find it).
  • Alternatively, remove the IP restriction entirely from the key settings. This is less secure but eliminates the issue if your IP changes frequently.
  • For a permanent solution, use a static IP address (available through your ISP or a VPN with a dedicated IP) so the whitelist never needs updating.

Insufficient Permissions

Error message
Insufficient permissions
This key does not have trading permissions
API key does not have permission for this action

Cause

The API key exists and is valid, but it was created without the Spot Trading permission enabled. TradingForge needs trading permissions to place and cancel orders.

Fix

Log in to your exchange and open the API key settings. Enable Spot Trading (sometimes called "Trade" or "Enable Trading"). You do not need to enable withdrawal permissions — doing so would be a security risk and is not required by TradingForge. Save the changes on the exchange, then retry.

Never enable withdrawal permissions on an API key used for automated trading. If the key were ever compromised, withdrawal permissions would allow an attacker to drain your funds.

Rate Limit Exceeded

Error message
Rate limit exceeded
Too many requests
HTTP 429 Too Many Requests

Cause

Every exchange imposes limits on how many API requests can be made per second or minute. TradingForge automatically throttles its requests to stay within these limits, but running a very large number of active trading pairs simultaneously can push up against them.

Fix

  • TradingForge will automatically back off and retry requests when rate limits are hit. Occasional rate limit warnings are not a problem.
  • If rate limit errors occur frequently, reduce the number of simultaneously active trading pairs.
  • If you use TradeSmith, increase the analysis interval to reduce the frequency of market data requests.

Connection Timeout / ETIMEDOUT

Error message
Connection timeout
ETIMEDOUT
ECONNRESET
Failed to fetch

Cause

TradingForge cannot reach the exchange API server. This is caused by a local network issue, the exchange being temporarily down, or an outbound connection being blocked by a firewall or antivirus.

Fix

  • Check your internet connection. Open your browser and verify you can access the exchange's website normally.
  • Check the exchange's official status page (usually at status.exchangename.com) for any reported outages or degraded API performance.
  • Temporarily disable your antivirus and Windows Firewall to test whether they are blocking outbound HTTPS connections. TradingForge communicates exclusively over port 443 (HTTPS).
  • If you use a VPN, try disconnecting from it. Some VPN exit nodes are blocked by exchanges.

Nonce Too Small (Kraken Specific)

Error message
EAPI:Invalid nonce
Nonce too small

Cause

Kraken uses the current timestamp as a nonce (a unique value that must always increase) to prevent replay attacks. If your computer's clock is out of sync by more than a few seconds, Kraken will reject the requests.

Fix

1

Sync your Windows clock

Open Settings → Time & Language → Date & Time and click Sync now under the Synchronize your clock section.
2

Enable automatic time sync

Toggle Set time automatically to On so your clock stays accurate.