Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

Get SENDER_ID_MISMATCH with FCM

75 views
Skip to first unread message

Dionys Skiner

unread,
May 22, 2025, 7:03:31 AMMay 22
to Tinode General

v0.24.0-rc3 tindroid
0.23 mysql:v0.24.0-rc2 tinode

im create firebase project
-fcm_prj_cfg.jpg

adding web app
-fcm_webapp_conf.jpg

and android app
-fcm_android_conf.jpg

create web push cert
-web_push_conf.jpg

download google-services.json
-google-services_json.jpg

and server side fcm credentials
-fcm_json.jpg

specifyed fcm credentials file path in tinode.conf
-tinode_conf.jpg

configured FIREBASE_INIT on server side
-tinode_webapp_conf.jpg

edit build.gradle deps in app folder
-build_gradle_dep.jpg

put google-services.json to app folder
compile new apk with Android Studio

restart tinode and get SENDER_ID_MISMATCH when send message to user with new compiled app
-tinode_error.jpg

user in chrome browser does not receive notifications.

what wrong? (

Gene

unread,
May 22, 2025, 7:20:01 AMMay 22
to Tinode General
>>> compile new apk with Android Studio
>>> user in chrome browser does not receive notifications.

What does compiling the Android app have to do with web?
Do you receive pushes in Android?
What do you see in the browser console?
How do you launch your web app? HTTP or HTTPS?

Dionys Skiner

unread,
May 22, 2025, 7:26:32 AMMay 22
to Tinode General
-fcm-stat.jpg

четверг, 22 мая 2025 г. в 15:03:31 UTC+4, Dionys Skiner:

Dionys Skiner

unread,
May 22, 2025, 7:32:54 AMMay 22
to Tinode General
1-2:
web users not receiving notifications
android users not receiving push notifications

3:
many message like:
[11:29:40.380] out:
[11:29:40.382] in:

without any error

4:
https over nginx reverse-proxy on server side

четверг, 22 мая 2025 г. в 15:20:01 UTC+4, Gene:

Gene

unread,
May 22, 2025, 8:04:49 AMMay 22
to Tinode General
Please show the client-side startup logs (first ~20 lines).
Please show the top of the server-side log (first 20 lines or so). 
Message has been deleted

Dionys Skiner

unread,
May 22, 2025, 9:38:29 AMMay 22
to Tinode General
js browser console
-weblog.txt

server side log
-sslog.txt

android log
-andlog_tinode.txt

четверг, 22 мая 2025 г. в 16:04:49 UTC+4, Gene:
-andlog_tinode.txt
-sslog.txt
-weblog.txt

Gene S

unread,
May 22, 2025, 9:52:02 AMMay 22
to tin...@googlegroups.com
This installation is using tnpg, not FCM. 

If you need assistance, please choose one (ONE and only ONE) issue for each thread. It's already difficult to understand the source of the problem and now you are mixing up FCM with TNPG.

On Thu, May 22, 2025 at 4:35 PM Dionys Skiner <dionys...@gmail.com> wrote:
js browser console
-weblog.txt

server side log
-sslog.txt

android log
-andlog_tinode.txt

четверг, 22 мая 2025 г. в 16:04:49 UTC+4, Gene:
Please show the client-side startup logs (first ~20 lines).

--
You received this message because you are subscribed to the Google Groups "Tinode General" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tinode+un...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/tinode/b9962e6a-8b98-4f18-8f9a-5000b8685381n%40googlegroups.com.

Dionys Skiner

unread,
May 22, 2025, 10:03:45 AMMay 22
to Tinode General
sorry.
later enable fcm, install my own app again, and attach new log.
thx!

четверг, 22 мая 2025 г. в 17:52:02 UTC+4, Gene:

Dionys Skiner

unread,
May 26, 2025, 6:41:17 AMMay 26
to Tinode General
im create new mob app in my firebase project with new package name co.tinode.tindroidex for clean testing.
get new google-services.json.
rebuild app.
enable fcm in tinode config.
install apk.

send message "test for fcm" from user with tnpg app to user with fcm app. recipient did not receive the notification.
send message "test for tnpg" from user with fcm app to user with tnpg app. recipient receive the notification.
send message "test two for fcm" again from user with tnpg app to user with fcm app. recipient did not receive the notification.

android syslog contain err and warn:
E AppOps  : Bad call made by uid 1000. Package "co.tinode.tindroidex" does not belong to uid 10481.
E AppOps  : java.lang.SecurityException: Specified package "co.tinode.tindroidex" under uid 10481 but it is not
...
W DynamicDDSService: appName is not found in cache: co.tinode.tindroidex
W FA-SVC  : Gms url request failed, app: co.tinode.tindroidex, CONFIG, m1.ll: Exception in CronetUrlRequest: net::ERR_NAME_NOT_RESOLVED, ErrorCode=1, InternalErrorCode=-105, Retryable=false

server log, android log and fixed google-services.json in attach.

четверг, 22 мая 2025 г. в 18:03:45 UTC+4, Dionys Skiner:
tindroidex_log.txt
google-services.json
tinode_log.txt

Dionys Skiner

unread,
May 26, 2025, 7:07:55 AMMay 26
to Tinode General
W FA-SVC  : Gms url request failed, app: co.tinode.tindroidex, CONFIG, m1.ll: Exception in CronetUrlRequest: net::ERR_NAME_NOT_RESOLVED, ErrorCode=1, InternalErrorCode=-105, Retryable=false
I guess the problem is this. The app calls the wrong url for client push registration.

понедельник, 26 мая 2025 г. в 14:41:17 UTC+4, Dionys Skiner:

Gene

unread,
May 26, 2025, 11:58:13 AMMay 26
to Tinode General
On Monday, May 26, 2025 at 1:41:17 PM UTC+3 Dionys Skiner wrote:
im create new mob app in my firebase project with new package name co.tinode.tindroidex for clean testing.
get new google-services.json.
rebuild app.
enable fcm in tinode config.
install apk.

send message "test for fcm" from user with tnpg app to user with fcm app. recipient did not receive the notification.
send message "test for tnpg" from user with fcm app to user with tnpg app. recipient receive the notification.
send message "test two for fcm" again from user with tnpg app to user with fcm app. recipient did not receive the notification.

android syslog contain err and warn:
E AppOps  : Bad call made by uid 1000. Package "co.tinode.tindroidex" does not belong to uid 10481.
E AppOps  : java.lang.SecurityException: Specified package "co.tinode.tindroidex" under uid 10481 but it is not

This is unlikely related to Tinode. This is an issue with your build or setup. Please  search for solutions first before posting here.

For example, here is something I found and 2 minutes of Google searching:

Most likely you did not completely remove the old build before installing the new one.

Gene

unread,
May 26, 2025, 12:02:00 PMMay 26
to Tinode General
BTW, the word Tinode is a registered trademark. It's very uncool for you to use it. i will not be able to help you at all if you continue to misuse it. Please do not use the word Tinode inn you app. You are in violation of our licensing terms and trademark laws.

Dionys Skiner

unread,
May 30, 2025, 9:51:15 AM (14 days ago) May 30
to Tinode General
im create new firebase project without "tinode" keyword.
step by step configured it with apk sign sha1 fingerprint.
download new app and serverside configs.
reconfigured tinode config and static/firebase-init.js
install new app on two different phone. fcm register without error in log. on phone using microg - fcm register status OK.
and open one tab Tinode Web in browser without error in console.
check Firebase Installations API status - 3 ok
sent 6 messages between two users
no one received notifications either on the web or in the app. there is one checkmark in the sender's chat.
check
Firebase Cloud Messaging API status - 6 request 100%

in tinode for each message an error was received:
fcm invalid config: SENDER_ID_MISMATCH SenderId mismatch; forbidden/SenderId mismatch

i assume that the configuration file is not read correctly by tinode
what else should I check? I can sniff packets if you tell me where to look for errors in requests. i am ready to solve this problem until I get the positive result.

does anyone have successful experience using FCM on tinode v0.24.0-rc2 for windows?

понедельник, 26 мая 2025 г. в 20:02:00 UTC+4, Gene:

Gene

unread,
May 30, 2025, 10:03:08 AM (14 days ago) May 30
to Tinode General
On Friday, May 30, 2025 at 4:51:15 PM UTC+3 Dionys Skiner wrote:
im create new firebase project without "tinode" keyword.
step by step configured it with apk sign sha1 fingerprint.
download new app and serverside configs.
reconfigured tinode config and static/firebase-init.js
install new app on two different phone. fcm register without error in log. on phone using microg - fcm register status OK.
and open one tab Tinode Web in browser without error in console.
check Firebase Installations API status - 3 ok
sent 6 messages between two users
no one received notifications either on the web or in the app. there is one checkmark in the sender's chat.
check
Firebase Cloud Messaging API status - 6 request 100%

in tinode for each message an error was received:
fcm invalid config: SENDER_ID_MISMATCH SenderId mismatch; forbidden/SenderId mismatch

SENDER_ID_MISMATCH means your "org" does not match your "token". I.e. you used "org" from one account and "token" from another.

// Name of the organization you registered at console.tinode.co.
"org": "sandbox",
// Authentication token obtained from console.tinode.co
"token": "eyJ***NiJ9.eyJ1***Tk4NX0._FDv***ErP_Y",

Dionys Skiner

unread,
May 30, 2025, 10:12:00 AM (14 days ago) May 30
to Tinode General
field "org" need for tnpg notification.
now i dont use this.
i use fcm.

пятница, 30 мая 2025 г. в 18:03:08 UTC+4, Gene:

Gene Sokolov

unread,
May 30, 2025, 10:32:38 AM (14 days ago) May 30
to tin...@googlegroups.com
On Fri, May 30, 2025 at 5:12 PM Dionys Skiner <dionys...@gmail.com> wrote:
field "org" need for tnpg notification.
now i dont use this.
i use fcm.

Then it means your client config does not match your server config.
 

Dionys Skiner

unread,
May 30, 2025, 10:53:30 AM (14 days ago) May 30
to Tinode General
my client is recompiled with new google-services.json of the same firebase project, the server settings of which I use in tinode in the fcm settings section.
recompiled clients are successfully registered in firebase project, tinode server requests are recorded as erroneous
in firebase project statistic.
in the tinod console
:

fcm invalid config: SENDER_ID_MISMATCH SenderId mismatch; forbidden/SenderId mismatch

dialog loop )))

where do i need to specify SenderId?
what else to check?

пятница, 30 мая 2025 г. в 18:32:38 UTC+4, Gene:

Gene Sokolov

unread,
May 30, 2025, 11:03:11 AM (14 days ago) May 30
to tin...@googlegroups.com
On Fri, May 30, 2025 at 5:53 PM Dionys Skiner <dionys...@gmail.com> wrote:
my client is recompiled with new google-services.json of the same firebase project, the server settings of which I use in tinode in the fcm settings section.
recompiled clients are successfully registered in firebase project, tinode server requests are recorded as erroneous
in firebase project statistic.
in the tinod console
:
fcm invalid config: SENDER_ID_MISMATCH SenderId mismatch; forbidden/SenderId mismatch

dialog loop )))

where do i need to specify SenderId?
what else to check?

I have no idea. I can't debug your code. If you did everything right then it should work. 
 

Dionys Skiner

unread,
Jun 1, 2025, 6:35:24 AM (12 days ago) Jun 1
to Tinode General
solved
https://github.com/tinode/tindroid/issues/165

пятница, 30 мая 2025 г. в 19:03:11 UTC+4, Gene:
Reply all
Reply to author
Forward
0 new messages