Contextflo Blog

The SaaS analytics stack: Postgres + Stripe + Amplitude + HubSpot

Your product, billing, usage, and CRM data live in four different systems. Here's how to query across all of them without building a data warehouse.

May 13, 20264 min readVivek Sah

Product data is in Postgres. Billing is in Stripe. Usage is in Amplitude. CRM is in HubSpot. The question your CEO keeps asking, which customers with declining usage are up for renewal next month, needs all four at once.

SaaS analytics stack setup

The problem

SaaS has the most fragmented data of any business model. Product behavior sits in one system, revenue in another, the customer relationship in a third, usage in a fourth. And the questions worth asking, churn risk, expansion revenue, which features predict an upgrade, always cross at least two of them.

Without a data team, the answer to nearly every cross-source question is "let me pull that together and get back to you." Which usually means a spreadsheet, a few hours, and a number nobody will be able to reproduce next quarter.

The setup

  1. Postgres → Contextflo, direct database connection
  2. Stripe + Amplitude + HubSpot → Contextflo, direct API connections
  3. All sources → queryable from Claude in one conversation

No warehouse, no ETL. That is the point of this particular stack: for a company at this stage, the warehouse is usually the most expensive part of the setup and the least of the value.

Use a read replica rather than your primary Postgres. Analytical queries scan far more than product queries do, and the last thing you want is a curious question during business hours competing with checkout.

What you can ask once it is connected

Which customers with declining Amplitude usage are up for Stripe renewal in the next 30 days?

What's the correlation between feature X usage in Amplitude and upgrade rate in Stripe?

Show me all HubSpot deals in negotiation where the contact's company has more than 50 active users in our product.

What's our net revenue retention by cohort, broken down by which features they use most?

The join key problem

Every question above is really a join across four systems, and the thing that decides whether the answer is right is what identifies a customer in each one.

Postgres has an internal account ID. Stripe has a customer ID. Amplitude has a user ID that is often a person rather than an account. HubSpot has a company record, which is a sales construct and may not map cleanly to either. A question about "customers with declining usage" is quietly asking you to resolve four different identities into one.

Sort this out once, at the start, by deciding which system is authoritative for account identity and how each other system maps into it. Write that mapping down as a saved definition. Skipping this is the single most common way teams end up with a confident answer that is quietly counting the wrong thing, and it is much harder to notice than a query that errors.

The good news is it is a one-time job, and it is the same work a warehouse model would have forced you to do anyway.

The unlock

The most valuable SaaS insight almost always sits at the intersection of product, revenue, and customer data, and that intersection is exactly what no single tool owns. Building a unified model over all four is a multi-month project that most teams under Series B should not start.

This gets you the cross-source answers now, with the identity mapping as the only real modeling work. When you eventually do build the warehouse, that mapping is the first thing you would have written anyway.

Connect your product, billing and usage data and ask across all of it in Claude. Free for one user and one data source.

Get started for free, or talk to the founder.