Amazon lex Bot integration with livechat

how to enable Rockectchat sdk to take livechat messages?
i am ready with lex api , i know how to use them to get replies
but problem is i am not able to find enough documentation about rockrtchat sdk

HI! Welcome to our community :hugs:

You want/need is to create a Bot Connector App, pretty much like this app here, from our good friend @frank.dase :slight_smile:

Let me know if you need any assistance while creating this App. A good reference is this Demo.App that I have been crafting: GitHub - RocketChat/Rocket.Chat.Demo.App: The best Rocket.Chat Apps Engine Demo out there.

Please, let me know if this helps!

Thanks!

thank you so much for replying
can i go with this

this also does the same work , rigth? and this application developed by you…:slightly_smiling_face: and as far as from my understanding your application not uses rocket.chat app engine… and therefore this one seems easy to understand
shall i refer this repo or the one you shared

Hi!

This lab bot uses the botpress connector App from Luis Hlatki. This botpress connector will only answer for omnichannel chats.

So you will be able to use botpress, insted of Amazon Lex Bot. So this will not be enough to integrate Rocket.Chat with Amazon Lex.

:slight_smile:

Thank you for the GitHup link.

okay so i have to use rocket chat app engine only for app developement to interact with livechat visitor via my bot or are there apis that i can use to communicate with livechat visistor as this lab bot uses by simple javascript no rocketchat engine involve

that’s right.

You can always use the realtime api as the user you want to answer with Amazon Lex, consume Amazon LEX Apis and send it back.

But using Rocket.Chat App Engine will give you a simple way to deploy and use this feature, not depending on external code being run.

okay i achieved integration using realtime api…but now i want my bot to reply with buttons i mean to give choices for visitor via buttons
can you suggest me way how can i do that

That’s when the Apps Engine comes into play :wink:

If you want to keep your app to a minimum, you can register an API that will send the buttons to the desired room and use your integration with it.

But you will not be able to add buttons or any other rich UI element using only Realtime or REST APIs.

let me know if this helps :slight_smile:

okay thanks for reply
plz can you guide me in step by step way for how to create endpoint and then how to use add UI element like button to reply in the any room
that will help a lot :slightly_smiling_face:

Sure!

There is a demo code here:

You will need to have an App that will register an endpoint and receive the payload from Amazon Lex.

Next, you will need to build up a message that has the buttons you get from the api, and send it with same user that you are configuring.

But this approach will land you with 2 moving parts
1 - The external Amazon Lex connector
2 - The App to generate the buttons

It’s optimal to run everything in one App.

We have a channel here for the Demo-App discussion, and we can help you if you want to craft the Rocket.Chat Amazon Lex Connector App

I am sure a lot of other users from our community can benefit from that.

Also, if you want to discuss it further, we do it at our Open Call next week :wink: