Advertisement
Guest User

Untitled

a guest
Oct 8th, 2017
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. var ConversationV1 = require('watson-developer-cloud/conversation/v1');
  2.  
  3. var conversation = new ConversationV1({
  4. username: '<username>', // service username not your email!
  5. password: '<password>', // service password
  6. version_date: ConversationV1.VERSION_DATE_2017_05_26
  7. });
  8.  
  9. conversation.message({
  10. input: { text: 'What's the weather?' },
  11. workspace_id: 'c9bfac7e-a7fa-4fe0-9b0d-e10f147209c8'
  12. }, function(err, response) {
  13. if (err) {
  14. console.error(err);
  15. } else {
  16. console.log(JSON.stringify(response, null, 2));
  17. }
  18. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement