How to integrate Watson Assistant chatbot with my own CRM? - python

As the title suggests I have made a chatbot through IBM Watson Assistant and have implemented on my website. I have also made a separate CRM through Python and Django and I have created a separate Messages html where I want the chatbot messages to be recorded so that the sales representatives can follow up with potential customers.
Is there an easy way to do this? Can the messages be recorded in the CRM??

You can integrate your chatbat (your assistant) in several ways. You probably have taken a look at the sections on integrating with your website and custom integrations. A custom integration is probably what you need if you want to store the messages in your CRM. Basically, you would use the API to send messages to Watson Assistant and receive the responses. Your app would collect user input and display the responses. Both could be stored in your CRM.

Related

Need a Https endpoint for microsoft teams and python integration

I have some python scripts which perform some jobs based on the user inputs I want to host this on microsoft teams. For an outgoing webhook teams asks for a https link where and how do I get it. I am pretty new to this so do not take anything for granted.
Basically, this "outgoing webhook" means that Teams has the ability to call a web service of some sort, hosted on a publicly-accessible https address. In the end, it functions very similarly to a bot, so it's possible to just create a full-blown bot. Here's guidance on creating a Microsoft bot (for Teams or otherwise) using Python.
However, there's a more simple option, of basically just hosting a web function somewhere (e.g. an Azure Function or, I guess, an Amazon Lamba). See this article. As mentioned in this link:
Outgoing webhooks post data from Teams to any chosen service capable
of accepting a JSON payload. Once an outgoing webhook is added to a
team, it acts like bot, listening in channels for messages using
#mention, sending notifications to external web services, and
responding with rich messages that can include cards and images.
An Azure Function automatically gets a full, unique, https address, so it's fine to use.
As another example, this blog post describes how to create a Flow ("Power Automate") that the webhook calls into. This example also ends up using an Azure Function to "glue together" Teams + Flow, but it explains the concepts a bit. You could ignore Flow and just use an Azure Function.
Whether to build an -actual- bot depends on -what else- you might want to be able to do. For instance, do you want to have a more complete conversation with the user? Do you want to the user to be able to interact with your code outside of a channel (e.g. a 1-1 conversation)? These are the kinds of things that will indicate if you might need a proper bot.
You need to use bot framework to create bot that will handle that:
https://github.com/microsoft/botframework-sdk
https://github.com/microsoft/BotBuilder-Samples

How do e-commerce websites integrate with ERP systems?

How does e-commerce usually handle integrations with ERP software?
We are working on a project for a client, who previously planned to use an ERP system that had a REST API.
This API allowed us to:
Place orders
Inform the ERP if the order was paid for
Get order status
Get all of the items available
Check item availability
Get user data
That would allow us to build a fairly complex online store with a lot of features.
Now the client wants to use another ERP system:
http://www.netsuite.com/portal/platform.shtml
I researched it, and the difficulty of integration surprised me. No REST API, some weird SOAP protocol to communicate with the system, and you have to write a lot of logic using SuiteScript. A whole new, different programming language just to build an integration with an online store? Why not just give developers access to an API to place orders and fetch items? And there are absolutely no docs available online for the thing. People on forums are saying that the system lacks in documentation and one has figure it out himself, along the way.
Magento and Shopify integration is done by third parties and looks dodgy. Same thing with SAP ERP. Am I missing something? Why is such a basic thing as a REST API for e-commerce not available for those systems?
Why develop using Python Django for the back-end and using React.js for the frontend. What is the right way to integrate them with the ERP system?
NetSuite does have a REST API and webservices. "you have to write a lot of logic using SuiteScript" is true but it's just JavaScript and there are many talented developers out there.
I'm not sure there is a "right way" but there are many ways to connect to the data.
My suggestion would be to contact a partner company, such as SWK Technologies. http://swktech.com
NetSuite has two main APIs, SuiteTalk and SuiteScript.
SuiteTalk is the Web Services API, which is SOAP based and allows for pulling data from and updating NetSuite. The SuiteScript API is JavaScript based and allows you to customize accounts and export data at the appropriate event during your business process. The term "SuiteCloud" encompasses all APIs and integration tools.
As for documentation, this is mostly only available to clients and partners. If you have a client who provides you with access to their account, you will gain access to the NetSuite Help Center and all relevant documentation.
Your options for integrating with the e-commerce platform depends on the exact platform. This ranges from Webhooks to HTTP requests.
You can't say NetSuite is delimiting developers in any way. It depends on how you look at it. As I see it, NetSuite provides two main method for developers - SuiteTalk and SuiteScript.By this, developer can create his/her own API, define what kind of acces those API should have.
SuiteTalk is SOAP based.
I would suggest using SuiteScript to create your own API using either NS RESTlet or NS Suitelet.
They have the feature for External URL. By sending request to this external URL you can trigger your own custom functions written on the SuiteScript. By SuiteScript, you can create your own API and define your own function. Ie, developer is in full control.
The only problem I see with NetSuite is its higher barrier for entry. There is no way you can access NetSuite Help Centre without having a Client/Partner/Test account.
But obviously, those who need some kind of integration with NetSuite have NS account.

How to put my DialogFlow chatbot with python on line?

I am developing a chatbot using DialogFlow, as my natural language processing handler, and Python as my client.
My application aims to talk with a human in a python environment (I am currently using a Jupyter Notebook), send the request to DialogFlow, get the response, then calculate the data using some python libraries and show the results to the user.
All the process described above is already working.
Now I must to find a way that lets the people uses my chatbot on line.
Here is my problem, I don't know how to model this.
I think I should put my chatbot in a webpage and make it communicate with my python application stored in a server.
Did anybody make something similar?
Given your current architecture, you'll have to do the following:
Write a client for your chatbot in HTML and JavaScript
Write a server in Python that contains your application logic and makes the API calls to Dialogflow
This is a pretty normal architecture for a web application. Given that you're using Python, you might find Flask or Django helpful.
There should be plenty of samples out there that can help you figure out what to do; I just found this blog post that demonstrates how to build a simple chat client/server with Flask and websockets.
If you're willing to change your architecture so that the user interacts directly with Dialogflow, and all of your application logic lives in the Dialogflow fulfillment webhook, you can make use of Dialogflow's Web Demo integration that provides a pre-built chat widget you can embed into an HTML page.

contextual conversation in chat bot using python

So I am making a chat bot. Things like Intent classification,entity extraction and dialog generation are almost done.The conversations are stateless and now i am stuck at implementing context in conversation(meaning chat bot can remember what the user said and respond accordingly ).
Is there any python library to do that?
If not can anyone guide me how can i do that?
I want the context management to be almost same as IBM Watson Conversation.
Thanks
At the present time, deep learning is the state of the art and Tensorflow is the great technology to take advantage of deep learning.
This is an amazing chatbot framework to build a conversational model for your custom chat bot. You should edit this JSON file to create your conversational intents. Moreover, you can edit the JSON file dynamically according to user's messages or information which are shared by user. You can create and develop an architecture for it so you can reach the stateless conversation system.
For example, you can analyze each messages of users by NLP and update the JSON file.
As a summary, you can develop an architecture by using this chatbot framework to create the stateless conversation system.

How do I enable SMS notifications in my web apps?

I have a web application and I would like to enable real time SMS notifications to the users of the applications.
Note: I currently cannot use the Twitter API because I live in West Africa, and Twitter doesn't send SMS to my country.
Also email2sms is not an option because the mobile operators don't allow that in my country.
There are a couple of options.
Get some kind of SMS modem or connectivity and use your own cell phone using smslib. I am sorry I don't provide python interfaces but my experience is Java. The downside is that you will pay the full consumer rate. And you will have to put a cell phone on your data center.
Connect to SMPP gateway. You will have to talk to the mobile operator in order to make this work. There is a library called jsmpp here. Again, I am sorry it is not python.
If it is too much of a hassle you could use an intermediary, which provides HTTP-SMS gateways, like this one. That's easy because you don't need to use SMPP and your system administrators wont bark at you for putting cell phones in the datacenter.
What about using a proper sms gateway. These guys got APIs for several languages:
http://www.clickatell.com/developers/php.php
There is an unofficial Python API too
http://www.arnebrodowski.de/projects/clickatell/
Another SMS gateway with a Python interface is TextMagic. Their Python API is available from the Google Code project textmagic-sms-api-python. They have libraries available for other languages as well; all wrapping a simple HTTPS API.
Code samples from the project website:
How to send an SMS:
import textmagic.client
client = textmagic.client.TextMagicClient('your_username', 'your_api_password')
result = client.send("Hello, World!", "1234567890")
message_id = result['message_id'].keys()[0]
And retrieve its delivery status:
response = client.message_status(message_id)
status = response[message_id]['status']
(Full disclosure: I am the author of the Python wrapper library)
The easiest way to accomplish this is by using a third party API. Some I know that work well are:
restSms.me
Twilio.com
Clicatell.com
I have used all of them and they easiest/cheapest one to implement was restSms.me
Hope that helps.
I don't have any knowledge in this area. But I think you'll have to talk to the mobile operators, and see if they have any API for sending SMS messages.
You'll probably have to pay them, or have some scheme for customers to pay them. Alternatively there might be some 3rd party that implements this functionality.
Warning: extremely elegant solution ahead! (Android app)
If you want to send SMS to any number in as simple of a manner as sending an e-mail:
mail('configuredEMail#configuredDomain', '0981122334', 'SMS message'); // PHP
or even:
echo 'SMS message' | mail -s '0981234567' configuredEMail#configuredDomain.com
or even from a GUI mail client, then read on.
To skip explanations google Evorion SMS Gateway.
What does it do? It forwards e-mail to SMS with a built-in battery saver.
In order to send an SMS you simply send an email to 'configuredEMail#configuredDomain.com' with Subject 'phoneNumberToForwardTo'.
Code contributions welcome.
If your country is in this list, Twilio is an extremely easy API to use :)

Categories

Resources