How to upload in muy website the watson chatbot, please - ibm-watson

I already finish the chatbot, but I have no idea of how to upload it to my website, please, help :)
I tried to look for some code to send to the IT developers, but cannot find it :( And the IT guys are too busy, so I'ld like to get the answer by myself so I can send it to them if I'm not able to apply it. Thank you. (Btw: I'm not an IT person... :( )

Where to start?
The dialog / conversation part of your Watson Assistant part chatbot is available as a REST API.
There are several deployment options available. For the more popular choices the Assistant tooling provides integrations. So if you want to access your chatbot through slack, or facebook messenger or on a word press site then look at the documentation as to how - https://cloud.ibm.com/docs/services/assistant?topic=assistant-deploy-integration-add
If you are developing your own application or web-page, then your developers will need to design the User Interface and handle the quirks of your dialog. eg. Decide how to display images, options etc., all from the API, which is essentially only message in, response out - https://cloud.ibm.com/apidocs/assistant-v2#send-user-input-to-assistant. There are samples available for them to base from - eg. https://github.com/watson-developer-cloud/assistant-intermediate

If your website is using Wordpress, there is a very easy way to deploy the chatbot to it using a wordpress plug in - https://wordpress.org/plugins/conversation-watson/

Related

Full-fledged Watson Assistant integration for testing

I have implemented a chatbot with Watson Assistant. There is a preview link integration available but this has the disadvantage that HTML and emojis are not supported. Using this and this tutorial I can integrate my bot into Facebook Messenger and Skype. But this only works on local devices and I cannot easily distribute it to other people for testing.
What I would like to do is to let several people test my chatbot simulatenously on their own smartphone with full functionality (HTML rendering, emojis). The integration should be very easy for them, for example just opening a webpage or just adding the bot to their Facebook Messenger or Skype (not so many steps as in the above links).
Is this possible?
You can fork this repository and replace the credentials with yours:
https://github.com/watson-developer-cloud/assistant-simple
Then host it wherever you prefer (you can host it on IBM Cloud as part of the Lite account) and share the link with the people you want to test it.

React Native Upload to YouTube

I am trying to upload a video that I take locally using react native camera and then send it to youtube for processing and then want to display that video on a react.js web dashboard.
We have tried using fetch-blob to upload the video and cloud firestore to store the video. We are not sure at a high level on how to go about the uploading to youtube. I know there is upload docs, however can we physically go about uploading straight from our react-native project to youtube, or would we have to upload to a database such as firebase and then use a cloud function to send it to youtube? Has anyone attempted this? The other alternative is that we can upload to S3 and then use AWS cloudstream to play back but that seems like overkill if there is a simple youtube upload that we can use. Do we have to authenticate a user to youtube before it would work? We do not want anyone having to log into a google account. We are hoping just to have an application created with youtube that we can upload to our channel.
Thank you!
Answer
You can absolutely upload a video to YouTube in many different ways. You mentioned a few options and I will line out how those could work for you.
Do we have to authenticate a user to youtube before it would work?
You will have to authenticate to YouTube in order to upload to a YouTube account. You could very well have one account for your app to use and when your users make videos the app could upload them directly to that account. I do highly advise against that though. Google is not very forgiving and the second someone uploads something to violate Google Policies I suspect you will be banned.
That leaves me to believe the best way here would be to use Auth0 to authenticate users and upload to their accounts. Otherwise maybe look into other options.
Possible Options
Option 1
It might be possible to upload all the videos to one YouTube account and make them all private. Then retrieve those videos and play them on your own site. Possibly something like that could work but it is probably a long shot. That could at least keep you from getting banned because of a user violating Google Policies.
Option 2
Another option would be to make one YouTube account. Save the videos to your server when the users creates them from your mobile application. Then have a waiting period for the video to post to YouTube in order for you and your team to have time to approve them.
At least this way you can use YouTube and have one account, but not take the chance of any repercussions from the videos people are posting.
Problem
How to upload a video from your mobile app using React Native to youtube.com
Solution 1
Upload straight from React Native. You can Use the Google APIs to upload directly to youtube. Google has an extensive API. You will have to create a Google API account and make sure to activate the APIs you want to use. Here is some information I found using the Google Javascript API to work with Youtube.
If you go to this link you can see some information on the scopes of this API.
Here is one scope mentioned on that page.
https://www.googleapis.com/auth/youtube.upload
Using Gogoles APIs you can upload videos directly to the youtube account.
Solution 2
The second solution is to post the video to your server, then once it hits the server use some other server side language to interact with Google's API. This could come in handy for other reasons. Like if you are better with a language other than JavaScript. For example Python might be your favorite language. In that case here is a Python Github repo that does just what your trying to do.
You could very well implement the repo mentioned above to your server and post the video you create from your phone to the server. Allowing the Python script to handle posting the video to YouTube.
Side Note
I do not think Firebase or really any database is necessary for the task you are trying to accomplish. Unless there are other requirements to your problem you have not mentioned.

Gmail API Tutorial only returns Labels

I've recently been trying to implement the Javascript quick-start guide on the official Google Dev page, which can be found here:
https://developers.google.com/gmail/api/quickstart/js
The example is meant to read your Gmail inbox and display the last 10 emails on your html page. I've gone through the example but after I grant permissions in my web browser, I only see a list of the "labels" present in my inbox with no emails/email content. I have created a new custom label in my Gmail inbox and this new label is view-able on my html page, which to me suggests that my connection to the Gmail API is fine.
However, I have not used Python like the example suggests. My html file is currently being hosted on 000WebHost so I figured I don't need to use Python. The reason I came to this conclusion is because the tutorial explains that Python is used to host a web server, as I'm using 000WebHost I think I don't need to host this web server.
This could be my issue if I've misunderstood what Python is really needed for here?
Other than that, I'm wondering if there are any other glaringly obvious issues to someone experienced with the gmail API?
Any advice would be appreciated.

Google Calendar Api Documentation better than the official V3

Please I want to create Event in Google Calendar API but the documentation official is BAD I cant use it .. And someone here who can help me please!! Sorry with my english but I speak spanish!
I agree...
This helps a bit: Google Calendar Events
Depending on the process you are using, there are few examples for using asp.net and the service account option. I successfully created events via service account with granting domain-wide access. With this you just need to create an app, then service account for the app and follow the domain wide delegation steps on the google documentation pages. This option is great if you have an app that needs to create events without having to authenticate the user.
For working code and more info you can see what I used at-
Google API Calender v3 Event Insert via Service Account using Asp.Net MVC
What is "bad" about the documentation? (Don't just complain; provide actionable feedback.) In the v3 docs, check out the reference section on creating events. There is even sample code in Java, Python, PHP, and Ruby to help get you started just below the reference. In addition, below the sample code is the APIs Explorer where you can issue requests with appropriate payload to the API and see the HTTP response to ensure you're calling the API correctly and receiving the data you requested. If there's any additional way for us to improve the docs, please let us know!
UPDATE (Sep 2015): I created a blogpost and video that walks through some pseudocode (well, it's Python) for creating events. There are examples in most other languages too.

How to track if browser is Silverlight enabled

I'm trying to get some stats on how many of the visitors to our website have Silverlight enabled browsers.
We currently use Google Analytics for the rest of our stats so ideally we'd like to just add 'Silverlight enabled' tracking in with the rest of our Google Analytics stats. But if it has to get written out to a DB etc then so be it.
Nikhil has some javascript to Silverlight tracking to Google Analytics. I have tried this code but Google Analytics doesn't pick it up.
Does anyone have any other ideas/techniques?
In case you missed it, there's a link to a more detailed article as well in the comments: http://blogs.msdn.com/jeffwilcox/archive/2007/10/01/using-google-analytics-with-rich-managed-web-applications-in-silverlight.aspx
Edit: As David pointed out, this article covers the reverse scenario more (how to write your silverlight app so that it plays well with Analytics).
I think you answered it yourself. The page you are linking to does just that: detect which version of Silverlight the user has (not if s/he installs it). From the page:
After a little poking around, I found that Google Analytics has support for reporting a user-defined field.
...
Basically this detects the presence of Silverlight, and if its available, it records the version as the value of the user-defined field. Now your analytics reports will have one of three values: "(not set)", "Silverlight/1.0" or "Silverlight/2.0".
#Vaibhav
The Using Google Analytics with rich (managed) web applications in Silverlight article is very interesing but is more focused on how to get your Silverlight app to send messages to Google Analytics.
#Cd-MaN
Yeah, I thought that too but I have tried running my page with Nikhil's javascript and Google Analytics didn't pick it up. But I could have screwed something up somewhere.
I'm just interested to know if anyone else has managed to do this (track Silverlight-ness) successfully.
I've written a lightweight Silverlight library that helps make it easy to integrate Google Analytics in your silverlight app. You can grab download the code or binaries here.
I think the code posted on Nikhil's blog is out of date if you are using ga.js and not urchin.js.
The use of the global function __utmSetVar() is replaced by the tracker method _setCustomVar()
http://code.google.com/apis/analytics/docs/gaJS/gaJSApiBasicConfiguration.html#_gat.GA_Tracker_._setCustomVar

Resources