汽車廣告使用的事件具有一組參數(事件參數詳細資訊的完整清單)。您可以在網站上使用 Facebook 像素,也可以在 Android 應用程式和 iOS 應用程式中使用行動應用程式事件。
這份指南會假設您已安裝 Facebook 像素。如尚未安裝,請參閱針對像素使用行銷 API。
注意事項
// This sample assumes the FB Pixel base code is already loaded fbq('track', 'Search', { content_type: 'vehicle', // RECOMMENDED: If sent, it must be set to 'vehicle' content_ids: ['123'], // RECOMMENDED: array of vehicle IDs postal_code: '94025', // RECOMMENDED country: 'United States', // RECOMMENDED don't use abbreviations make: 'Lexus', // RECOMMENDED model: 'ES', // RECOMMENDED year: '2017', // RECOMMENDED state_of_vehicle: 'CPO', // RECOMMENDED exterior_color: 'black', // RECOMMENDED transmission: 'automatic', // RECOMMENDED body_style: 'sedan', // RECOMMENDED fuel_type: 'gasoline', // RECOMMENDED drivetrain: 'awd', // RECOMMDENDED price: 1234.99, // RECOMMENDED, up to 2 decimals optional currency: 'USD', // REQUIRED if price and preferred_price_range is used, currency has to be the same for both price and preferred_price_range preferred_price_range: '[10000,20000]' // Optional up to two decimals, min,max });
// This sample assumes the FB Pixel base code is already loaded fbq('track', 'ViewContent', { content_type: 'vehicle', // RECOMMENDED: If sent, it must be set to 'vehicle' content_ids: ['123'], // REQUIRED: array of vehicle IDs postal_code: '94025', // RECOMMENDED country: 'United States', // RECOMMENDED don't use abbreviations make: 'Lexus', // RECOMMENDED model: 'ES', // RECOMMENDED year: '2017', // RECOMMENDED state_of_vehicle: 'CPO', // RECOMMENDED exterior_color: 'black', // RECOMMENDED transmission: 'automatic', // RECOMMENDED body_style: 'sedan', // RECOMMENDED fuel_type: 'gasoline', // RECOMMENDED drivetrain: 'awd', // RECOMMDENDED price: 1234.99, // RECOMMENDED, up to 2 decimals optional currency: 'USD', // REQUIRED if price and preferred_price_range is used preferred_price_range: '[10000,20000]' // Optional up to two decimals, min,max });
// This sample assumes the FB Pixel base code is already loaded fbq('track', 'AddToWishlist', { content_type: 'vehicle', // RECOMMENDED: If sent, it must be set to 'vehicle' content_ids: ['123'], // REQUIRED: array of vehicle IDs postal_code: '94025', // RECOMMENDED country: 'United States', // RECOMMENDED don't use abbreviations make: 'Lexus', // RECOMMENDED model: 'ES', // RECOMMENDED year: '2017', // RECOMMENDED state_of_vehicle: 'CPO', // RECOMMENDED exterior_color: 'black', // RECOMMENDED transmission: 'automatic', // RECOMMENDED body_style: 'sedan', // RECOMMENDED fuel_type: 'gasoline', // RECOMMENDED drivetrain: 'awd', // RECOMMDENDED price: 1234.99, // RECOMMENDED, up to 2 decimals optional currency: 'USD', // REQUIRED if price and preferred_price_range is used preferred_price_range: '[10000,20000]' // Optional up to two decimals, min,max });
這份指南會假設您已在 Android 行動應用程式中實作 Facebook SDK。如果尚未實作,請參閱 Android SDK。如果使用成效衡量合作夥伴,請確認合作夥伴是否將必要事件傳遞給 Facebook。
Bundle parameters = new Bundle(); // IF YOU CHOOSE NOT TO USE A RECOMMENDED PARAM, THEN REMOVE IT, DON'T LEAVE IT EMPTY // RECOMMENDED: If sent, it must be set to 'vehicle' parameters.putString(AppEventsConstants.EVENT_PARAM_CONTENT_TYPE, "vehicle"); // RECOMMENDED: content ids - include eg top 5 search results parameters.putString(AppEventsConstants.EVENT_PARAM_CONTENT_ID, "[\"123\", \"234\", \"345\", \"456\", \"567\"]"); // top search results // RECOMMENDED: postal_code parameters.putString("fb_postal_code", "94025"); // RECOMMENDED: country parameters.putString("fb_country", "United States"); // RECOMMENDED: make // Allows you to target people based on their search of a specific make parameters.putString("fb_make", "Lexus"); // RECOMMENDED: model // Allows you to target people based on their search of a specific make model parameters.putString("fb_model", "ES"); // RECOMMENDED: year, in yyyy format // Allows you to target people based on their search for vehicles manufactured from a specific year parameters.putInt("fb_year", "2017"); // RECOMMENDED: state_of_vehicle // Allows you to target people based on their search of specific type of vehicle parameters.putString("fb_state_of_vehicle", "CPO"); // RECOMMENDED: exterior_color parameters.putString("fb_exterior_color", "black"); // RECOMMENDED: transmission parameters.putString("fb_transmission", "automatic"); // RECOMMENDED: body_style // Allows you to target people based on their search of a vehicle body style parameters.putString("fb_body_style", "sedan"); // RECOMMENDED: fuel_type parameters.putString("fb_fuel_type", "gasoline"); // RECOMMENDED: drivetrain parameters.putString("fb_drivetrain", "awd"); // RECOMMENDED: price parameters.putInt("fb_price", 1234.99); // RECOMMENDED: currency parameters.putInt("fb_currency", 'USD'); // RECOMMENDED: preferred_price_range parameters.putInt("fb_preferred_price_range", '[10000,20000]'); // Fire the 'Search' event on the search results page logger.logEvent(AppEventsConstants.EVENT_NAME_SEARCHED, parameters );
Bundle parameters = new Bundle(); // IF YOU CHOOSE NOT TO USE A RECOMMENDED PARAM, THEN REMOVE IT, DON'T LEAVE IT EMPTY // REQUIRED: content id of the vehicle that is shown parameters.putString(AppEventsConstants.EVENT_PARAM_CONTENT_ID, "123"); // RECOMMENDED: If sent, it must be set to 'vehicle' parameters.putString(AppEventsConstants.EVENT_PARAM_CONTENT_TYPE, "vehicle"); // RECOMMENDED: postal_code parameters.putString("fb_postal_code", "94025"); // RECOMMENDED: country parameters.putString("fb_country", "United States"); // RECOMMENDED: make // Allows you to target people based on their search of a specific make parameters.putString("fb_make", "Lexus"); // RECOMMENDED: model // Allows you to target people based on their search of a specific make model parameters.putString("fb_model", "ES"); // RECOMMENDED: year, in yyyy format // Allows you to target people based on their search for vehicles manufactured from a specific year parameters.putInt("fb_year", "2017"); // RECOMMENDED: state_of_vehicle // Allows you to target people based on their search of specific type of vehicle parameters.putString("fb_state_of_vehicle", "CPO"); // RECOMMENDED: exterior_color parameters.putString("fb_exterior_color", "black"); // RECOMMENDED: transmission parameters.putString("fb_transmission", "automatic"); // RECOMMENDED: body_style // Allows you to target people based on their search of a vehicle body style parameters.putString("fb_body_style", "sedan"); // RECOMMENDED: fuel_type parameters.putString("fb_fuel_type", "gasoline"); // RECOMMENDED: drivetrain parameters.putString("fb_drivetrain", "awd"); // RECOMMENDED: price parameters.putInt("fb_price", 1234.99); // RECOMMENDED: currency parameters.putInt("fb_currency", 'USD'); // RECOMMENDED: preferred_price_range parameters.putInt("fb_preferred_price_range", '[10000,20000]'); // Fire the 'ViewContent' event on the vehicle details or other specific content page logger.logEvent(AppEventsConstants.EVENT_NAME_VIEWED_CONTENT, parameters );
Bundle parameters = new Bundle(); // IF YOU CHOOSE NOT TO USE A RECOMMENDED PARAM, THEN REMOVE IT, DON'T LEAVE IT EMPTY // REQUIRED: content id of the vehicle that is added to wishlist parameters.putString(AppEventsConstants.EVENT_PARAM_CONTENT_ID, "123"); // RECOMMENDED: If sent, it must be set to 'vehicle' parameters.putString(AppEventsConstants.EVENT_PARAM_CONTENT_TYPE, "vehicle"); // RECOMMENDED: postal_code parameters.putString("fb_postal_code", "94025"); // RECOMMENDED: country parameters.putString("fb_country", "United States"); // RECOMMENDED: make // Allows you to target people based on their search of a specific make parameters.putString("fb_make", "Lexus"); // RECOMMENDED: model // Allows you to target people based on their search of a specific make model parameters.putString("fb_model", "ES"); // RECOMMENDED: year, in yyyy format // Allows you to target people based on their search for vehicles manufactured from a specific year parameters.putInt("fb_year", "2017"); // RECOMMENDED: state_of_vehicle // Allows you to target people based on their search of specific type of vehicle parameters.putString("fb_state_of_vehicle", "CPO"); // RECOMMENDED: exterior_color parameters.putString("fb_exterior_color", "black"); // RECOMMENDED: transmission parameters.putString("fb_transmission", "automatic"); // RECOMMENDED: body_style // Allows you to target people based on their search of a vehicle body style parameters.putString("fb_body_style", "sedan"); // RECOMMENDED: fuel_type parameters.putString("fb_fuel_type", "gasoline"); // RECOMMENDED: drivetrain parameters.putString("fb_drivetrain", "awd"); // RECOMMENDED: price parameters.putInt("fb_price", 1234.99); // RECOMMENDED: currency parameters.putInt("fb_currency", 'USD'); // RECOMMENDED: preferred_price_range parameters.putInt("fb_preferred_price_range", '[10000,20000]'); // Fire the 'AddToWishlist' event on the vehicle details or other specific content page logger.logEvent(AppEventsConstants.EVENT_NAME_ADDED_TO_WISHLIST, parameters );
這份指南會假設您已在 iOS 行動應用程式中實作 Facebook SDK。如果尚未實作,請參閱 iOS SDK。如果使用成效衡量合作夥伴,請確認合作夥伴是否將必要事件傳遞給 Facebook。
// Fire the 'Search' event on the search results page [FBSDKAppEvents logEvent:FBSDKAppEventNameSearched // IF YOU CHOOSE NOT TO USE A RECOMMENDED PARAM, THEN REMOVE IT, DON'T LEAVE IT EMPTY parameters:@{ // RECOMMENDED: If sent, it must be set to 'vehicle' FBSDKAppEventParameterNameContentType : @"vehicle", // RECOMMENDED: content ids - include eg top 5 search results FBSDKAppEventParameterNameContentID : @"[\"123\", \"234\", \"345\", \"456\", \"567\"]", // RECOMMENDED: postal_code @"fb_postal_code" : @"94110", // RECOMMENDED: country @"fb_country" : @"US", // RECOMMENDED: make // Allows you to target people based on their search of a specific make @"fb_make" : @"Toyota", // RECOMMENDED: model // Allows you to target people based on their search of a specific make model @"fb_model" : @"Camry", // RECOMMENDED: year, in yyyy format @"fb_year" : @"2015", // RECOMMENDED: state_of_vehicle // Allows you to target people based on their search of specific type of vehicle @"fb_state_of_vehicle" : @"CPO", // RECOMMENDED: exterior_color @"fb_exterior_color" : @"black", // RECOMMENDED: transmission @"fb_transmission" : @"automatic", // RECOMMENDED: body_style // Allows you to target people based on their search of a vehicle body style @"fb_body_style" : @"Sedan", // RECOMMENDED: fuel_type @"fb_fuel_type" : @"gasoline", // RECOMMENDED: drivetrain @"fb_drivetrain" : @"awd", // RECOMMENDED: price @"fb_price" : @18000, // RECOMMENDED: currency @"fb_currency" : @"USD", // RECOMMENDED: preferred_price_range @"fb_preferred_price_range" : @"[10000,20000]", } ];
// Fire the 'ViewContent' event on the search results page [FBSDKAppEvents logEvent:FBSDKAppEventNameViewedContent // IF YOU CHOOSE NOT TO USE A RECOMMENDED PARAM, THEN REMOVE IT, DON'T LEAVE IT EMPTY parameters:@{ // REQUIRED: content ids for vehicle shown FBSDKAppEventParameterNameContentID : @"123", // RECOMMENDED: If sent, it must be set to 'vehicle' FBSDKAppEventParameterNameContentType : @"vehicle", // RECOMMENDED: postal_code @"fb_postal_code" : @"94110", // RECOMMENDED: country @"fb_country" : @"US", // RECOMMENDED: make // Allows you to target people based on their search of a specific make @"fb_make" : @"Toyota", // RECOMMENDED: model // Allows you to target people based on their search of a specific make model @"fb_model" : @"Camry", // RECOMMENDED: year, in yyyy format @"fb_year" : @"2015", // RECOMMENDED: body_style // Allows you to target people based on their search of a vehicle body style @"fb_body_style" : @"Sedan", // RECOMMENDED: state_of_vehicle // Allows you to target people based on their search of specific type of vehicle @"fb_state_of_vehicle" : @"CPO", // RECOMMENDED: exterior_color @"fb_exterior_color" : @"black", // RECOMMENDED: transmission @"fb_transmission" : @"automatic", // RECOMMENDED: fuel_type @"fb_fuel_type" : @"gasoline", // RECOMMENDED: drivetrain @"fb_drivetrain" : @"FWD", // RECOMMENDED: price @"fb_price" : 18000, } ];
// Fire the 'AddToWishlist' event on the search results page [FBSDKAppEvents logEvent:FBSDKAppEventNameAddedToWishlist // IF YOU CHOOSE NOT TO USE A RECOMMENDED PARAM, THEN REMOVE IT, DON'T LEAVE IT EMPTY parameters:@{ // REQUIRED: content id of vehicle added to wishlist FBSDKAppEventParameterNameContentID : @"123", // RECOMMENDED: If sent, it must be set to 'vehicle' FBSDKAppEventParameterNameContentType : @"vehicle", // RECOMMENDED: postal_code @"fb_postal_code" : @"94110", // RECOMMENDED: country @"fb_country" : @"US", // RECOMMENDED: make // Allows you to target people based on their search of a specific make @"fb_make" : @"Toyota", // RECOMMENDED: model // Allows you to target people based on their search of a specific make model @"fb_model" : @"Camry", // RECOMMENDED: year, in yyyy format @"fb_year" : @"2015", // RECOMMENDED: body_style // Allows you to target people based on their search of a vehicle body style @"fb_body_style" : @"Sedan", // RECOMMENDED: state_of_vehicle // Allows you to target people based on their search of specific type of vehicle @"fb_state_of_vehicle" : @"CPO", // RECOMMENDED: exterior_color @"fb_exterior_color" : @"black", // RECOMMENDED: transmission @"fb_transmission" : @"automatic", // RECOMMENDED: fuel_type @"fb_fuel_type" : @"gasoline", // RECOMMENDED: drivetrain @"fb_drivetrain" : @"FWD", // RECOMMENDED: price @"fb_price" : 18000, } ];
儘管各家汽車廣告商的目標可能各有差異,網站的自訂追蹤需求也不盡相同,我們仍歸納出汽車網站最常見的動作和 KPI,據此在以下提供一些建議的參數。
參數是標準事件的子集,用於追蹤每個動作的其他相關資訊。舉例來說,若您正在追蹤車輛詳細資料頁面(VDP)上的 ViewContent
事件,則每次有人瀏覽車輛詳細資料頁面時,您便可利用參數同時擷取汽車廠牌、車款、年份等資訊。
雖然一般像素設定的參數是選用項目,但一些特定參數對於汽車廣告卻是必要的。我們建議(至少)加上這些內容,現在或將來就可以更輕鬆地設定 DAA。
fb_
,但有少數例外,例如 content_ids
相對於 fb_content_id
、value
相對於 _valueToSum
。content_ids
或 content_type
)時,其會提供 JSON 編碼的值陣列:["value1", "value2"]
。注意:請勿以逗號串連各值。欄位和類型 | 說明 |
---|---|
類型:字串 | 若為 預先定義的事件名稱,可讓您衡量行銷活動的成效,並瞭解廣告受眾的意圖。 |
類型:字串陣列 | 若為 您的車輛目錄中列出的相關編號。 範例: |
類型:字串 | 若為 產品或內容類型。支援的值: |
類型:字串 | 建議使用。 車輛所在位置的郵遞區號。 範例: |
類型:字串 | 建議使用。 車輛所在位置的國家/地區名稱。 範例: |
類型:字串 | 建議使用。 車輛廠商/品牌/製造商。 範例: |
類型:字串 | 建議使用。 車款。 範例: |
類型:整數 | 建議使用。 車輛上市年份,格式是 yyyy(西元年)。 範例: |
類型:列舉 | 建議使用。 必要資訊,用以註明車輛為新車或二手車。支援的值: |
類型:整數 | 建議使用。 車輛行駛里程數(公里或英里);新車為零( 範例: |
類型:字串 | 建議使用。 里程數單位為英里( |
類型:字串 | 建議使用。 車輛外觀顏色。 範例: |
類型:列舉 | 建議使用。 車輛傳動類型。支援的值: |
類型:列舉 | 建議使用。 車身樣式。支援的值: |
類型:列舉 | 建議使用。 車輛燃料類型。支援的值: |
類型:列舉 | 建議使用。 車輛傳動系統。支援的值: |
類型:浮點數 | 建議使用。 車輛價格。 範例: |
類型:[浮點數(最小), 浮點數(最大)] | 建議使用。 車輛價格範圍。 範例: |
類型:字串 | 建議使用。
|
類型:字串 | 建議使用。 車輛裝飾。 範例: |
類型:字串 | 建議使用。 車輛識別號碼。字元數上限:17 範例: |
類型:字串 | 選用。 車輛內裝顏色。 範例: |
類型:列舉 | 選用。 車輛狀態。支援的值: |
類型:字串 | 對於 使用 範例: |
類型:字串 | 對於 使用 範例: |
類型:字串 | 對於 使用 範例: |