1 /// @file FIRParameterNames.h
3 /// Predefined event parameter names.
5 /// Params supply information that contextualize Events. You can associate up to 25 unique Params
6 /// with each Event type. Some Params are suggested below for certain common Events, but you are
7 /// not limited to these. You may supply extra Params for suggested Events or custom Params for
8 /// Custom events. Param names can be up to 40 characters long, may only contain alphanumeric
9 /// characters and underscores ("_"), and must start with an alphabetic character. Param values can
10 /// be up to 100 characters long. The "firebase_", "google_", and "ga_" prefixes are reserved and
11 /// should not be used.
13 #import <Foundation/Foundation.h>
15 /// Game achievement ID (NSString).
17 /// NSDictionary *params = @{
18 /// kFIRParameterAchievementID : @"10_matches_won",
22 static NSString *const kFIRParameterAchievementID NS_SWIFT_NAME(AnalyticsParameterAchievementID) =
25 /// Ad Network Click ID (NSString). Used for network-specific click IDs which vary in format.
27 /// NSDictionary *params = @{
28 /// kFIRParameterAdNetworkClickID : @"1234567",
32 static NSString *const kFIRParameterAdNetworkClickID
33 NS_SWIFT_NAME(AnalyticsParameterAdNetworkClickID) = @"aclid";
35 /// The store or affiliation from which this transaction occurred (NSString).
37 /// NSDictionary *params = @{
38 /// kFIRParameterAffiliation : @"Google Store",
42 static NSString *const kFIRParameterAffiliation NS_SWIFT_NAME(AnalyticsParameterAffiliation) =
45 /// The individual campaign name, slogan, promo code, etc. Some networks have pre-defined macro to
46 /// capture campaign information, otherwise can be populated by developer. Highly Recommended
49 /// NSDictionary *params = @{
50 /// kFIRParameterCampaign : @"winter_promotion",
54 static NSString *const kFIRParameterCampaign NS_SWIFT_NAME(AnalyticsParameterCampaign) =
57 /// Character used in game (NSString).
59 /// NSDictionary *params = @{
60 /// kFIRParameterCharacter : @"beat_boss",
64 static NSString *const kFIRParameterCharacter NS_SWIFT_NAME(AnalyticsParameterCharacter) =
67 /// The checkout step (1..N) (unsigned 64-bit integer as NSNumber).
69 /// NSDictionary *params = @{
70 /// kFIRParameterCheckoutStep : @"1",
74 static NSString *const kFIRParameterCheckoutStep NS_SWIFT_NAME(AnalyticsParameterCheckoutStep) =
77 /// Some option on a step in an ecommerce flow (NSString).
79 /// NSDictionary *params = @{
80 /// kFIRParameterCheckoutOption : @"Visa",
84 static NSString *const kFIRParameterCheckoutOption
85 NS_SWIFT_NAME(AnalyticsParameterCheckoutOption) = @"checkout_option";
87 /// Campaign content (NSString).
88 static NSString *const kFIRParameterContent NS_SWIFT_NAME(AnalyticsParameterContent) = @"content";
90 /// Type of content selected (NSString).
92 /// NSDictionary *params = @{
93 /// kFIRParameterContentType : @"news article",
97 static NSString *const kFIRParameterContentType NS_SWIFT_NAME(AnalyticsParameterContentType) =
100 /// Coupon code for a purchasable item (NSString).
102 /// NSDictionary *params = @{
103 /// kFIRParameterCoupon : @"zz123",
107 static NSString *const kFIRParameterCoupon NS_SWIFT_NAME(AnalyticsParameterCoupon) = @"coupon";
109 /// Campaign custom parameter (NSString). Used as a method of capturing custom data in a campaign.
110 /// Use varies by network.
112 /// NSDictionary *params = @{
113 /// kFIRParameterCP1 : @"custom_data",
117 static NSString *const kFIRParameterCP1 NS_SWIFT_NAME(AnalyticsParameterCP1) = @"cp1";
119 /// The name of a creative used in a promotional spot (NSString).
121 /// NSDictionary *params = @{
122 /// kFIRParameterCreativeName : @"Summer Sale",
126 static NSString *const kFIRParameterCreativeName NS_SWIFT_NAME(AnalyticsParameterCreativeName) =
129 /// The name of a creative slot (NSString).
131 /// NSDictionary *params = @{
132 /// kFIRParameterCreativeSlot : @"summer_banner2",
136 static NSString *const kFIRParameterCreativeSlot NS_SWIFT_NAME(AnalyticsParameterCreativeSlot) =
139 /// Purchase currency in 3-letter <a href="http://en.wikipedia.org/wiki/ISO_4217#Active_codes">
140 /// ISO_4217</a> format (NSString).
142 /// NSDictionary *params = @{
143 /// kFIRParameterCurrency : @"USD",
147 static NSString *const kFIRParameterCurrency NS_SWIFT_NAME(AnalyticsParameterCurrency) =
150 /// Flight or Travel destination (NSString).
152 /// NSDictionary *params = @{
153 /// kFIRParameterDestination : @"Mountain View, CA",
157 static NSString *const kFIRParameterDestination NS_SWIFT_NAME(AnalyticsParameterDestination) =
160 /// The arrival date, check-out date or rental end date for the item. This should be in
161 /// YYYY-MM-DD format (NSString).
163 /// NSDictionary *params = @{
164 /// kFIRParameterEndDate : @"2015-09-14",
168 static NSString *const kFIRParameterEndDate NS_SWIFT_NAME(AnalyticsParameterEndDate) = @"end_date";
170 /// Flight number for travel events (NSString).
172 /// NSDictionary *params = @{
173 /// kFIRParameterFlightNumber : @"ZZ800",
177 static NSString *const kFIRParameterFlightNumber NS_SWIFT_NAME(AnalyticsParameterFlightNumber) =
180 /// Group/clan/guild ID (NSString).
182 /// NSDictionary *params = @{
183 /// kFIRParameterGroupID : @"g1",
187 static NSString *const kFIRParameterGroupID NS_SWIFT_NAME(AnalyticsParameterGroupID) = @"group_id";
189 /// Index of an item in a list (signed 64-bit integer as NSNumber).
191 /// NSDictionary *params = @{
192 /// kFIRParameterIndex : @(1),
196 static NSString *const kFIRParameterIndex NS_SWIFT_NAME(AnalyticsParameterIndex) = @"index";
198 /// Item brand (NSString).
200 /// NSDictionary *params = @{
201 /// kFIRParameterItemBrand : @"Google",
205 static NSString *const kFIRParameterItemBrand NS_SWIFT_NAME(AnalyticsParameterItemBrand) =
208 /// Item category (NSString).
210 /// NSDictionary *params = @{
211 /// kFIRParameterItemCategory : @"t-shirts",
215 static NSString *const kFIRParameterItemCategory NS_SWIFT_NAME(AnalyticsParameterItemCategory) =
218 /// Item ID (NSString).
220 /// NSDictionary *params = @{
221 /// kFIRParameterItemID : @"p7654",
225 static NSString *const kFIRParameterItemID NS_SWIFT_NAME(AnalyticsParameterItemID) = @"item_id";
227 /// The Google <a href="https://developers.google.com/places/place-id">Place ID</a> (NSString) that
228 /// corresponds to the associated item. Alternatively, you can supply your own custom Location ID.
230 /// NSDictionary *params = @{
231 /// kFIRParameterItemLocationID : @"ChIJiyj437sx3YAR9kUWC8QkLzQ",
235 static NSString *const kFIRParameterItemLocationID
236 NS_SWIFT_NAME(AnalyticsParameterItemLocationID) = @"item_location_id";
238 /// Item name (NSString).
240 /// NSDictionary *params = @{
241 /// kFIRParameterItemName : @"abc",
245 static NSString *const kFIRParameterItemName NS_SWIFT_NAME(AnalyticsParameterItemName) =
248 /// The list in which the item was presented to the user (NSString).
250 /// NSDictionary *params = @{
251 /// kFIRParameterItemList : @"Search Results",
255 static NSString *const kFIRParameterItemList NS_SWIFT_NAME(AnalyticsParameterItemList) =
258 /// Item variant (NSString).
260 /// NSDictionary *params = @{
261 /// kFIRParameterItemVariant : @"Red",
265 static NSString *const kFIRParameterItemVariant NS_SWIFT_NAME(AnalyticsParameterItemVariant) =
268 /// Level in game (signed 64-bit integer as NSNumber).
270 /// NSDictionary *params = @{
271 /// kFIRParameterLevel : @(42),
275 static NSString *const kFIRParameterLevel NS_SWIFT_NAME(AnalyticsParameterLevel) = @"level";
277 /// Location (NSString). The Google <a href="https://developers.google.com/places/place-id">Place ID
278 /// </a> that corresponds to the associated event. Alternatively, you can supply your own custom
281 /// NSDictionary *params = @{
282 /// kFIRParameterLocation : @"ChIJiyj437sx3YAR9kUWC8QkLzQ",
286 static NSString *const kFIRParameterLocation NS_SWIFT_NAME(AnalyticsParameterLocation) =
289 /// The advertising or marketing medium, for example: cpc, banner, email, push. Highly recommended
292 /// NSDictionary *params = @{
293 /// kFIRParameterMedium : @"email",
297 static NSString *const kFIRParameterMedium NS_SWIFT_NAME(AnalyticsParameterMedium) = @"medium";
299 /// Number of nights staying at hotel (signed 64-bit integer as NSNumber).
301 /// NSDictionary *params = @{
302 /// kFIRParameterNumberOfNights : @(3),
306 static NSString *const kFIRParameterNumberOfNights
307 NS_SWIFT_NAME(AnalyticsParameterNumberOfNights) = @"number_of_nights";
309 /// Number of passengers traveling (signed 64-bit integer as NSNumber).
311 /// NSDictionary *params = @{
312 /// kFIRParameterNumberOfPassengers : @(11),
316 static NSString *const kFIRParameterNumberOfPassengers
317 NS_SWIFT_NAME(AnalyticsParameterNumberOfPassengers) = @"number_of_passengers";
319 /// Number of rooms for travel events (signed 64-bit integer as NSNumber).
321 /// NSDictionary *params = @{
322 /// kFIRParameterNumberOfRooms : @(2),
326 static NSString *const kFIRParameterNumberOfRooms NS_SWIFT_NAME(AnalyticsParameterNumberOfRooms) =
329 /// Flight or Travel origin (NSString).
331 /// NSDictionary *params = @{
332 /// kFIRParameterOrigin : @"Mountain View, CA",
336 static NSString *const kFIRParameterOrigin NS_SWIFT_NAME(AnalyticsParameterOrigin) = @"origin";
338 /// Purchase price (double as NSNumber).
340 /// NSDictionary *params = @{
341 /// kFIRParameterPrice : @(1.0),
342 /// kFIRParameterCurrency : @"USD", // e.g. $1.00 USD
346 static NSString *const kFIRParameterPrice NS_SWIFT_NAME(AnalyticsParameterPrice) = @"price";
348 /// Purchase quantity (signed 64-bit integer as NSNumber).
350 /// NSDictionary *params = @{
351 /// kFIRParameterQuantity : @(1),
355 static NSString *const kFIRParameterQuantity NS_SWIFT_NAME(AnalyticsParameterQuantity) =
358 /// Score in game (signed 64-bit integer as NSNumber).
360 /// NSDictionary *params = @{
361 /// kFIRParameterScore : @(4200),
365 static NSString *const kFIRParameterScore NS_SWIFT_NAME(AnalyticsParameterScore) = @"score";
367 /// The search string/keywords used (NSString).
369 /// NSDictionary *params = @{
370 /// kFIRParameterSearchTerm : @"periodic table",
374 static NSString *const kFIRParameterSearchTerm NS_SWIFT_NAME(AnalyticsParameterSearchTerm) =
377 /// Shipping cost (double as NSNumber).
379 /// NSDictionary *params = @{
380 /// kFIRParameterShipping : @(9.50),
381 /// kFIRParameterCurrency : @"USD", // e.g. $9.50 USD
385 static NSString *const kFIRParameterShipping NS_SWIFT_NAME(AnalyticsParameterShipping) =
388 /// Sign up method (NSString).
390 /// NSDictionary *params = @{
391 /// kFIRParameterSignUpMethod : @"google",
395 static NSString *const kFIRParameterSignUpMethod NS_SWIFT_NAME(AnalyticsParameterSignUpMethod) =
398 /// The origin of your traffic, such as an Ad network (for example, google) or partner (urban
399 /// airship). Identify the advertiser, site, publication, etc. that is sending traffic to your
400 /// property. Highly recommended (NSString).
402 /// NSDictionary *params = @{
403 /// kFIRParameterSource : @"InMobi",
407 static NSString *const kFIRParameterSource NS_SWIFT_NAME(AnalyticsParameterSource) = @"source";
409 /// The departure date, check-in date or rental start date for the item. This should be in
410 /// YYYY-MM-DD format (NSString).
412 /// NSDictionary *params = @{
413 /// kFIRParameterStartDate : @"2015-09-14",
417 static NSString *const kFIRParameterStartDate NS_SWIFT_NAME(AnalyticsParameterStartDate) =
420 /// Tax amount (double as NSNumber).
422 /// NSDictionary *params = @{
423 /// kFIRParameterTax : @(1.0),
424 /// kFIRParameterCurrency : @"USD", // e.g. $1.00 USD
428 static NSString *const kFIRParameterTax NS_SWIFT_NAME(AnalyticsParameterTax) = @"tax";
430 /// If you're manually tagging keyword campaigns, you should use utm_term to specify the keyword
433 /// NSDictionary *params = @{
434 /// kFIRParameterTerm : @"game",
438 static NSString *const kFIRParameterTerm NS_SWIFT_NAME(AnalyticsParameterTerm) = @"term";
440 /// A single ID for a ecommerce group transaction (NSString).
442 /// NSDictionary *params = @{
443 /// kFIRParameterTransactionID : @"ab7236dd9823",
447 static NSString *const kFIRParameterTransactionID NS_SWIFT_NAME(AnalyticsParameterTransactionID) =
450 /// Travel class (NSString).
452 /// NSDictionary *params = @{
453 /// kFIRParameterTravelClass : @"business",
457 static NSString *const kFIRParameterTravelClass NS_SWIFT_NAME(AnalyticsParameterTravelClass) =
460 /// A context-specific numeric value which is accumulated automatically for each event type. This is
461 /// a general purpose parameter that is useful for accumulating a key metric that pertains to an
462 /// event. Examples include revenue, distance, time and points. Value should be specified as signed
463 /// 64-bit integer or double as NSNumber. Notes: Values for pre-defined currency-related events
464 /// (such as @c kFIREventAddToCart) should be supplied using double as NSNumber and must be
465 /// accompanied by a @c kFIRParameterCurrency parameter. The valid range of accumulated values is
466 /// [-9,223,372,036,854.77, 9,223,372,036,854.77]. Supplying a non-numeric value, omitting the
467 /// corresponding @c kFIRParameterCurrency parameter, or supplying an invalid
468 /// <a href="https://goo.gl/qqX3J2">currency code</a> for conversion events will cause that
469 /// conversion to be omitted from reporting.
471 /// NSDictionary *params = @{
472 /// kFIRParameterValue : @(3.99),
473 /// kFIRParameterCurrency : @"USD", // e.g. $3.99 USD
477 static NSString *const kFIRParameterValue NS_SWIFT_NAME(AnalyticsParameterValue) = @"value";
479 /// Name of virtual currency type (NSString).
481 /// NSDictionary *params = @{
482 /// kFIRParameterVirtualCurrencyName : @"virtual_currency_name",
486 static NSString *const kFIRParameterVirtualCurrencyName
487 NS_SWIFT_NAME(AnalyticsParameterVirtualCurrencyName) = @"virtual_currency_name";
489 /// The name of a level in a game (NSString).
491 /// NSDictionary *params = @{
492 /// kFIRParameterLevelName : @"room_1",
496 static NSString *const kFIRParameterLevelName NS_SWIFT_NAME(AnalyticsParameterLevelName) =
499 /// The result of an operation. Specify 1 to indicate success and 0 to indicate failure (unsigned
500 /// integer as NSNumber).
502 /// NSDictionary *params = @{
503 /// kFIRParameterSuccess : @(1),
507 static NSString *const kFIRParameterSuccess NS_SWIFT_NAME(AnalyticsParameterSuccess) = @"success";