This guide walks you through the setup process for Stripe on Sync Inc. In just a couple of minutes, you'll have a Postgres database with all your Stripe data, syncing in real-time.
First, add your Stripe secret key to Sync Inc:
Step 1: Create a new Sync Inc account at https://app.syncinc.so/signup.
Step 2: Select Stripe as the paltform you want to sync.
Step 3: Provide us with your Stripe secret key (it should begin with the characters
`sk_live_`). On our console, click the How do I get this? link if you need a little help generating your API key or follow this link to your Stripe dashboard.
As a best practice, we recommend you create a new Restricted secret key for Sync Inc. Sync Inc needs read permissions for everything and just write access for webhooks.
Step 4: Select the destination database you want to sync your data to. We can sync to a new or existing database we provision and host. Or, we can sync to a database you host (just send us a note).
Step 5: Click Create.
After you click Create, we'll immediately connect to Stripe and begin backfilling all your data. While we're backfilling, you can still connect to your database and start querying your data.
As soon as your database is provisioned, you can connect to it and start querying.
Step 1: Download and install TablePlus from https://tableplus.com/.
Step 2: Open TablePlus and click Create a new connection...
Step 3: Click the Import from URL button.
Step 4: Copy and paste the Connect URL from Sync Inc into the Connection URL in TablePlus then click Import.
Step 5: Then name your your TablePlus connection and click Create.
To begin playing with your data, you can use our in-browser query tool. Just click "Connect" then visit the "Query" tab.
This simple query will calculate the total revenue for each of your Stripe customers:
selectcustomer.email as "customer",sum(invoice.amount_paid) as "total revenue"from customerleft join invoice on invoice.customer = customer.idgroup by customer.email;
From here, check out our Cheat Sheet for quick tips on how to query your Stripe database in SQL.
Read our Stripe Reference to learn more about how we make Stripe work with SQL.