How to get Device Token (for Android) to test push notifications from Test devices in Push Woosh

Comments

6 comments

  • Avatar
    Dmitry Dyudeev

    Hello,

    Actually, pretty much all you need in order to retrieve the device's push is any logcat tool.

    There is a logcat tool in the Android SDK that you can download on android.com.

    You should simply open the monitor.bat file, connect your device to the PC and allow USB debugging in the Android settings. Android push tokens always start with "APA91", so it is quite easy to locate them.

  • Avatar
    Francisco

    Is there any alternative method to get the token on code? E.x.: if you need to assign the token to a remote database registered user

  • Avatar
    Dmitry Dyudeev

    Hello,

    Yes, of course there is. You should use the corresponding method from our SDK: for instance, on Native Android, you can use getPushToken method, as you can see here.

  • Avatar
    Francisco

    Perfect! In Native Android there are lot of methods, that doc is gold. Now, I'm on a Titanium Appcelerator project, and there's no method like getPushToken. I made a suggestion to include it on the following suggestion: https://community.pushwoosh.com/questions/1009/get-device-token?page=1&focusedAnswerId=1037#1037

    Thanks!

  • Avatar
    Dmitry Dyudeev

    I strongly apologize for the inconvenience! My bad, I missed your response.

    We haven't published the module yet, but you can download it here. The method is exactly the same - "getPushToken".

  • Avatar
    Francisco

    Perfect! The method now is defined ;) Thanks! Please upload it to github and notify in this thread to people be informed, thanks.

Please sign in to leave a comment.