Skip to content

horeaporutiu/REST-API-Tutorial-IBM-Watson

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

REST API Tutorial - IBM Watson

This repo contains the code to use Watson conversation, tone analyzer, and language translation APIs. Please refer to youtube tutorials for full explanation of the code to use Watson APIs.

Simple to use

Before you get started, you'll need a couple things.

  1. Free IBM Cloud Account, to create Watson Service Credentials (Username and Passwords used to authenticate your API call)

  2. NPM (Node package Manager)

  3. Login to IBM Cloud Dashboard

Instant Access to Watson

  1. Create your credentials for the service you want to use (Language Translator and Tone Analyzer for this tutorial).

1H1HXM

  1. Add your credentials by modifiying the 'Username and Password' variables at the top of either translate.js or tones.js based on which API you want to use.

9NqBZy

Install Dependencies

If you cloned the repository, to install all the required npm packages, run: npm install
Otherwise, run: npm install request and then: npm install http

Get the output

To see the output for the Language Translator API, add the credentials and run: node translate.js

To see the output for the Tone Analyzer API, add the credentials and run: node tones.js

Debugging

  1. If you get an error such as 'Error: Cannot find module 'request' simply run: npm install request
  2. If you get an error such as 'Error: Cannot find module 'http' simply run: npm install http
  3. If you get 404 error, usually the credentials are wrong. Check your credentials first, and if that doesn't work, try deleting the instance and then re-creating it.

About

Code based on Youtube Tutorial (Link attached). Learn to use Watson conversation, language translation, and tone analyzer. - Discovery coming soon :)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published