Appcelerator钛Android推送通知GCM失败? [英] Appcelerator titanium Android push notification GCM failure?
问题描述
我已经在Appcelerator工作室的新项目中为Android和IOS设置了推送通知,IOS工作正常,但是android并不是,我的问题是android设备令牌已成功获取并注册,但是当我从Appcelerator工作室IOS在Android失败时成功。
以及创建的API键:
,并且我在Appcelerator ASC中使用了API密钥:
我不明白为什么我可以使用Android设备令牌,但我无法发送推送通知?
$ b $我发现解决方案文件的appcelerator没有更新所以在这里你有什么
推送适用于Android设备的服务:
使用Firebase WEB API KEY
和项目ID
https://console.firebase.google.com/?pli=1
获取项目编号(作为发件人ID)从您的Firebase控制台中的JSON文件和Web API KEY(作为GCM API密钥)。现在,将您的仪表板配置为推送通知
http://docs.appcelerator.com/platform/latest/#!/guide/Sending_and_Scheduling_Push_Notifications
i've setup push notification for Android and IOS in new project in Appcelerator studio , the IOS working fine , but the android not , my issue is the android devices token is successfully taken and registered but when i send a push from Appcelerator studio IOS success when Android failed.
I've enabled this API's in google developer console .
and created API key :
and i used the API key in Appcelerator ASC :
i don't understand why i can take the Android device token but i am not able to send push notification ?
i found the solution the document of appcelerator is not updated yet
so here what you have to do
try the following sample code for devices registration :
https://gist.github.com/MotiurRahman/68bb7aad307901805b5f
Then Configuring push services for Android devices :
With Firebase WEB API KEY and project ID
https://console.firebase.google.com/?pli=1
Get project_number (as Sender ID ) from JSON file and Web API KEY( as GCM API key ) from your firebase console.Now configure your dashboard for push notification
http://docs.appcelerator.com/platform/latest/#!/guide/Sending_and_Scheduling_Push_Notifications
这篇关于Appcelerator钛Android推送通知GCM失败?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!