# Rasa bot integration with Facebook Messenger

**URL:** <https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649>\
**Category:** Rasa Open Source\
**Created:** [July 8, 2019, 9:36pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649 "2019-07-08T21:36:06Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 8, 2019, 9:36pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/1 "2019-07-08T21:36:06Z")

</div>

Hello, I am an intern working on an already developed Rasa chatbot. My internship deliverable is to integrate the chatbot on FB messenger. However, I am not able to create a webhook for the same. Attaching a copy of the error image. Any help on this would be appreciated

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/4/406100dfaf5d365d892a64c5a99fde5ab889a8af.png)

@Juste @erohmensing

---

<div class="post-metadata">

**Author:** ![Bunny99](https://avatars.discourse-cdn.com/v4/letter/b/48db29/32.png) [@Bunny99](https://forum.rasa.com/u/Bunny99)\
**Post date:** [July 9, 2019, 8:23am UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/2 "2019-07-09T08:23:55Z")

</div>

1. Which port number you are using in ngrok ?(default 5005)
2. After running the project (rasa run) ,then try to connect fb using webhook
3. FB page admin only do this
4. Change the verify token

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 9, 2019, 1:15pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/3 "2019-07-09T13:15:04Z")

</div>

Yes 5005 is the port that I’m using, also I am not able to execute rasa run command, I am just running my chatbot using “npm start”. What do you suggest? If I run the command “rasa run” it gives me an error

---

<div class="post-metadata">

**Author:** ![Juste](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/juste/32/15_2.png) [@Juste](https://forum.rasa.com/u/Juste)\
**Post date:** [July 10, 2019, 3:03pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/4 "2019-07-10T15:03:37Z")

</div>

HI @RenuDighe. Could you share the log of the error you get when you run the `rasa run` command? Also, what would help is if you could share the message you see on ngrok once the facebook tries to validate the URL.

---

<div class="post-metadata">

**Author:** ![Rogers\_ntr](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/rogers_ntr/32/3067_2.png) [@Rogers\_ntr](https://forum.rasa.com/u/Rogers_ntr)\
**Post date:** [July 10, 2019, 3:17pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/5 "2019-07-10T15:17:54Z")

</div>

Actually, I think it is because, Facebook is not able to verify that your “webhook handler”(Rasa facebook webhook endpoint) is working. So to help you as other suggest, you need to give I think the error that you get from rasa run.

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 10, 2019, 3:27pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/6 "2019-07-10T15:27:08Z")

</div>

![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/0/05977d1bb46457ee5c3b531c1213fd7b4840e272.png)

This is what I get when I click on Save and Verify on FB Developers Page

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/7/7c7d25a8bafa2ebdfea975d6ede758870f88c71f.png)

And this is what I get when I run rasa with the credentials file

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 10, 2019, 3:32pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/7 "2019-07-10T15:32:42Z")

</div>

I usually run the bot using “npm start”

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/3/3bc1bd8307eeb93b07dff90ebfcc7b161ef8b440.png)

---

<div class="post-metadata">

**Author:** ![Rogers\_ntr](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/rogers_ntr/32/3067_2.png) [@Rogers\_ntr](https://forum.rasa.com/u/Rogers_ntr)\
**Post date:** [July 10, 2019, 4:44pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/8 "2019-07-10T16:44:00Z")

</div>

In which port are you running the rasa serveur whe using ‘npm start’; If you run on the port “5005”, you should run “./ngrok http 5005”. Because, what I see is that you are using the port 80 on ngrok. Hope this help

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 10, 2019, 4:49pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/9 "2019-07-10T16:49:48Z")

</div>

Screenshot is of port 80, but I have tried doing the same for 5005, 5004 and 5055. My chatbot is using 5055. But does not work for it either

---

<div class="post-metadata">

**Author:** ![Bunny99](https://avatars.discourse-cdn.com/v4/letter/b/48db29/32.png) [@Bunny99](https://forum.rasa.com/u/Bunny99)\
**Post date:** [July 11, 2019, 10:34am UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/10 "2019-07-11T10:34:02Z")

</div>

Do you have model folder or not ? in your project.If you don’t have please train your project with (rasa train)

---

<div class="post-metadata">

**Author:** ![Rogers\_ntr](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/rogers_ntr/32/3067_2.png) [@Rogers\_ntr](https://forum.rasa.com/u/Rogers_ntr)\
**Post date:** [July 11, 2019, 11:58am UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/11 "2019-07-11T11:58:33Z")

</div>

Which version of rasa are you using ?

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 11, 2019, 1:32pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/12 "2019-07-11T13:32:31Z")

</div>

I have the models folder and running ‘rasa train’ command gives this error

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/7/75ffcea6ac337c4a5db8cf469013411558912ed2.png)

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 11, 2019, 1:32pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/13 "2019-07-11T13:32:43Z")

</div>

0.11.1

---

<div class="post-metadata">

**Author:** ![erohmensing](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/erohmensing/32/1789_2.png) [@erohmensing](https://forum.rasa.com/u/erohmensing)\
**Post date:** [July 11, 2019, 1:56pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/14 "2019-07-11T13:56:41Z")

</div>

@RenuDighe what’s the version? `rasa train` wasn’t a command until `rasa` 1.0.0. Are you still on `rasa_core` and `rasa_nlu`?

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 11, 2019, 2:21pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/15 "2019-07-11T14:21:30Z")

</div>

Yes I am using rasa\_core and rasa\_nlu. What should be done to migrate to rasa 1.0.0?

---

<div class="post-metadata">

**Author:** ![erohmensing](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/erohmensing/32/1789_2.png) [@erohmensing](https://forum.rasa.com/u/erohmensing)\
**Post date:** [July 11, 2019, 2:36pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/16 "2019-07-11T14:36:04Z")

</div>

There is a migration guide [here](https://rasa.com/docs/rasa/migration-guide/) 🙂 since your versions are so old you might also need to checkout the older migration guides too [here](https://legacy-docs.rasa.com/docs/core/migrations/)

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 11, 2019, 2:38pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/17 "2019-07-11T14:38:37Z")

</div>

Thanks a lot 🙂

---

<div class="post-metadata">

**Author:** ![erohmensing](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/erohmensing/32/1789_2.png) [@erohmensing](https://forum.rasa.com/u/erohmensing)\
**Post date:** [July 11, 2019, 2:40pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/18 "2019-07-11T14:40:11Z")

</div>

Sure thing! Hope the migration goes well, then let us know if you still have trouble with facebook 🙂

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 11, 2019, 2:40pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/19 "2019-07-11T14:40:51Z")

</div>

Sure 👍🏻

---

<div class="post-metadata">

**Author:** ![RenuDighe](https://avatars.discourse-cdn.com/v4/letter/r/c57346/32.png) [@RenuDighe](https://forum.rasa.com/u/RenuDighe)\
**Post date:** [July 11, 2019, 2:50pm UTC](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649/20 "2019-07-11T14:50:36Z")

</div>

![image](https://europe1.discourse-cdn.com/flex013/uploads/rasa/original/2X/3/350c19c1adc7890e600c547d3e3bd42656e049b3.png)

I am confused a little. My rasa installation folder shows rasa, rasa\_core and rasa\_nlu all three. How should I proceed?

[Next page](https://forum.rasa.com/t/rasa-bot-integration-with-facebook-messenger/12649.md?page=2)
