Use Google App Scripts to import Stripe data to Google Sheets

In this article, we'll use the Google App Script platform to get data from Stripe into Google Sheets before creating a new Spreadsheets widget.

Note

We do have a Stripe integration with the following widgets:

  • Number widget:
    Display counts of charges by status, customers, coupon redeemed and subscriptions
  • Subscriptions by plan:
    Display bar chart of subscription counts by plan
  • Current balance:
    Retrieve your available, pending or net balance

Create a Stripe widget using data from Google Sheets

To create a Stripe widget using data pulled from a Google Sheet, follow these steps:

  1. Make sure you're already logged into your Google Drive account.
  2. Make a copy of this Google Sheet.
  3. To find your Stripe secret key, log in to your Stripe account.
  4. Click Account from the top right hand of the page.
  5. Click Account Settings.
  6. Click the API Keys from the top tabs. Here, you will need the Live Secret Key.
  7. Return to your copied Stripe Sync 1.8 spreadsheet.
  8. From the navigation menu, click Add-ons > Stripe Sync > Setup.
  9. In the pop-up window that appears, enter your Live Secret Key, Granularity, Initial load and Metrics where prompted.Stripe sync settings
  10. Click Save.
  11. Select a cell in your spreadsheet where you want balance data to be written.
  12. Click Add-ons > Stripe Sync > Initial Load.
  13. Click Run.

    Tips

    When you want to manually refresh the balances, click Add-ons > Stripe Sync > Manual Sync.

    To schedule the values to sync every hour, click Add-ons > Stripe Sync > Schedule Sync. To cancel this schedule click Add-ons > Stripe Sync > Cancel Schedule.

  14. With your data now populating your Google Sheet, switch to your Geckoboard dashboard to start creating some Stripe widgets.
  15. Click Add widget, located in the top right of your dashboard.
  16. Search for Spreadsheets using the Search sources field.

    Alternatively, you can also scroll down the alphabetical list of integrations until you reach the Spreadsheets integration.
  17. Click on the Spreadsheets integration.
  18. Choose the copied Stripe Sync 1.8 spreadsheet with your Stripe data on.
  19. Create your widget by configuring the way you’d like to visualize the data.
  20. And that's it! You may also find this step-by-step video useful.
Was this article helpful?

Awesome! 👍  Thanks so much for your feedback!