Jan 13, 2025

How fast do you ship? Measure your deployment velocity with Vercel and Tinybird

Learn how to use Vercel webhooks, Tinybird, and Next.js to build a simple app that tracks your deployment velocity.
Alasdair Brown
Developer Advocate

Vercel is the web platform for software teams that ship fast. But how fast? And do we maintain that velocity over time?

Vercel webhooks allow you to push your data out of Vercel and do whatever you want with it. This works out of the box with Tinybird’s Events API, meaning you can push all that Vercel data straight into the world’s fastest database in a few lines of code.

If you want to start from scratch and build your own insights based on your own Vercel webhook events, you can find here a step-by-step guide to send Vercel webhooks to Tinybird. 

But, in the words of daytime TV, “Here’s one I made earlier”.

Note
We're building an open source utility for devs to analyze data from their entire stack - including tools like Vercel, Auth0, GitHub, Resend, Clerk, Stripe, and more - in one place. The demo here draws from Tinynest.

Show me the money data

This dashboard (source here) can immediately show us what's happening across our Vercel team. We can see how fast we’re making changes by the number of deployments over time, and how fast we can test and iterate by plotting our deployment durations.

A dashboard showing metrics for deployment velocity in Vercel
I built these charts using Vercel webhooks, Tinybird, and a simple Next.js app.

To build this dashboard we have a stack like this:

  1. Vercel pushes data to the Tinybird Events API via webhooks.
  2. We create some SQL transformations (Pipes) in Tinybird and publish them as API endpoints.
  3. A Next.js app with shadcn/charts calls the Tinybird APIs and plots the data.

As far as web app stacks go, it couldn't be much simpler.

Adding a new chart

To add a new chart, we only need to do two things:

  1. Write a new SQL query
  2. Build the chart component

Here’s what that looks like if I want to know who gets bragging rights as the fastest developer in the west.

Vercel’s webhook data looks something like this:

I’m interested in several things in this data:

  1. The user’s git login and name
  2. The event type
  3. The event time

I want to count how many deployments each person is creating, so I can rank them. The query looks like this:

Pushing that query to Tinybird, I get an API that returns a result like this:

Just a quick fetch() to pull the data:

And via the magic of shadcn/charts, I can plot this data with little more than copy and paste

A shadcn component showing top contributors to Vercel projects
I used shadcn chart components to visualize the response from my Tinybird endpoint

But what else?

Vercel exposes many event types that we could use to further analyze this data, so what else could we do?

The only thing better than going fast is going faster, right?

We could plot deployment.error events over time to correlate the impact of errors against deployments and see how increasing error rates impact our shipping speed.

Or we could enrich deployment errors with deployment logs, find the most common errors, and eliminate them to improve deployment consistency overall. 

Once the data lands in Tinybird, exploring and productizing these ideas takes just minutes.

Give it a go. If you need help, pop into our Slack Community and ask away.

Do you like this post?

Related posts

How we processed 12 trillion rows during Black Friday
A privacy-first approach to building a Google Analytics alternative
Changelog: BigQuery connector, CLI improvements, Pagination on endpoints and more

Tinybird

Team

Mar 04, 2021
More Data, More Apps: Improving data ingestion in Tinybird
Changelog: Snowflake connector, cancellable jobs and more

Tinybird

Team

Mar 23, 2021
Low-code analytics with James Devonport of UserLoop

Tinybird

Team

May 05, 2023
How We Handle Technical Incidents and Service Disruptions
Modern data management with real-time Change Data Capture
You can now explore and analyze time series data in Tinybird
Tinybird at South Summit Madrid 2019

Build fast data products, faster.

Try Tinybird and bring your data sources together and enable engineers to build with data in minutes. No credit card required, free to get started.
Need more? Contact sales for Enterprise support.