# Moonfall

> Send Moonfall calls, booked appointments, and completed visits into Ours Privacy with a webhook source, then route them to your analytics and ad destinations.

Source: https://docs.oursprivacy.com/docs/moonfall

Use this page to send calls and appointments from Moonfall into Ours Privacy as events. You copy one URL out of Ours Privacy and give it to Moonfall, and the source arrives with its mapping already set up, so no code is required on your side.

***

## Before you start

* A Moonfall account for your clinic or clinic group.
* The Ours Privacy Web SDK on your website. Moonfall reads the visitor ID it sets, which is how a phone booking connects back to the ad click and website visit that led to it.

***

## Setup

### 1. Create the source in Ours Privacy

1. Open [Sources](https://app.oursprivacy.com/sources) in the Ours Privacy dashboard.
2. Click **Add source**.
3. Select **Moonfall**.
4. On the source's **Settings** tab, copy the **Webhook URL**.

Anyone with the URL can send events to this source, so share it only with Moonfall. If it leaks, create a new Moonfall source, give Moonfall its URL, and disable the old source.

### 2. Give the URL to Moonfall

Paste the Webhook URL into Moonfall where it asks for your Ours Privacy URL. One source can serve every location in a clinic group: each event carries its location, so you can split reports and destinations by location later.

### 3. Allow the events at your destinations

Moonfall sends events named with the [Standard Healthcare Events](https://docs.oursprivacy.com/docs/standard-healthcare-events), so attribution and funnels recognize them without extra mapping:

* `call_tracked`, `appointment_booked`, and `appointment_completed` are sent by default.
* `appointment_cancelled` and `purchase` are sent when your clinic turns them on in Moonfall.

Add the events you want each destination to receive to its [allowed events](https://docs.oursprivacy.com/docs/allow-listing-events).

***

## How events are mapped

The source comes with a **Moonfall Event** mapping that connects each event to the visitor who browsed your site and uses Moonfall's event ID as the **Event ID**, so a retried event is counted once. Moonfall's own event time and location are kept as the `time` and `location_id` event properties, next to the call and appointment details Moonfall sends. You can add or change fields in the source's mapping like any other source; see [Data mapping](https://docs.oursprivacy.com/docs/data-mapping).

Events are timed when Ours Privacy receives them, which is usually within seconds of the call or booking. Use the `time` property when you need the moment Moonfall recorded.

***

## Test your integration

After Moonfall sends its first event, open the source's **Preview Data** panel to see the latest payload, then check [Recent Events](https://docs.oursprivacy.com/docs/tracking-and-debugging-events) for the mapped event.

***

## Next steps

* [Standard Healthcare Events](https://docs.oursprivacy.com/docs/standard-healthcare-events) for the properties each event carries.
* [Deduplication](https://docs.oursprivacy.com/docs/deduplication) for how the Event ID keeps retried events from counting twice.
* [Track and debug events](https://docs.oursprivacy.com/docs/tracking-and-debugging-events) to confirm calls and appointments are arriving.

***

## Need help?

Contact [support@oursprivacy.com](mailto:support@oursprivacy.com) if calls or appointments are not showing up in Ours Privacy.
