[asterisk-users] With ARI, is it possible to create (originate) a call and pass both the caller id name and number?

Dan Cropp dan at amtelco.com
Fri Aug 7 11:51:21 CDT 2020


I'm trying to transition from AMI to ARI.

Running into a small hiccup when I try to create (originate a call) with the caller id name and number

I can pass the Name and Number if the name has no spaces in it and it shows up in my PhonerLite application.

curl -v -u asterisk:asterisk -X POST http://asterisk:astersk@localhost:8088/ari/channels/mycallerid.1?endpoint=PJSIP/1003@1003&app=hello-world&extension=1000&context=mycontext&priority=1&channelId=mycallerid.1&formats=ulaw&timeout=30&callerId=Dan<291>

However, when the caller id name has a space in it, I can't figure out how to pass the name and number successfully.  The following only displays asterisk for the number and Dan for the name

curl -v -u asterisk:asterisk -X POST http://asterisk:astersk@localhost:8088/ari/channels/mycallerid.1?endpoint=PJSIP/1003@1003&app=hello-world&extension=1000&context=mycontext&priority=1&channelId=mycallerid.1&formats=ulaw&timeout=30&callerId=Dan Cropp<291>

Here is an example of how we do this with AMI successfully.
Action: Originate
ActionID: S40
Channel: PJSIP/1003 at 1003
Exten: createcall
Context: IS
Priority: 1
Timeout: 60000
CallerID: Dan Cropp <291>
Variable: CALLERID(num-pres)=allowed_passed_screen,TrunkAllocateId=1,OriginateCallId=2
Async: true

Dan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20200807/a56aec37/attachment.html>


More information about the asterisk-users mailing list