Stripe data sync and ReTool
Last Authored: Monday, July 24th, 2023By: KJ Chabra
In this tutorial, we will be exploring how to sync data from Stripe into Dynamo Database Tables and creating a dashboard in ReTool to display sales data and MRR in almost realtime.
For this tutorial, we will be syncing Charges, Products and Subscriptions data only.
Why?
Stripe's dashboard for calculating MRR is delayed by 24-48 hours. With Project Compound you can make it almost real-time.
You can give internal team members access to ReTool shielding customer data and preventing data leaks
In ReTool, using the native Stripe API connection is paginated and takes a long time to query. With Project Compound, since the data is written to AWS Dynamo DB, the data can be fetched immediately.
ReTool has the ability to cache queried data. Hence, if multiple team members are querying data with same parameters, cached data is used to display the info.
Why use Project Compound?
Project Compound delivers a well tested solution that is self-hosted on your own AWS (all the data stays in your own domain)
Additionally it reduces time, effort and nuisances of working with API's that are rate limited
You don't need to know how to code or architect software or cloud resources (the guided UI will handle that for you)
Requirements
Stripe Private Key with read access to Charges, Products and Subscriptions scope
Who is this for?
Businesses using Stripe as a method of collecting payments (one time fee or subscriptions).
Get in touch via Twitter or Email if you have any questions regarding this tutorial.
End Result
Workflow Diagram
Steps
Start by Creating a new application from dashboard page and entering data into the Settings stage. Once all the inputs have been entered, click the Next button.
In the Interaction stage, select Stripe > Charges and fill out the required inputs. To retrieve stripe token, follow the steps listed on the Stripe Private Key page.
In the Extraction stage, you will have to select Dynamo DB option from the AWS services menu.
This will render a form which allows you to enter the table name.
Enter the table name, which will be created on deployment. We also list out the indexes that will be created in the table.
Once the table name has been entered, the Next button becomes enabled which will allow you to deploy the app.
You can test the sync from the Dashboard page under Triggers and Testers to ensure scheduler and the trigger are configured properly.
Repeat steps 1 - 6 for syncing of Stripe Products and Stripe Subscriptions
ReTool
Start by navigating to Resources tab in the menu and click on create a new Resource
Search for "Dynamo" and click on Amazon DynamoDB option
In the "Configure Amazon DynamoDB" page enter the credentials you pasted in the settings stage of Project Compound
Click Test Connection and if that succeeds click on "Create resource"
Navigate to the Apps and click Create New > From JSON
Upload this JSON and you should have the app layout in your ReTool
Lastly, change all the Resource to the one you created in Step 3 and ensure Tables are correctly entered for each resources
Once you have altered all the Resource details, simply hit the refresh button for Charges and Subscriptions tab and you should see the data on the dashboard