Returned fields for the SurveyResponse object are explained below. Go to the Example Returns section to view return examples for each call type.
Returned Fields for the SurveyResponse Object
Field | Description | Format |
---|---|---|
id | Response ID | string |
status | Complete, Partial, Disqualified | string |
contact_id | Email Campaign Contact ID | string |
is_test_data | Test data flag | boolean |
date_submitted (EST/EDT or GMT -5/GMT -4) | Date/time response was submitted | YYYY-MM-DD HH:MM:SS |
session_id | Unique session ID generated for each response | string |
language | Language in which survey was taken | string |
date_started (EST/EDT or GMT -5/GMT -4) | Date/time response was started | YYYY-MM-DD HH:MM:SS |
link_id | ID of the survey share link | string |
url_variables | URL variable value | array |
ip_address | IP address value | string |
referer | Referer value | string |
user_agent | User agent value | string |
response_time | ISP data | string |
data_quality | Data Cleaning Tool response flags | string/numeric |
comments | ISP data | string |
longitude | Longitude | string |
latitude | Latitude | string |
country | Country | string |
city | City | string |
region | Region | string |
postal | Postal code | string |
dma | ISP data | string |
survey_data[id] | Question ID | numeric |
survey_data[type] | Question type | string |
survey_data[question] | Question title | string |
survey_data[section_id] | Page ID | numeric |
survey_data[answer] | Selected answer | string |
survey_data[original_answer] | Original value of selected answer(used to preserve original value when reporting value was altered after response was submitted) | string |
survey_data[answer_id] | Selected answer option ID | number |
survey_data[shown] | Indicates whether given question ID was shown | boolean |
subquestions[id] | Sub question ID | numeric |
subquestions[type] | Sub question type | string |
subquestions[parent] | Parent question ID | numeric |
subquestions[question] | Sub question title | string |
subquestions[shown] | Indicates whether given sub-question ID was shown | string |
subquestions[answer] | Sub question answer | string |
options[id] | Answer option ID | numeric |
options[option] | Answer option reporting value | string |
*Check out the SurveyResponse Return Per Question Type Document for more specifics on how each question type returns.
Example Returns (.json format)
- Get SurveyResponse Return Example
- Create SurveyResponse Return Example
- Update SurveyResponse Return Example
- Delete SurveyResponse Return Example
GetSurveyResponse Return Example (.json format):
{
"result_ok": true,
"total_count": 2,
"page": 1,
"total_pages": 1,
"results_per_page": 50,
"data": [
{
"id": "1",
"contact_id": "",
"status": "Complete",
"is_test_data": "0",
"date_submitted": "2018-09-27 10:42:26 EDT",
"session_id": "1538059336_5bacec4869caa2.27680217",
"language": "English",
"date_started": "2018-09-27 10:42:16 EDT",
"link_id": "7473882",
"url_variables": [],
"ip_address": "50.232.185.226",
"referer": "https://app.alchemer.com/distribute/share/id/4599075",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.100 Safari/537.36",
"response_time": 10,
"data_quality": [],
"longitude": "-105.20369720459",
"latitude": "40.050701141357",
"country": "United States",
"city": "Boulder",
"region": "CO",
"postal": "80301",
"dma": "751",
"survey_data": {
"2": {
"id": 2,
"type": "RADIO",
"question": "Will you attend the event?",
"section_id": 1,
"original_answer": "Yes",
"answer": "1",
"answer_id": 10001,
"shown": true
},
"3": {
"id": 3,
"type": "TEXTBOX",
"question": "How many guests will you bring?",
"section_id": 1,
"answer": "3",
"shown": true
},
"4": {
"id": 4,
"type": "TEXTBOX",
"question": "How many guests are under the age of 18?",
"section_id": 1,
"answer": "2",
"shown": true
}
}
},
{
"id": "2",
"contact_id": "",
"status": "Complete",
"is_test_data": "0",
"date_submitted": "2018-09-27 10:43:11 EDT",
"session_id": "1538059381_5bacec751e41f4.51482165",
"language": "English",
"date_started": "2018-09-27 10:43:01 EDT",
"link_id": "7473882",
"url_variables": {
"__dbget": {
"key": "__dbget",
"value": "true",
"type": "url"
}
},
"ip_address": "50.232.185.226",
"referer": "",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.100 Safari/537.36",
"response_time": 10,
"data_quality": [],
"longitude": "-105.20369720459",
"latitude": "40.050701141357",
"country": "United States",
"city": "Boulder",
"region": "CO",
"postal": "80301",
"dma": "751",
"survey_data": {
"2": {
"id": 2,
"type": "RADIO",
"question": "Will you attend the event?",
"section_id": 1,
"original_answer": "1",
"answer": "1",
"answer_id": 10001,
"shown": true
},
"3": {
"id": 3,
"type": "TEXTBOX",
"question": "How many guests will you bring?",
"section_id": 1,
"answer": "2",
"shown": true
},
"4": {
"id": 4,
"type": "TEXTBOX",
"question": "How many guests are under the age of 18?",
"section_id": 1,
"answer": "0",
"shown": true
}
}
}
]
}
Create SurveyResponse Return Example (.json format):
{
"result_ok": true,
"data": {
"id": "3",
"contact_id": "",
"status": "Complete",
"is_test_data": "0",
"date_submitted": "2018-09-27 10:50:48 EDT",
"session_id": "1538059848_5bacee48d88a29.53780353",
"language": "English",
"date_started": "2018-09-27 10:50:48 EDT",
"link_id": null,
"url_variables": [],
"ip_address": "50.232.185.226",
"referer": null,
"user_agent": "Alchemer REST API",
"response_time": null,
"data_quality": [],
"longitude": "-105.20369720459",
"latitude": "40.050701141357",
"country": "United States",
"city": "Boulder",
"region": "CO",
"postal": "80301",
"dma": "751",
"survey_data": {
"2": {
"id": 2,
"type": "RADIO",
"question": "Will you attend the event?",
"section_id": 1,
"original_answer": "Yes",
"answer": "1",
"answer_id": 10001,
"shown": true
},
"3": {
"id": 3,
"type": "TEXTBOX",
"question": "How many guests will you bring?",
"section_id": 1,
"shown": false
},
"4": {
"id": 4,
"type": "TEXTBOX",
"question": "How many guests are under the age of 18?",
"section_id": 1,
"shown": false
}
}
}
}
Update SurveyResponse Return Example (.json format):
{
"result_ok": true,
"data": {
"id": "3",
"contact_id": "",
"status": "Complete",
"is_test_data": "0",
"date_submitted": "2018-09-27 10:50:48 EDT",
"session_id": "1538059848_5bacee48d88a29.53780353",
"language": "English",
"date_started": "2018-09-27 10:50:48 EDT",
"link_id": null,
"url_variables": [],
"ip_address": "50.232.185.226",
"referer": null,
"user_agent": "Alchemer REST API",
"response_time": null,
"data_quality": [],
"longitude": "-105.20369720459",
"latitude": "40.050701141357",
"country": "United States",
"city": "Boulder",
"region": "CO",
"postal": "80301",
"dma": "751",
"survey_data": {
"2": {
"id": 2,
"type": "RADIO",
"question": "Will you attend the event?",
"section_id": 1,
"original_answer": "Yes",
"answer": "1",
"answer_id": 10001,
"shown": true
},
"3": {
"id": 3,
"type": "TEXTBOX",
"question": "How many guests will you bring?",
"section_id": 1,
"shown": false
},
"4": {
"id": 4,
"type": "TEXTBOX",
"question": "How many guests are under the age of 18?",
"section_id": 1,
"shown": false
}
}
}
}
Delete SurveyResponse Return Example (.json format):
{
"result_ok": true
}