Quick overview
This workflow controls pallet deposit assets by ingesting WMS pallet events via authenticated webhooks, reconciling them against Odoo shipments, tracking liabilities in Google Sheets, escalating issues in GoHighLevel, and sending operational, finance, and executive alerts to Slack.
How it works
- Receives WMS pallet events via a POST webhook, validates an ingest token and required fields, and returns a 400/401 response for invalid requests.
- Checks Google Sheets for the event’s idempotency key to ignore duplicates, otherwise appends the transaction to a Pallet_Transactions sheet and acknowledges the webhook.
- For large damaged returns, logs a high-severity exception in Google Sheets, upserts the customer in GoHighLevel, creates a follow-up task, and posts an alert to a Slack operations channel.
- Every 4 hours, pulls recent completed stock pickings, customers, and stock move lines from Odoo and compares them to the last 6 hours of WMS dispatch transactions in Google Sheets to detect pallet variances.
- Logs ERP/WMS variance exceptions to Google Sheets, creates a dispute task in GoHighLevel, posts a Slack finance alert, and marks related transactions as reconciled or “review” in the Pallet_Transactions sheet.
- Daily at 06:00, calculates FIFO aging and deposit liability per customer from Google Sheets, upserts a reconciliation ledger, and when overdue assets or credit breaches exist, creates or reuses a single Odoo draft deposit invoice and opens GoHighLevel recovery tasks/opportunities with a critical Slack alert for CRITICAL risk.
- On a weekly schedule (or manual run), summarizes the reconciliation ledger and open exceptions from Google Sheets and posts an executive KPI digest to a Slack executive channel.
- Receives GoHighLevel resolution events via a second authenticated webhook, records the settlement transaction in Google Sheets, closes the related exception, tags the contact in GoHighLevel, posts a Slack resolution notice, and returns a 200 response.
Setup
- Create a Google Sheet with the required tabs and columns (at least Pallet_Transactions, Exception_Queue, Customer_Master, and Reconciliation_Ledger) and set the Sheet ID in the CONFIG nodes.
- Add Google Sheets service account credentials and share the spreadsheet with the service account email.
- Add an Odoo API Key credential, map Odoo partner IDs in Customer_Master, and replace the placeholder Odoo pallet product IDs (and deposit product ID) used for variance detection and draft invoicing.
- Add a GoHighLevel OAuth2 credential, create the custom fields referenced in the CONFIG nodes, and copy the webhook URLs into your GoHighLevel/WMS automations using the x-ingest-token and x-ghl-token headers.
- Add a Slack credential, set the correct channel IDs for ops/finance/exec in the CONFIG nodes, and ensure the bot has permission to post in those channels.