Your agency's CRM sends each new lead into Moonshot EHR. When the front desk turns that lead into a patient, the EHR tells the CRM, so the agency sees which leads became patients without asking the clinic. Works with HighLevel and any CRM that can send and receive webhooks.
How it fits together
Leads travel in from the CRM. What happens to them at the clinic travels back out.
lead.converted
lead.linked
lead.created
Both directions
The CRM keeps running the ads, the forms and the follow-up. The EHR keeps the patient record. Each tells the other what it needs to know.
The CRM posts each new lead to the clinic's lead webhook address, with the clinic's key. Email is the one required field.
The clinic switches each event on in Settings > Notifications > Marketing webhook. Each is sent to one https address the clinic saves.
lead.converted). Sent once per lead when it becomes a new patient: staff convert it, or create a chart from its online registration.lead.linked). Sent once per lead when it turns out to be someone who is already a patient. Same body as a conversion, with its own event name.lead.created). A lead the front desk adds by hand on the Leads page. Leads that came from the CRM are never sent back, so nothing loops.Why it matters
Ads reach people who are already patients. A current patient sees a promotion, fills in the form, and becomes a lead in the CRM like anyone else. If the CRM only ever hears about new patients, that lead either sits open forever, or someone closes it by hand and it gets counted as a new patient the campaign won. Either way the agency's report is wrong.
Moonshot EHR keeps the two apart. A lead that matches a current patient reaches the front desk flagged Already a patient. When staff put it on the existing chart, the CRM receives Lead matched to an existing patient instead of Lead converted to patient.
The agency closes the contact without counting a new patient. Open leads are people still deciding, new-patient counts are new patients, and the clinic owner and the agency read the same numbers.
At the clinic
The desk works leads in the EHR, and every lead shows what came in and what was sent back.
Each lead arrives with its source badge and the service the visitor asked about. Event and webinar sign-ups are filed under Event or Webinar, with the ad platform kept on the lead.
The visitor's message is on the lead's timeline, labelled From the form. Other answers sit in the lead drawer under their own labels, and the campaign in Attribution.
A lead that matches a current patient lands in New flagged Already a patient, so the desk knows a patient responded. Link to patient puts it on the existing chart.
Every conversion or match sent to the CRM writes a line on the lead's timeline: delivered, or not delivered with the reason and a prompt to tell the marketing team.
The Marketing webhook card lists the last 50 events with Delivered, Pending or Failed, the HTTP code and the number of attempts.
Pick an event and send a sample to the CRM. The result, delivered with the HTTP status or failed and why, shows next to the button.
Setup
The clinic and the agency each do their half. The clinic's steps are on one Settings card.
X-Tenant-Slug and X-Webhook-Key. In HighLevel, a Custom Webhook action sends the contact's fields as flat pairs, which is what the address expects.For the agency's developer
Lead events carry the lead's name, email and phone, the lead source, the campaign attribution captured with the lead and the service they asked about. Converted and matched events also carry the chart id and the time. Deliveries go only to the https address the clinic saved, and are signed with HMAC-SHA256 when the clinic sets a secret. The clinic points that address only at a system covered by its agreements with that vendor (a BAA where one is required).
Field names, the response receipt, event bodies, headers and signature checks are in the developer reference: Send leads and Receive signed events.
HighLevel is named on this page as an example CRM. This integration is independently developed by Moonshot Clinic LLC and is not affiliated with or endorsed by HighLevel.
Book a demo and bring your agency. We'll walk through the Leads board, the Marketing webhook card and exactly what your CRM receives.
Book a Demo