Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var DiscoveryV1 = require('watson-developer-cloud/discovery/v1');
- var discovery = new DiscoveryV1({
- username: '{username}',
- password: '{password}',
- version_date: '2016-12-01'
- });
- discovery.createCollection(('{environment_id}', '{collection_name}', '{description}' '{configuration_id}'), function(error, data) {
- console.log(JSON.stringify(data, null, 2));
- });
- var params;
- params = {description:'test',collection_name:'name test',environment_id:'xxxxxxx',
- configuration_id:'xxxxxxx'};
- discovery.createCollection(params, function(error, data) {
- if(error){
- console.log(error);
- }
- console.log(JSON.stringify(data, null, 2));
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement