Status Codes and Error Responses
Each request returns a status code or error response to indicate whether the request was successful.
When an error occurs or when a response is successful, the response header contains an HTTP code, and the response body usually contains:
- The HTTP response code
- The message accompanying the HTTP response code
| HTTP response code | Description |
|---|
| 200 | “OK” success code. |
| 202 | “Accepted” success code, for POST request. |
| 204 | “No Content” success code for Message request; resend the request as part of the message loop. |
| 400 | The request couldn’t be understood, usually because the JSON body contains an error. |
| 403 | The request has been refused because the session isn’t valid. |
| 404 | The requested resource couldn’t be found. Check the URI for errors. |
| 405 | The method specified in the Request-Line isn’t allowed for the resource specified in the URI. |
| 409 | A duplicate long poll using the same session ID has caused the chat to terminate. Reestablish the chat in a new session. |
| 500 | An error has occurred within the Chat server, so the request couldn’t be completed. Contact Customer Support. |
| 503 | The affinity token has changed. Make a ReconnectSession request to get a new affinity token, then make a ChasitorSessionData request to reestablish the chat visitor’s data within the new session. |
See Also