Firebase console - problem receiving test push FCM notification in android device - android

I am sending push notification using firebase console and i am getting "0% of potential users are eligible for this campaign: 0". and push notification is not displaying in mobile..If anyone got same experience and solve issue then please suggest me how can i solve this issue. I followed all the thing..that i added json file that i got from firebase.

Please check for the following:
Have you configured your android package name correctly.
Did you place the google-services.json file in android/src folder.
Make sure you have done all steps present in this link (If you using android studio i suggest going with option 2)
Get user token to send firebase message Follow the steps
After all these if you still can't receive push notifications try setting channelid in advanced messaging options

Refer https://firebase.google.com/docs/cloud-messaging/android/client link step by step and you will be good to go for your push notification using fcm and if you already implemented the basic things then compare your code with the sample code step by step mentions on the link. you must find out the error. let me know if it resolves your issue.

Go to Build --> clean project -->Rebuild project
(Build is at top in android studio)
Why it was not working - You must have had deleted google-services.json file and re-added it.

Make sure you have only one firebase project configured for this app (if no then delete one you dont plan to use)
Go to firebase setiings -> Left top angle -> settings icon -> Project settings ->
scroll to bottom, then make sure to add SHA certificate fingerprints Type. How to get it
Then (still on this page) press See SDK instructions button. And place google-services.json file in your project.
If all this steps passed for you and you still getting this error then just wait a little bit, for me it take 2 days, before it started working.

Related

React-Native Headless task not working on android

I'm using sample code available on connecty-cube GitHub repo. When I call to user who is on android phone doesn't receive the notification for call when app is in background. And when app is open user can see the incoming call. Constructor of PushNotificationsService run and I can see this console [PushNotificationsService][constructor]. But inside _registerBackgroundTasks() function [JSNotifyWhenKilledTask] notificationBundle console doesn't run. I do get UDID for channels APNS, APNS VOIP and UDID for channel FCM in connecty cube dashboard.
So that's how I figured out the problem.
Make sure you have properly configured each step of every required library for connecty-cube.
Follow the docs
After that I checked sdk version of firebase on firebase console.
It stated classpath 'com.google.gms:google-services:4.3.13' in (<project>/build.gradle). But mine was classpath 'com.google.gms:google-services:4.3.10'. And because of that notification was not appearing. Now it's works.
I assume you are referring https://github.com/ConnectyCube/connectycube-reactnative-samples/tree/master/RNVideoChat
I suggest the following:
follow Getting started guide https://github.com/ConnectyCube/connectycube-reactnative-samples/tree/master/RNVideoChat#getting-started and make sure you have google-services.json properly located
Re-check https://developers.connectycube.com/reactnative/videocalling?id=receive-call-request-in-backgroundkilled-state where it describes how BG task works

Fragment not Generated in AppSync Sample App

I'm going through the sample app for AppSync as described here.
I found a sample Android client app on GitHub here and am trying to just get it to run with my data but for some reason the fragments aren't being generated.
events.graphql has what appears to be the events fragment definition.
fragment Event on Event {
id
description
name
when
where
comments {
items {
eventId
commentId
content
createdAt
}
}
I've tried adding it to the schema in the appsync web interface and it saves the schema but then doesn't actually add the fragment. I'm just now trying GraphQL tonight so I'm not really sure where to even put the fragment definition and Google doesn't seem to have anything about this.
Going to need more information here before answering, but I'm working on the same sample project and was able to get it working so I might be of some help.
Is your project syncing and building? That's a good first step.
It looks like your .graphql files are being autogenerated in your app-> source -> appsync -> com file, but the classes are not being generated in the app -> build -> source -> appsync -> com folder.
Something I learned in the process of working on this project was that it's important to have all your resolvers and the backend set up fairly completely in the AWS console before calling the amplify add api command. Have you setup the back end with resolvers?
If you have and it's still not working, try running in the app terminal amplify gql-compile then running amplify pushto pull the data back into your app from the console, then resync and rebuild as necessary. This should build your Query/Mutation/Subscription classes for you, as well as the Fragment.class, which are the resolvers in your program for the .graphql queries/etc that you want to run in your application.
If that doesn't work, make sure you've completed all the necessary steps in the amplify API like amplify add api, amplify update api. It appears that you've already done that since you have generated .graphql files in the app-> source directory, but in case you haven't, those are first steps. You can also check to make sure that you're actually connected to the DB (and correct api in the console) by running amplify status. Are you connected to the console API that you need to be connected to?
As a last resort, you can copy the Event.class file from github and paste it into the appropriate file/subdirectory, along with the rest of the Query/Mutation/etc .class files that should have been generated by the ApolloGraphql plugin.

'Cannot read property 'listRegistrationsByTag' of undefined' from Microsoft.WindowsAzure.MobileServices.Push.RegisterAsync

This is a Xamarin.Forms app running on Android, based on the Azure getting started Mobile App example.
I'm trying to register a device's id for notification services. Originally I was getting unauthorized, so I relaxed authorization settings on the backend. Now I am getting this error and cannot find a reason why.
I checked and double checked that notification hub has the correct Firebase details that align with the app and cannot see what the problem is here, any help appreciated.
John,
If you set WEBSITE_PUSH_ENABLED=false in your appsettings, does the problem go away?
Can you check your Mobile App's app settings?
Specifically, I am looking for the existence of the app setting "MS_NotificationHubName". If that app setting doesn't exist, you need to add it, with the name of your notification hub.
There is a bug in the Azure App Service Push blade right now. A fix is being rolled out. In the interim, instead of using RegisterAsync(), use the method described in the book http://aka.ms/zumobook - chapter 5.

Titanium: Android device token without Cloudpush

Is there anyway to get device tokens without using Cloudpush modules. 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
I followed these steps:
1) First Step :
Open this link https://developers.google.com/console/
than login with you account. 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
2) Second Step :
Click on this link https://cloud.google.com/console#/project
You can found you project that you already created.
Just Click on that and you found the Example: Project Number: 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.
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:
However all I'm getting is Failed receiving 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.
Following info will be helpful in using module :
You can view the module's info at GCM Titanium.
The zip file of module is at in dist folder ( use latest version of zip ).
Example to use module is under example folder.
Hope it helps.

Getting Error while Sending automatic email on background

Getting error "java.lang.NoClassDefFoundError: javax.activation.DataHandler" while Sending automatic email on background..I have added activation.jar ,additional.jar.mail.jar already ,but getting same error again,,plz tell me proper solution..
Thanks in advance..
The Android SDK makes it very easy to send emails from an application, but unfortunately, that's only if you want to send them via the built-in mailing app. For most situations this works fine, but if you want to send something out and don't want any input/intervention from the user, it's not as easy.
so please follow this link
http://www.jondev.net/articles/Sending_Emails_without_User_Intervention_(no_Intents)_in_Android
Try going to Project -> Properties -> Java Build Path -> Order & Export and ensure Android Private Libraries are checked for your project and for all other library projects you are using.

Categories

Resources