Constants

The following constants are available globally.

  • Game achievement ID (NSString).

        NSDictionary *params = @{
          kFIRParameterAchievementID : @"10_matches_won",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterAchievementID: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterAchievementID = @"achievement_id"
  • Ad Network Click ID (NSString). Used for network-specific click IDs which vary in format.

        NSDictionary *params = @{
          kFIRParameterAdNetworkClickID : @"1234567",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterAdNetworkClickID: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterAdNetworkClickID = @"aclid"
  • The store or affiliation from which this transaction occurred (NSString).

        NSDictionary *params = @{
          kFIRParameterAffiliation : @"Google Store",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterAffiliation: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterAffiliation = @"affiliation"
  • The individual campaign name, slogan, promo code, etc. Some networks have pre-defined macro to capture campaign information, otherwise can be populated by developer. Highly Recommended (NSString).

        NSDictionary *params = @{
          kFIRParameterCampaign : @"winter_promotion",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCampaign: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCampaign = @"campaign"
  • Character used in game (NSString).

        NSDictionary *params = @{
          kFIRParameterCharacter : @"beat_boss",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCharacter: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCharacter = @"character"
  • The checkout step (1..N) (unsigned 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterCheckoutStep : @"1",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCheckoutStep: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCheckoutStep = @"checkout_step"
  • Some option on a step in an ecommerce flow (NSString).

        NSDictionary *params = @{
          kFIRParameterCheckoutOption : @"Visa",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCheckoutOption: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCheckoutOption = @"checkout_option"
  • Campaign content (NSString).

    Declaration

    Swift

    let kFIRParameterContent: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterContent = @"content"
  • Type of content selected (NSString).

        NSDictionary *params = @{
          kFIRParameterContentType : @"news article",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterContentType: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterContentType = @"content_type"
  • Coupon code for a purchasable item (NSString).

        NSDictionary *params = @{
          kFIRParameterCoupon : @"zz123",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCoupon: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCoupon = @"coupon"
  • Campaign custom parameter (NSString). Used as a method of capturing custom data in a campaign. Use varies by network.

        NSDictionary *params = @{
          kFIRParameterCP1 : @"custom_data",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCP1: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCP1 = @"cp1"
  • The name of a creative used in a promotional spot (NSString).

        NSDictionary *params = @{
          kFIRParameterCreativeName : @"Summer Sale",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCreativeName: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCreativeName = @"creative_name"
  • The name of a creative slot (NSString).

        NSDictionary *params = @{
          kFIRParameterCreativeSlot : @"summer_banner2",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCreativeSlot: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCreativeSlot = @"creative_slot"
  • Purchase currency in 3-letter ISO_4217 format (NSString).

        NSDictionary *params = @{
          kFIRParameterCurrency : @"USD",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterCurrency: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterCurrency = @"currency"
  • Flight or Travel destination (NSString).

        NSDictionary *params = @{
          kFIRParameterDestination : @"Mountain View, CA",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterDestination: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterDestination = @"destination"
  • The arrival date, check-out date or rental end date for the item. This should be in YYYY-MM-DD format (NSString).

        NSDictionary *params = @{
          kFIRParameterEndDate : @"2015-09-14",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterEndDate: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterEndDate = @"end_date"
  • Flight number for travel events (NSString).

        NSDictionary *params = @{
          kFIRParameterFlightNumber : @"ZZ800",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterFlightNumber: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterFlightNumber = @"flight_number"
  • Group/clan/guild ID (NSString).

        NSDictionary *params = @{
          kFIRParameterGroupID : @"g1",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterGroupID: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterGroupID = @"group_id"
  • Index of an item in a list (signed 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterIndex : @(1),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterIndex: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterIndex = @"index"
  • Item brand (NSString).

        NSDictionary *params = @{
          kFIRParameterItemBrand : @"Google",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterItemBrand: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterItemBrand = @"item_brand"
  • Item category (NSString).

        NSDictionary *params = @{
          kFIRParameterItemCategory : @"t-shirts",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterItemCategory: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterItemCategory = @"item_category"
  • Item ID (NSString).

        NSDictionary *params = @{
          kFIRParameterItemID : @"p7654",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterItemID: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterItemID = @"item_id"
  • The Google Place ID (NSString) that corresponds to the associated item. Alternatively, you can supply your own custom Location ID.

        NSDictionary *params = @{
          kFIRParameterItemLocationID : @"ChIJiyj437sx3YAR9kUWC8QkLzQ",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterItemLocationID: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterItemLocationID = @"item_location_id"
  • Item name (NSString).

        NSDictionary *params = @{
          kFIRParameterItemName : @"abc",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterItemName: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterItemName = @"item_name"
  • The list in which the item was presented to the user (NSString).

        NSDictionary *params = @{
          kFIRParameterItemList : @"Search Results",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterItemList: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterItemList = @"item_list"
  • Item variant (NSString).

        NSDictionary *params = @{
          kFIRParameterItemVariant : @"Red",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterItemVariant: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterItemVariant = @"item_variant"
  • Level in game (signed 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterLevel : @(42),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterLevel: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterLevel = @"level"
  • Location (NSString). The Google Place ID that corresponds to the associated event. Alternatively, you can supply your own custom Location ID.

        NSDictionary *params = @{
          kFIRParameterLocation : @"ChIJiyj437sx3YAR9kUWC8QkLzQ",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterLocation: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterLocation = @"location"
  • The advertising or marketing medium, for example: cpc, banner, email, push. Highly recommended (NSString).

        NSDictionary *params = @{
          kFIRParameterMedium : @"email",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterMedium: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterMedium = @"medium"
  • Number of nights staying at hotel (signed 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterNumberOfNights : @(3),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterNumberOfNights: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterNumberOfNights = @"number_of_nights"
  • Number of passengers traveling (signed 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterNumberOfPassengers : @(11),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterNumberOfPassengers: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterNumberOfPassengers = @"number_of_passengers"
  • Number of rooms for travel events (signed 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterNumberOfRooms : @(2),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterNumberOfRooms: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterNumberOfRooms = @"number_of_rooms"
  • Flight or Travel origin (NSString).

        NSDictionary *params = @{
          kFIRParameterOrigin : @"Mountain View, CA",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterOrigin: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterOrigin = @"origin"
  • Purchase price (double as NSNumber).

        NSDictionary *params = @{
          kFIRParameterPrice : @(1.0),
          kFIRParameterCurrency : @"USD",  // e.g. $1.00 USD
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterPrice: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterPrice = @"price"
  • Purchase quantity (signed 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterQuantity : @(1),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterQuantity: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterQuantity = @"quantity"
  • Score in game (signed 64-bit integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterScore : @(4200),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterScore: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterScore = @"score"
  • The search string/keywords used (NSString).

        NSDictionary *params = @{
          kFIRParameterSearchTerm : @"periodic table",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterSearchTerm: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterSearchTerm = @"search_term"
  • Shipping cost (double as NSNumber).

        NSDictionary *params = @{
          kFIRParameterShipping : @(9.50),
          kFIRParameterCurrency : @"USD",  // e.g. $9.50 USD
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterShipping: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterShipping = @"shipping"
  • Sign up method (NSString).

        NSDictionary *params = @{
          kFIRParameterSignUpMethod : @"google",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterSignUpMethod: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterSignUpMethod = @"sign_up_method"
  • The origin of your traffic, such as an Ad network (for example, google) or partner (urban airship). Identify the advertiser, site, publication, etc. that is sending traffic to your property. Highly recommended (NSString).

        NSDictionary *params = @{
          kFIRParameterSource : @"InMobi",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterSource: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterSource = @"source"
  • The departure date, check-in date or rental start date for the item. This should be in YYYY-MM-DD format (NSString).

        NSDictionary *params = @{
          kFIRParameterStartDate : @"2015-09-14",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterStartDate: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterStartDate = @"start_date"
  • Tax amount (double as NSNumber).

        NSDictionary *params = @{
          kFIRParameterTax : @(1.0),
          kFIRParameterCurrency : @"USD",  // e.g. $1.00 USD
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterTax: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterTax = @"tax"
  • If you’re manually tagging keyword campaigns, you should use utm_term to specify the keyword (NSString).

        NSDictionary *params = @{
          kFIRParameterTerm : @"game",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterTerm: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterTerm = @"term"
  • A single ID for a ecommerce group transaction (NSString).

        NSDictionary *params = @{
          kFIRParameterTransactionID : @"ab7236dd9823",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterTransactionID: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterTransactionID = @"transaction_id"
  • Travel class (NSString).

        NSDictionary *params = @{
          kFIRParameterTravelClass : @"business",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterTravelClass: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterTravelClass = @"travel_class"
  • A context-specific numeric value which is accumulated automatically for each event type. This is a general purpose parameter that is useful for accumulating a key metric that pertains to an event. Examples include revenue, distance, time and points. Value should be specified as signed 64-bit integer or double as NSNumber. Notes: Values for pre-defined currency-related events (such as kFIREventAddToCart) should be supplied using double as NSNumber and must be accompanied by a kFIRParameterCurrency parameter. The valid range of accumulated values is [-9,223,372,036,854.77, 9,223,372,036,854.77]. Supplying a non-numeric value, omitting the corresponding kFIRParameterCurrency parameter, or supplying an invalid currency code for conversion events will cause that conversion to be omitted from reporting.

        NSDictionary *params = @{
          kFIRParameterValue : @(3.99),
          kFIRParameterCurrency : @"USD",  // e.g. $3.99 USD
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterValue: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterValue = @"value"
  • Name of virtual currency type (NSString).

        NSDictionary *params = @{
          kFIRParameterVirtualCurrencyName : @"virtual_currency_name",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterVirtualCurrencyName: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterVirtualCurrencyName =
        @"virtual_currency_name"
  • The name of a level in a game (NSString).

        NSDictionary *params = @{
          kFIRParameterLevelName : @"room_1",
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterLevelName: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterLevelName = @"level_name"
  • The result of an operation. Specify 1 to indicate success and 0 to indicate failure (unsigned integer as NSNumber).

        NSDictionary *params = @{
          kFIRParameterSuccess : @(1),
          // ...
        };
    

    Declaration

    Swift

    let kFIRParameterSuccess: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRParameterSuccess = @"success"
  • The method used to sign in. For example, google, facebook or twitter.

    Declaration

    Swift

    let kFIRUserPropertySignUpMethod: UnsafeMutablePointer<Int32>!

    Objective-C

    static NSString *const kFIRUserPropertySignUpMethod = @"sign_up_method"