node-ari-client icon indicating copy to clipboard operation
node-ari-client copied to clipboard

can i make a call to an extension using node-ari-client (ARI APIs)?

Open sadeghrz opened this issue 7 years ago • 1 comments

hi gays i am new in asterisk and this question make me in problem. can i make a call to an extension using node-ari-client (ARI APIs)? if yes tell me how and if no give me a key for do it using api. thank you.

sadeghrz avatar Nov 14 '17 13:11 sadeghrz

Yes you can. Use the /channels/create endpoint or Channel().originate() method

client.Channel().originate({
    endpoint: 'PJSIP/+123456@siptrunk', formats: config.get('rtpServer.format'), app: ariConfig.appName,
}).then(() => {
    console.log('made a call to +123456!')
});

vcidst avatar Apr 29 '22 09:04 vcidst