Enable webhooks for your surveys

On the settings page scroll down to Webhooks and click on Add new. Add a name, add the endpoint and select which events you want to subscribe to.

Attributes:

  • survey_id string
    Unique identifier for the survey.

  • survey_name string
    Name of the survey.

  • answer_id string
    Unique identifier for the given answer.

  • answer_values object
    Contains all the answers that the user gave.

  • nps integer
    Answer to the question "How likely are you to recommend our service to a friend or colleague?" On a scale of 0-10.

  • custom object
    If your survey had custom questions their answers will be listed here as key value pairs. Keys are question ids, values can be answer ids, strings or arrays if the question had multiple selection answers.

  • feedback string
    Answer to the question "What is the primary reason for your score?"

  • comment string
    Answer to the question "Do you want to give your feedback publicly?". This answer is used as the public recommendation.

  • name string
    Answer to the question "Your name"

  • email string
    Answer to the question "E-mail (not displayed)"

  • location string
    Answer to the question "Location"

  • organization string
    Answer to the question "Organization"

  • imageFilename string
    Answer to the question "Profile picture". This picture can be accessed, with parameters w=width and h=height from https://d3hwc7twidb4ye.cloudfront.net/w128-h128-c/survey/[imageFilename]

  • publicConsent string
    Answer to the question "I want to publish my feedback. I have read the [Companys] privacy policy". Will be "true" or "".

  • noPublicConsent string
    Answer to the question "I don't want to publish my feedback". Will be "true" or "".

  • created_at ISO 8601 with timezone
    Time when the first page was submitted.

  • organization_id string
    Unique identifier for the organization.

  • contact contact_object
    Contains a contact_object if answer link contained an identifier.

{
"answer": {
"survey_id": "tmetCfXyD",
"survey_name": "Survey Name",
"answer_id": "1lwBnVbM4",
"created_at": "2021-01-26T11:46:01.815Z",
"answer_url": "https://app.trustmary.com/survey/tmetCfXyD/responses?answer_id=1lwBnVbM4",
"contactName": "Person Name",
"contactEmail": "[email protected]",
"contactPhone": "+35850123456789",
"contactConsent": "true",
"noNegativeContact": false,
"nps": 10,
"question_NdfJASMGj": [
"Toyota",
"Mercedes"
],
"feedback": "I gave 10 because the product is awesome!\n",
"question__VmZtTZ1_": "I have a silver car.",
"question_x5MS9K6Wm": "My car has 4 wheels.",
},
"contact": {},
"review": {
"review_id": "zkHIUR2NZ",
"source": "trustmary",
"published": false,
"eid": "1lwBnVbM4",
"published_at": null,
"created_at": "2021-01-26T11:46:22.088Z",
"deleted_at": null,
"updated_at": "2021-01-26T11:46:22.088Z",
"reviewNps": 8,
"personName": "Person Name",
"commentText": "I really loved the product!"
},
"organization_id": "5S1I9ACyt",
"event": "surveyAnswerComplete"
}
Did this answer your question?