| Pixel Event | App Event | Requirement Level | Description |
|---|---|---|---|
Search | fb_mobile_search | ◉ | Someone searched home listings |
ViewContent | fb_mobile_content_view | ◉ | Someone viewed of a specific listing |
InitiateCheckout | fb_mobile_initiated_ checkout | ◉ | Someone saved, liked or showed special interest in a listing |
Purchase | fb_mobile_purchase | ◉ | Someone contacted an agent about a listing |
<!-- Facebook Pixel Code -->
<script>
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
document,'script','https://connect.facebook.net/en_US/fbevents.js');
// Insert Your Facebook Pixel ID below.
fbq('init', '<FB_PIXEL_ID>');
fbq('track', 'Search', {
content_type: 'home_listing',
content_ids: ['1234', '2345', '3456', '4567'], // Top search results
city: 'New York City', //Required for Search event
region: 'New York', // region is the state for the US. Required for Search event
country: 'US', //Required for Search event
} );
</script>
<!-- End Facebook Pixel Code -->
| Pixel Parameter | Mobile Parameter | Requirement Level |
|---|---|---|
content_ids | fb_content_id | ◉ |
content_type | fb_content_type | ◯ |
lease_start_date | ◎ | |
lease_end_date | ◎ | |
preferred_baths_range | ◎ | |
preferred_beds_range | ◎ | |
preferred_price_range | ◎ | |
currency | fb_currency | ◎ |
property_type | ◎ | |
listing_type | ◎ | |
availability | ◎ | |
city | fb_city | ◎ |
neighborhood | ◎ | |
region | fb_region | ◎ |
country | fb_country | ◎ |
| Parameter Name | Data Type | Description |
|---|---|---|
availability | string | Value must be available_soon, for_rent, for_sale, off_market, recently_sold or sale_pending. |
city | string | Provide the user’s city of the interest, e.g. 'Menlo Park' |
content_ids | string or string[] | Any IDs in your listing catalog. For example, for ViewContent event, send the ID of the item viewed, or for Search send an array of IDs for top results: ['1234', '2345', '3456', '4567'] |
content_type | string or string[] | e.g.
|
country | string | Target country of the interest, such as 'United States' |
currency | string | Specified using ISO 4217 currency format: 'USD' |
lease_start_date | string | Allows us to recommend properties based off their date availability (using available_dates_price_config in the catalog), and improve the user landing experience (using template tags). Specified using ISO 8601 date format: 'YYYY-MM-DD' (e.g. 2018-01-01). |
lease_end_date | string | Specified using ISO 8601 date format: 'YYYY-MM-DD' (e.g. '2018-02-01'). |
listing_type | string | Value must be for_rent_by_agent, for_rent_by_owner, for_sale_by_agent, for_sale_by_owner, foreclosed, new_construction or new_listing. |
neighborhood | string | Neighborhood of interest: 'Menlo Oaks' |
preferred_baths_range | [int(min), int(max)] | Number of bathrooms chosen as range: [1, 2] |
preferred_beds_range | [int(min), int(max)] | Number of bedrooms chosen as range: [1, 2] |
preferred_price_range | [float(min), float(max)] | Price range: [1000.99, 2000.99] |
property_type | string | Must be apartment, condo, house, land, manufactured, other or townhouse. |
region | string | State, district, or region of interest: 'California' |
HTTP POST:curl \ -F '0=<PIXEL_ID>' \ -F '1=<APP_ID>' \ -F 'access_token=<ACCESS_TOKEN>' \ https://graph.facebook.com/<API_VERSION>/<PRODUCT_CATALOG_ID>/external_event_sources
| Field Name | Data Type | Description |
|---|---|---|
external_event_sources (required) | int[] | List of Pixel and App IDs to associate with the catalog. |
HTTP POST:curl \ -F 'name=My Real Estate Company Events' \ -F 'event_sources=['<PIXEL_ID>','<APP_ID>']' \ -F 'access_token=<ACCESS_TOKEN>' \ https://graph.facebook.com/<API_VERSION>/<BUSINESS_ID>/event_source_groups
HTTP POST:curl \ -F 'accounts=['<ACCOUNT_ID_WITHOUT_ACT>']' \ -F 'access_token=<ACCESS_TOKEN>' \ https://graph.facebook.com/<API_VERSION>/<EVENT_SOURCE_GROUP_ID>/shared_accounts
HTTP POST to /act_<AD_ACCOUNT_ID>/customaudiences.| Field Name | Data Type | Description |
|---|---|---|
name | string | Audience name. |
subtype | enum {CLAIM} | Type of custom audience.
Must be set to CLAIM. |
claim_objective | enum {HOME_LISTING} | Objective of audience.
Must be set to HOME_LISTING. |
event_source_group | id | Event source group to build audience. |
inclusions | object[] | Array of JSON objects. Lists each intent signal that makes someone eligible for this audience. |
inclusions: event (required) | enum {
Search,
ViewContent,
InitiateCheckout,
Purchase
} | Event name of a signal. Used for inclusion in audience: {'event': 'Search', …}. |
inclusions: retention (required) | object | Minimum and maximum amount of time since event received. Determine if event considered for inclusion. Example: {…, 'retention': {'min_seconds': 0, 'max_seconds': 259200}, …}. Retention must be at least 4 hours. |
inclusions: count | JSON operators | Number of times event fired. You can use both equality and numeric comparison operators such as {…'count': {'lte': 3}, …}. |
| Field Name | Data Type | Description |
|---|---|---|
content_type | enum {HOME_LISTING} | Type of signals used to build this audience. |
description | string | Description of audience. |
exclusions | object[] | Array of JSON objects listing each intent signal that excludes someone from this audience. |
exclusions: event (required) | enum {
Search,
ViewContent,
InitiateCheckout,
Purchase
} | Event name of a signal used for exclusion: {'event': 'Search', …}. |
exclusions: retention (required) | object | Minimum and maximum amount of time since event received. Determines if event considered for exclusion, for example, {…, 'retention': {'min_seconds': 0, 'max_seconds': 259200}, …}. Retention must be at least 4 hours. |
rule | object | Audience Rule from Website Custom Audiences. Filter event stream by these rules before any inclusions and exclusions processed.See a list of specific fields available. You can use these with any of standard JSON Operators for Audience Rules. |
rule: home_listing_set_id (required) | object | Listing set ID: {'eq': '1234'}} |
curl \
-F 'name=Viewed or Purchased Last 14 days' \
-F 'subtype=CLAIM' \
-F 'claim_objective=HOME_LISTING' \
-F 'content_type=HOME_LISTING' \
-F 'event_source_group=<EVENT_SOURCE_GROUP_ID>' \
-F 'rule={"home_listing_set_id":{"eq":"<HOME_LISTING_SET_ID>"}}' \
-F 'inclusions=[
{
"event": "ViewContent",
"count": {"gt":0},
"retention": {"min_seconds":0,"max_seconds":1209600}
},
{
"event": "Purchase",
"count": {"gt":0},
"retention": {"min_seconds":0,"max_seconds":1209600}
}
]' \
-F 'access_token=<ACCESS_TOKEN>' \
https://graph.facebook.com/<API_VERSION>/act_<AD_ACCOUNT_ID>/customaudiences