Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.7k views
in Technique[技术] by (71.8m points)

Send FCM from one Firebase account to apps compiled w/ different package names

This may really be more of a branding question but I'm asking here because it has to do with how FCM handles notifications.

We have an app that sends notifications to users based on the topic they subscribe to. The topics are specific to our customers who are businesses themselves. So the relationship is:

Our Company -> Other Company (our customers) -> Other Company's Customers (end users)

Say we have "Other Company A" and "Other Company B" with topics "A" and "B". Company A can use our system to send notifications to it's customers, and Company B can do the same. When their customer (end user) downloads and opens the app, they put in a topic A or B. This subscribes to the topic and also downloads that particular company's image, info, etc. so it is semi-branded for that company.

Now those companies want the app to show up in their own app/play stores. So we re-compiled the app changing the package name from com..app to com..app to submit to their stores even though that seemed like a brute force approach. But now notifications do not go through to the newly compiled apps.

I'm not sure what needs to change so that notifications can be sent from the same Firebase service to differently compiled apps?

And I guess the higher-level question would be is this even the correct approach for taking the app and branding it for a customer? The business only wants their customers (the end users) to see the app in their store instead of ours, and to have their image saved on the mobile devices instead of our company image when the app is installed.

Any guidance would be greatly appreciated!


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

It is recommend to have apps for different customers on separate Firebase projects. While combining them into a single project may work in some cases, there is no guarantee this may continue to work as you scale.

For example, you can only have a limited number of OAuth client IDs in a project, and a limited number of apps. Once you hit those limits, you'll need to set up multiple projects anyway, so you might as well do that straight away and find another way to optimize rolling out apps for new customers.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

1.4m articles

1.4m replys

5 comments

57.0k users

...