Blog

Software tips, techniques, and news.

Filemaker SurveyMonkey Integration

SurveyMonkey is a popular cloud-based survey platform boasting over 20 million questions answered per day. Flexible and user friendly, surveys generated by SurveyMonkey can be used for a variety of purposes, from large company wide reviews to customer satisfaction surveys. Using SurveyMonkey's API you can automatically collect survey responses and data directly into your FileMaker application, allowing you to link your surveys to your FileMaker data.

youtube-preview

Prerequisites

In order to integrate FileMaker with SurveyMonkey, you will need a SurveyMonkey account with the Premier service plan. Without this package you will not be able to fully communicate with the SurveyMonkey API. However with the Advantage plan you are granted a 90 day trial period if you would like to test it before pursuing the Premier plan.

Getting Started

First you need to create a new app on SurveyMonkey's developer website.

FileMaker SurveyMonkey Apps

From there under the settings you can set the scopes of what this app has access to. For the sole purpose of pulling survey responses you will need the following scopes enabled: View Responses, View Response Details, View Surveys, View Collectors, View Webhooks and Create/Modify Webhooks.

FileMaker SurveyMonkey Scopes

In addition, you will need to save the access token provided to you by SurveyMonkey for FileMaker to authenticate across the API.

Creating a Webhook

Arguably the most useful part of the SurveyMonkey API is that they allow you to tie webhooks to certain actions that can take place on their website. To try out the API you can create a webhook via Postman (SurveyMonkey has a library you can use in their API documentation) or use the demo file attached to this article. You will need to specify the layout and field of your FileMaker application where you want the raw data to be stored. Here is a sample create webhook request:

{
    "event_type" : "response_completed",
    "name" : "MyWebhook",
    "object_ids" : [ "176444261" ],
    "object_type" : "survey",
    "subscription_url" : "https://your.domain.com/webhook.php"
}

And the response:

{
    "event_type" : "response_completed",
    "href" : "https://api.surveymonkey.net/v3/webhooks/3579938",
    "id" : "3579938",
    "name" : "MyWebhook",
    "object_ids" : [ "176444261" ],
    "object_type" : "survey",
    "subscription_url" : "https://your.domain.com/webhook.php"
}

Receiving the Webhook

To receive the webhook you will need to create the web script that you specified in the url of the initial webhook creation request. In this article we used PHP. This PHP code is run whenever the webhook is triggered, communicating with FileMaker's Data API to pass the survey's information into your FileMaker application.

Parsing the Webhook

You should parse the returned JSON object in the FileMaker script instead of PHP because FileMaker is the one that needs the data. While being the easiest part of the integration, it must be noted that the parsing code will in most cases have to be written to match how your survey(s) are formatted. Due to the plethora of different question and answer types that SurveyMonkey has to offer, writing a catch-all script could potentially be very time-consuming.

Here is a sample webhook response:

{
    "event_datetime" : "2019-05-30T19:35:08.362289+00:00",
    "event_id" : "10014567306",
    "event_type" : "response_completed",
    "filter_id" : "176444261",
    "filter_type" : "survey",
    "name" : "MyWebhook",
    "object_id" : "10766574798",
    "object_type" : "response",
    "resources" :
    {
        "collector_id" : "0123446546",
        "recipient_id" : "0",
        "respondent_id" : "9832489383",
        "survey_id" : "23784237",
        "user_id" : "0439219"
    }
}

Conclusion

The SurveyMonkey API allows you to automatically pull in all your survey's data directly into your FileMaker application. With your surveys in FileMaker you can link them up to your employee or customer data to track satisfaction over time and to build a process to handle negative feedback on surveys. Contact us if you would like help integrating your SurveyMonkey surveys with your FileMaker application!

Did you know we are an authorized reseller for Claris FileMaker Licensing?
Contact us to discuss upgrading your Claris FileMaker software.

Download the FileMaker SurveyMonkey Integration File

Please complete the form below to download your FREE FileMaker file.

FileMaker Experience *
Terms of Use *
OPT-IN: I agree that I am downloading a completely free FileMaker application file with no strings attached. This file is unlocked, and I may use it for my business or organization as I see fit. Because I am downloading a free file, I agree that I should receive occasional marketing. I understand that I can OPT-OUT of these emails at anytime.
andrew bosworth headshot.
Andrew Bosworth

Andrew is a certified FileMaker and web developer with a penchant for building things, particularly custom applications to improve business efficiencies.