Using Zapier to push new trial customers from HubSpot to ChartMogul

Pushing trial customers to ChartMogul enables you to track metrics such as Leads and Trial to paid conversion rates alongside your subscription metrics. Zapier allows you to automatically send leads to ChartMogul when they are created in your CRM or billing system. 

This article will demonstrate how to import new trial accounts from HubSpot. 

This zap requires multiple actions. You'll therefore need a paid Zapier account.

If you want to manually import historical trial data into ChartMogul (in bulk), you can use our Google Sheets App

Setup instructions

  1. In Zapier, click Make a Zap.
  2. Select HubSpot as your trigger app, then click New Contact as the trigger. You may need to connect your HubSpot account to Zapier if you haven't already done this. 
    Screen_Shot_2018-09-17_at_3.07.32_PM.png
  3. Select Formatter by Zapier as your first action app, then click Date/Time as the action.
    Screen_Shot_2018-09-17_at_3.09.02_PM.png
  4. In the Formatter by Zapier template, enter the following details:
    • For Transform, select Format.
    • When the Values field becomes available, select Became a lead date.
    • For To Format, select YYYY-MM-DD (2006-01-22).
    • For From Format, select X (1137971045).
    • Leave UTC as default for both time zones.

    Screen_Shot_2018-09-17_at_3.15.54_PM.png
  5. Click continue, then Test this step.
    Screen_Shot_2018-09-17_at_3.20.50_PM.png 
  6. Click Add a Step and search for Webhooks by Zapier as your action app, then click POST as the action.  
    Screen_Shot_2018-09-17_at_3.24.51_PM.png
  7. In the Webhooks by Zapier template, enter the following details:
    • The URL should be https://api.chartmogul.com/v1/import/customers
    • The Payload Type should be json
    • The Data fields should have the following values: 
      Screen_Shot_2018-09-17_at_3.28.36_PM.png
    • For Free_trial_started_at, choose the formatted date field in Step 2 that best suits your needs. This can include custom fields you've created as long as the value is a date. However, you may need to add an additional action with the Formatter by Zapier app to format any additional dates you would like to use.
    • In the data_source_uuid field, enter the ChartMogul Import API data source UUID. You can create a ChartMogul Import API data source by navigating to ChartMogul > Admin > Data Load and clicking Add data source. Once you have created an Import API data source, copy the data source UUID provided and paste it into the data_source_uuid field in the Webhooks by Zapier template.
    • Leave the Wrap Request In Array, File, and Unflatten fields as the default values.
    • Enter your ChartMogul API Token and Secret Key in the Basic Auth field separated by the pipe character (|). For example, if your API Token is 123 and your API Secret Key is 456, you would enter 123|456 in this field. Next, find your API Token and Secret Key in ChartMogul > Admin > API.
    • In the Headers field, enter Content-Type as the key and application/json as the value. Screen_Shot_2018-09-17_at_3.40.02_PM.png
  8. Click on Continue, then Send Test to Webhooks by Zapier to ensure that the Zap will import new leads and trial HubSpot accounts into your ChartMogul account. You should see the following success message:
    Screen_Shot_2018-09-17_at_3.33.54_PM.png
  9. Click Finish, enter a name for the Zap, and click Turn on Zap.
When a customer converts from a free trial to a paying customer, a duplicate customer record will be created in ChartMogul from your billing connector. When this happens, you should merge the trial customer record with the new customer record. You need to complete this step to report trial to paid conversion rates. 

We'd love to hear how you use Zapier to automate integrations with ChartMogul. Please write to us at platform@chartmogul.com if you'd like to share feedback and ideas for integrations.

Was this article helpful?