Want to send your quiz leads and responses automatically to your favorite marketing software or data warehouse?

Send quiz leads & data to your favorite software with a webhook

Our webhook will send the quiz data to your system – for each person who completes your included lead generation form.

Riddle has a wide range of native integrations – including Mailchimp, ActiveCampaign, Google Sheets, and more.

But if you have different software – a webhook is a great solution.

What’s a webhook? Check out this great overview – especially the difference between APIs and webhooks.

Securing your webhooks

You can secure your webhook with a signature. This will ensure that all data received on your endpoint is coming from your Riddle and not from someone trying to exploit your webhook. Please read our dedicated article on webhook signatures for more information.

Legacy Riddle 1.0: Code examples: connecting Riddle to different software

If you are still working in our old version of Riddle, here are some examples how you can use our webhook to integrate with your various data systems.

The following code snippets are just extracts and not working examples.

Simple logger:



SwiftMailer (examples for native PHP mailer and PHPMailer are included):


$message = Swift_Message::newInstance()
        ->setFrom(array($fromMail => $fromName))
        ->setTo(array($toMail => $toName))
        ->addPart(getMailBody($riddle), 'text/html');

$transport = Swift_MailTransport::newInstance();

$mailer = Swift_Mailer::newInstance($transport);

Send riddle data to your Google Spreadsheet Document (although you can also use our native Google Doc integration):


$client = new Google_Client();
putenv('GOOGLE_APPLICATION_CREDENTIALS=' . $authConfigFile);

if ($client->isAccessTokenExpired()) {

$riddleData = new RiddleData(file_get_contents('php://input'));
$riddleSpreadsheet = new RiddleGoogleSpreadsheet($client, $spreadsheetId, $worksheatId);

Leave a Comment