Stripe tells you how much money came in. It does not tell you whether that money came from a Google search, a newsletter or a post on Reddit. Connecting Stripe to Reveata joins the two halves: the payment from Stripe and the visit from your website.
What you get when you connect Stripe
- Revenue by channel, source, campaign and page. Every report that shows visitors also shows revenue, customers, conversion rate and revenue per visitor.
- Subscriptions. MRR, trials, upgrades, downgrades and cancellations come from your Stripe subscriptions. See Stripe subscription analytics.
- Refunds and disputes. A refund is booked as negative revenue on the day it happens, against the source of the original payment. A dispute that closes lost is treated like a refund.
- Built-in goals. Payments become goals such as
billing:paidandbilling:renewed, so a funnel can end at "Paid" (subscription goals). - Twelve months of history. On connect, Reveata imports the last 12 months of payments, refunds, lost disputes and subscriptions.
How the connection works
There are two ways to connect, and both give Reveata the same data:
- A restricted key. Reveata's Create the key in Stripe button opens Stripe's form with read access to Payment Intents, Invoices, Subscriptions, Checkout Sessions, Refunds, Charges, Customers and (optionally) Disputes already ticked. With write access to Webhook Endpoints, Reveata creates its own webhook. See Stripe: connect with a restricted key.
- Connect with Stripe, when the card offers it: you approve read-only access in Stripe and no webhook needs adding. See Stripe: Connect with Stripe.
New payments arrive within seconds through the webhook. If the webhook is not working yet, Reveata still reads Stripe on a schedule (every hour without a webhook, every six hours with one), so payments arrive late rather than never. Restricted keys are a Stripe feature described in Stripe's API keys documentation (opens in a new tab).
How payments are matched to visits
Connecting brings in the money. Crediting it to a visit needs the Reveata visitor id on the checkout:
| How you sell on Stripe | Where the id goes |
|---|---|
| Payment Links, Buy Buttons, Pricing Tables | Added by the script as client_reference_id=dt_<visitorId>_<sessionId>, no code |
| Checkout Sessions your server creates | metadata.reveata_visitor_id and metadata.reveata_session_id |
| Elements, Payment Element, mobile SDKs | The PaymentIntent's metadata |
| Subscriptions | The first invoice or the subscription's metadata; renewals inherit |
reveata_user_id (the id you pass to identify) is read as a third key. Payments with no id are matched by the customer's email for visitors you identified, and unmatched payments are retried every hour for 90 days.
How Reveata counts Stripe money
- A subscription invoice is one payment, without tax. A PaymentIntent that pays an invoice is counted once, through its invoice.
- A $0 invoice is not a payment; free trials come from the subscription.
- Live keys only count live payments and test keys only test payments.
- Amounts are converted to your website currency at the rate of the payment day.
Every payment is stored once under its Stripe id, however often Stripe sends it (why payments are never counted twice).