Jason
Jason

Reputation: 1072

SurveyMonkey Email Collector Custom Values

In order to include information (like an order number) in a survey using an Email Collector, it's my understanding that this information needs to be stored in the Contact's custom variables. My concern is what happens if I am sending something like a customer satisfaction survey that needs to reference the order number, and the same customer (email address) places more than one order, and I have to send out more than one survey.

Will the custom values that are returned with the collectors/.../responses API call include the custom values at the time of the survey invite? Or will these be set to current values?

Upvotes: 0

Views: 483

Answers (1)

General Kandalaft
General Kandalaft

Reputation: 2285

The custom values are stored on the response at the time the survey is taken. So if they change later, they will not change on the response. This will work fine as long as you don't sent out another survey with new custom values to the same contact before they respond to the previous one.

Just an FYI, there is also an option to set extra_fields on a recipient when adding recipients to an email collector (rather than on the contact).

POST /v3/collectors/<collector_id>/messages/<message_id>/recipients
{
    "email": "[email protected]",
    "extra_fields": {
        "field1": "value1",
        "field2": "value2"
    }
}

I don't believe that data is stored with he response, but the recipient_id is and you can fetch the recipient by ID to get that data back.

Those are two options, you can see which one works best for you. The benefit of contact custom values is that you can view them and edit them from the web, whereas extra_fields are API only fields.

Upvotes: 1

Related Questions