# Telegram bot does not respond with Rasa x

**URL:** <https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560>\
**Category:** \[Deprecated\] Rasa X Community Edition\
**Created:** [February 9, 2020, 8:55pm UTC](https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560 "2020-02-09T20:55:44Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![eduardodsaraujo](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/eduardodsaraujo/32/7056_2.png) [@eduardodsaraujo](https://forum.rasa.com/u/eduardodsaraujo)\
**Post date:** [February 9, 2020, 8:55pm UTC](https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560/1 "2020-02-09T20:55:44Z")

</div>

Hi,

I followed the Docker-Compose Quick Install deployment procedure [Docker-Compose Quick Install](https://rasa.com/docs/rasa-x/installation-and-setup/docker-compose-script/) and followed the Rasa Master Class video lessons. I used Google Cloud for hosting, ran the certbot for the ssl certificate, integrated with my project on github and created the credentials file for integration with the telegram. The rasa-x page works perfectly, however when I talk to the bot on the telegram I get the request below in the log:

```auto
nginx_1 | 2020-02-09T18:49:02.280548875Z 91.108.6.145 - - [09/Feb/2020:18:49:02 +0000] "POST /webhooks/telegram/webhook HTTP/1.1" 200 1578 "-" "-"

```

However, the bot does not respond on the telegram. Looking at the log, some errors appear:

```auto
rasa-production_1 | 2020-02-09T11:47:51.871809910Z message = self._parse(resp.data)
rasa-production_1 | 2020-02-09T11:47:51.871815392Z File "/build/lib/python3.6/site-packages/telegram/utils/reque
st.py", line 174, in _parse
rasa-production_1 | 2020-02-09T11:47:51.871820596Z raise RetryAfter(retry_after)
rasa-production_1 | 2020-02-09T11:47:51.871826197Z telegram.error.RetryAfter: Flood control exceeded. Retry in 1 s
econds
rasa-production_1 | 2020-02-09T11:48:03.594653607Z 2020-02-09 11:48:03 ERROR pika.adapters.utils.io_services_ut
ils - Socket failed to connect: <socket.socket fd=22, family=AddressFamily.AF_INET, type=2049, proto=6, laddr=('17
2.18.0.8', 55590)>; error=111 (Connection refused)
rasa-production_1 | 2020-02-09T11:48:03.595339411Z 2020-02-09 11:48:03 ERROR pika.adapters.utils.connection_wor
kflow - TCP Connection attempt failed: ConnectionRefusedError(111, 'Connection refused'); dest=(<AddressFamily.AF_
INET: 2>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('172.18.0.5', 5672))
rasa-production_1 | 2020-02-09T11:48:03.599042068Z 2020-02-09 11:48:03 ERROR pika.adapters.utils.connection_wor
kflow - AMQPConnector - reporting failure: AMQPConnectorSocketConnectError: ConnectionRefusedError(111, 'Connectio
n refused')
rasa-production_1 | 2020-02-09T11:48:08.608190150Z 2020-02-09 11:48:08 ERROR pika.adapters.utils.io_services_ut
ils - Socket failed to connect: <socket.socket fd=22, family=AddressFamily.AF_INET, type=2049, proto=6, laddr=('17
2.18.0.8', 55604)>; error=111 (Connection refused)
rasa-production_1 | 2020-02-09T11:48:08.608871181Z 2020-02-09 11:48:08 ERROR pika.adapters.utils.connection_wor
kflow - TCP Connection attempt failed: ConnectionRefusedError(111, 'Connection refused'); dest=(<AddressFamily.AF_
INET: 2>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('172.18.0.5', 5672))
rasa-production_1 | 2020-02-09T11:48:08.609965674Z 2020-02-09 11:48:08 ERROR pika.adapters.utils.connection_wor
kflow - AMQPConnector - reporting failure: AMQPConnectorSocketConnectError: ConnectionRefusedError(111, 'Connectio
n refused')
rasa-worker_1 | 2020-02-09T11:47:51.295880857Z 2020-02-09 11:47:51 ERROR pika.adapters.utils.connection_wor
kflow - AMQPConnector - reporting failure: AMQPConnectorSocketConnectError: ConnectionRefusedError(111, 'Connectio
n refused')
rasa-worker_1 | 2020-02-09T11:47:56.316261937Z 2020-02-09 11:47:56 ERROR pika.adapters.utils.io_services_ut
ils - Socket failed to connect: <socket.socket fd=22, family=AddressFamily.AF_INET, type=2049, proto=6, laddr=('17
2.18.0.7', 45942)>; error=111 (Connection refused)
rasa-worker_1 | 2020-02-09T11:47:56.316716168Z 2020-02-09 11:47:56 ERROR pika.adapters.utils.connection_wor
kflow - TCP Connection attempt failed: ConnectionRefusedError(111, 'Connection refused'); dest=(<AddressFamily.AF_
INET: 2>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('172.18.0.5', 5672))

```

Please, can anyone help me?

---

<div class="post-metadata">

**Author:** ![Arjaan](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/arjaan/32/5754_2.png) [@Arjaan](https://forum.rasa.com/u/Arjaan)\
**Post date:** [February 11, 2020, 12:55am UTC](https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560/2 "2020-02-11T00:55:35Z")

</div>

Hi @eduardodsaraujo,

To make sure that the issue comes from the telegram connection and is not caused by something else, can you try to run another test by `sharing the bot with test users`, as described here?

[https://rasa.com/docs/rasa-x/user-guide/enable-workflows/#conversations-with-test-users](https://rasa.com/docs/rasa-x/user-guide/enable-workflows/#conversations-with-test-users)

---

<div class="post-metadata">

**Author:** ![eduardodsaraujo](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/eduardodsaraujo/32/7056_2.png) [@eduardodsaraujo](https://forum.rasa.com/u/eduardodsaraujo)\
**Post date:** [February 12, 2020, 12:51am UTC](https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560/3 "2020-02-12T00:51:15Z")

</div>

Hi Arjaan,

It works now, I saw the last part of the text in this link, here:

- change from : `http://<HOSTNAME>:<PORT>/webhooks/<CHANNEL>/webhook`
- to : `http://<RASA X HOSTNAME>/core/webhooks/<CHANNEL>/webhook`

And I saw that my credentials file was wrong. The bot in the telegram is answering now and I think that the error didn’t appear anymore too. Thank you very much, you saved my life.

---

<div class="post-metadata">

**Author:** ![gulafshan](https://avatars.discourse-cdn.com/v4/letter/g/71e660/32.png) [@gulafshan](https://forum.rasa.com/u/gulafshan)\
**Post date:** [June 7, 2020, 5:00pm UTC](https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560/4 "2020-06-07T17:00:57Z")

</div>

Hi I am facing the same issue.My telegram bot is not replying.I am getting error File “c:\users\gutanweer\anaconda3\envs\rasa\lib\site-packages\telegram\utils\request.py”, line 245, in \_request\_wrapper raise BadRequest(message) telegram.error.BadRequest: Bad webhook: failed to resolve host: no address associated with hostname

Can someone help me please.

@eduardodsaraujo where to update the suggested link u gave in ur post?

Thanks in advance

---

<div class="post-metadata">

**Author:** ![athenasaurav](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/athenasaurav/32/8139_2.png) [@athenasaurav](https://forum.rasa.com/u/athenasaurav)\
**Post date:** [June 8, 2020, 12:29pm UTC](https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560/5 "2020-06-08T12:29:19Z")

</div>

Hi @gulafshan,

The it depends on the rasa x version you have deployed on the GCP.

This is dependent on your Rasa X version. It should work without the `/core/` for any version \>= 0.27.0: [Rasa X Changelog](https://rasa.com/docs/rasa-x/changelog/rasa-x-changelog/#id105)

for version below 0.27.0: quest URL should not be

```auto
http://<host>:<port>/webhooks/telegram/webhook

```

which is wrong.

The request url should be

```auto
http://<host>/core/webhooks/telegram/webhook

```

For version above 0.27.0 you can use:

```auto
http://<host>:<port>/webhooks/telegram/webhook

```

---

<div class="post-metadata">

**Author:** ![gulafshan](https://avatars.discourse-cdn.com/v4/letter/g/71e660/32.png) [@gulafshan](https://forum.rasa.com/u/gulafshan)\
**Post date:** [June 8, 2020, 9:45pm UTC](https://forum.rasa.com/t/telegram-bot-does-not-respond-with-rasa-x/24560/6 "2020-06-08T21:45:23Z")

</div>

Appreacited your immediate response!

My Rasa X version is 0.28.6 and my telegram credentials look like

telegram:

access\_token: “xxxxx” verify: “xxx\_bot” webhook\_url: “[http://xxxx.ngrok.io/webhooks/telegram/webhook](http://xxxx.ngrok.io/webhooks/telegram/webhook)”

Even my custom actions are working fine in Rasa Shell but not working with rasa X. Though default scenarios are working in Rasa x.

For telegram my bot is not responsing at all.

Please help me I am trying hard to resolve but no luck.

Thanks a ton 🙂
