Keep My Members - Simple Mail Merge
Keepmymembers application to send automated individual emails

Key Elements of a single Mailing, the application screen explained

Name of Campaign

This is a name you'll give to keep one campaign separate from another. In our example, this is a group of emails that go out each day, to all customer's that have a membership expiring in seven days. Keep in mind, this campaign will run each day, as long as it is flagged as active (we'll get to that).

Query to Run

If you're sending lots of emails, everyday, you'll want to automate as much as possible. This field allows you to specify a query that resides on a remote server. In our case, the query would open the database, and ask, what members expire in seven days? If you have a programming department, you may want to get them involved. In general terms, the query will often run against a MYSQL database, with a php query. What's nice about this, is that the query is written once, and you can forget about it. It get's called everyday, pulling out the customers that expire in seven days, no other work on your part.

Resulting Data File

When the query runs, it will output the records that satisfy the query to a file. This field holds the name of the file that will be written. When the local program runs, it calls the query above, and the query writes this file on the server. In a step that you don't see, the application goes to the server, and retrieves the file. The file is downloaded, and stored locally. The file will have one line at the top called a header record that will define what fields are stored for each record.

File to Merge with

This is basically the email that will be sent. There are two copies, one that is basic text, and the second that includes html. Depending upon the recipient's software and personal settings, they will open the text or html version. You can look here to learn more about the merge file. Basically, you'll use some special codes to signify where you want to have specific pieces of data merged into the file. The fields to be merged will be spelled exactly the same as the fields that are in the header line of the Resulting Data File discussed above.

Mailgun Fields

Registering and setting up an account with Mailgun will provide you with the data you need to complete this section.

The screen below is from the Mailgun website. You'll see this information after you register, and click on the Domain menu item.

Mailgun screen that has the key data you'll need to interface with Keepmymembers application to send automated individual emails

Mailgun Base URL

The Mailgun Base URL in the application setup screen corresponds to the API Base URL on the Mailgun Website page pictured above. Enter the text just as you see it there.

Mailgun API

This field in the application corresponds to the API Key on the Mailgun website, for your domain. This key is unique for your website emails. Don't let others have this key!

Mailgun Domain

This is the website you have entered with Mailgun. It is the website you will be sending mail for.

Mailgun From

This is the address that replies will be sent to. Somewhere you should have this email set up so that you can see any replies.

Tracking Opens

When you go to the Mailgun website, if you check this box, you'll be able to see what number of your emails are being opened.

Mailgun Tag

This tag will allow you to track in the Mailgun website certain key statistics about this specific email. If you don't have a key, your seven day campaign won't be differentiated from any other campaign you might have going on.


It's less expensive to keep your current members than find new ones!

© www.36in36.com Copyright 2015