Export responses as json
Responses / Export
Export responses as json
Description
Gets a single response full data.
Body
{
"projectId": "50c957e3f3e4670e361b5fca",
"campaignId": "50c957e3f3e4670e361b5fcb",
"fromDate": "2020-01-01",
"toDate": "2022-12-31",
"offset": 0,
"limit": 100,
"onlyCount": true
}
where:
projectId: The id of the project.campaignId: The id of the campaign. Don’t send this field to get responses from all campaigns.fromDate: The initial date of the responses data desired.toDate: The final date of the responses data desired.- offset: numeric. From what response to export (using for pagination).
- limit: Boolean. How much response to export, the maximun for this value is 100 (using for pagination).
onlyCount: when it is set to true, the endpoint only returns the amount of responses available
Response
200 OK
[{
"answers": {
"questionId": {
"na": boolean,
"values": array|object|null,
"value": array|number|string|null,
},
},
"timeToComplete": number,
"id": string,
"projectId": string,
"createdAt": string,
"channel": string,
"campaignId": string,
"serverCreationDate": string,
"requestInfo": object,
"code": string,
"conceptTestsDisplayed": {
"conceptTestId": [
"conceptId"
]
},
"headers": object,
"urlHash": string,
"isAdmin": boolean,
"uuid": string,
"completenessPercent": number,
"questionsDisplayedCount": number,
"responsesCount": number
},
...
]
where:
answers: Object containing the responses of the questions answered by the respondent. The format of each response may vary according to the type of the question.timeToComplete: Time in seconds that the respondent took to complete the survey.id: The unique id of the response.projectId: The id of the project.createdAt: The timestamp when the response was submitted.channel: The distribution channel through the survey was sent to the respondent.campaignId: The id of the campaign.serverCreationDate: The date in UTC format when the response was submitted.requestInfo: The location info of the request that was made when the response was submitted.code: The unique and short code assigned to the response.conceptTestsDisplayed: The concept tests that were displayed to the respondent.headers: The headers info of the request that was made when the response was submitted.urlHash: The public url hash to identify the survey. Used in the public survey link.isAdmin: A flag to know if the response was submitted with the admin link.uuid: Unique code generated to avoid duplicates.completenessPercent: The percentage of completion of the survey. Calculated withquestionsDisplayedCountandresponsesCount.questionsDisplayedCount: The amount of questions displayed to the respondent in the survey.responsesCount: The amount of questions actually answered by the respondent in the survey.
401 Unauthorized
The user doesn’t have permissions.
500 Internal Server Error
Error occurred while processing the request.
POST
Export responses as json
Description
Gets a single response full data.Body
projectId: The id of the project.campaignId: The id of the campaign. Don’t send this field to get responses from all campaigns.fromDate: The initial date of the responses data desired.toDate: The final date of the responses data desired.- offset: numeric. From what response to export (using for pagination).
- limit: Boolean. How much response to export, the maximun for this value is 100 (using for pagination).
onlyCount: when it is set to true, the endpoint only returns the amount of responses available
Response
200 OK
answers: Object containing the responses of the questions answered by the respondent. The format of each response may vary according to the type of the question.timeToComplete: Time in seconds that the respondent took to complete the survey.id: The unique id of the response.projectId: The id of the project.createdAt: The timestamp when the response was submitted.channel: The distribution channel through the survey was sent to the respondent.campaignId: The id of the campaign.serverCreationDate: The date in UTC format when the response was submitted.requestInfo: The location info of the request that was made when the response was submitted.code: The unique and short code assigned to the response.conceptTestsDisplayed: The concept tests that were displayed to the respondent.headers: The headers info of the request that was made when the response was submitted.urlHash: The public url hash to identify the survey. Used in the public survey link.isAdmin: A flag to know if the response was submitted with the admin link.uuid: Unique code generated to avoid duplicates.completenessPercent: The percentage of completion of the survey. Calculated withquestionsDisplayedCountandresponsesCount.questionsDisplayedCount: The amount of questions displayed to the respondent in the survey.responsesCount: The amount of questions actually answered by the respondent in the survey.
401 Unauthorized
The user doesn’t have permissions.
500 Internal Server Error
Error occurred while processing the request.