have a quick question on iBeacons.
Is there a way the user can capture messages they receive when they
are in a particular range to a beacon? Lets say an iBeacon app is being used
in a retail store, the user walks close to a particular beacon and
gets a message prompt and likes it but when he walks away it goes away
and another message appears. Is there a way for the user to capture
which messages they like and look at it later on even when they are
not in the store r within range to a beacon?
Thank you very much
The iBeacon itself doesn't send any messages to the end user. It just makes a three-part numeric identifier available to the app when the iBeacon is visible through the Monitoring or Ranging APIs. Any messaging directly displayed to the user (through a text field or a notification or whatever) always originates from the app itself, in the use case you describe triggered by the iBeacon being detected.
Because the messages always originate from the app and not the iBeacon, you can simply program the app to save off any messaging for later viewing by the end user.
What you want to achieve doesn't seem to be directly related to ibeacons.
It's more about how you will design your app and features. Surely you can save any kind of messages/notifications for posterior use/visualisation. For example you can store them on a server database or locally using iOS user-defaults of your app.
The same thing happens when you receive SMS or email. An app stores them so you can see later, including the time you received and who sent you.
Related
I'm using Plot Projects service to send geofencing notifications to users of iOS and Android application.
I want to use "dwelling" event to trigger specific notifications when user remains at one specific geofence for some extended time. The documentation states that dwelling event can be used on iOS, but has certain specifics:
Please note that due to restrictions in iOS the notification filter for dwelling notifications is called when the user enters the geofence or beacon region and that the returned notifications are only shown when the user remains in the region for the specified amount of time.
By my understanding, this would mean that the Notification filter gets triggered as soon as user enters the geofence, but the notification, if properly filtered, will be displayed after user dwells there. Filtering logic in my case is done on server-side - iOS app sends notification info to server, and then appropriate logic is applied to decide whether to show notification or not.
So, server-side logic for checking whether to show notification or not would be triggered at the time user trips geofence, but the notification would be shown to the user once he dwells there for some time. In my specific case, in order to properly decide whether to show the notification or not, I'd need the check to be done at the time the user really dwells, and not on entering. My understanding is that this cannot be done on iOS (unlike Android).
Am I right to assume this? If not, what would be the way to achieve a dwell-time filtering check, as opposed to enter-time filtering check?
You're correct about the moment when the Notification Filter will trigger on iOS. This is done because of platform limitations. The filter will be called directly when you enter the geofence. When you want filter out messages, that is indeed the time to do so. There is no way to filter at the time of the end of the dwelling period.
This, as mentioned, differs from the behaviour on Android. There it will be called at the end of the dwelling period.
I would like to create a very simple app. When 2 peoples (who got the app) are geographically very close (20-30-40 meters), the 2 automatically receive a push notification with some infos about the other person. First, is it technically possible ? What would the most efficient way to make it ? Ibeacons ? Bluetooth ?
You can probably do something like what you are describing, however you can't solve it with iBeacon alone, that would just be a single component in the system.
The main parts of the system would be
Mobile app
Physical iBeacons (to let you know when you are close by)
Backend web service (to coordinate between the app)
When a user with your App comes within range of an iBeacon you could have it call up to the web service and provide the iBeacon identifiers. Then you could use that information on the back end to see if another device was also recently with in range. If so, push out a notification.
Just be conservative on your expectations. This would require a number of moving parts, and you should become familiar with the limitations of how iOS background notifications and how iBeacons work.
From Apple's Push Notification Guide:
If the target application isn’t running when the notification arrives, the alert message, sound, or badge value is played or shown. If the application is running, iOS delivers it to the application delegate as an NSDictionary object. The dictionary contains the corresponding Cocoa property-list objects (plus NSNull).
I have implemented this in my app and everything works fine. If the app is in focus, the app gets the message directly. If not active, an alert is shown, the app launches when the user clicks the alert, and finally the app gets hold of the message.
Would it be possible, however, in the case of a message arriving when the app is not active, to get iOS to activate the app and pass the message on without showing any message or requiring any user interaction?
I would like this behavior because the push message from my server only might be of interest to the user, depending on her current position. The app works like this: When it starts, it registers for push and tells my server: I am at this position and would like to be notified when something interesting happens near me. At a later point the server sends a message, but since the user might have moved from the area, I would like the app to check the user's position again, and not bother the user if she now is too far from the original position.
I suppose it would be possible to have a background service that notifies the server about the current position every n minutes, but I fear that this will drain the battery.
Any thoughts on this?
Unfortunately, you can't — in iOS — directly open your app when a notification is received. The user must choose himself to open it via the alert displayed by the system.
However, using the background location is not that battery-unfriendly. It depends on the location accuracy you set for your CLLocationManager object.
All the informations about location accuracy can be found here : Location Awareness Programming Guide
In your case, you may want to use the significant location changes methods or the kCLLocationAccuracyKilometer accuracy for example.
Here is a good tutorial to get started : iOS Multitasking: Background Location
Hope this will help.
I have an app which is tracking the coordinates of the user. I want the user to receive a push notification at a specific longitude and latitude. That means that my device has to track coordinates and make requests even if it's closed.
Is there any way to accomplish this?
Push Notifications can't do this.
CLLocationManager actually has a method, startMonitoringForRegion:desiredAccuracy: to monitor for when a users enters a region and wake your app if needed. See more here. I'm pretty sure this is the system they use for their Reminders app, where you can get a reminder at a specific location. It uses a lot less energy than having your app monitor the location all the time, since the OS can use information like which cell towers or wifi hotspots you are nearby, to figure out if it's even necessary to use the GPS.
Take a look at the document and this
Your app will keep running in the background and receive location updates.Then send local notification to the user. But if the user killed your app manually.The work will not been done.
Within my iPhone application I periodically make calls to a webservice, providing the endpoint with a list of numeric IDs. The webservice then returns information relating to the IDs it receives.
This is all well and good. However, I would like to be able to provide functionality whereby the user will receive a local/push notification when these changes occur, regardless of whether the application is open or not.
I'm just looking for guidance on my options in this scenario. As I see it, there are two main approaches: calculate any data changes on my webserver and send a push notification to all devices, or query the webservice from the device itself.
The second option seems ideal, as not all devices will need each push notification, but I'm unsure as to whether this is possible with the current state of iOS' multitasking APIs. Any advice would be appreciated.
Bad news: it's not possible. Apps can only run in the background for a short period of time after the user has exited unless it fits into a small number of categories (GPS, VoIP, etc).
Web services, unfortunately, do not count. So this would have to be performed on the server side and with push notifications.