kreait / laravel-firebase

A Laravel package for the Firebase PHP Admin SDK
https://github.com/kreait/firebase-php
MIT License
995 stars 161 forks source link

Requested entity was not found. [Bug] #50

Closed BSpirit-Dev closed 3 years ago

BSpirit-Dev commented 3 years ago

Hello, i use this library to send notification cloud message, but i get an error when token is old, i mean i try to launch application from my device (react-native) register my new token on laravel and then send notification, and working, on relaunch and re-installetion of appliation and so new registration of token (no refresh - i manage this - but isnew one, so the old is unregisted) i get error near old token that block the execution of script:

NotificationChannels\Fcm\Exceptions\CouldNotSendNotification
Requested entity was not found.

NotificationChannels\Fcm\Exceptions\CouldNotSendNotification::serviceRespondedWithAnError
vendor/laravel-notification-channels/fcm/src/Exceptions/CouldNotSendNotification.php:11

exist a way to fix it? maybe ignore if return an error ? thanks

BSpirit-Dev commented 3 years ago

problem is other package that use this package!

juanzeta33 commented 3 years ago

Hi, I'm having this same error but with Notifications and messaging Facades, with Laravel 7.x

I need to say that I can setup succesfully previous with lumen.

I update my vendor with composer update before and after intall also, I try it to clear cache.

jeromegamez commented 3 years ago

This seems to be an error returned by the Firebase API - my first guess is that the target of a message (probably the registration token of a device) doesn't exist or has changed.

BSpirit-Dev commented 3 years ago

This seems to be an error returned by the Firebase API - my first guess is that the target of a message (probably the registration token of a device) doesn't exist or has changed.

yeah, and i need to know how to fix it, exist a way to check who "working", this happened when the token device is changed, or doesnt exist (tested with real device and localhost - and when i remove the application and then re-install it this happen)

juanzeta33 commented 3 years ago

This seems to be an error returned by the Firebase API - my first guess is that the target of a message (probably the registration token of a device) doesn't exist or has changed.

Sure, I will check, thanks!