Building Brave Care using Hasura: A case study of a YC backed healthcare startup
Brave Care is a YC backed healthcare startup that provides primary, urgent & remote care for kids. Brave Care runs in person & mobile clinics with a team of front line medical workers. Brave Care recently announced a 10M funding round with which they are planning to expand to building more clinics across several states in the United States.
When COVID hit in 2020, the Brave Care team rapidly launched telehealth visits and got licensed in 14 states. They became the first company to release an online COVID symptom checker and helped thousands of kids get their COVID tests.
We recently spoke to Asa Miller, CTO and co-founder at Brave Care to talk about how they're using Hasura to build and scale rapidly.
We have gotten a lot done as a small team. While looking at other companies of our size, we have a much smaller engineering team, and that’s largely because of Hasura and Hasura Cloud - Asa Miller
Applications & Tech Stack at Brave Care
Brave Care has built software for facilitating online appointment bookings, visitor management, records storage and management as well as mobile apps with real time chat functionality to support their patients and their caregivers.
Brave Care uses React Native, TypeScript, Postgres and Hasura as their tech stack across all of their applications. All of their business logic is hosted as serverless functions on AWS Lambda.
Adopting Hasura at Brave Care
Brave Care had already decided to use GraphQL, and even built a few custom GraphQL services. Their applications were initially built using a NoSQL database. As they were building out more functionality, they needed more out of their backend.
"Our lead engineer spent a weekend trying out Hasura on a personal project. He really liked it and came back to the team to share what Hasura did and why he thought it could be a good fit for us. This was early in the Hasura development process so we were a little nervous about that, but after talking with Hasura's team we felt like it had a strong future. We were able to stand up a quick test and build some of our backend with it."
Hasura is open source at its core, so the team knows there is no lock-in, and not being locked into Hasura also gave the team the confidence to move ahead with Hasura.
Brave Care started incrementally adopting Hasura by bringing their custom built GraphQL servers into Hasura with remote schemas. They later switched over to use Hasura Actions to delegate custom business logic to their custom GraphQL servers.
Prior to Hasura Cloud, Brave Care was hosting Hasura themselves on a Kubernetes cluster. They’ve now moved their stack over to Hasura Cloud so as to not worry about operating & scaling Hasura.
Benefits that Brave Care has observed from using Hasura
- Developer Productivity & Time to Market
Hasura lets the team focus on the parts of the application that differentiates Brave Care from their competitors. The redundant code that needs to be written time and again for building secure APIs is reduced drastically saving the team a lot of time.
Brave Care uses React Native and TypeScript heavily. With Hasura, all their developers are able to work across the stack and write TypeScript end-to-end, on the front end as well as on the back end.
Hasura removed the need to write CRUD logic. At least 50% of our application backend is just CRUD operations and it’s good to not have to write individual endpoints for each operation.
2. Role Based Access Control:
Hasura comes with extremely granular role based access control which removes the need to write permission logic. This allows Brave Care to not have access control logic in their code, and not have to worry about the security aspects of accessing data. They get to set up different authorization and permission rules, and assign it to the relevant roles from right within the Hasura Console.
3. Flexibility of Custom Logic
Hasura doesn’t restrict how you write your custom business logic. This allows Brave Care the flexibility of writing custom logic in any framework or language as a custom server or a lambda.
Another common pattern at Brave Care is to use Hasura event triggers in a reactive programming model to react to data changes, and fire other logic as required.
Brave Care uses event triggers to handle things like sending email messages, recording events into their analytics, and communicating with hardware in the clinics.
4. No Ops
In a typical backend stack, there are multiple services to install, configure and manage, including an app server, an ORM and an API gateway. Hasura reduces the ops requirement drastically by collapsing these three layers into one Hasura layer, and Hasura Cloud goes further and eliminates the ops requirement completely by fully managing this Hasura layer.
The adoption of GraphQL in general, and Hasura Cloud in specific, has been of great benefit for a company like Brave Care. Could it be the same for you? Get started in 30 seconds on Hasura and let us know.