简体   繁体   English

钛:没有Cloudpush的Android设备令牌

[英]Titanium: Android device token without Cloudpush

Is there anyway to get device tokens without using Cloudpush modules. 无论如何,不​​使用Cloudpush模块就可以获得设备令牌。 All I'm interested in is getting tokens and store onto my server and then I can push notification to registered devices. 我只想获取令牌并将其存储到服务器上,然后将通知推送到已注册的设备。

I have tried to use it Cloudpush module from this link http://docs.appcelerator.com/titanium/3.0/#!/api/Titanium.CloudPush 我尝试通过此链接http://docs.appcelerator.com/titanium/3.0/#!/api/Titanium.CloudPush使用它Cloudpush模块

I followed these steps: 我按照以下步骤操作:

1) First Step : Open this link https://developers.google.com/console/ than login with you account. 1)第一步:打开此链接https://developers.google.com/console/ ,然后使用您的帐户登录。 Create a new project 创建一个新项目

i) "Creating a Google API Project", 
ii)"Enabling the GCM Service"
iii)"Obtaining an API Key"

Image snap link : http://1.bp.blogspot.com/-AKAcUDtW0gg/UlK8rcpqUQI/AAAAAAAACuI/aq89OFZc2C4/s1600/all_steps.png 图片快照链接: http : //1.bp.blogspot.com/-AKAcUDtW0gg/UlK8rcpqUQI/AAAAAAAACuI/aq89OFZc2C4/s1600/all_steps.png

2) Second Step : Click on this link https://cloud.google.com/console#/project You can found you project that you already created. 2)第二步:单击此链接https://cloud.google.com/console#/project您可以找到已经创建的项目。 Just Click on that and you found the Example: Project Number: 91060sdsdgsd 只需单击该按钮,您就会找到示例:项目编号:91060sdsdgsd

3) Third Step : Now next step open this url https://my.appcelerator.com/apps Login with your appcelerator account where you want to configure this vcm. 3)第三步:现在下一步打开此URL https://my.appcelerator.com/apps使用您要在其中配置此vcm的appcelerator帐户登录。 Click on your project than at the top side there are two option (Production/Development). 单击您的项目,然后在顶部有两个选项(生产/开发)。 Click on Development. 单击开发。 Now the main menu box will open in that there is 2nd (Second) tab click on that. 现在将打开主菜单框,在该菜单上单击第二(第二)选项卡。 Now you found in that page Android Push Configuration please fill this both fields i) Google Cloud Messaging(GCM) API Key: ii)Google Cloud Messaging (GCM) sender ID: 现在,您在该页面中找到了Android Push Configuration,请同时填写以下两个字段:i)Google Cloud Messaging(GCM)API密钥:ii)Google Cloud Messaging(GCM)发送者ID:

However all I'm getting is Failed receiving GCM SenderId. 但是,我得到的只是接收GCM SenderId失败。

As you already know the process to get keys/etc, so I wont rewrite it. 您已经知道获取密钥/等的过程,所以我不会重写它。

You asked to fetch the device token without Cloudpush , yes it can be done and you have to use a GCM module for this process. 您要求不使用Cloudpush来获取设备令牌,是的,可以做到这一点,并且您必须使用GCM模块进行此过程。

Following info will be helpful in using module : 以下信息将有助于使用模块:

Hope it helps. 希望能帮助到你。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM