Find the Jethro report ID
In Jethro, create a report (Under 'Persons') that returns the set of users you wish to sync with MailChimp. In this example we have a report called 'Coast Card':
- In the URL, note the
queryidparameter value (here 186). If you have a pre-existing report, the ID can be seen in the list of reports:
This ID will be used later.
Set up MailChimp API Key
- In MailChimp, click on your username, then Account Settings. In the Extras drop-down menu click API keys:
- In the Your API Keys section, Create A Key to generate a key:
Find the MailChimp list ID
- Create a List in MailChimp if you haven't yet done so. Eg:
- In the Lists section, select the list you wish to populate with emails. Click Settings, then List name & defaults:
- Note the List ID for later use.
You may find (on Debian anyway) that php dies with an error:
At google's suggestion, I fixed this by purging the package:
- Export the variables you found above, and run the
scripts/mailchimp_sync.phpscript. For example:
Initially you will get the errors above.
To fix this, go to your MailChimp List's Settings -> List Fields page:
- Click Add A Field and define a field for each one that the
Click Save when you're done.
Now run the script again. It should complete without errors or any output:
- In MailChimp, your list should now be populated with subscribers. Click Manage Subscribers -> View subscribers to see them:
Finally, automate periodic running of the sync script by creating a file,