XUND
API ReferenceChatbot

Get the full state of an ongoing check

GET/v1/chatbot/status

Use this endpoint to rebuild the entire check page for a given check in the case of interruption or data loss on the client side.

Authorization

BearerToken
AuthorizationBearer <token>

Authenticate with a JWT bearer token obtained from the token endpoint with your Client Id and API key.

In: header

Header Parameters

check-id*string

The ongoing check's identifier.

language*string

The expected language of the response.

Response Body

application/json

curl -X GET "https://example.com/v1/chatbot/status" \  -H "authorization: Bearer <token>" \  -H "check-id: 5e93d7a1-f240-43b5-8937-33419ea9cb6a" \  -H "language: en"
{  "checkType": "ILLNESSCHECK",  "isClosed": false,  "currentState": {    "detailedState": "AFTER_OVERVIEW_SYMPTOM_SURVEY",    "state": "SECONDARY_SYMPTOMS"  },  "questions": [    {      "id": "ceb77a18-271f-441d-813f-29555dfccf79",      "text": "In which year were you born?",      "isSkippable": false,      "isAnswered": true,      "type": "TEXT",      "detailedType": "AGE",      "checkStateInfo": {        "detailedState": "AGE",        "state": "PROFILE"      },      "answerValidatorRegex": "^(19[0-9][0-9]|20[01][0-9]|202[0-1])$"    },    {      "id": "30294d32-ae0b-4666-884c-ff1d69d79d73",      "text": "Do you suffer from sniffles?",      "isSkippable": true,      "isAnswered": true,      "type": "SINGLE_SELECT",      "detailedType": "SYMPTOM_SURVEY",      "checkStateInfo": {        "detailedState": "PRIMARY_SYMPTOMS_SURVEY",        "state": "PRIMARY_SYMPTOMS"      },      "detailedTypeData": {        "linkedSymptom": {          "id": "a8ea44a7-a956-4655-8359-624f9546ab3c",          "name": "Sniffles"        }      }    }  ],  "possibleSymptoms": [    {      "id": "a8ea44a7-a956-4655-8359-624f9546ab3c",      "name": "Sniffles"    },    {      "id": "67181a30-0441-45b7-bf82-38130b9c2cca",      "name": "Fever"    }  ],  "predictedIllnessQuestionCategories": [    {      "id": "3",      "name": "Health"    }  ]}

Last updated on