huawei-mobile-services - 华为移动服务推送套件 907122036 : no right API call

标签 huawei-mobile-services huawei-developers huawei-push-notification

我想使用 Push Kit..我的配置或设置有问题吗?

环境:

手机型号(设置 > 关于手机):ANA-NX9 华为 P40。

EMUI版本(设置>关于手机):11.0.0

HMS Core版本号(设置 > 应用 > 应用 > HMS Core):6.1.0.314 SDK版本号

(应用级 build.gradle 文档):24

日志: **错误/异常:{"framesToPop":1,"nativeStackAndroid":[],"userInfo":null,"message":"907122036: 没有权利","code":"907122045"}

每当我尝试通过 HmsPushInstanceId.getToken('')** 获取 token 时都会出现上述错误**

enter image description here

最佳答案

基本上,如果未启用华为推送服务,就会出现此错误(907122036)。详情参见Getting Started检查应用是否启用了相关服务。

Result Code reference

检查您是否具有“管理 API”的启用权限:转到“项目设置”>“管理 API”并启用 Push Kit。

How can I check whether HUAWEI Push Kit is enabled for an app? 登录AppGallery Connect,选择需要检查的应用,点击管理API,检查是否开启HUAWEI Push Kit。

检查服务状态参数。如果值为Enabled,则表示该应用已启用华为推送服务。

React native push kit reference sample code

确保您使用的是React Native Push Plugin,下载HMS Core SDK包并本地集成。

集成过程请引用React Native开发指南。 latest plugin .

编码愉快!!

关于huawei-mobile-services - 华为移动服务推送套件 907122036 : no right API call,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/71044045/

相关文章:

java - android.app.RemoteServiceException : Bad notification posted on huawei Y6

android - 华为,logcat 没有显示我的应用程序的日志?

huawei-mobile-services - json int数据类型自动变为double

android - 从 AppGallery Connect API 获取错误代码 204144647,消息为 "The new service has can' 无法编辑服务,无法更新

android - com.huawei.hms :push:5. 3.0.301 中不推荐使用 "AGConnectServicesConfig"类

android - Push Kit 什么时候会包含 android :exported attributes required for Android 12?

Python - 华为重启脚本

android - 找不到具有两个不同维度的默认 Activity

flutter - 如何使用Flutter华为Push Kit插件获取推送通知点击事件?

php - 如何验证华为X-HW-SIGNATURE?