Please make sure that the proper browser is being used to setup and use this integration. For more information, refer to this article from Salesforce.
Install the Application Package
Salesforce System Administrator permissions are required.
Click on the Salesforce package link and login to the target environment and select Install for Admins Only.
Click Install to start the installation.
The app will take some time to install. A prompt appears letting you know that you will receive an email once the installation is complete.
When done, confirm that the package is installed by navigating to Setup > Installed Packages.
Assign Permission Sets
There are two permission sets which can be assigned through Setup > Users.
-
Maxio AB Admin
This permission set should only be assigned to those who will modify the configuration of the integration. Maxio AB Admin permission set includes all of the permissions of the Advanced Billing User, so there is no need to assign both to Admin users.
-
Maxio AB User
This permission set should be assigned to all other users of the integration.
Add Remote Site Settings for Your Advanced Billing Sites
-
Navigate to Setup > Remote Site Settings.
-
For each Advanced Billing Site you want to connect with Salesforce, create a new remote site settings record by clicking New Remote Site.
-
Enter the Remote Site Name (for example, "MaxioAdvancedBilling") and enter the Remote Site URL (your Maxio Advanced Billing URL in the form of "https://<servername>.chargify.com/").
Remote Site Naming Requirements
The Remote Site Name can only contain underscores and alphanumeric characters. More specifically, this name must be unique, begin with a letter, not include spaces, not end with an underscore, and not contain two consecutive underscores.
- Check the Active box and click Save.
Connecting the Integration to a Advanced Billing Site
For this procedure (steps 6 and 7), you will need:
- The domain of the Advanced Billing site you are connecting to from Salesforce;
- The API Key, which can be found in the Advanced Billing by navigating to Config > Integrations > API Keys.
-
Login to your Salesforce environment as the Admin user (the one with Advanced Billing Admin permission set assigned previously).
-
Navigate to the Salesforce App Launcher.
-
Select the Maxio Advanced Billing app.
If you don't see it from the dropdown you may need to select View All.
- Click the Maxio AB Configuration tab.
The integration is disabled by default. You must complete the following configuration steps before enabling the integration.
-
Click Add Maxio AB Site to Salesforce.
-
From the Maxio AB Site Config page, enter the Maxio AB Site Name, which is the domain of the Advanced Billing site.
Only the subdomain.chargify.com is used. Remove the https:// from the site name.
-
Add your API Key, which is generated in the Advanced Billing app by navigating to Config > Integrations > API Keys.
- Check the isActive checkbox and click Create Site to save the configuration.
Data Validation Report
Before configuring and turning your integration on, we recommend you run a Data Validation Report. This report allows you to see what exactly will be matched from Advanced Billing to Salesforce. To run this report, go to the Maxio AB Configuration tab, then click Data Validation Report.
From the Running Data Validation Report popup, click Run Report and click OK in the popup that follows to confirm.
The time it takes to generate the report depends on the size of the data volume of your Maxio AB instance. You will receive an email once the report is ready.
The Data Validation button also indicates the "in progress" status and is grayed out.
To view the report results, click the Advanced Billing PreIntegration tab, where you will find a breakdown of everything that currently matches between Advanced Billing and Salesforce, giving you a preview of how things will be synced. This report includes Customer, Products, Components, and Coupons and matches between existing Salesforce records.
Customer Configuration Options
Before clicking Turn On Integration, we recommend you review the Customer Configuration options and, if needed, make changes. These settings will determine sync timings as well as what is synced between Advanced Billing and Salesforce.
A few things to note about how the sync works:
- The Batch Sync setting determines when data is pulled by Salesforce from Advanced Billing (via Maxio AB API) using the batch job timing setup (Maxio AB Configuration tab).
- Any changes in Salesforce will immediately be synced over to Advanced Billing.
The settings are pre-configured for you, and you can keep defaults. But you do have the option to change settings to meet your workflow needs.
Data Flow (Batch Processing)
In this section of the Maxio AB Configuration tab, you can change the sync timing. This timing is when Salesforce will pull new data over from Advanced Billing.
Customer Sync Direction
Customer Configuration settings will dictate what customer information is synced between Salesforce and Advanced Billing. The Customer ID is required and the ultimate matching ID. First the integration is going to search for matching Customer ID, if not found then will search Reference ID, if not found, then search by email.
Of course if you opt out from matching by Reference or email, this step will be skipped. When a match using Reference or Email is found, the system populates Customer ID. From now on, the match is established and the system will not try to match by Reference or Email.
Choose the direction of synchronization between Advanced Billing and Salesforce. If Sync both ways is chosen, Advanced Billing and Salesforce can be used to update Customer information and the sync will update the other apps information.
If Sync from Maxio AB to Salesforce is chosen, any updates in Salesforce will not be synced to Advanced Billing. Updates in Advanced Billing will be synced to Salesforce. This setting is helpful if separate Account/Contact names are used between Salesforce and Advanced Billing. This will prevent names and information from being overwritten in Advanced Billing.
Scope
Choose the scope of synchronization between Advanced Billing and Salesforce.
-
All Accounts with respective primary Contact will be synced to Advanced Billing as a Customer. This setting will allow for Subscriptions to be created later with that information.
-
Only Accounts marked “Sync to Advanced Billing” will be synced to Advanced Billing. Note, that every Customer received from Advanced Billing will be automatically marked as “Sync to Advanced Billing”. This option is handy if Accounts/Contacts need to be selectively synced. This setting can be found when editing a Contact.
Matching Customers
Choose how to match Salesforce accounts and contacts with Advanced Billing customers. Matching by customer Id is defaulted and cannot be unchecked.
-
Customer ID - the ultimate matching Id between Advanced Billing and Salesforce. This will always be used first.
-
Reference ID - uses unique IDs used between Advanced Billing and Salesforce to determine if the customer is already existing.
-
Emails - can also be used to match Accounts/Contacts and Customers between Advanced Billing and Salesforce.
Match Found Behavior
-
Override all fields - default option is set to update data each time a change is identified and a match is found.
-
Populate only empty fields - when the match is found the system will populate only empty fields, leaving the existing data unchanged.
-
Do not update any information (except Customer Id) - no updates are made when a match is found. A new Account will be created in SF when there is no match found, but the updates are turned off.
No Match Found Behavior
This option determines what occurs when no Match between Advanced Billing and Salesforce is found. Either an Account will be created if no match is found between Advanced Billing and Salesforce or alternatively this can also be set to not create a new account.
Customer Hierarchy
Only one option supported. Checking with will allow for Advanced Billing customer hierarchies to be synced over.
Batch size for Customer
Batch size for Customer. Entry value between 1-2000.
Product Configuration Options
-
Product Sync Direction
Sync products from Advanced Billing to Salesforce. Currently only one option is available. -
Sync Scope
Sync all Products from Advanced Billing to your Salesforce price book. -
Matching options
Allows for product matching based on API Handle or Product ID. Helpful if other integrations are using another one or the other. -
Batch size for Product
Batch size for Product. Entry value between 1-2000.
Subscription Configuration Options
-
Sync Scope - Sync both ways
Selecting this option will allow for sync both ways. -
Sync Scope - All subscription
When selected all subscriptions will be synced. -
Opportunity Closed/Won option
Options for how Opportunities are handled after being Closed or Won. Create Subscription when Opportunity is Closed/Won.Block closing opportunity without Payment Method. -
Batch size for Subscription
Batch size for Subscription. Entry value between 1-2000.
Transactions Configuration Options
-
Transactions Sync Status
When enabled transaction status will be displayed. -
Transactions Sync Direction
Advanced Billing to Salesforce. -
Retention period in Days
Maximum age of the Transactions to synchronize in days. Records older than retention period will be removed to save the cloud storage. -
Batch size for Transactions
Batch size for Transactions. Entry value between 1-2000. -
Transaction types
When moved into the Selected column these transactions will be displayed in Salesforce. Transactions that can be displayed are: Charge, Credit, Adjustment, Payment, Refund.
Enable the Integration
After the desired sync options are selected you can now turn on your sync. To enable the integration, click the Turn ON integration button located at the top of the Maxio AB Configuration tab. The status then changes to ENABLED and the button label toggles to Turn OFF integration, which can be used to disable the integration if needed.
Configure Your Salesforce Layouts
The final installation steps are to configure the layouts for your Salesforce - Advanced Billing views by adding the Advanced Billing action buttons and fields which you want to have in your Advanced Billing - Salesforce integration.
The following are recommended steps, but you can decide to add or not add fields and buttons per your workflow requirements.
Setup Account Layout
-
From the Setup screen, navigate to Object Manager > Account.
-
On the left navigation panel, select Page Layouts and then select the Advanced Billing Accounts Layout.
-
From Accounts Layout, create an Advanced Billing section by going to the palette list and selecting the Fields view (A in the image below).
-
Drag the Section field (B) into the page layout and name the section Advanced Billing.
-
Select and place the fields you want into the Advanced Billing section.
- From the palette list, switch from the Fields to the Buttons view.
- Drag the Create Subscription button to Custom Buttons in the Contact Details section of the layout
-
Again, from the palette list, select Mobile & Lightning Actions view (A in the image below).
-
Drag the Create Subscription action (B) to Account Details > Custom Buttons area (C) of the layout.
-
From the palette list, switch to Related Lists view.
-
Drag Maxio AB Subscriptions to the lists section of the layout.
-
Repeat for related Advanced Billing lists, which include: Advanced Billing Invoices, Advanced Billing Transaction, and Advanced Billing Events.
-
Click Save.
Setup Contact Layout
- From the Setup screen, navigate to Object Manager > Contact.
- On the left navigation panel, select Page Layouts and then select Contact Layout.
-
From Contact Layout, create an Advanced Billing section by going to the palette list and selecting the Fields view (A in the image below).
- Drag the Section field (B) into the page layout and name the section Advanced Billing.
- Select and place the fields you want into the Advanced Billing section.
- From the palette list, switch from the Fields to the Buttons view.
-
Drag the Create Subscription button to the Custom Buttons box in the Contact Details section of the layout.
- Again, from the palette list, switch from the Buttons to the Mobile & Lightning Actions view.
- Drag the Create Subscription action to Account Details > Custom Buttons area of the layout.
- From the palette list, switch to the Related Lists view.
- Drag Maxio AB Subscriptions to the lists section of the layout.
- Click Save.
Setup Product Layout
- From the Setup screen, navigate to Object Manager > Product.
- On the left navigation panel, select Page Layouts and then select Product Layout.
- From Contact Layout, create an Advanced Billing section by going to the palette list and selecting the Fields view.
- Drag the Section field into the page layout and name the section Advanced Billing.
- Select and place the fields you want into the Advanced Billing section.
- From the palette list, switch from the Fields to the Related Lists view.
-
Drag Maxio AB Subscriptions to the lists section of the layout (A in the image below).
Other Advanced Billing related lists are available, which include: Maxio AB Invoices, Maxio AB Transaction, and Maxio AB Events.
- Next, drag Maxio AB Subscriptions Preview to the lists section of the layout (B in the image above).
- Click Save.
- Next, on the left navigation panel, select List View Button Layout.
- From the List View drop-down, select Edit.
-
Under Custom Buttons, add Create Coupon to the Selected Buttons box.
-
Click Save.
Setup Opportunity Layout
- From the Setup screen, navigate to Object Manager > Opportunity.
- On the left navigation panel, select Page Layouts and then select Opportunity Layout.
-
From the palette list, switch from the Fields to Buttons view.
-
Drag the New Subscription button to the Custom Buttons box in the Opportunity Details section of the layout.
-
From the palette list, switch from the Buttons to the Mobile & Lightning Actions view.
-
Drag New Subscription to the Salesforce Mobile and Lightning Experience Actions section of the layout.
-
Again, from the palette list, switch to the Related Lists view.
-
Drag Maxio AB Subscriptions to the Related Lists section of the layout.
-
Then drag Maxio AB Subscriptions Previews to the lists section of the layout.
-
Click Save.
Setup Opportunity Product Layout
- From the Setup screen, navigate to Object Manager > Opportunity Product.
- On the left navigation panel, select Page Layouts and then select Opportunity Product Layout.
- From Opportunity Product Layout, create an Advanced Billing section by going to the palette list and selecting the Fields view.
- Drag the Section field into the page layout and name the section Advanced Billing.
- Drag the Maxio AB Subscription Preview field into the Opportunity Product Detail section.
- Click Save.
Setup Advanced Billing Subscription Layout
- From the Setup screen, navigate to the Salesforce Object Manager.
- Select Maxio AB Subscription.
- Navigate to the layout configuration tool via Page Layouts > Maxio AB Subscription Layout.
- Change the selection view from Fields to Buttons.
- Drag the buttons names below to the Custom Button area under Maxio AB Subscription Detail:
- Cancel Subscription
- Clear Pending Cancellation
- Give/Deduct Service Credit
- Put On Hold
- Reactivate Subscription
- Record Prepayment
- Resume
- From the palette list, switch from the Buttons to the Mobile and Lightning Actions view.
- Once on this page, drag the actions below into the Salesforce Mobile and Lightning Experience Actions area:
- Cancel Subscription
- Clear Pending Cancellation
- Give/Deduct Service Credit
- Put On Hold
- Reactivate Subscription
- Record Prepayment
- Resume
- If you would like to view subscription component allocations and history this can be done by clicking from Mobile and Lightning Actions to Visualforce Pages.
- Drag a new Section onto the page and label it “Component Allocations”.
- Drag Advanced Billing Components into the newly created section.
- Click Save.
Custom Offer Signup Pages
Custom Offer Signup Page is an externally available offer summary page, that can be shared with the customer for secured self-signup. The custom offer page can be accessed from Opportunity > Subscription Preview > Generate Signup Link.
Force.com Site Creation
-
From Setup, go to Sites and register a custom Force.com domain for your organization.
-
Create a New site.
- Choose a Visualforce page for the "Active Site Home Page" required field. You can use ChargifyPublicOfferSignupPage.
- Click Save, to create the site.
- Scroll down on the newly created Site, and click Edit in the Visualforce Pages section and enable the following Visualforce pages:
- ChargifyJSIframe
-
ChargifyPublicOfferSignupPage
- Click Activate on the Site Details page.
Here is the full Salesforce’s guide on creating and setting up Force.com Sites.
Custom Offer Template Creation
- To create a template for Custom Offer Signup Pages, go to the Maxio AB Signup Page tab and click New Maxio AB Signup Page.
-
Fill in the required fields as follows:
- Maxio AB Signup Config Name - enter a helpful name (the name is for internal use only. The prospective subscriber won't see this on their end).
- Force.com Site URL - field enter the full Site URL (starting with “https://”) from the site created in the section above. URL can be found in Setup > Sites.
- Advanced Billing Site Config - Field if the offer applies to only one site. Leave blank if the offer is applicable for all sites.
- Validity in Days - You can override Validity in days number (default is 14). Value can be changed further per specific Custom Offer.
- Page Content Section is optional.
- And if you chose to show it on the offer sign-up page, fill in the Terms & Conditions field.
Custom Offer Signup Page Creation
To generate a Custom Offer Signup Page, go to Opportunity > Subscription Preview and click Generate Signup Link.
Setup CPQ
These steps are required if you plan on enabling CPQ functionality in Salesforce. Once completed you will find new options in your quote configuration screen that will allow you to add subscriptions to the quote.
Add Custom Fields
- Go to Setup > Create > Objects > Quote Line (SBQQ__QuoteLine__c).
- Create a new Lookup field to the Advanced Billing Subscription Preview object, making sure the fields are as follows:
- Field Label: Chargify Subscription Preview
- Field Name: Chargify_subscription_preview
- Create a new formula field and fill in the fields as follows:
- Field Label: Chargify Subscription
- Field Name: Chargify_subscription
- Formula Type: Checkbox
-
Formula:
NOT(ISBLANK(Chargify_subscription_preview__c))
Create Custom Actions for CPQ
- Go to Setup > Create > Objects > object “Custom Action” (SBQQ__CustomAction__c).
- Find and edit the field “Label” (SBQQ__Label__c).
-
Add the following three new values to the picklist:
- New CH Subscription
- Edit CH Subscription
- Upgrade CH Subscription
- Click the Custom Actions tab.
- Click New Custom Action, and set up the fields as follows:
- Name: New CH Subscription
- Display Order: 2
- Type: Button
- Active: true
- URL Target: Replace Page
- URL: /apex/CHRGFYNG__ChargifyCPQRedirect?id={!Id}&type=create
- Page: Quote Line Editor
- Location: Quote
- Action: Save and Navigate
- Label: New CH Subscription
- Click Save.
- Click New Custom Action and make sure the fields are named as follows:
- Name: Upgrade CH Subscription
- Display Order: 3
- Type: Button
- Active: true
- URL Target: Replace Page
- URL: /apex/CHRGFYNG__ChargifyCPQRedirect?id={!Id}&type=add
- Page: Quote Line Editor
- Location: Quote
- Action: Save and Navigate
- Label: Upgrade CH Subscription
- Click Save.
- Click New Custom Action again and make sure the fields are named as follows:
- Name: Edit CH Subscription
- Display Order: 1
- Type: button
- Active: true
- Icon: edit
- URL Target: Replace Page
- URL: /apex/CHRGFYNG__ChargifyCPQRedirect?id={!Id}&type=edit"eid={!SBQQ__Quote__c.Id}
- Page: Quote Line Editor
- Location: Line
- Label: Edit CH Subscription
Create Triggers
- Go to Setup > Create > Objects > Quote (SBQQ__Quote__c).
- Create new trigger, then copy and paste the code below:
trigger ChargifyQuoteTrigger on SBQQ__Quote__c (before insert, before update, before delete, after insert, after update, after delete, after undelete) { CHRGFYNG.ChargifyCPQAPI.QuoteTrigger(Trigger.operationType, Trigger.old, Trigger.new, Trigger.oldMap, Trigger.newMap); }
- Go to Setup > Create > Objects > Quote Line (SBQQ__QuoteLine__c).
- Create a new trigger, then copy and paste the code below:
trigger ChargifyQuoteLineTrigger on SBQQ__QuoteLine__c (before insert, before update, before delete, after insert, after update, after delete, after undelete) { CHRGFYNG.ChargifyCPQAPI.QuoteLineTrigger(Trigger.operationType,Trigger.old,Trigger.new,Trigger.oldMap,Trigger.newMap); }
Configure Quote Line Item Editor (Optional)
- Navigate to Setup > Installed Packages > Salesforce CPQ > Configure > Line Editor.
- Enable Option: Visualize Product Hierarchy.
- Move the product name to the top of the list.
- Go to Setup > Create > Objects > Quote Line (SBQQ__QuoteLine__c) > Field Set.
- Click Edit for the Line Editor.
- Move the product Code after the Product Name.
- Add Field Advanced Billing Subscription.
- Click Save.