ApiException: 907122036: no right - huawei-mobile-services

I'm trying to create a special version of my app for Huawei App Gallery, this means replacing Firebase Cloud Messaging with Huawei Push Kit.
My app's failing to obtain a token with this exception:
I HMSSDK_HmsClient: receive msg status_code:0, error_code800100000, api_name:push.gettoken, app_id:102999567|, pkg_name:org.kman.test1.huawei, session_id:*, transaction_id:102999567ttoken20201001165618936966550, resolution:null
E HMSSDK_HmsInstanceIdEx: TokenTask failed, ErrorCode: 800100000
E HMSSDK_AutoInit: Push init failed
E HMSSDK_AutoInit: com.huawei.hms.common.ApiException: 907122036: no right
E HMSSDK_AutoInit: at com.huawei.hms.opendevice.a.a(ErrorEnum.java:272)
E HMSSDK_AutoInit: at com.huawei.hms.opendevice.k.doExecute(GetTokenTask.java:58)
E HMSSDK_AutoInit: at com.huawei.hms.opendevice.k.doExecute(GetTokenTask.java:34)
E HMSSDK_AutoInit: at com.huawei.hms.common.internal.TaskApiCall.onResponse(TaskApiCall.java:190)
According to Huawei documentation, this error ("no right") means that Push Kit is not enabled for the project. However it is enabled, I just checked.
I ran into this with my main work project where I'm adding AG support and also same exact issue with a small test app.
Main work project App ID: 102982583
Package: org.kman.skymail.huawei
Small test project App ID: 102999567
Package: org.kman.test1.huawei
I have done all (it seems) the other steps: adding agconnect-services.json, enabling plugin 'com.huawei.agconnect', creating a special upload certificate, uploading an .aab, adding sha-256 hashes to Project configuration, adding push_kit_auto_init_enabled to the manifest, creating a subclass of HmsMessageService.

Check whether HMS push kit is enabled properly like below image:

Login to app gallery connect, go to My Projects. Select your project. Select Manage API , and enable push kit.
For details, please refer to Enabling Services.

This error code means the service is not enabled in AppGallery Connect.
Please check whether you have enabled the Push Service.
You can follow the guide below to check:
Sign in to AppGallery Connect and select My projects.
Find your project from the project list and click the app for which you need to enable a service on the project card.
Click the Manage APIs tab and toggle the switch for the service to be enabled.
For more information, see docs.

Related

Is there anything wrong with Unity GPGS Production Setting?

Currently, my Unity Android app that I uploaded as a production on Google Play has a big problem.
We started Google As advertisement and checked the inflow of users (installation of 1,597),
However, there are only 67 users who have actually accessed it...
I downloaded my app that I uploaded to Google Play directly and logged in with my Google account, so there was no problem, and I asked my friend to download and run the app, so there was no problem logging in.
The predictable problem is that due to the number of concurrent users, many users are unable to access when starting the advertisement, or something seems to be wrong with my GPGS setting.
Please check the possible problems and the image of my GPGS setup.
**Setting **
Unity Ver : 2021.3.8f1
GPGS Plugin : 0.10.14
State
Upload Google Console Production
Google Console -> Play Games Services -> Setup And Management -> Configuration -> Publish Complete
Create 3 Google Cloud Platform OAuth Clients
-> Upload key, app signature key, server
1. Suspected Problem 1
If the AndroidManifest.xml Package Name is different from the package name of the Google Console, can the Production user not access it?
Unity -> PlaySetting -> Identification -> Package Name is entered as the package name of the Google Console, but AndroidManifest.xml Package Name is marked as package="com.google.example.games.mainlibproj" and modified it directly to the package name of the Google Console, but it was restored again.
enter image description here
enter image description here
(If it is a problem and you need to check the Unity error list, you can attach it later)
2. Suspected Problem 2
Can't the user access because Unity's keystore certificate is set to upload authentication signature, not app authentication signature?
enter image description here
3. If you have any other problems, please give us your opinion.

Implementing google login flutter gives 12500 error

I implemented google login in flutter without using firebase in flutter (google cloud console). It was working in apk then later I needed push notification service for which I used firebase (fcm token and all) then I released the app to playstore but google login does not work. I keep getting apiexception error. Has anybody faced this issue? if yes any help would be highly appreciated.
I do not have a specific answer to your problem but I have also faced this problem once, I accidentally resolved it though.
But Error 12500 is a general error code that may occur when attempting to use the Google Sign-In feature and is caused by a few potensial issues:
An issue with the SHA-1 fingerprint of your app's signing
certificate: To use Google Sign-In, you need to configure your app's
SHA-1 fingerprint and package name in the Firebase console. Make
sure that the fingerprint and package name you have configured in
the Firebase console match the ones you are using to sign your app.
An issue with the Google Services configuration file: Make sure you
have properly added the Google Services configuration file to your
app.
An issue with the Google Play Services library: Make sure you have
the latest version of the Google Play Services library installed in
your app.
An issue with the device or emulator you are using: Make sure you
are testing on a device or emulator that has Google Play Services
installed and is up to date.
Possible fixes to try/check:
Double-check the SHA-1 fingerprint and package name: Make sure that
the SHA-1 fingerprint and package name you have configured in the
Firebase console match the ones you are using to sign your app.
Make sure you have added the Google Services configuration file: The
Google Services configuration file is required for your app to
communicate with Google services, including Google Sign-In. Make
sure you have properly added this file to your app.
Update the Google Play Services library: Make sure you have the
latest version of the Google Play Services library installed in your
app. You can check for updates by going to the "SDK Manager" in
Android Studio.
Test on a device or emulator with Google Play Services installed:
Make sure you are testing on a device or emulator that has Google
Play Services installed and is up to date.
I hope this helps! I will quickly search if I can find any other solution.

can't find google smart app in home control

when I run the Google smart home demo, I have a problem at 25.Find your app in the list of providers. The result is that I can’t find my APP in Home control use the Google Pixel device.
I am sure that:
1、I use the same google account to create the project in web and login in google home App on Google Pixel, and I launch the test in 30 mins which mean that the test shouldn’t be expired.
2、I have done the command "gactions test --action_package PACKAGE_NAME --project PROJECT_ID"
Could you any body gave me some suggestions? I have sticked it for more than two weeks.
The Google smart home demo you mentioned is to help you build web service to process Google smart home requests. After building web service and host it on some public URL, you have to specify this URL in your action.json.
Also you need to build your OAuth 2.0 server and specify it in project setting in AoG console.
Then after executing"gactions test --action_package PACKAGE_NAME --project PROJECT_ID", you shold see your app [test]YOUR_APP_NAME in the add devices section.
Please check if you miss any part above and your gactions command runs without error messages.
Good luck~

Google App Engine: This application does not exist

I try to upload sample app to Google App Engine with existing progect ID.
Here is GAE screenshot
gae screenshot
I'm using the same ID in the progect.
But when I try to upload it with plugin from Eclipse then I recive an error:
eclipse error
The whole error from a console:
------------ Deploying frontend ------------
Preparing to deploy:
Created staging directory at: 'C:\Users\User\AppData\Local\Temp\appcfg2693799039714166602.tmp'
Scanning for jsp files.
Scanning files on local disk.
Initiating update.
com.google.appengine.tools.admin.HttpIoException: Error posting to URL: https://appengine.google.com/api/appversion/create?app_id=app1-152711&version=1&
404 Not Found
This application does not exist (project_id=u'app1-152711'). To create an App Engine application in this project, run "gcloud beta app create" in your console.
Debugging information may be found in C:\Users\User\AppData\Local\Temp\appengine-deploy7186088524405894873.log
Why I can not upload it?
This is actually the new intended behavior. App Engine will not be enabled for new projects until you go through the app creation flow in the Cloud Console under 'App Engine' to enable the App Engine service, or alternatively run gcloud beta app create from the console.
I just encountered this myself. The project has to be created in the Cloud Console AND you need to go through the project setup in AppEngine. Something must be broken in the API that creates the AppEngine part of the process while uploading. So doing it through the web interface creates the project for you... and then uploading will essentially fill it in.
It never used to be this way, so maybe something changed.
I have the same problem. This is what I did to solve it.
Log in to your google cloud account.
Select your project from the blue header bar.
Click the menu button(the 3 bars) on the top left of blue header bar.
Select IAM - you should permission for App Engine Service account. If not, you have to set it up.
To do that:
Click the menu button (the 3 bars) again
Click the App Engine
If you have not set it up, you will be prompt to do a tutorial.
Cancel the tutorial.
Go back to IAM.
Now you should see that the App Engine Service account added to the permission
Go ahead to upload. Should work now.
Make sure you are logged in with the correct Gmail account. At the bottom right corner of Eclipse you will see which account you have authorized, or you will see "Sign in to Google" - click on it to authorize Eclipse.

Add iOS push notifications to Visual Studio Cordova Project

Hi I'm following this tutorial https://github.com/ggailey777/mobile-services-samples/tree/master/CordovaNotificationsArticle
to add iOS push notification to my Cordova project but couldn't get it to work. The APNS certificate is configured and I've uploaded the p12 file to azure mobile notification.
When I run the app it shows "Registered with Azure!" and in azure notification hub I can see the registration.
However when I send test push notification using visual studio, the message result is empty.
If I use azure portal, it shows "The test notification was sent"
And my iphone never got any notifications either when it's open or closed.
Am I missing something? Any help is much appreciated.
Thanks!
You are mixing and matching technologies. You cannot use iOS Native code in an Apache Cordova app. Based on your comments, use the cordova-push-notifications plugin. The README.md in the project describes how to add it for iOS. It's relatively simple.
You will still have to deal with how to get your device registered with Notification Hubs and getting a notification sent to your device. That is covered in detail in the Azure Notification Hubs documentation.