Skip to main content
NinjaNext

Client project

HSA Second Opinion: a medical second-opinion platform

A patient app, a doctor app, a web admin portal and a Kotlin backend for remote specialist second opinions, with mobile-wallet payments, chat and push notifications.

On Google Play

The patient app (HSA Second Opinion) and the doctor app (HSA Doctor Connect) are published on Google Play under the NinjaNext Technologies developer account.

Client
HSA Second Opinion
Sector
Healthcare
Period
2024
Platforms
Android (patient app), Android (doctor app), iOS apps, Web admin portal, REST API
Key figures
2Android apps live on Google Play
4parts: patient app, doctor app, admin and API

Apps people use

  • Android (patient app)
  • Android (doctor app)
  • iOS apps
  • Web admin portal

Backend and business rules

  • Kotlin
  • Spring Boot
  • Spring Security + JWT
  • PostgreSQL

Connected services

  • Firebase Cloud Messaging
  • Sendbird
  • JazzCash
Simplified overview of how the main parts of HSA Second Opinion fit together. Not every component is shown.

The problem

Patients wanted a specialist's second opinion without travelling to a clinic. The service needed a simple way for them to submit their history and reports, pay, and talk to an assigned doctor, and a way for the team to onboard doctors and route each case to the right one.

What we built

We built a Kotlin and Spring Boot backend and native Android apps for patients and doctors, and worked with the client's wider team on the iOS apps and the web admin portal. A patient fills in a guided multi-step request, uploads reports, pays by mobile wallet and then chats with the doctor assigned to the case.

Key features

  • Patient sign-up with email OTP verification and password reset
  • Guided multi-step request: demographics, family members, clinical details and acute illnesses
  • Section-by-section upload of medical reports and case sheets
  • Specialty categories with prices managed by the admin
  • JazzCash mobile-wallet payments with server-side payment notifications; requests stay as drafts until paid
  • Real-time patient and doctor chat with text, images and voice notes (Sendbird)
  • Push notifications at each status change (Firebase Cloud Messaging)
  • Doctor app with assigned cases, full case details, chat and a mark-as-completed step
  • Admin portal with a dashboard, patient and doctor management, doctor assignment and category pricing
  • Role and ownership checks on every API call, and a forced-update check for old app versions

Technology stack

The main technologies used in this project.

  • Kotlin
  • Android (Hilt, Retrofit, Navigation)
  • Swift / SwiftUI
  • Spring Boot
  • Spring Security + JWT
  • PostgreSQL
  • Firebase Cloud Messaging
  • Sendbird
  • JazzCash
  • Angular

Our role

NinjaNext built the backend API and the Android patient and doctor apps, integrated payments, chat and notifications, and published both Android apps. The iOS apps and the Angular admin portal were built together with other developers.

Challenges and how we handled them

  • Paying before a case is opened

    A request stays a draft until the mobile-wallet payment is confirmed by the provider's server-to-server notification, so no doctor is assigned to an unpaid case and refunds can be traced.

  • Medical information in small, clear steps

    Long medical forms put people off. The request is split into short sections with a review step at the end, and reports are uploaded against the section they belong to.

  • The right person sees the right case

    Patients, doctors, admins and support staff have separate roles. Custom annotations check both the role and whether the user owns or is assigned to the case before any data is returned.

What the client said

We needed a digital solution that was simple to use and could support our service requirements. NinjaNext Technologies worked with us to understand the product goals and turn them into a practical software solution. Their team was responsive to feedback and focused on making the user experience clear and easy to follow.

Sarah WilliamsProduct Director, HSA Second Opinion, United Kingdom

Let's build it

Planning something similar?

Tell us about your project. If it is close to HSA Second Opinion, we will explain what we would reuse, what we would do differently and what to decide first.