org.telegram.telegrambots.exceptions.TelegramApiRequestException: Unable to deserialize response

Samebug tips

Check if you forgot to set the "data" field inside your request. If you did set it, check if it's being serialized before sending, and if it's being serialized the right way.

4 months ago
Expert tip

You're inputing information in a way the Json Parser can't understand. This page might enlighten you a little:

7 months ago
Expert tip

Solutions on the web

Solution icon of github
via GitHub by ospavel
, 8 months ago
Unable to deserialize response

Stack trace

org.telegram.telegrambots.exceptions.TelegramApiRequestException: Unable to deserialize response
	at org.telegram.telegrambots.api.methods.updates.GetUpdates.deserializeResponse(
	at org.telegram.telegrambots.updatesreceivers.DefaultBotSession$
Caused by: com.fasterxml.jackson.core.JsonParseException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', '
false' or 'null')
 at [Source: <html>
<head><title>502 Bad Gateway</title></head>
<body bgcolor="white">
<center><h1>502 Bad Gateway</h1></center>
; line: 1, column: 2]
	at com.fasterxml.jackson.core.JsonParser._constructError(
	at com.fasterxml.jackson.core.base.ParserMinimalBase._reportError(
	at com.fasterxml.jackson.core.base.ParserMinimalBase._reportUnexpectedChar(
	at com.fasterxml.jackson.core.json.ReaderBasedJsonParser._handleOddValue(
	at com.fasterxml.jackson.core.json.ReaderBasedJsonParser.nextToken(
	at com.fasterxml.jackson.databind.ObjectMapper._initForReading(
	at com.fasterxml.jackson.databind.ObjectMapper._readMapAndClose(
	at com.fasterxml.jackson.databind.ObjectMapper.readValue(
	at org.telegram.telegrambots.api.methods.updates.GetUpdates.deserializeResponse(
	... 1 more

Write tip

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

Users with the same issue

412 times, 1 week ago
25 times, 1 week ago
84 times, 1 month ago
Once, 1 month ago
3 times, 2 months ago
113 more bugmates