Open App By Clicking Push Notification

0 votes
Hi All I want to send invite my friend to match. When app is running or in background, it is working. It receives OnMessage method and inside it I can show whatever I want. But problem is that when application is not running on his phone, he receives push notification. When he clicks it, application is opened but not any method is fired. So, somehow, I should be able to solve this problem. Do you have any solution to this problem? I need a way like that OnMessage is fired if application is opened by clicking push. Thanks
asked Nov 24, 2016 in Unity by gokhan (20 points)
I am waiting...

2 Answers

0 votes
Hi Gokhan,


I forwarded your query to device team, they will help you out by today EOD.

Thanks for your patience.


Himanshu Sharma
answered Nov 28, 2016 by hs00105 (2,005 points)
Hi Himanshu
I think your team forgot me..
0 votes

Hi Gokhan,


Aplologies for delay.

You can download the Unity Push Sample. I have added an API by which you can track that the application is opened using Notification click or not.

Here are steps you need to do in your project.

  • Do replace app42pushservice.jar file in Assets/plugins/Android folder.
  • Also apdate the App42Push.cs file with the sample application, new API are added in this file.

Here are the API added in App42Push.cs file to get the status of Notification click.

bool isClicked=App42Push.isNotificationClicked();


  • API used to track whether Notification is clicked or Not. It returns true if clicked else return false.
  • Using the second API you can resetNotification click status.
I have also added a default Android Activity in plugin jar file so you need to add following Activity in your AndroidManifest.xml file.
   <activity android:name="com.shephertz.app42.push.plugin.App42Activity"></activity>

Let me know if any query is concern.


Vishnu Garg



answered Dec 1, 2016 by Vishnu Garg (674 points)
Hi Vishnu
I cannot download unity push sample project from given link. Page cannot be accessed!
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on