Automated GHL Opportunity to QuickBooks Invoicing (Make.com)

Streamline revenue recognition by automatically generating QuickBooks invoices from GoHighLevel 'Won' opportunities using Make.com.

Tools: GHLQuickBooks

Platform: Make.com

Short Answer

A seamless, real-time sync where 'Won' opportunities in GoHighLevel trigger the creation or update of a QuickBooks customer and the generation of a corresponding invoice with accurate line items and tax data.

The Problem

Manual data entry between CRM sales stages and accounting software leads to invoicing delays, human error in line-item pricing, and fragmented financial reporting. Sales teams often forget to notify accounting when a deal is closed, resulting in stalled cash flow.

The Outcome

A seamless, real-time sync where 'Won' opportunities in GoHighLevel trigger the creation or update of a QuickBooks customer and the generation of a corresponding invoice with accurate line items and tax data.

Step-by-Step Guide

1. **Create Scenario**: In Make.com, create a new scenario and add the **GoHighLevel (GHL)** module with the 'Watch Opportunities' trigger. Create a 'Webhook' and copy the URL into a GHL Workflow (Trigger: Opportunity Status Changed to Won -> Action: Webhook). 2. **Establish Connections**: Authenticate GHL via API Key/OAuth and QuickBooks Online via OAuth2. Ensure you have 'Company Admin' rights in QuickBooks. 3. **Search Customer**: Add a **QuickBooks Online** 'Search for Customers' module. Use the `Email` from the GHL bundle as the search criteria (Query: `PrimaryEmailAddr = '{{1.contact.email}}'`). 4. **Add Router**: Place a Router module after the search. This allows the logic to bifurcate based on whether the customer was found. 5. **Create/Update Customer Path**: - **Path A (Customer Not Found)**: Set a filter `Total number of bundles` equal to 0. Add 'Create a Customer' module. - **Path B (Customer Found)**: Set a filter `Total number of bundles` greater than 0. Add 'Update a Customer' module using the `ID` from the search result. 6. **Map Line Items**: Add a **QuickBooks Online** 'Create an Invoice' module. Since GHL might send multiple products, use the `map()` function or an **Iterator** if GHL returns an array of products to build the `Line` items array for the invoice. 7. **Define Revenue Account**: In the 'Create Invoice' module, manually select or map the `Income Account ID` (e.g., 'Sales of Product Income'). This is a required field in QuickBooks API. 8. **Error Handling**: Right-click the QuickBooks modules and select 'Add error handler'. Use a **Break** module to retry on temporary API timeouts or a **Rollback** if the data is malformed. 9. **Feedback Loop**: Add a final **GHL** 'Add Tag to Contact' module to tag the lead as 'Invoiced' or 'QB-Synced' to prevent duplicate triggers.