node.js lib for Fast AGI (Asterisk Gateway Interface) server
voicer - AGI voice recognizer for Asterisk (use Yandex and Google speech recognizers)
lcr-finder - least cost router for Asterisk
npm install pcm-solucoes/ding-dong-pcm
const AGIServer = require('ding-dong-pcm');
const handler = async (context) => {
var variable = await context.onEvent('variables')
console.log(variable)
await context.setVariable('RECOGNITION_RESULT', 'I\'m your father, Luc');
await context.end();
};
const agi = new AGIServer(handler, {
debug: true,
port: 3000
});
agi.init()
[default]
exten = > 1000,1,AGI(agi:https://localhost:3000)
see API.md