Get All Contacts

So… I’ve been using Appgyver for a while now. Really like the platform.

I’m working on a texting app that allows users to upload an excel file to Firebase Cloud Storage, cloud function converts to json, stores it in a firestore document in the unique user’s collection, allows them to access this list of name’s & phone numbers, select which recipients to automate sending a personalized text message to each recipient as a peer to peer (not group) text. App is to be used by organizations with a few hundred members as a way of communicating important information quickly with their members without having to push send a few hundred times (i.e. automated). Messages get sent via SMS on the user’s own mobile phone using their own number (not some short code) so that responses go to their mobile phone etc. This app is currently working in another platform (long story) not native to iOS or Android, which is why we’re trying to use Appgyver to create both iOS and Android apps.

I’ve said all this to explain that we know what we want the app to do and more or less the functionality that users of the other platform like and don’t like.

One important feature users like is that when the app sends the messages, it adds the recipient’s contact info to the user’s device so when the recipient responds to the message the user knows who is responding, not just a phone number. We do not however want to add duplicate contact info every time a message gets sent to that person. What our other platform does is search the user’s contacts for the number it’s sending the message. If it finds the number in the user’s contacts it moves on to the next recipient. If it does not find the number, it adds the contact info before moving to the next recipient. Pretty straightforward stuff.

I’ve been trying to use the Get All Contacts flow function and map the output to an app variable. We aren’t interested in all the field the flow function returns, so we are only mapping the fields we want, givenName, familyName, phoneNumber, company, jobTitle, email etc.

I have a toast set up on both outputs of the flow function. Neither of them ever fire. The preview app locks up and that’s it.

I have about 3500 contacts on my phone.

The last picture is just there to show that I do understand how to display a list of contacts. That picture is the list being pulled from firestore. We have almost an Identical page to display the phone’s contacts.

And yes, I know that I’m only getting the first phone number for each item and the schemas don’t match, but I’m just trying to get it to get the data and show it in a repeating container at the moment.

It just never gets the contacts.

Any suggestions?