I installed the server on OS X and started it. I need to have 2 different users connect to the server and 1 could call another. Can I do for these purposes do ARI?
1 answer
ARI is needed to manage asterisk from third-party applications (on different PLs). If you just need to make a call between two users, configure two peers in sip.conf:
[user1] type=friend username=user1 secret=user1 host=dynamic disallow=all allow=ulaw context=test [user2] type=friend username=user2 secret=user2 host=dynamic disallow=all allow=ulaw context=test In extensions.conf you register dialplan:
[test] exten => user1,1,Dial(SIP/user1); exten => user2,1,Dial(SIP/user2); Perform sip reload and core reload to read configs. Clients from softphones connect to the server ip with asterisk on port 5060 (default for SIP, can be changed in sip.conf). Logins and passwords for them user1 / user1 and user2 / user2. In theory, this should be enough for a simple call.
- I forgot to mention that I need it on PL (Objective C / Swift and Java) - Gikas
- Who is the initiator of the call? A third-party application that wants to connect two subscribers or one calls, then an application is called that dials to the second? - carapuz
- In theory, in one application should be visible to other subscribers connected to the server. The user calls through the application to the connected subscriber and this subscriber in the same application receives the call - Gikas
- Asterisk currently has three interfaces for interacting with third-party applications: AMI, AGI, ARI. Calling AGI scripts is used when the call processing logic is rather complicated in the description in the language of the configuration of a dilaplane, or when some possibilities are not available at all. AMI allows you to initiate calls from the side, keeps track of all sorts of events. ARI is a mixture of AGI and AMI. - carapuz
- If I understand correctly, you need a wrapper application for the SIP client. Call, respectively, through SIP is carried out. Caller list, call initialization with ARI - carapuz
|