Resolving AI Writing Tool Connection Issues

The AI Writing Tool may fail to connect due to several common configuration issues. This guide covers the most frequent connection problems and their solutions.

Check API Key Configuration

Navigate to DigiFusion > Write with AI in your WordPress admin dashboard.

Verify that you have entered a valid API key for your selected provider:

For OpenAI (ChatGPT):

  • Ensure your API key starts with sk-
  • Copy the key exactly from your OpenAI platform account
  • Remove any extra spaces or characters

For Anthropic (Claude):

  • Ensure your API key starts with sk-ant-
  • Copy the key exactly from your Anthropic console
  • Remove any extra spaces or characters

Verify AI Provider Selection

In the AI Settings, confirm that your AI Provider selection matches the API key you’ve entered:

  • If using an OpenAI API key, select “OpenAI (ChatGPT)”
  • If using an Anthropic API key, select “Anthropic (Claude)”

Save the settings after making any changes.

Enable the AI Writing Tool

Ensure that Enable Write with AI is turned on in the AI Settings page.

Verify that your current post type is selected in the Choose Post Types section. By default, only “Posts” is enabled.

Check API Key Validity

Invalid or expired API keys are the most common cause of connection failures.

For OpenAI:

  • Log into your OpenAI platform account
  • Navigate to the API Keys section
  • Verify your key is active and has available credits
  • Check if your account has any usage restrictions

For Anthropic:

  • Log into your Anthropic console
  • Verify your API key is active
  • Check your account’s API usage limits

Resolve Server Connection Issues

If your WordPress site cannot reach the AI provider’s servers, add these lines to your wp-config.php file:

define('WP_HTTP_BLOCK_EXTERNAL', false);
define('WP_ACCESSIBLE_HOSTS', 'api.openai.com,api.anthropic.com');

This allows WordPress to make external API requests to the AI providers.

Clear Browser Cache

Clear your browser cache and cookies, then refresh the WordPress editor page.

Try opening the editor in an incognito/private browsing window to rule out browser-related issues.

Test with Minimal Content

When testing the AI connection, start with a simple prompt like “Write a short paragraph about technology” to verify basic connectivity before attempting complex content generation.

Check WordPress Error Logs

If connection issues persist, examine your WordPress error logs for specific error messages related to the AI functionality.

Most hosting providers provide access to error logs through their control panel or you can check the /wp-content/debug.log file if WordPress debugging is enabled.

Max Tokens Configuration

Ensure the Max Tokens setting is appropriate for your needs. If set too high, some API calls may fail:

  • For short content: 500-1000 tokens
  • For medium content: 1000-1500 tokens
  • For long content: 1500-2500 tokens

Excessively high token counts can cause API timeouts or rejection.

Plugin Conflicts

Deactivate other AI or content-related plugins temporarily to check for conflicts.

Some security plugins may block external API requests. Check your security plugin settings and whitelist the AI provider domains:

  • api.openai.com
  • api.anthropic.com

Network and Firewall Issues

Contact your hosting provider if the connection issues persist, as they may need to:

  • Allow outbound HTTPS connections to AI provider APIs
  • Remove any firewall restrictions blocking the API domains
  • Increase timeout limits for external API requests

The AI Writing Tool requires stable internet connectivity and proper server configuration to function correctly.