Title: api key not valid always
Last modified: August 21, 2016

---

# api key not valid always

 *  Resolved [l0c0luke](https://wordpress.org/support/users/l0c0luke/)
 * (@l0c0luke)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/api-key-not-valid-always/)
 * I am using 2.4.5 on wp 3.9
 * I logged into benchmark and craeted a new api key. I add that key in my BM settings.
   And no matter what I get the X saying it is invalid next to it. I have tried 
   setting the timeout to 30 seconds with no luck.
 * Do I need to open a port on my server to communicate with API?
 * [https://wordpress.org/plugins/benchmark-email-lite/](https://wordpress.org/plugins/benchmark-email-lite/)

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Sean Conklin](https://wordpress.org/support/users/seanconklin/)
 * (@seanconklin)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/api-key-not-valid-always/#post-4842995)
 * Hi l0c0luke,
 * Your web server needs to be able to speak outbound to api.benchmarkemail.com 
   on SSL port 443. If your firewall is blocking this, then you would need to add
   a rule. Most web servers allow outgoing connections, but you may be in a more
   secure environment.
 * To diagnose your specific issue, I recommend putting a test PHP file in your 
   web root and running it from the command line (php ./test.php) or a web browser
   to see what’s going on more specifically. The file can contain this sample test
   run of the listGet command with your API key:
 *     ```
       <?php
   
       // Settings
       $service = 'https://api.benchmarkemail.com/1.0/';
       $api_key = 'PUT-YOUR-API_KEY_HERE';
       $timeout = 30;
       ini_set( 'default_socket_timeout', $timeout );
   
       // Load WP
       require( 'wp-load.php' );
       require( 'wp-includes/class-IXR.php' );
   
       // Try Connection
       $client = new IXR_Client( $service, false, 443, $timeout );
       $args = array( 'listGet', $api_key, '', 1, 100, 'name', 'asc' );
       call_user_func_array( array( $client, 'query' ), $args );
   
       // Output
       print_r( $client->getResponse() );
   
       ?>
       ```
   
 * This request suggests that we should have a feature that reports whether it can
   talk to Benchmark Email API server separately from the individual token authentications.
   We’ll work on that in an upcoming release.
 *  Plugin Author [Randy Sandberg](https://wordpress.org/support/users/randywsandberg/)
 * (@randywsandberg)
 * [12 years, 1 month ago](https://wordpress.org/support/topic/api-key-not-valid-always/#post-4843119)
 * Hi l0c0luke, just wondering if you had any luck with Sean’s suggestions for a
   fix above?

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘api key not valid always’ is closed to new replies.

 * ![](https://ps.w.org/benchmark-email-lite/assets/icon-256x256.png?rev=2863856)
 * [Benchmark Email Lite](https://wordpress.org/plugins/benchmark-email-lite/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/benchmark-email-lite/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/benchmark-email-lite/)
 * [Active Topics](https://wordpress.org/support/plugin/benchmark-email-lite/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/benchmark-email-lite/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/benchmark-email-lite/reviews/)

 * 2 replies
 * 3 participants
 * Last reply from: [Randy Sandberg](https://wordpress.org/support/users/randywsandberg/)
 * Last activity: [12 years, 1 month ago](https://wordpress.org/support/topic/api-key-not-valid-always/#post-4843119)
 * Status: resolved