How PlanetScale uses WorkOS to power the next generation of serverless databases

PlanetScale is a MySQL-compatible serverless database built on top of Vitess, the open source database behind Youtube, Square, and Hubspot.

Serverless and edge computing are two of the fastest-growing cloud paradigms today. These emerging deployment patterns became popular thanks to AWS Lambda, Cloudflare Workers, and Vercel Edge Functions. PlanetScale uses Vitess, the database behind, to provide a serverless database to their users.

Today PlanetScale serves hundreds of millions of queries a day across thousands of databases, and its customers include companies like Airbnb, Slack, and GitHub. Along the way, this meant they needed to become enterprise ready and build new features for IT admins. That's why they chose WorkOS — to help move upmarket.

When I asked the team, how was the experience with WorkOS? They were just like, this is incredible.

— Sam Lambert, CEO

As their enterprise database service hit general availability, PlanetScale raised $50M in Series C funding so that developers from any company size can be productive without ever having to worry about scale.

Single Sign-On: the first step to becoming Enterprise Ready

The engineering team at PlanetScale uses the WorkOS Ruby SDK to abstract away the complexity of supporting multiple identity providers.

Single Sign-On (SSO) was the first API they integrated, followed by Admin Portal. This combination allowed them to build a self-serve experience that doesn't require all the back-and-forth that typically happens when setting up SSO.

Enabling SSO on PlanetScale's Dashboard

Once SSO is enabled, organization members can log in using the credentials configured in their company's identity provider. There are two ways you can configure that within WorkOS; you can choose between initiating SSO via connection ID or organization ID.

The data modeling that made more sense for PlanetScale was via organization ID. After persisting that data, the WorkOS API is responsible for handing off the rest of the authentication workflow.

Authenticating via SSO on PlanetScale

Using Directory Sync to manage user access

When it comes to something as important as roles and permissions, it's crucial to have all of the tools necessary to control who and what can access your data. Iheanyi Ekechukwu, Senior Software Engineer at PlanetScale, showed us how their Surfaces team used WorkOS to build an easier way to manage database administrator access within PlanetScale.

Loving the use of WorkOS, I'm having fun integrating with it.

— Iheanyi Ekechukwu, Sr. Software Engineer

By leveraging Directory Sync, they built the concept of teams, which allow users to easily manage administrator access to one or multiple databases in one spot. If a customer is using Azure AD, for example, they can synchronize all directories and groups into PlanetScale.

Visualizing Organization Teams within PlanetScale

With teams, users can create groups within their organization, add members, and assign them administrator access to one or more databases. They also have the option to add administrators to a database directly on the database settings page, but if they want to group admin access all in one place, teams is the way to go.

The cool thing about this is that administrators have the freedom to update the roles of members as needed. If a new employee joins the organization or if a member is removed from a group, their access is automatically provisioned or deprovisioned. All of this is taken care of by WorkOS in real time.

Managing roles of team members on PlanetScale

Try SSO and Directory Sync now

By using WorkOS, PlanetScale can close more enterprise deals and focus on what matters to them: building scalable databases with impeccable developer experience.

If you want to initiate that same transformation at your company, you can try WorkOS today.


Developer Tools

Cloud Databases

WorkOS stack
Single Sign-On
Directory Sync
Admin Portal
Time to integrate

Add SSO,
the easy way.

WorkOS provides a single, elegant interface abstracting dozens of enterprise integrations.

More customer stories
“We refused to build username and password functionality, both because it was a dying security tactic and because it was resource intensive.”
John Myers
Co-Founder & CTO
Read more
“The Admin Portal gives our customers a polished experience. It’s exciting to see customers want to use SSO now and to give them the Admin Portal.”
Samantha Kaplan
Senior Manager
Read more

What’s your enterprise story?

WorkOS is the only integration you’ll need to get enterprise customers using your application.

This site uses cookies to improve your experience. Please accept the use of cookies on this site. You can review our cookie policy here and our privacy policy here. If you choose to refuse, functionality of this site will be limited.