(Quick Reference)
Service: Show an answer
Description: This web service return an existing answer of the specified id in JSON format
URL:
https://BASE_URL/api/VERSION/answers/{id}
Method: GET
Parameters:
Name | Description | Type | Required | Example values |
---|
id | The numerical ID of the desired answer | Long | Yes | 777 |
Success Output
Success case: response.status=200
{
"id": 22,
"latitude": null,
"longitude": null,
"checkInDate": null,
"customer": {
"id": 16,
"reference": "cust_A17",
"href": "/api/v1.0/customers/16"
},
"user": {
"id": 4,
"reference": "emp-00",
"href": "/api/v1.0/users/4"
},
"survey": {
"id": 4,
"name": "Quality and satisfaction with documentation",
"href": "/api/v1.0/surveys/4"
},
"question": {
"id": 4,
"text": "Do you have any others comments, questions, or concerns?",
"href": "/api/v1.0/questions/4"
},
"text": "photo comment",
"questionOptionAnswers": [],
"questionLine": null,
"questionColumn": null,
"photo": "https://BASE_URL/entity1-1450169988465/question/1472469520057_130x130x2.png",
"organization": "entity1",
"dateCreated": "2016-08-29T11:18:39Z",
"lastUpdated": "2016-08-29T11:18:40Z",
"responseIndex" : "ind_82547411353884",
"lineIndex" : "ind_82547411353884"
}
Failure Output
Failure case:response.status = 404
{
"error": "not_found",
"error_description": "The answer with the id 3 doesn't exist."
}
Failure case:response.status = 400
{
"error": "invalid_param_type",
"error_description": "The type of parameter id you provided is not valid for this request."
}