> For the complete documentation index, see [llms.txt](https://help.gleantap.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.gleantap.com/integration/send-conversion-events-to-facebook.md).

# Send Conversion Events to Facebook

You can send online and offline conversion events to Facebook API from within Gleantap. This is done by setting up a Webhook within the flows.

Here is how you can go about it -&#x20;

1. **Go to Flows -** Click "+" to add a new Flow.
2. Add the Name of the Flow and click "Next" to specify the segment.
3. Select the segment that has your conversions.&#x20;
4. Continue forward to the Design your Flow step and click "+" select - "Action".
5. From the right panel, select Sales > "Submit to Webhook"
6. Add the following info for the Webhook
   1. URL: <https://api.gleantap.com/v1/facebook/fireConversionEvent>
   2. Method: POST
   3. Payload Type: JSON
   4. Payload
      1. email - (Select "Email" from the dropdown)
      2. phone - (Select "Phone" from the dropdown)
      3. event\_name - (Enter Custom Value - could be anything eg. "purchase")
      4. app\_id - (Enter Custom Value - this is your workroom ID. If you go to your dashboard, this is your last part of the URL after "/")
      5. pixel\_id - (Enter Custom Value - this is your facebook pixel id)
      6. access\_token - (Enter Custom Value - get your access token from facebook - [instructions here](https://developers.facebook.com/docs/marketing-api/conversions-api/get-started/))
      7. user\_id - (Select "Member ID" from dropdown)
      8. action\_source - (Enter Custom Value - this could be anything eg. "web" or "instore")
7. Click "Save"
8. Click "Publish" to go live with the flow.

Once the flow is live it starts sending each of the conversions you have in the segment to facebook. You can verify if its working correctly by clicking and opening any of the contacts that got processed through the flow and find a attribute in their profile called "fb\_conversion\_api\_response" and it should look like&#x20;

<figure><img src="https://312952119-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FaFKpjLzPT7iDAWD0tQXo%2Fuploads%2FIyb3McigpMaGbjNbE0po%2FScreenshot%202025-09-22%20at%206.15.44%E2%80%AFPM.png?alt=media&amp;token=fc7ab059-d0ae-4862-9943-ddb053d226af" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.gleantap.com/integration/send-conversion-events-to-facebook.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
