> ## Documentation Index
> Fetch the complete documentation index at: https://restoo.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Restoo Connect

> Connect Restoo to GA4, Google Ads, Meta Pixel, TikTok Pixel, OpenAI Pixel, or Google Tag Manager, with the visitor's consent applied per destination.

Restoo Connect translates [Restoo Widget Events](/widget/events) into the native calls expected by your analytics and advertising platforms. It can send events directly to **Google Analytics 4**, **Google Ads**, **Meta Pixel**, **TikTok Pixel**, and **OpenAI Pixel**, or push the equivalent data to **Google Tag Manager**.

**Enable the destinations you use [in your Restoo account](/widget/integrations) and Restoo Connect does the rest**: it turns every event into the call each platform expects, and **applies the visitor's consent** destination by destination. You collect the consent — **working out what each platform is allowed to receive is already done**.

## Before you start

What you need to prepare depends on **where your guest books**, because that decides who loads the measurement tags.

**If the widget is embedded in your own site**, the tags live on your page and Restoo Connect only forwards to the ones already there: it **installs none**, not inside the iframe either. Each destination needs its own tag installed and loaded **before** Restoo.js; otherwise the first events are lost. And you collect the consent: you pass it in with [`setConsent()`](/widget/advanced-installation#setconsent-signals) or by declaring your [consent platform](/widget/consent#what-a-consent-management-platform-is).

**If your guests book on the page Restoo hosts for you**, there is nothing to prepare on your site: Restoo loads the tags configured in your account — GA4, Google Ads, Meta Pixel, TikTok Pixel, and OpenAI Pixel — and collects consent with its own cookie notice. The exception is Google Tag Manager, which never loads on the pages Restoo hosts.

Each destination states what it needs in [its own section](#destinations). If its library is unavailable, Restoo Connect logs a warning and skips that operation; the other destinations keep working.

<Note>
  **Already managing your tags through Google Tag Manager?** Then you don't need
  the direct destinations: [enable `gtm` in your
  account](/widget/integrations#google-tag-manager) and the tags in your
  container forward every event as they already did. It only works with the
  widget on your own site, which is where your container lives. And if you need
  more than this model gives you, skip Restoo Connect and build your integration
  from [Restoo Widget Events](/widget/events).
</Note>

And it forwards nothing to a destination until it knows the visitor's decision: each one requires its own consent signals. See [Consent](/widget/consent#what-each-destination-requires) for what each destination needs, the extra requirement for `customer_identified`, and the one exception, `gtm`.

## Turn a destination off for one installation

The only thing a page can declare is **turning a destination off here**, because it is the one thing your account can't know: whether a given platform's library is actually installed on this particular page.

```js theme={null}
widget.create({ connect: { gtm: false } });
```

<ParamField body="connect" type="object">
  Destinations to switch off for this installation. `false` is the only accepted value: anything
  else, including an unknown destination name, is ignored and logged as a warning in the console.
  Everything else about a destination comes from your account.

  Worth doing on a page that doesn't have a destination's library installed: left enabled, every
  event it should send is skipped with a warning.

  <Expandable title="properties">
    <ParamField body="ga4" type="false">
      Stops sending to Google Analytics 4 from this installation.
    </ParamField>

    <ParamField body="googleAds" type="false">
      Stops sending conversions to Google Ads from this installation.
    </ParamField>

    <ParamField body="metaPixel" type="false">
      Stops sending to the Meta Pixel here, Advanced Matching included.
    </ParamField>

    <ParamField body="tiktokPixel" type="false">
      Stops sending to the TikTok Pixel from this installation.
    </ParamField>

    <ParamField body="openaiPixel" type="false">
      Stops sending to the OpenAI Pixel from this installation.
    </ParamField>

    <ParamField body="gtm" type="false">
      Stops pushing to `window.dataLayer` from this installation.
    </ParamField>
  </Expandable>
</ParamField>

```html theme={null}
<!-- Load the enabled platform scripts before the Restoo widget. -->
<script
  type="module"
  src="https://best-burger.myrestoo.net/js/restoo-widget"
></script>
<script>
  window.addEventListener("restoo:loaded", () => {
    window
      .Restoo("best-burger")
      .create({
        // This landing page has no GTM container; every other destination
        // comes from the account.
        connect: { gtm: false },
      })
      .bindTriggers();
  });
</script>
```

Restoo Connect is initialized before the first widget event is emitted. If your account has no destination enabled — or this installation turns every one of them off — it is **not initialized**: no event goes out to any destination.

<Warning>
  Do not send the same event to the same destination twice. If GTM forwards
  Restoo events to a GA4 property, do not also enable the direct `ga4`
  destination for that property, or the other way round — see [avoiding duplicate
  conversions](/widget/bidding-optimization#avoiding-duplicate-conversions-across-ga4-google-ads-and-gtm).
</Warning>

## Destinations

What each destination sends and what it needs to receive it. IDs and conversion labels [are stored in your account](/widget/integrations).

What appears as **"On your page"** is your job if you embed it in your site; hosted on Restoo, Restoo puts it there.

### Google Analytics 4

The `ga4` destination. Sends events directly through `gtag("event", …)`. See the [Google Analytics 4 event reference](/widget/connect-mappings#google-analytics-4) for event mappings and data models.

**On your page:** load [`gtag.js`](https://support.google.com/analytics/answer/9539598) and configure your [GA4 property](https://support.google.com/analytics/answer/14183469) with `gtag("config", "G-…")`.

**In your account:** save the [measurement ID and declare what you use that property for](/widget/integrations#google-analytics-4). That answer decides [what consent `ga4` requires](/widget/consent#ga4-with-a-property-that-feeds-advertising); until you give it, Restoo applies the strict case.

### Google Ads

The `googleAds` destination. Sends conversions directly through `gtag`. Hashed email and phone data are attached through Google Enhanced Conversions when available. See [Google Ads conversions](/widget/connect-mappings#google-ads) for conversion mappings and setup.

**On your page:** load `gtag.js` and configure your [Google Ads account](https://support.google.com/google-ads/answer/6366720) with `gtag("config", "AW-…")`.

**In your account:** save [the conversion ID and one label per action](/widget/integrations#google-ads). Only the actions that have a label fire a conversion, and [what fires each one](/widget/connect-mappings#google-ads) is in the reference.

Each booking fires **only one** booking conversion — `booking_lead` or `booking_confirmed`, according to the status it is created with — so it is never counted twice. Neither sends `value` or `currency`.

### Meta Pixel

The `metaPixel` destination. Sends supported lead-acquisition events through `fbq("trackSingle", pixelId, …)` and manages Advanced Matching through `fbq("init", pixelId, userData)`. See the [Meta Pixel reference](/widget/connect-mappings#meta-pixel) for event mappings and parameters.

**On your page:** [install the Meta Pixel](https://www.facebook.com/business/help/952192354843755) so `fbq` is available.

**In your account:** save the [pixel ID](/widget/integrations#meta-pixel). It is what associates the guest's hashed email and phone with that pixel, so it decides who receives personal data — which is why a page cannot point this destination somewhere else.

### TikTok Pixel

The `tiktokPixel` destination. Sends supported lead-acquisition events through `ttq.instance(pixelId).track(…)` and updates customer matching data through `ttq.instance(pixelId).identify(…)`. See the [TikTok Pixel reference](/widget/connect-mappings#tiktok-pixel) for event mappings and parameters.

**On your page:** [install the TikTok Pixel](https://ads.tiktok.com/help/article/get-started-pixel) so `ttq` is available.

**In your account:** save the [pixel ID](/widget/integrations#tiktok-pixel), which is required to enable this destination. Restoo Connect uses the `ttq` already initialized on your page and scopes every call to that pixel, so the other pixels on the page receive nothing.

### OpenAI Pixel

The `openaiPixel` destination, the ChatGPT Ads pixel. Sends supported lead-acquisition events through `oaiq("measureSingle", pixelId, …)` and sets customer matching data through `oaiq("init", { pixelId, user })`. See the [OpenAI Pixel reference](/widget/connect-mappings#openai-pixel) for event mappings and data.

**On your page:** [install the OpenAI Pixel](https://developers.openai.com/ads/measurement-pixel) so `oaiq` is available. That SDK starts with its own consent granted, so your cookie notice has to call `oaiq("consent", false)` before `init` and `oaiq("consent", true)` when the visitor accepts, as [its documentation](https://developers.openai.com/ads/measurement-pixel#control-measurement-consent) describes. That switch governs everything your page sends to that pixel and Restoo Connect leaves it alone: it applies [its own](/widget/consent#what-each-destination-requires), destination by destination.

**In your account:** save the [pixel ID](/widget/integrations#openai-pixel), which is required to enable this destination. Restoo Connect uses the `oaiq` already initialized on your page and scopes every call to that pixel, so the other pixels on the page receive nothing.

### Google Tag Manager

The `gtm` destination. Pushes the GA4-compatible event mapping to `window.dataLayer`. See the [Google Tag Manager reference](/widget/connect-mappings#google-tag-manager) for event mappings and data locations.

**On your page:** install your [GTM container](https://support.google.com/tagmanager/answer/14847097) so `window.dataLayer` is available.

**In your account:** save your [GTM container ID](/widget/integrations#google-tag-manager). GTM stays yours: Restoo never loads it.

**Your tags apply their own consent**, because `window.dataLayer` is a router, not a destination: [what `gtm` requires and what it doesn't](/widget/consent#what-each-destination-requires).

## Check that events fire

Before calling the installation done, make a test booking with each platform's Chrome extension and watch which events show up. The extensions, the symptom table and what the console tells you are all in [Troubleshooting](/widget/diagnostics).

## Next steps

<CardGroup cols={2}>
  <Card title="Event mapping" icon="table" href="/widget/connect-mappings">
    The full event mappings, their parameters, and the Google Ads setup.
  </Card>

  <Card title="Bidding and optimization" icon="bullseye" href="/widget/bidding-optimization">
    Choose which events your campaigns optimize toward on each platform.
  </Card>
</CardGroup>
