Title: Integraiton with Sparkpost HTTP API
Last modified: August 31, 2016

---

# Integraiton with Sparkpost HTTP API

 *  Resolved [DK](https://wordpress.org/support/users/dip-recipes/)
 * (@dip-recipes)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/)
 * I’d like to be able to use the Sparkpost HTTP API to send the MailPoet newsletters.
   My host doesn’t allow SMTP setup.
 * Is this possible at all or will there be future support for this? I’ve used the
   hidden MailPoet option to send via WP Mail and I got it to work, but the email
   is not displayed properly and appears as plain text although both plain text 
   and html mime parts are present.
 * [https://wordpress.org/plugins/wysija-newsletters/](https://wordpress.org/plugins/wysija-newsletters/)

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

 *  [Wysija](https://wordpress.org/support/users/wysija/)
 * (@wysija)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180210)
 * Unfortunately we don’t plan on adding API support for this service in the future.
 *  [tony_phillips](https://wordpress.org/support/users/tony_phillips/)
 * (@tony_phillips)
 * [10 years ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180305)
 * I’ve recently had the same problem moving from Mandrill to Sparkpost. The Sparkpost
   wpmail plugin works for sending other emails from our site but MailPoet emails
   end up as DK describes (both HTML and plain text present but both are plain text).
 * Looking through the Mailpoet emailing code, I found what looks like a bug that
   explains this. Lines 329-330 of wp_content/plugins/wysija-newsletters/helpers/
   mailer.php (function wpmail_init()) look like this:
 *  $phpmailer->Body = $this->AltBody;
    $phpmailer->AltBody = $this->AltBody;
 * To see whether this was the problem, I changed these lines in our install to:
 *  $phpmailer->Body = $this->Body;
    $phpmailer->AltBody = $this->AltBody;
 * And now our Mailpoet emails work fine with the Sparkpost plugin! Mailpoet, if
   this is all that the problem is, is there any chance you could fix it? Many thanks.
 *  [Wysija](https://wordpress.org/support/users/wysija/)
 * (@wysija)
 * [10 years ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180306)
 * Hi Tony,
 * We will look into this. Thanks for your help.
 *  [Shane Gowland](https://wordpress.org/support/users/thewebatom/)
 * (@thewebatom)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180312)
 * I can confirm that the fix suggested by ‘tony_phillips’ corrected the formatting
   issues when sending newsletters with SparkPost.
 *  [freshjustin](https://wordpress.org/support/users/freshjustin/)
 * (@freshjustin)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180314)
 * How do you access the hidden MailPoet option to send via WP Mail?
 *  [Wysija](https://wordpress.org/support/users/wysija/)
 * (@wysija)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180315)
 * Here’s how to use the SparkPost API on the latest 2.7.2 version: MailPoet’s Settings
   page > Send with tab > Third Party > type “sparkpost.com” on the hostname field.
   The API Key will show up.
 *  [freshjustin](https://wordpress.org/support/users/freshjustin/)
 * (@freshjustin)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180316)
 * Awesome thank you mailpoet!
 *  [freshjustin](https://wordpress.org/support/users/freshjustin/)
 * (@freshjustin)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180323)
 * Is injecting mail using the API faster then SMTP?

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

The topic ‘Integraiton with Sparkpost HTTP API’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wysija-newsletters_ffddcc.svg)
 * [MailPoet Newsletters (Previous)](https://wordpress.org/plugins/wysija-newsletters/)
 * [Support Threads](https://wordpress.org/support/plugin/wysija-newsletters/)
 * [Active Topics](https://wordpress.org/support/plugin/wysija-newsletters/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wysija-newsletters/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wysija-newsletters/reviews/)

 * 8 replies
 * 5 participants
 * Last reply from: [freshjustin](https://wordpress.org/support/users/freshjustin/)
 * Last activity: [9 years, 11 months ago](https://wordpress.org/support/topic/integraiton-with-sparkpost-http-api/#post-7180323)
 * Status: resolved