AutomateWoo - MailerLite
Add MailerLite functionality to AutomateWoo
by Abundant Designs · github.com/robertstaddon/automatewoo-mailerlite
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/robertstaddon/automatewoo-mailerlite/archive/refs/heads/main.zipCompanion plugin that adds MailerLite actions to AutomateWoo. Use it to subscribe contacts, assign or remove MailerLite groups, update fields, or unsubscribe someone when a WooCommerce event fires — for example when a subscription becomes active or expires.
Built by Abundant Designs.
This plugin talks to the MailerLite Connect API. It does not modify AutomateWoo or the official MailerLite WooCommerce plugin (woo-mailerlite).
Requirements
- WordPress 6.0+
- PHP 7.4+
- WooCommerce
- AutomateWoo
- A MailerLite Connect API token (Classic API keys are not supported)
Optional: MailerLite - WooCommerce integration. If that plugin is connected with a Connect token, this plugin can reuse it and you can leave the settings token blank.
Installation
- Install and activate WooCommerce and AutomateWoo.
- Upload this plugin to
wp-content/plugins/automatewoo-mailerlite, or clone this repository there. - Activate AutomateWoo - MailerLite.
- Go to AutomateWoo → Settings → MailerLite.
- Enable the integration. Paste a Connect API token, or leave the field blank to use the token from
woo-mailerlite. - Create workflows using the MailerLite actions.
Actions
All actions appear in the workflow editor under the MailerLite group.
| Action | What it does |
|---|---|
| Subscribe Contact | Creates or updates a subscriber (POST /subscribers) and optionally adds them to groups. Supports first/last name and a resubscribe option. |
| Unsubscribe Contact | Unsubscribes the contact from MailerLite entirely (all groups). Can also delete or GDPR-forget the subscriber. |
| Add Contact To Group | Assigns groups without removing other memberships. Can create the contact if they do not exist. |
| Remove Contact From Group | Unassigns the selected groups only. The contact stays subscribed and remains in any other groups. |
| Update Contact Field | Sets a MailerLite field on an existing contact. The contact must already exist. |
MailerLite has no tags API. Use groups for segmentation.
Double opt-in is an account-level MailerLite setting. It is not toggled per workflow.
Example: WooCommerce Subscriptions
A typical pair of workflows:
-
Trigger: Subscription Status Changed → Active
Action: Subscribe Contact or Add Contact To Group (your “active subscribers” group). -
Trigger: Subscription Status Changed → Expired
Action: Remove Contact From Group.
Use Unsubscribe Contact on expiry only if you want them off all MailerLite email, not just one group.
Credentials
Priority:
- API token saved under AutomateWoo → Settings → MailerLite
- Connect token stored by
woo-mailerlite
Classic (short) API keys are rejected. Tokens are validated against GET /account when settings are saved.
Development
automatewoo-mailerlite.php
admin/settings-tab.php
includes/
Plugin.php
Credentials.php
Integration.php Connect API client
Autoloader.php
Admin/Settings_Tab.php
Actions/
Subscribe.php
Unsubscribe.php
Add_To_Group.php
Remove_From_Group.php
Update_Contact_Field.php
The client lives in includes/Integration.php and follows the MailerLite API docs for subscribers, groups, and fields. Subscriber and group IDs are kept as strings.
See CHANGELOG.md for release history.
License
GPLv2 or later. See readme.txt.