Steps to connect a RASA chatbot to Twilo - rasa-nlu

Can i have the steps to connect rasa chatbot to twilio.I already have ngrok and a demo bot.All i need is the commands and url and where to put that in the twilio,in incoming message or callback url as such.please guide me through it ,i cant find a proper documentation for rasa twilio integration for rasa chatbot.

Go to Twilio and create a project "Programmable SMS".
https://www.twilio.com/console/sms/dashboard and click on "Show API Credentials" (top/right)
Copy there information and add in your credentials.yml (like in the docs Rasa Twilio)
twilio:
account_sid: "ACbc2dxxxxxxxxxxxx19d54bdcd6e41186"
auth_token: "e231c197493a7122d475b4xxxxxxxxxx"
twilio_number: "+440123456789"
Use the ngrok on the port where rasa is running (normally it's 5005).
Add your URL (ngrok url + "/webhooks/rest/webhook") for message incomes in https://www.twilio.com/console/sms/whatsapp/sandbox

You can read more about integrating Twilio with Rasa here - https://rasa.com/docs/rasa/user-guide/connectors/twilio/.

Sometimes, RASA library may not read from credentials.yml file, In that case, it's better to set as environment variables like below or you can keep in env file.
export TWILIO_ACCOUNT_SID=ACbc2dxxxxxxxxxxxx19d54bdcd6e41186
export TWILIO_AUTH_TOKEN=e231c197493a7122d475b4xxxxxxxxxx

Related

Rasa Slack Integration Issue

I am using rasa to connect to slack using Ngrok.
My bot is properly responding with RASA X. These are steps i have done to connect with slack.
Create new Channel.
Added new user in App home(new in slack, worked with dialogflow for me).
Added the URL in event subscription like this:
Event Subscription containing ngrok/webhook url
subscribed to following bot events.
Added localhost to redirect URL
Installed the app to a channel
Copied the Bot User OAuth Access Token to my credentials file:
then started the bot using rasa run on port 5005 where ngrok is running
I get the response from slack into rasa (rasa run actions terminal, trying to run some google drive api).
Even simple bot is not responding to a hi msg tried that also.
Only in cmd i get the response, which means that msg is coming from slack to the rasa
And no message is fetched back in rasa window.
Note : i have also used
rasa run -m models --enable-api --cors “*” --debug
to debug the output and it shows clearly message coming to rasa from slack, bot predicting correct intent and uttering correct response. but this msg is not getting fetched back to slack

Bot Framework SDK4 C# - send proactive message to a user in Teams / REST response timeout

Based on a GitHub sample, I created a dialog bot in Teams that collects information from a user and sends that to a Flow (Microsoft Flow/Power Automate) with a HTTP POST call.
After that the Bot waits for a response and sends it back to the user. This generally would be sufficient if the timeout for the call wasn't limited to 2 minutes - sometimes it takes longer to get the complete actions in Flow and get the response.
My question is how I could accomplish the same without getting the timeout. REST seemed the easiest as I'm not a programmer..
I checked the GitHub sample for proactive messaging (https://github.com/microsoft/BotBuilder-Samples/tree/master/samples/csharp_dotnetcore/16.proactive-messages), and that worked in the Emulator when I enter http://localhost:3978/api/notify, but I have no idea how to use it published to Azure. What would be the endpoint and how I could pass the message text?
Thanks
You should do some code modify if you want to send an message based on proactive-messages demo .
You can refer to my previous post which will meet your requirement.
After you modify the NotifyController.cs file , you can use send messages to a specific user with steps below :
Connect to your bot get current user ID :
Send message to this user by rest client tool or post man :
Result :
If you publish your bot to Azure , lets assume your Azure App service host is :https://xxxxxx.azurewebsites.net , then your bot message endpoint will be :https://xxxxxx.azurewebsites.net/api/messages and your /notify function endpoint will be : https://xxxxxx.azurewebsites.net/api/notify . In brief , just use your Azure App service endpoint to replace http://localhost:3978 will be fine .
Hope it helps . If there is anything unclear pls feel free to let me know .

How can I setting webhook callback url for Bot Framework (Skype)?

I need to setting URL for a service that was been receive event for new messages. According to Microsoft documentation I can set the url for, e.g., Facebook (https://learn.microsoft.com/en-us/azure/bot-service/bot-service-channel-connect-facebook?view=azure-bot-service-3.0#generate-a-page-access-token), but I can't find information about setting url for Skype.
But I can specify a message endpoint for my bot. The message endpoint is a webhook url?
Sorry for my bad English
See also: Messaging Webhook for Microsoft skype bot
PS: about web hooks for Skype: https://msdn.microsoft.com/en-us/skype/trusted-application-api/docs/webhooks
I'm not sure if you are using C# or node but I will try my best to answer both.
The Webhook is just the endpoint for your calling controller in C# so for example in the sample from the botbuilder repository in C# They are using the CallController.cs Your webhook would be https://{your site}/api/call.
In the sample from node they are using server.post('/api/calls', connector.listen()); so your webhook url would be https://{your site}/api/calls in this setup

Host on Heroku a Gupshup ChatBot with Wit.ai

I Would like to know if this is possible. I would like to host on my own Heroku Server my ChatBot and deploy it with Gupshup on my Website. I want to add Wit.ai to manage NLP.
Is it possible to do that ?
If it is, How can I do that ? DO you have a sample to test this solution ?
Thank you
Yes, this is possible with the Callback option that Gupshup has. You can write your bot code and host it on the server then go to the Gupshup dashboard and create a bot using the callback option as in the screenshot.
This URL will receive all the information like message from the user, type of message,unique id etc. which you need to read and then respond back to the same callback.
More details can be found in this document.

How to transfer my domain from bluehost, enable email notification and receive emails?

This is sort of planning question . I have my domain at bluehost.com. But since I started to learn laravel and I am currently having temp domain in hover and I have forge/digitalocean solution.. Now I want to pull my real domain and make some email inboxes for my team.. how can I achieve that.. what tools I need to use.. my question has three parts :
1- How to pull my old domain from bluehost to forge/digitalocea, ? 2- How to create email for my team such as support#mydomain.com .. admin#mydomain.com and I want to get emails from outside world 3- How can I send email notifications from my project such as ,, account confirmation.. etc? ( I tried mailgun but it seems it not stable. it failed sometimes to send and sometimes there is delay ).
Please advice!!
How to pull my old domain from bluehost to forge/digitalocean?
Please refer on this link: https://www.digitalocean.com/community/tutorials/how-to-set-up-a-host-name-with-digitalocean
Or see an example here: http://bivori.com/migration-form-bluehost-to-digitalocean/
How to create an email server?
You can use and integrate Zoho Mail Server for Free upto 25 users.
Just follow this link:
https://www.digitalocean.com/community/tutorials/how-to-set-up-zoho-mail-with-a-custom-domain-managed-by-digitalocean-dns
How can I process email messaging?
If your using Laravel, I suggest you follow instructions as stated in their manual:
https://laravel.com/docs/5.3/mail

Resources