pex

Stripe

The Stripe connector imports payment data — charges, refunds, and customer information — giving you actual revenue numbers to pair with your marketing and experiment data. This is the bridge between "leads generated" and "money earned."

Authentication

Stripe supports two authentication methods:

  1. OAuth via Stripe Apps (recommended) — One-click authorization through Stripe's marketplace
  2. API Key — Direct integration using a restricted Stripe API key

The method is determined automatically based on whether STRIPE_APP_CLIENT_ID and STRIPE_APP_SECRET_KEY are configured.

Click Connect on the Sensors page

Find the Stripe card and click Connect.

Authorize (OAuth) or enter your API key

OAuth: You'll be redirected to Stripe's marketplace to authorize the Apex app. Select the Stripe account to connect.

API Key: Enter a restricted API key with charges:read and customers:read permissions. You can create one in the Stripe Dashboard under Developers > API Keys.

Verify the connection

Apex validates the connection by fetching a single charge. If successful, the Stripe card shows a green "Connected" badge.

Warning

If using an API key, create a restricted key with only the read permissions Apex needs. Never use your Stripe secret key directly.

Data Synced

Each sync paginates through Stripe charges for the configured date range:

DataDescription
ChargesSuccessful charges with amount, currency, and timestamp
Customer emailResolved from the charge's customer object or receipt email
Revenue totalSum of all successful charges (amounts converted from cents)

Refunds and failed charges are excluded — only status: succeeded charges are imported.

How Apex Uses This Data

  • Revenue attribution — Match charges to leads via customer email. When a Stripe customer's email matches a lead captured by the tracking snippet, Apex attributes that revenue to the original marketing channel
  • LTV calculation — Aggregate charges per customer to build lifetime value metrics
  • Experiment ROI — Measure the actual revenue impact of experiments, not just conversion rate lift
  • True ROAS — Combine with Google Ads, Meta Ads, or LinkedIn Ads spend to calculate return on ad spend using real payment data

Tip

Revenue attribution works best when your Stripe customers have email addresses. Ensure your checkout flow captures the customer's email — this is what links a payment back to the marketing touchpoint.

Configuration

ParameterTypeDescription
access_token or api_keyrequiredstringOAuth access token (set automatically) or restricted Stripe API key.
dateRangeobjectCustom date range for charge syncs. Default: last 30 days.

Troubleshooting

IssueCauseFix
"Invalid API key"Key is malformed or revokedGenerate a new restricted key in Stripe Dashboard
No charges returnedNo successful charges in the date rangeExpand the date range or verify charges exist in Stripe
Revenue not matching leadsCustomer emails don't match lead emailsEnsure your Stripe checkout captures the same email used in your forms

Next Steps