Hello everyone, I am Vishal Kumar Yadav, pursuing my Bachelor’s Degree in Electrical Engineering from IIT Jodhpur. I have contributed to developing the all-new Glific Mobile Application that will make the platform more convenient for NGOs. It has features similar to the web platform, such as sending and receiving messages, managing flows, collections, contacts, etc. easily through your mobile phone. Thus increasing the overall functionality of the Glific platform. You can read my previous blog titled Glific Mobile Application & Udaipur Sprint, which describes my journey of joining Glific and Udaipur Sprint, where we launched the mobile application.
With nearly a year of experience in mobile app development, I was immediately drawn to the project when I first discovered it while exploring C4GT projects for potential contributions. What particularly intrigued me was the opportunity to build the project from scratch. This presented the prospect of learning a wide array of new skills and technologies. As expected, I learned a lot of new things like TypeScript, React Native, GraphQL, software testing, and much more.
I will be discussing some of the key features that I implemented in the application and their use.
- Messages Subscriptions for Sent/Received Messages: The messages need to be fetched as soon as they are available on the server. This ensures real-time synchronization of the chat between the communicating parties. We use GraphQl subscriptions for this purpose. Subscriptions allow the clients to poll the server, and the server pushes data to the client as soon as new information becomes available.
An Apollo Cache is used to manage cache data on the client side. As subscription events occur (in our case, a message is sent/received), the Apollo Client is used to update the cache accordingly. This involves merging the new data into the existing cache, ensuring that the client-side data remains up-to-date.
A similar method was used to update the contact cards on the list of messages on the chat screen.
- Notifications: Notifications in Glific are different from the usual mobile notifications. They are the events/activities that are notified to the user. We have a separate page for displaying these notifications. The notifications are fetched from the server using GraphQL queries and are displayed in categories. These notifications can also be searched for a specific term.
- Start Flows for Contact/Collections: Flows are the rules for an automated response for the chatbot. We can start a flow for a contact or a collection. The feature is implemented as a popup in the chat options.
You can select a list of already-built flows and start a flow for the contact/collection. This involved implementing a Picker component that displays a list of flows. The selected flow’s ID, along with the contact/collection ID, is then used to make a mutation to start the flow for that contact/collection.
- Contact/Collection Information: Clicking on name of contact/collection on the chat screen, displays information about that contact/collection. These were simple fetches and formatting to display them on the screen. The real challenge was implementing the history list in the contact information, which requires displaying an initial 10 fields and then fetching more as we scroll through.
- Add Contacts to Collection/ Add Collections to Contact: As confusing as it sounds, it was as confusing to implement this.
Let’s understand what a Collection is. A collection is a group (not a WhatsApp Group) of contacts that could be sent messages/HSMs simultaneously. They have no interconnections, i.e. a contact of a collection can’t communicate with any other contact in the same collection.
Add Contacts to a Collection: Add different contacts to a collection.
Add Collections to a Contact: Adding this contact to multiple collections
I did this using a multi-select component, using which I could select multiple options from a list. These were then used to send mutations to update backend data. For Adding Contacts to a Collection, the removing a contact option was disabled. In future, it would require a search option to search the contacts, as the number of contacts can be in the thousands.
And many more things, small or big…
Overall, it was a great experience for me. I was fortunate to be part of an exceptional team, providing me with valuable opportunities to learn and engage. Our daily meetings were a blend of productive work and enjoyable moments. My mentor, Shamoon, is an exceptionally skilled software developer, and his guidance was instrumental in helping me implement features effectively. I also benefited greatly from my fellow intern, Aman, who not only reviewed my work but also provided valuable suggestions to enhance code cleanliness and optimization.
The picture above was from the endpoint evaluation of my internship, where I presented the work I did and gave a live demo of the app’s features. After spending time with the Tech4Dev team at Sprint and throughout my internship, I can confidently say that it’s an excellent startup with a positive work environment and a strong commitment to nonprofit tech.
I want to express my gratitude to my mentors – Shamoon, Akhilesh, and Lobo, as well as the entire Glific team, for making this internship experience so rewarding and collaborative.
To sum it up, my first job experience was fantastic, all thanks to the supportive teams at Glific and Tech4Dev. I learned a lot and grew both personally and professionally, and I’m excited to use these experiences in the future.