Flutter: Get list of contacts only signed up in my flutter app using Firebase Auth (like WhatsApp) - flutter

I build an application similar to the chat applications, the user signup via the phone number using the Firebase Auth.
How I can create a list of the contacts stored by the user in their phone that is signed up in the application, such as those in the WhatsApp application.

How to fetch the phone contacts is already answered here Fetching contacts in flutter
Now you need think of your own way how you would create a list of those contacts which are also using the app. One option would be to make a query to your database for each phone number of the devices contact list and if its in the database you know this contact is also signed up, so you can add it to your list.

Related

Firebase Auth for multiple projects?

I have two apps and using same firebase project for both the apps , and i want to check if the user logged in through the first app , then if he open the second app for the first time get the data if the current user is logged is or not with the same email. Is it possible to check this through firebase or i have to do it locally .

database Firebase flutter RevenueCat security

I have a security issue with Firebase.
I want all users to be able to update their data in a Firebase database from a flutter app but only after some app verification, payment for example. so I don't want them to be able to write data except through the app process and I have no idea how to separate the app user who has the right after verification and the one who doesn't and just knows the address of the database.
To summarize, how can I be sure a request is from the flutter app and only grant access if it's the case ?

Can you use CloudKit to access a user's contacts from a React/Django project?

I have a react/django project and we need to somehow access the contacts of our users. I was told to look into CloudKit's API in order to take care of this, however there seems to be no real information in their docs or in my Google searches on using this API to specifically access a user's contacts.
I am open to other suggestions as well. The ideal would be to access their contacts initially and then every so often compare their contacts to our list to see if any have been added.
You cannot access this data from a third-party app via a CloudKit API.
While Apple does store a user's contacts on CloudKit, they do so under these conditions:
The user opts-in to sync their contacts with iCloud (this isn't required for iOS users; they can be on-device only, or sync with another service like Google).
The contacts Apple stores on CloudKit are in a container that is private to Apple.
When you use CloudKit as a developer, you are creating a container for your app. You can only access data in containers you create.
Here's what you would have to do:
Create an iOS or macOS app that requests/manages access to the user's contacts.
Add the Contacts entitlement to your target in Xcode: Signing & Capabilities > App Sandbox > App Data > Contacts
Use Apple's Contacts framework to access contact data using Swift in your iOS/macOS app.
Once you have the data in your Swift app, communicate with your Django API to do what you need to.
One last thing. If you choose to go this route, you will have to reveal in your app privacy disclosures (in App Store Connect) what you are doing with the users' data.

How does Instagram check if the users contact are using the application?

In the Instagram app you are able to sychronize your contacts and than the app shows which of them use the application. They are probably using the Contacts framework. Are they fetching the numbers of all contacts and than comparing them in their database?
Yes, once you allow to give access to your contacts. Step #1 is to sync your contacts with their server and they checkout in their database, if any of your contact already using the app (registered to app with that mobile number), they show it for you to better getting in touch with them, otherwise shows you an option to invite them to get started.

Extract contact info like facebook/google id from contacts list/people app in windows phone

The people app in windows phone keeps all the connected accounts synced. Is there a way to extract this synced information in windows phone(Please note that the user would have authorized my app on Facebook and Google too).
Basically i just need the facebook and google ID or any such identifying credential(of the user's contacts in his contact list) on the phone to maintain a sync across contacts.
I already receive the list of all connected email addresses but I am trying to get the facebook/google userID without having to go through the process of cross referencing them