Closed digas closed 8 years ago
Ok just forget it , i found the answer on the index.js file following the example there ,
var namiLib = require(__dirname + "node_modules/nami/src/nami.js");
Anyway still not in the good path 🈂️
response: 'Success', actionid: '0', message: 'Authentication accepted', events: [] } /Volumes/Wow/digas/shell/Repos/Django/webconference/node_monitor_calls/test.js:30 nami.send(new namiLib.Actions.CoreShowChannelsAction(), function(response){ ^
TypeError: namiLib.Actions.CoreShowChannelsAction is not a function
at Nami.
You should:
var namiLib = require('nami');
Once nami is in your package.json. The example also works fine:
node src/index.js 127.0.0.1 5038 user secret
Please confirm me this on the example you try to call a function : nami.send( new namiLib.Actions.CoreShowChannelsAction(),
But i only found on messages/actions.js CoreShowChannels() function and if i change it on the example it works ... is it ok ?
Hey, is just me or there is no definition of namiLib on the code ? Tried to implement the simple quickstart example and (the user on manager is ok so i know it can login) node complians with this.... can you give me a light ? thanks
nami.send(new namiLib.Actions.CoreShowChannelsAction(), function(response){ ^ ReferenceError: namiLib is not defined
sorry let me give you some versions: nami 0.7.1 node v4.4.0 (and tested it on v0.12.2 too) Asterisk 11.21.0