It's sometimes necessary to add additional invoices to your customers after they have been imported from your billing system. For example, if a customer has been billed in multiple systems, their full billing history may not be reflected in ChartMogul.
This article will demonstrate how to manually add additional invoices to your customers in ChartMogul with our Google Sheets app without needing to make changes in your billing system.
Contents
- Installing the Google Sheets app
- Setting up the Google Sheets app
- Adding historic invoices to customers
Installing the Google Sheets app
Install the Google Sheets app by navigating to the ChartMogul app page in the Google Apps Web Store and then click Install.
Next, create a new Google Sheet and open the ChartMogul app by clicking Add-ons > ChartMogul.
This will open the ChartMogul Google Sheets app in the sidebar of the Google Sheet.
Setting up the Google Sheets app
You will need to be an admin to access your API Keys.
1. Enter your ChartMogul API Keys
You can find your API Keys in ChartMogul > Admin > API. Enter your ChartMogul API Account Token and Secret Key in the fields provided in the ChartMogul Google Sheets app.
2. Select Billing Data
Select Billing Data from the ChartMogul Google Sheets app navigation menu.
3. Creating a Data Source
In the ChartMogul Google Sheets app, enter a memorable name for your Data Source (such as "Google Sheets") and click Create Data Source. You will only need to do this once. Next time you open the Billing Data section of the app you will be prompted to select a data source.
Adding historic invoices to customers
Let's say your customer John Smith has a $100/month subscription to the Gold Monthly plan. They were billed from January to September for their monthly subscription in another billing system until you began billing them through Recurly in October.
To add these historic invoices from January to September to ChartMogul using the Google Sheets app, you would have to:
- Create a new customer
- Create a new plan called Gold Monthly
- Add the historic invoices to the new customer
- Merge the newly created customer into the existing customer record
Create a new customer
Enter your customer details into a Google sheet according to the requirements and then click on Send customer to ChartMogul.
Create a new plan
Create a new plan according to the requirements. In this example scenario with the plan_name of "Gold Monthly", an interval_count of "1", and an interval of "month". When ready to load your plan, hit Send to ChartMogul.
Add historic invoices
To import these historic invoices from January to September to ChartMogul you would:
- Import two "subscription" type invoices.
- The invoice Email or External id would be the Email or External id of the customer you just created through Google Sheets.
- The invoice amount in cents for both invoices would be 10000.
- The plan name would be Gold Monthly.
- You would also need to import a "subscription_cancellation" type invoice. To cancel a customer's subscription, use the customer's email address or ID in the Email or External id field, enter "subscription_cancellation" in the Type field, also add the Date and the Subscription number. If the customer only has one subscription, or if you left this field blank when creating a customer's subscription, enter "1" for the Subscription number field, otherwise enter the corresponding subscription number that you would like to cancel.
- Click on Send invoices to ChartMogul
Merge the customer records
You would need to merge the Google Sheets customer record into the customer record imported from Recurly to complete this process.
The Recurly customer in this example scenario would look like this:
The Google Sheets customer in this example scenario would look like this:
You can merge the two customers by:
- Navigating to the Google Sheets customer.
- Clicking MERGE at the top right of the profile page.
- Finding and selecting the Recurly customer.
- Clicking Next > Confirm and Merge.
The end result will look like this: