Estimote Proximity



I’m having a problem with estimotes proximity. I have downloaded the package example for my projeto (after create a new app thrown the estimote Cloud) and put in my phone to check if it work or not.

What i check is that the range, by default, is set to 3.0, but when i put the app on my phone, a received both of Hello notification and Goodbye notification. The GoodBye notification must open only after a get out of this range (3). What is wrong?

I didnt change anything, a just download the app and create the .apk to verify the funcionality.


class MyApplication : Application() {

val cloudCredentials = EstimoteCloudCredentials("proximitypush-cwj", "KEY_OF_APP")

fun enableBeaconNotifications() {
    val notificationsManager = NotificationsManager(this)


class MainActivity : AppCompatActivity() {

override fun onCreate(savedInstanceState: Bundle?) {

    val app = application as MyApplication

                    onRequirementsFulfilled = {
                        Log.d("app", "requirements fulfilled")
                    onRequirementsMissing = { requirements ->
                        Log.e("app", "requirements missing: " + requirements)

                    onError = { throwable ->
                        Log.e("app", "requirements error: " + throwable)


class NotificationsManager(private val context: Context) {

private val notificationManager = context.getSystemService(Context.NOTIFICATION_SERVICE) as NotificationManager
private val helloNotification = buildNotification("Hello", "You're near your beacon")
private val goodbyeNotification = buildNotification("Bye bye", "You've left the proximity of your beacon")

private fun buildNotification(title: String, text: String): Notification {
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
                "content_channel", "Things near you", NotificationManager.IMPORTANCE_HIGH))

    return NotificationCompat.Builder(context, "content_channel")
            .setContentIntent(PendingIntent.getActivity(context, 0,
                    Intent(context,, PendingIntent.FLAG_UPDATE_CURRENT))

fun startMonitoring() {
    val notificationId = 1
    val proximityObserver = ProximityObserverBuilder(context, (context as MyApplication).cloudCredentials)
            .onError { throwable ->
                Log.e("app", "proximity observer error: $throwable")

    val zone = ProximityZoneBuilder()
            .onEnter {
                notificationManager.notify(notificationId, helloNotification)
            .onExit {
                notificationManager.notify(notificationId, goodbyeNotification)




Someone can help me with this issue?