2

I read this link https://www.smartface.io/developer/guides/advanced/push-notifications/ then I used the fallowing code:

 function Global_Events_OnStart(e) {
        Notifications.remote.registerForPushNotifications({
            OnSuccess : function () {
                alert("Success");    
                alert(Notifications.remote.token);
            },
            OnFailure : function () {
                alert("Fail");
            }
        });
    }

I published the app However but I am getting an empty string when I use

  alert(Notifications.remote.token);

I should get a token instead because I want to use it to send a notification using http://api.smartface.io/api/PushNotification/Send/{access_token}

Note :

 alert("Success"); 

is working

How can I get the token?

1 Answers1

2

I also asked many times but no any reply from smartface support support@smartface.io but no any answer. Probably there is a bug with smartface 4.5. Previous versions were working by following guide that you gave. You may ask them may be they reply for you!

Alex Guba
  • 134
  • 1
  • 10