Advanced API Debugging
If your client sites are failing to connect or generate content, follow this diagnostic checklist.
1. The "Heartbeat" Check
Every client site pings the Hub daily.
- Check: In the Agency Portal, look at the "Last Seen" column for the client.
- Fix: If "Last Seen" is > 48 hours, the client's Cron jobs may be broken. Install a plugin like WP Crontrol on the client site to verify events are running.
2. Firewall Whitelisting
If your client uses a strict security plugin (Wordfence, iThemes) or host (WPEngine), they may be blocking our API.
Whitelist IP: [Your Hub Server IP Address]
Whitelist User-Agent: iSquared-Client-Agent/1.0
3. Rate Limiting (429 Errors)
If a client receives a 429 Too Many Requests error:
- They are hitting the Hub too fast (e.g., clicking "Generate" 10 times in 1 minute).
- Protection: Our Redis limiter blocks IPs for 60 seconds after 20 rapid requests.
- Action: Tell the client to wait 1 minute and try again.
4. "Empty Response" on Content
If the AI returns a blank string:
- Cause: The OpenAI API may have timed out (took longer than 60s).
- Fix: Ensure your Hub server
php.ini has max_execution_time = 120 or higher.