Version: 1.0
Author: Ryan T. M. Reiffenberger
Author URL: Falls Technology Group
Description: Automatically subscribes Stripe checkout customers to specified MailerLite mailing lists.
The Stripe to MailerLite Integration plugin allows you to automatically add customers who complete a Stripe checkout session to designated mailing lists in MailerLite. This can help streamline your email marketing efforts by ensuring that customers are automatically subscribed to relevant lists based on the products they purchase.
- Map specific Stripe products to MailerLite groups
- Automatically subscribes customers to appropriate MailerLite groups after checkout
- Easy configuration through the WordPress dashboard
- Securely authenticates Stripe webhook requests
- WordPress installation
- Stripe account with API keys and enabled webhooks
- MailerLite account with API key
- PHP 7.4 or higher
- Download the plugin or clone this repository into your WordPress plugins directory (
wp-content/plugins/
). - Activate the plugin through the WordPress dashboard under Plugins > Installed Plugins.
- Configure your API keys and product mappings under Settings > Stripe to MailerLite.
- Go to Settings > Stripe to MailerLite in your WordPress dashboard.
- Enter your Stripe Secret Key, Stripe Webhook Secret, and MailerLite API Key in the provided fields.
- Save changes.
- In your Stripe account, go to Developers > Webhooks and create a new webhook.
- Set the endpoint URL to your WordPress site, appending
/wp-json/smi/v1/webhook
(e.g.,https://yourwebsite.com/wp-json/smi/v1/webhook
). - Choose the
checkout.session.completed
event. - Copy the Webhook Secret provided by Stripe and enter it in the plugin settings.
- In the plugin settings page, you’ll see a list of your Stripe products alongside available MailerLite groups.
- Select the MailerLite group to associate with each Stripe product. When a customer purchases this product, they’ll be added to the corresponding MailerLite group.
Once configured, the plugin will automatically subscribe customers to the appropriate MailerLite group(s) upon completing a Stripe checkout session. No further actions are required.
- Product List Empty: Ensure your Stripe Secret Key is correct and has permissions to fetch products.
- MailerLite Group List Empty: Verify the MailerLite API Key and ensure it has permissions to access groups.
- Webhook Not Triggering: Confirm that the webhook endpoint is set correctly in Stripe and that the
checkout.session.completed
event is enabled.
stripe-mailerlite-integration.php
: Main plugin filesmi_add_settings_page()
: Registers the settings page in WordPresssmi_render_settings_page()
: Renders the settings pagesmi_handle_stripe_webhook()
: Handles incoming Stripe webhookssmi_add_to_mailerlite()
: Adds subscribers to MailerLite groups
The plugin uses WordPress REST API routes and settings pages to handle configuration, webhook processing, and customer subscriptions.
This plugin is open-source and released under the MIT License.
For assistance, please contact Falls Technology Group.