As the Principal Engineer of our company, I've led a team that's delivered 30+ global projects, specializing in video conferencing, appointment systems, consultation apps, custom web apps, and telemedicine solutions. We're problem solvers, passionate about tech, and dedicated to crafting innovative software solutions. In this blog, we'll showcase our latest achievement—a serverless presence service, replacing a previous solution. Our commitment to excellence and innovation drives us, and we invite you to explore this journey with us. Discover how our serverless expertise can elevate your projects and enhance your organization. Let's collaborate to bring your vision to life.

Problem Statement:

We're currently engaged in an exciting Canadian telemedicine project, pioneering a doctor-patient consultation platform. This comprehensive solution encompasses both mobile and web applications, offering seamless communication channels via video conferences and chat functionality. One of our standout features is a sophisticated online presence system that ensures real-time availability of medical professionals.

To streamline the patient experience, we've incorporated an efficient queue management system. Patients can easily join the queue, and our innovative platform intelligently prioritizes their appointments. Doctors have the flexibility to select patients from the queue, ensuring timely and personalized care.

Furthermore, our platform boasts a robust appointment scheduling system. Patients can conveniently book appointments, and doctors can manage their schedules with ease. This ensures a structured and organized workflow for healthcare providers and patients alike.

At the heart of our mission is to bridge the gap between healthcare accessibility and convenience, making quality medical consultations more accessible to Canadians. With our telemedicine solution, we aim to enhance the doctor-patient relationship, improve healthcare delivery, and provide a secure, user-friendly experience. This project exemplifies our commitment to innovation and our dedication to crafting solutions that have a positive impact on the healthcare industry.

In our telemedicine project, we initially utilized Firebase for real-time presence tracking, but encountered complications. Firebase conflicted with our native SDK in our React Native mobile app, causing compatibility issues. To address this, we integrated PubNub for mobile presence management while retaining Firebase for the web component. This dual-stack solution added complexity to our system.

Firebase's real-time capabilities didn't offer offline control, negatively affecting our queue system and causing delays for doctors. Additionally, firewall issues and antivirus software blocking Firebase further complicated matters. These issues prompted our shift towards a more reliable and efficient solution.

These issues prompted our transition to a more seamless and efficient presence management solution, addressing the limitations posed by Firebase and enhancing the user experience for both doctors and patients.

Solution Overview:

To overcome the challenges of our previous real-time and presence management systems, we've undertaken a strategic transformation. Our solution leverages the robust capabilities of the AWS serverless stack, including Lambda for efficient serverless computing, API Gateway for seamless API management, and API Gateway WebSocket for real-time communication. SQS (Simple Queue Service) facilitates efficient message queuing, ensuring smooth data flow, while EventBridge enhances event-driven functionality.

DynamoDB plays a pivotal role in our architecture, tracking user connections and their last activity timestamps. EventBridge operates at a rapid 10-second interval, continuously detecting online/offline user statuses. This event-driven mechanism underpins our real-time system, ensuring timely updates.

Our data is stored securely and efficiently in MongoDB, offering a solid foundation for a fallback system. In cases where WebSocket connections falter, we seamlessly transition to HTTP requests, maintaining uninterrupted service.

This AWS serverless solution empowers us to take full control of real-time and presence management, mitigating compatibility issues and minimizing delays. We are committed to providing healthcare professionals and patients with a seamless, reliable, and responsive telemedicine platform, continually refining and optimizing our systems to deliver the highest level of service.

Benefits and Features:

In the early stages of our system's development, we've harnessed the power of a serverless stack to our advantage. This strategic choice not only optimizes costs but also eliminates the complexities associated with scaling. As our user base grows, we're well-prepared to seamlessly accommodate increased demand without hassle.

One of the key benefits of our serverless setup is the enhanced control it affords us. We're able to provide precise and accurate notifications regarding user online and offline statuses. This level of real-time insight ensures a more responsive and reliable telemedicine platform for both healthcare professionals and patients.

In the event of any unforeseen issues with WebSocket connections, our ingenious fallback system automatically transitions to API-based communication, ensuring uninterrupted service delivery. All our data is securely stored in MongoDB, adhering to strict compliance with HIPAA and Ontario Health regulations. This centralized and fortified data repository includes robust backup mechanisms, safeguarding critical healthcare information.

This comprehensive approach ensures not only cost-efficiency and scalability but also the utmost reliability and security of our telemedicine application. It underscores our commitment to delivering a robust and compliant healthcare platform while providing a seamless experience for all users.

Technical Details:

In our system, powered by AWS serverless components like Lambda, API Gateway, WebSocket, SQS, EventBridge, and DynamoDB, we've crafted an agile and responsive architecture. DynamoDB efficiently tracks user connections, while EventBridge operates in real-time, updating user online/offline statuses every 10 seconds. MongoDB securely houses our application data, meeting compliance standards. Our system's hallmark is its event-driven mechanism, ensuring seamless functionality. This combination of technologies not only optimizes costs and scalability but also guarantees accurate user status notifications and, in case of WebSocket issues, effortlessly transitions to API-based communication. It reflects our commitment to reliability and data security in the healthcare domain.

Performance Metrics:

Transitioning from PubNub and Firebase, which incurred over $100 in costs, to our serverless stack has resulted in a substantial reduction. With the current user base, our expenses have remained under $30, offering significant cost savings while maintaining a highly efficient and responsive system.

Related Projects and Expertise:

In our latest project, we've harnessed a robust combination of AWS services to build a highly efficient and secure system. AWS Elastic Beanstalk manages our API servers, while load balancing ensures smooth traffic distribution. AWS Web Application Firewall (WAF) safeguards our application from public threats.

Our architecture is deployed within a Virtual Private Cloud (VPC), and we've established peering connections to MongoDB Atlas for secure data access. For communication, AWS Simple Email Service (SES) handles email sending, while Simple Notification Service (SNS) manages messaging. Amazon S3 stores our content, and CloudFront accelerates content delivery. We've utilized React Native for the mobile app and SQS for event management.

AWS Secrets Manager securely stores sensitive information. We've implemented the ELK (Elasticsearch, Logstash, Kibana) stack for request tracing, error tracking, and centralized logging. Automated alerts through email and Slack keep us informed of errors or unexpected occurrences.

Our prior experience with serverless stacks and technologies like API Gateway, Cognito, DynamoDB, CloudWatch, and GraphQL, along with proficiency in React, NestJS, NextJS and GraphQL, has enabled us to deliver a scalable, secure, and high-performing solution tailored to our project's needs.


In the early stages of our startup, cost-effectiveness and security are paramount considerations. Traditional server management for staging, production, UAT, and development environments can quickly become expensive and complex. Embracing a serverless stack minimizes these costs, allowing us to focus on rapid development without worrying about scaling complexities.

By leveraging AWS's secure infrastructure, we ensure the protection of our data and applications while optimizing operational expenses. Avoiding Kubernetes or cluster management systems simplifies our setup, reducing both complexity and costs. This cost-efficient approach enables us to allocate resources where they matter most, fostering our growth without compromising security or scalability.

Elevate your digital journey with! We specialize in video conferencing, telemedicine, consultations, and custom web applications. Seamlessly connect, collaborate, and innovate with our cutting-edge solutions. Contact us today to unlock limitless possibilities for your software needs.