IMS Clearwater configuring Application Server - sip

I want to configure application server (in this case Restcomm) to ims clearwater so I added IFC line to /usr/share/clearwater/ellis/web-content/js/app-servers.json. Notice REGISTER SPT method.
"Restcomm" : "<InitialFilterCriteria><Priority>1</Priority><TriggerPoint><ConditionTypeCNF></ConditionTypeCNF><SPT><ConditionNegated>0</ConditionNegated><Group>0</Group><Method>REGISTER</Method><Extension></Extension></SPT><SPT><ConditionNegated>0</ConditionNegated><Group>0</Group><Method>INVITE</Method><Extension></Extension></SPT></TriggerPoint><ApplicationServer><ServerName>sip:192.168.56.101:5080</ServerName><DefaultHandling>0</DefaultHandling></ApplicationServer></InitialFilterCriteria>"
I want to do scenario
ims registration
but red circled flow is not done.
User created in Ellis Gui is registering fine in IMS but in trace I don't see REGISTER request to application server. What I have to do to achieve that flow except adding IFC line? Based on above flow, should Sprout component send independently REGISTER to AS?
Settings in zoiper for Ellis user. zoiper
[EDIT]
After testing I have some observations, i.a.:
1.When I removed INVITE SPT, and set only REGISTER SPT then flow works as I wanted and described above. So how to set few SPT?
"Restcomm-Register" : "<InitialFilterCriteria><Priority>1</Priority><TriggerPoint><ConditionTypeCNF></ConditionTypeCNF><SPT><ConditionNegated>0</ConditionNegated><Group>0</Group><Method>REGISTER</Method><Extension></Extension></SPT></TriggerPoint><ApplicationServer><ServerName>sip:192.168.56.101:5080</ServerName><DefaultHandling>0</DefaultHandling></ApplicationServer></InitialFilterCriteria>"
2.Not clear behaviour I noticed, when I created second server (with INVITE only), then provisioned two numbers via ellis gui, first number set to Restcomm-Register (above), second to Restcomm-Invite (below). On the Restcomm AS I have simple sip servlet app which is triggered on Invite and Register requests. I assumed that first number would only trigger simple app only on Register request but NOT! This number can also trigger Invite method... Why is this happennig if Register iFC only is added for first number? I thought that Invite should be send to build-in MMTel AS). On the other hand second number triggers only Invite method as I want.
"Restcomm-Invite" : "<InitialFilterCriteria><Priority>1</Priority><TriggerPoint><ConditionTypeCNF></ConditionTypeCNF><SPT><ConditionNegated>0</ConditionNegated><Group>0</Group><Method>INVITE</Method><Extension></Extension></SPT></TriggerPoint><ApplicationServer><ServerName>sip:192.168.56.101:5080</ServerName><DefaultHandling>0</DefaultHandling></ApplicationServer></InitialFilterCriteria>"
Both servers Restcomm-Register and Restcomm-Invite are the same server (the same IP) but with different SPT.

Related

How I can send request to the nearest app user just like Uber in flutter

I want to create an application just like Uber using Firebase. I do not under stand how I can show the nearest application user on google map using costume markers and how I can send the request to the all nearest application users at same time just like Uber do.
Since you're already using Firebase, you can use Firebase Cloud Messaging. This is obviously a rather big feature that will envolve lots of sub-tasks, but here's a simplified overview of how it could be:
You have three players involved:
the "Uber user" client app
the "Uber driver" client app
your app server (which could be Firebase Cloud Functions, for a serverless backend)
The data flow could be as follows:
"Drivers" open their apps. This establishes a connection with the server, and keeps the server constantly updated with their geolocation.
A "user" opens his app. This triggers a request to the server sending the user's geolocation.
The server (which knows the realtime location of all drivers) calculates which drivers are near the user, and responds the user request with this data. The user client app can now render a map widget with the drivers locations (for this, you'll probably use a package like google_maps_flutter).
The user clicks a button to request a ride. This again triggers a request to the server.
The server receives the request, and notifies the nearby drivers using Cloud Messaging. FCM has a message type called Data message which is well suited for this; you can send custom data, and the client app will process it however it wants.
The drivers' apps receives this Data Message and render the UI showing there's a ride available. If the driver accepts the ride, this sends a request to the server.
Once the server sees the "accepted ride" request, it sends another message to all other drivers informing the ride is no longer available, as well as sends a message to the user informing the ride has been accepted.
As I said, this is not a simple feature. There are several tricky parts, such as race conditions, and making sure only a single driver accepts a ride. But this should be a high-level overview of how it can be done.
Finally, this schema is a quite technology agnostic; it isn't specific to Flutter. The architecture to have that feature could be implemented like this in pretty much any modern mobile framework - Flutter is just a UI framework.

How to email exception logs at the end of robot run

Email logs only if there was an exception at any point in the run.
I only want this for a specific robot, not all robots under management console.
I know there is an option under management console, but that emails for every robot and every log.I don't want that. Thanks
Add a try step as the very first action of your robot. At the lower branch, add any action to log your error (write file, send email):
Configure each action that may fail as follows:
The special robot property Robot.executionErros will hold the relevant error message. Here's an example:
That being said, I would rather rely on Kofax RPA's logging capabilities - any error gets logged to the logging database. You can then use another robot to get those entries and email send messages. This allows you to use a single robot for sending out email notifications instead of adding above steps to each one of them.

How can I set up a webhook or subscription from Presence Insights?

I have been using IBM's Presence Insights to gather indoor location based information. How can I get Presence Insights to send me updates about location events that are important to me? I would like to perform some action when, for example, a mobile devices enters my "entrance" zone.
You can set up Subscriptions to get an HTTPS POST every time a certain exit/enter/dwell event happens in a zone, group of zones, tag, or group of tags. You will need to provide a callback URL to Presence Insights that will be the endpoint that receives the POST.
You can create a subscription pretty easily within the Presence Insights UI:
Ensure you have a site configured with a floor map, zones, and beacons/sensors in place.
Click on "Management" heading
Click on "Subscriptions" subheading
Click on the blue "Create Subscription" button on the right. Fill in the popup:
The "Webhook URL" is the HTTP endpoint owned by you that will receive the POSTed event from PI. (More on this later.)
Check the boxes for the different events you are interested in (Enter, Dwell, Exit, Timeout)
Username and Password are BASIC AUTH credentials for your "Webhook URL" above.
Select the site name/tag that you are interested in with the dropdowns.
Select a zone tag. You can tag multiple zones with the same tag, or have unique tags for each zone, or a combination of both.
Ensure that "Active" is checked. If you want to disable this Subscription at any point, you can simple uncheck the Active button.
Regarding a Webhook URL - this generally requires a server. You can mock up an endpoint very quickly using Node.js, or my personal favorite, NodeRED. We have example NodeRED flows out there already, see this tutorial: https://github.com/presence-insights/pi-sample-NodeRED/tree/master/Eventing
The idea of Subscriptions is to allow any events that are detected and passed into Presence Insights, to also be shared with additional applications, i.e. A marketing / offer engine, or system to create Mobile Push marketing messages as examples. The data that get passed out of Presence Insights includes the device id, location, and any additional device information that has been included in the device registration document. Again, this could include a phone number, loyalty card number, or any info you wish, which can be both encrypted or not. The Doc' s detail how to set up a Subscription event; Management -> Subscriptions -> Create a Subscription via button -> Set the URL you wish the info to be passed on to { this would be your application } -> then select the location you wish to trigger Subscription event, and event type. ( i.e. You select a complete floor or site, and when an event happens at that site or floor, and subscription event gets created and forwarded out of PI). You can then also focus the event, so may be only when in a zone or such.
Its hard to show an example, but when we do demos, one of the applications that very easy to setup and configure to receive these Subscription events, and then perform some action is the Open Source package 'Node-Red' (nodered.org) which is also available in Bluemix (https://console.ng.bluemix.net/catalog/starters/node-red-starter/). You then create a flow such as ..
Picture of Node-red flow

Skype for Business - Response group SIP headers

We are running Skype For Business 2015 with EnterpriseVoice and want to allow calls coming through response group queues to be forwarded to mobile phones.
We have developed a small app / service to facilitate that through replacement of SIP header names and values according to documentation in
http://blog.greenl.ee/2011/12/30/modifying-sip-headers-managed-sip-application-api/
http://blog.greenl.ee/2013/12/16/response-groups-call-forwarding/.
The replacement seems to work flawlessly, but Skype server still identifies the call as a ‘Team call’ and doesn’t perform simultaneous ring or forward.
Our suspicion is that we replace wrong header details or just one of several needed for S4B to identify the call as a personal call.
Can anyone shed some light on Skype logic regarding this?
Which headers control the Personal / Team call identification?
What are correct Name / Value pairs to replace and with what?
There is already a similar post regarding this, but is't about Lync
Enabling call forwarding for Lync response group
You are talking about 2 different concepts here:
Call forwarding control
As said by the linked question, Ms-Sensitivity or Ms-Target-Class headers are controll if call forwarding is disabled.
So if you want to disable call forwarding to any call, you can add either:
request.AllHeaders.Add(new Header(Header.StandardHeaderType.MSTargetClass, "Secondary"));
or
request.AllHeaders.Add(new Header("ms-sensitivity", "Private-no-diversion"));
and you will disable the call forwarding.
If you want to enable call forwarding, remove the headers (as per the Greenlee blog post).
Lync Client Call presentation
This is controlled by the ms-retarget-reason parameter in the History-Info header.
For response group calls uses a value of acd.
Values that display Call For can be:
acd - Displays Call For and excepts the call to be transferred after call establised.
delegation - Displays Call For.
If you want to remove the Call For display you need to remove the History-Info headers.
The Transferred By display is controlled by the Referred-By header.
If you want to control the names display in the Call For or Transferred By display, you can't from the SIP message. The lync client looks up and displays the information from a lync contact from the sip address. If there is no lync contact, it will only display the sip address only.

How to check Asterisk SIP registration in realtime?

I am running Asterisk 11 and using MySQL realtime. I've used FreePBX previously, and it shows all details how many users are registered in realtime. I can check a user registration if I type show peer username on Asterisk CLI. However, I would like to know whether a specific user has registered SIP server or not in realtime.
Example
UserA - registered
UserB - unregistered
UserC - registered
I checked sip_buddies table in MySQL, and it only shows regseconds. I couldn't figure out whether a user is registered or not with this information. Does anyone how to check user's registration in realtime?
You have 3 options
1) (bad one) do command "sip show peers" (rtcachefriends has to be set to yes)
2) (better one) create an event listener, which will listen for an event via AMI and store that info.
3) (db variant) Set
rtupdate=yes
rtautoclear=yes
and check in db registration time. Downside - a lot of db writes.
This is not the specific answer, but is a relevant solution to different Asterisk setups. Some deployments use openSIPS as a clients registration proxy (it's better than the baked in SIP capabilities of Asterisk, even with the new pjsip stack). In this case "sip show peers" will be empty. In that case you can use the Management Interface via the opensipsctl application. opensipsctl ul show on the proxy will show all clients registered to the proxy.