We have an older application using AMI. It can send the audio to our websocket server.
Kudos to those who worked on this new feature!!!
Action: AGI
ActionID: C59
Channel: PJSIP/100-00000003
CommandID: C59
Command: EXEC Dial WebSocket/1/c(slin16)v(urlparamname1=urlparamvalue1,urlparamname2=urlparamvalue2),30
- Is it possible for the Dial to be used for this as well?
- If so, would the channel value be?
WebSocket/1/c(slin16)v(urlparamname1=urlparamvalue1,urlparamname2=urlparamvalue2)
I haven’t attempted a Dial via ARI before, but ran some tests by hand.
I tried simulating manually via curl requests and it wasn’t working for me. Then, I decided to verify I’m passing everything correctly via the curl by dialing a phone and also ran into problems.
Guessing I’m misunderstanding how to pass the parameters via ARI?
AMI, the following does call my phone 1005 on the PJSIP endpoint 1005
Action: AGI
ActionID: C60
Channel: PJSIP/100-00000003
CommandID: C60
Command: EXEC Dial PJSIP/1005@1005,30
However, when I try this via curl/ARI it doesn’t work (yes, I have the call in Stasis)
curl -v -u user:password -X POST “http://myip:myport/ari/channels/1756934869.22/dial?channel=PJSIP/1005@1005&timeout=30”
For comparison, I can start playing music on hold using a similar request
curl -v -u user:password -X POST “http://myip:myport/ari/channels/1756934869.22/moh?mohClass=1”
3) Any suggestions on what I am doing incorrectly via the ARI request? Is it not possible to use ARI to dial a number?
From the API, it looks like it wants to dial an existing channel so I tried that and it also doesn’t work.
curl -v -u user:password -X POST “http://myip:myport/ari/channels/1756934869.22/dial?channel=1234567890.46&timeout=30”
Any thoughts/suggestions?
Dan