[In-App Notifications Web] 403 error

[In-App Notifications Web] 403 error

  
Forge Component
(4)
Published on 2017-09-15 by Labs
4 votes
Published on 2017-09-15 by Labs

Hi!

I am getting a 403 error after the send notification Function,


Its returning sucsess = true 

 no error msg

an appnotifiactionID <> null


I am assuming this is what is causing the notifications wb on the header to not refresh. 


Any suggestions ?


Thanks So much in advance!



mordi reches wrote:

Hi!

I am getting a 403 error after the send notification Function,


Its returning sucsess = true 

 no error msg

an appnotifiactionID <> null


I am assuming this is what is causing the notifications wb on the header to not refresh. 


Any suggestions ?


Thanks So much in advance!




Meaning it seems like the send notification part is working... just not the receiving part 


Hello Mordi.
Have you tried to setup the sample application and test it with your firebase credentials?
The sample app is a working example of both send and receive scenarios. 


Please make sure you're handling the OnNotify action of the NotificationReceiver block in your screen.

It should be setup with the same parameter values as the SendNotifications action.


It looks something like this:

In this scenario, there's a list of notifications, which is being refreshed.

If you're only interested in the number of notifications, you can use the GetNumberOfNotifications action from the API.

Don't forget to Ajax Refresh the block where you're displaying your counter/list so it stays up to date.


Hope this helps.

Cheers.


Rui Mendes



mordi reches wrote:

mordi reches wrote:

Hi!

I am getting a 403 error after the send notification Function,


Its returning sucsess = true 

 no error msg

an appnotifiactionID <> null


I am assuming this is what is causing the notifications wb on the header to not refresh. 


Any suggestions ?


Thanks So much in advance!




Meaning it seems like the send notification part is working... just not the receiving part 




Hi Thanks So much for your reply.


This is occurring in the sample app with on notify as constructed above. 

Its actually a 401 error. 

Still happening. 

Rui Mendes wrote:

Hello Mordi.
Have you tried to setup the sample application and test it with your firebase credentials?
The sample app is a working example of both send and receive scenarios. 


Please make sure you're handling the OnNotify action of the NotificationReceiver block in your screen.

It should be setup with the same parameter values as the SendNotifications action.


It looks something like this:

In this scenario, there's a list of notifications, which is being refreshed.

If you're only interested in the number of notifications, you can use the GetNumberOfNotifications action from the API.

Don't forget to Ajax Refresh the block where you're displaying your counter/list so it stays up to date.


Hope this helps.

Cheers.


Rui Mendes




mordi reches wrote:

mordi reches wrote:

Hi!

I am getting a 403 error after the send notification Function,


Its returning sucsess = true 

 no error msg

an appnotifiactionID <> null


I am assuming this is what is causing the notifications wb on the header to not refresh. 


Any suggestions ?


Thanks So much in advance!




Meaning it seems like the send notification part is working... just not the receiving part 



Hi Thanks So much for your reply.


This is occurring in the sample app with on notify as constructed above. 

Its actually a 401 error. 

Still happening. 




Hi, I'm getting the same 401 error.  Was there any resolution?

Hello Mordi & Binish.

I've just made a new installation of the In-App Chat component using a new Firebase project.

The sample works just fine if you follow the instructions and set the Site Properties correctly.

This being said, Firebase changed its process in creating a database for the project. You now have two options:

Locked Mode and Test Mode.
In Locked Mode, the database cannot be updated, and so, the receiver is not notified on the changes.

Please try the settings for the Test Mode, by changing your database rules to the following:

{
   "rules":  {
       ".read" : true,
       ".write" : true
   }
}


Hope this helps.

Cheers,

Rui Mendes