CTBot icon indicating copy to clipboard operation
CTBot copied to clipboard

Fix CTBot::sendCommand - json emply

Open VashCrHm opened this issue 3 years ago • 11 comments

From the date 21-06-2021 16:00 is necessary add "https://api.telegram.org";

const String URL = (String)"GET /bot" + m_token + (String)"/" + command + parameters;

to

const String URL = (String)"GET https://api.telegram.org/bot" + m_token + (String)"/" + command + parameters;

File CTBot.cpp, line 30

  1. auto-redirect from "api.telegram.org" to "core.telegram.org"
  2. "getNewMessage error: ArduinoJson deserialization error code: json emply" (because it receives html code as a response, no json file)

I hope it will be of help, greetings :)

VashCrHm avatar Jun 22 '21 16:06 VashCrHm

Thank you it works like a charm

grosdax avatar Jun 22 '21 17:06 grosdax

Perfect! Thanks!

bbird8 avatar Jun 22 '21 18:06 bbird8

Perfect. i wrote issue #84 some days ago. now it works, here is my configuration:

  1. Arduino ver 1.8.12
  2. libreria CTbot ver 2.1.5
  3. JSON LIBRARY by Benoit Blanchon ver 6.18.0
  4. core di ESP8266 (programmatore) ver 2.6.3 AND IT S WORKING (i just run echoBot from Examples and it works fine, testConnection OK, yesterday was "NOK".

konig87nikkinakki avatar Jun 22 '21 20:06 konig87nikkinakki

Thanks a lot, @VashCrHm Cause of you my room lamp can lights again hahaha...

GhaniyKie avatar Jun 22 '21 22:06 GhaniyKie

Perfect. i wrote issue #84 some days ago. now it works, here is my configuration:

  1. Arduino ver 1.8.12
  2. libreria CTbot ver 2.1.5
  3. JSON LIBRARY by Benoit Blanchon ver 6.18.0
  4. core di ESP8266 (programmatore) ver 2.6.3 AND IT S WORKING (i just run echoBot from Examples and it works fine, testConnection OK, yesterday was "NOK".

could you drop the sytax for me so I can try it? Thanks @konig87nikkinakki

mhilmanmaulana avatar Jun 23 '21 05:06 mhilmanmaulana

Many thanks VashCrHm, I'm updating the two library and soon I'll draft a new release.

UPDATE

I've uploaded a quick fix in the v3.0.0 branch. I'll do the same with a new v2.x.x release this evening.

shurillu avatar Jun 23 '21 06:06 shurillu

i hope so... because i really need it for college assignment

gokil0815 avatar Jun 23 '21 16:06 gokil0815

I have just published a new release (2.1.6) with fixes suggested (and verified) in this thread. It should fix the problem. Please let me know if it solve the issue.

Cheers

Stefano

shurillu avatar Jun 23 '21 18:06 shurillu

Grat job!!!!!!!!!!

rolo11 avatar Jun 23 '21 18:06 rolo11

sytax

What is a sytax? i ve modified the file in library as shown in top of this Issue, and it's working now. I wrote my configuration so everyone can know exactly what i'm using to Compile and Program

By the way it's working since yesterday so maybe we solved the issue ;-)

konig87nikkinakki avatar Jun 23 '21 20:06 konig87nikkinakki

Had the same issue, connection with telegram server failed after my esp8266 was running for >1 year. The latest version fixed it, so thanx a lot.

bgie avatar Jun 27 '21 18:06 bgie