Creating Secret Santa

3 minute read

You may remember our original little Secret Santa app from 2011. It was a simple page that lets an organiser enter a list of participants, then jumbled them up and emailed each Santa a random gift recipient. It’s a nerdy twist on the more traditional folded-bits-of-paper-in-a-hat theme.

This year we thought we’d put our money where our mouth is and rebuild Secret Santa from the ground up.  We used a form from our very own form builder, a custom opt-in email, a Marketing Automation rule, a Campaign Designer template with personalisation and the subscriber API.

So how does it work?  First, the organiser comes to and we ask them to fill in a form.

Editing the Secret Santa form

This main form captures the organiser’s name and email address, and stores the information in our account. It was built in the new form builder. We simply dropped in the required fields and a nice header graphic, and linked the form to a list in our account called “Secret Santa – 2012”.

The next step was to build a campaign. We created it as a Campaign Designer template to make it easier for our copywriters to come in and adjust the text later on.

Then, once we had our email and our list with the form attached, we tied the two together with a Marketing Automation rule!

Marketing Automation rules

The rule we set up is triggered whenever a subscriber is added to the “Secret Santa 2012” list. As soon as the new subscriber confirms his or her email address, we send them the Secret Santa email campaign we built.

Here’s the clever (and slightly more technical) part! Our email campaign contains a personalised link that uses the email address we originally captured from the form, this generates a custom URL that leads the organiser back to and passes us their email address.

Whenever the organiser visits the Secret Santa page, a call is made to the subscriber API. This call verifies that the organiser’s email address exists on our Secret Santa list, ensuring that naughty people can’t just rock up and start sending everyone on the planet an email from our Secret Santa generator.

Once the API gives the application the all-clear, we know that this is a returning organiser and we let them use the Secret Santa application. From this point the application takes over and does its own thing, requesting a list of participants from the organiser and randomly generating the Secret Santas for everyone! Secret Santa screenshot