Really weird and no one has ever asked this.
I\'m getting MismatchSenderIdas an error with my server key as my authorization key(server key).
And on the
The MismatchSenderId error is encountered when you are attempting to send to a registration token that is associated with a different Sender (Project). From the docs:
A registration token is tied to a certain group of senders. When a client app registers for FCM, it must specify which senders are allowed to send messages. You should use one of those sender IDs when sending messages to the client app. If you switch to a different sender, the existing registration tokens won't work.
Make sure that the Server Key you are using is from the same Sender Project that the registration token is associated to. You can do this by checking your google-services.json file and see if the Sender ID there matches the Sender ID visible in the Firebase Project you are using to send the message.
For the matter of not receiving messages, It's a bit unclear as to what is the structure of payload that your code is sending. Try checking if it is a properly structured message payload with a notification and/or data message payload.