Skip to main content

Create a response

This endpoint creates a response.

Request

POST https://api.nicereply.com/responses

Request body

Field NameData TypeIs NullableDescription
survey_idSurvey IDNo
feedback_object_idFeedback Object IDNo
customer_idCustomer IDYes
ticket_idStringYes
fromStringYes
commentStringNoDeprecated
ip_addressStringYes
answersArray of Answer objectsNo

Answer object

Field NameData TypeIs Nullable
question_idQuestion IDNo
scaleScale ObjectYes
open_endedOpen Ended ObjectYes

Scale object

Field NameData TypeIs NullableDescription
valueIntegerNoScore

Open Ended object

Field NameData TypeIs Nullable
valueStringNo
Example body
{
"survey_id": "9df60603-9453-41a2-a938-436fd603820d",
"feedback_object_id": "4f4d2bc5-a75f-4c42-b240-7f4a70da9a0b",
"customer_id": "09c58845-b8e9-4aa5-8ca8-0ca2a7caaebb",
"ticket_id": "some_ticket_id",
"from": "John Doe",
"comment": "This is nice!",
"ip_address": "10.76.23.211",
"answers": [
{
"question_id": "dedff21d-c4a7-431d-b734-c8a5ad15985f",
"scale": {
"value": 5
},
"open_ended": null
}
]
}

Example response

200 OK
{
"data": {
"id": "bc4284a0-23fe-4d6e-92f8-323d50de8690",
"feedback_object_id": "4f4d2bc5-a75f-4c42-b240-7f4a70da9a0b",
"survey_id": "9df60603-9453-41a2-a938-436fd603820d",
"customer_id": "09c58845-b8e9-4aa5-8ca8-0ca2a7caaebb",
"from": "John Doe",
"comment": "This is nice!",
"ticket_id": "some_ticket_id",
"location": "",
"ip_address": "10.76.23.211",
"is_instant": false,
"status": "CLOSED",
"created_at": "2023-09-12T12:32:05+02:00",
"updated_at": "2023-09-26T10:16:40+02:00",
"answers": [
{
"id": "09afa565-04ad-4184-9c96-a89dfa5ad9f4",
"question_id": "dedff21d-c4a7-431d-b734-c8a5ad15985f",
"question_type": "SCALE",
"scale": {
"value": 5
},
"open_ended": null,
"created_at": "2023-09-12T12:32:05+02:00",
"updated_at": "2023-09-20T15:43:05+02:00"
},
],
"tags": []
}
}