Event Properties

To optimize your marketing strategy, it is crucial to track and measure events in your digital service and understand user behavior. Define the events you want to track with Airbridge using the Airbridge event properties.

Event Properties Overview

In Airbridge, an event is defined by its properties, namely the Event Category, Event Action, Event Label, Event Value, Attributes, and Trigger.

 

Event Category

The Event Category is an essential property that must be configured to define an event. In addition to being used as the name of an event, the Event Category can be used when you select the events to send via postbacks.

Events are divided into Standard Events and Custom Events. The Event Category of Standard Events is pre-set by Airbridge, whereas that of Custom Events shall be configured by Airbridge users.

Rules and limitations for Event Category

The Event Category is subject to the following rules:

  • The Event Category is case-sensitive.

  • For Standard Events, the Event Category is pre-set by Airbridge.

  • For Custom Events, the Event Category can include letters in mixed case and numbers, but cannot start with airbridge.. For special characters, only underscore (_) is allowed. The maximum length is 128 characters.

Data collected as the Event Category is subject to the following limitations:

  • The event cannot be collected in case of a data type mismatch. The data type of the Event Category is string.

  • If the data to be collected exceeds the maximum length, it is truncated to the maximum length, which is 128 characters for the Event Category.

View data by Event Category

Select a metric to view the event count where the metric name corresponds to the Event Category. Data collected as the Event Category can be viewed by selecting the “Event Category” GroupBy or filter in Airbridge reports or as a property in raw data exports.

 

Event Action and Event Label

By configuring the Event Action and the Event Label, you can determine up to 2 additional event details to collect. Data collected as the Event Action and Event Label can be viewed in Airbridge reports.

Event details collected as Event Action and Event Label

Any event detail can be collected as the Event Action and the Event Label. The event details are not related to the literal definitions of the words action and label. This means that you can use the Event Action to collect event details that are not related to user actions.

Rules and limitations for Event Action and Event Label

The Event Action and the Event Label are subject to the following rules:

  • The Event Action and the Event Label can include letters in mixed cases and numbers and are case-sensitive. The maximum length is 128 characters.

  • As for the use of symbols, it is advised to use underscores _ only. Spaces and the following symbols are also supported: ?, !, ,, ., /, &, (, ).

Data collected as the Event Action and Event Label is subject to the following limitations:

  • The event cannot be collected in case of a data type mismatch. The data types of both the Event Action and the Event Label are strings.

  • If the data to be collected exceeds the maximum length, it is truncated to the maximum length, which is 128 characters for both the Event Action and the Event Label.

View data by Event Action and Event Label

Data collected as the Event Action and the Event Label can be viewed by selecting the “Event Action” and “Event Label” GroupBys in Airbridge reports.

 

Event Value

The Event Value must be configured to perform calculations with numerical data collected. Only data collected as the Event Value can be used for calculations in Airbridge. Numbers with up to 9 decimal places can be collected.

For instance, you must have configured the Event Value to find out your total revenue by adding up the prices of the products sold or your total subscription revenue by adding subscription fees in the Revenue Report.

Understanding Event Value

Data collected as the Event Value can be used for calculations with other data collected as the Event Value. Data collected as the Event Action or the Event Label cannot be used for calculations. Note that the event count is tracked whether or not the Event Value is configured.

Let’s say you have collected data for the “Order Complete” event as shown in the following table:

The data collected as the Event Value can be used for calculations. Therefore, you can add the 2 pieces of data to get a sum of 30,000 for the event.

Data collected as the Event Action or the Event Label cannot be used for calcaulations, but you can still view the event count. Therefore, Airbridge reports will show that there were 2 times when the Event Action was 1000 and 1 time when the Event Label was 100 and 200, respectively.

Limitations for Event Value

Data collected as the Event Value is subject to the following limitations:

  • The event cannot be collected in case of a data type mismatch. The data type of the Event Label is float.

  • If the data to be collected exceeds the maximum length, it is truncated to the maximum length, which is up to 9 decimal places for the Event Value.

  

Attributes

Attention

Data collected as the Attribute cannot be viewed in Airbridge reports. If you want to collect event details and view them in Airbridge reports, use the Event Action and the Event Label.

Attributes can be used to collect additional event details. Data collected as the Attribute can be viewed only via raw data exports but not in Airbridge reports.

Attributes are divided into Semantic Attributes and Custom Attributes. Semantic Attributes are pre-defined by Airbridge, whereas Custom Attributes can be configured by Airbridge users.

Semantic Attributes

Semantic Attributes are pre-defined by Airbridge. Read on to learn more about Semantic Attributes and their use cases.

Find the Semantic Attributes supported by Airbridge below.

Android SDK (v4)

1234567891011121314151617181920212223
Airbridge.trackEvent(
	"purchase_card",
	mapOf(
		AirbridgeAttribute.TRANSACTION_ID to "1458132a-0d09-4944-a686-fcbee81b74f7",
		AirbridgeAttribute.PRODUCTS to listOf(
			mapOf(
				AirbridgeAttribute.PRODUCT_ID to "1234",
				AirbridgeAttribute.PRODUCT_NAME to "Nike 1",
				AirbridgeAttribute.PRODUCT_PRICE to 55,
				AirbridgeAttribute.PRODUCT_CURRENCY to "USD",
				AirbridgeAttribute.PRODUCT_QUANTITY to 1,
			),
			mapOf(
				AirbridgeAttribute.PRODUCT_ID to "1235",
				AirbridgeAttribute.PRODUCT_NAME to "Nike 2",
				AirbridgeAttribute.PRODUCT_PRICE to 44,
				AirbridgeAttribute.PRODUCT_CURRENCY to "USD",
				AirbridgeAttribute.PRODUCT_QUANTITY to 1,
			),
		),
		AirbridgeAttribute.CURRENCY to "USD",
	)
)
1234567891011121314151617181920212223
Airbridge.trackEvent(
	"purchase_card",
	new HashMap() {{
		put(AirbridgeAttribute.TRANSACTION_ID, "1458132a-0d09-4944-a686-fcbee81b74f7");
		put(AirbridgeAttribute.PRODUCTS, Arrays.asList(
			new HashMap() {{
				put(AirbridgeAttribute.PRODUCT_ID, "1234");
				put(AirbridgeAttribute.PRODUCT_NAME, "Nike 1");
				put(AirbridgeAttribute.PRODUCT_PRICE, 55);
				put(AirbridgeAttribute.PRODUCT_CURRENCY, "USD");
				put(AirbridgeAttribute.PRODUCT_QUANTITY, 1);
			}},
			new HashMap() {{
				put(AirbridgeAttribute.PRODUCT_ID, "1235");
				put(AirbridgeAttribute.PRODUCT_NAME, "Nike 2");
				put(AirbridgeAttribute.PRODUCT_PRICE, 44);
				put(AirbridgeAttribute.PRODUCT_CURRENCY, "USD");
				put(AirbridgeAttribute.PRODUCT_QUANTITY, 1);
			}}
		));
		put(AirbridgeAttribute.CURRENCY, "USD");
	}}
);

Android SDK (Previous)

1234567891011121314151617181920212223
Airbridge.trackEvent(
	category = "purchase_card",
	semanticAttributes = mapOf(
		SemanticAttributes.KEY_TRANSACTION_ID to "1458132a-0d09-4944-a686-fcbee81b74f7",
		SemanticAttributes.KEY_PRODUCTS to listOf(
			mapOf(
				Product.KEY_ID to "1234",
				Product.KEY_NAME to "Nike 1",
				Product.KEY_PRICE to 55,
				Product.KEY_CURRENCY to "USD",
				Product.KEY_QUANTITY to 1
			),
			mapOf(
				Product.KEY_ID to "1235",
				Product.KEY_NAME to "Nike 2",
				Product.KEY_PRICE to 44,
				Product.KEY_CURRENCY to "USD",
				Product.KEY_QUANTITY to 1
			)
		),
		SemanticAttributes.KEY_CURRENCY to "USD"
	)
)
12345678910111213141516171819202122232425262728293031
Map<String, Object> product1 = new HashMap<>();
product1.put(Product.KEY_ID, "1234");
product1.put(Product.KEY_NAME, "Nike 1");
product1.put(Product.KEY_PRICE, 55);
product1.put(Product.KEY_CURRENCY, "USD");
product1.put(Product.KEY_QUANTITY, 1);

Map<String, Object> product2 = new HashMap<>();
product2.put(Product.KEY_ID, "1235");
product2.put(Product.KEY_NAME, "Nike 2");
product2.put(Product.KEY_PRICE, 44);
product2.put(Product.KEY_CURRENCY, "USD");
product2.put(Product.KEY_QUANTITY, 1);

List<Map<String, Object>> products = new ArrayList<>();
products.add(product1);
products.add(product2);

Map<String, Object> semanticAttributes = new HashMap<>();
semanticAttributes.put(SemanticAttributes.KEY_TRANSACTION_ID, "1458132a-0d09-4944-a686-fcbee81b74f7");
semanticAttributes.put(SemanticAttributes.KEY_PRODUCTS, products);
semanticAttributes.put(SemanticAttributes.KEY_CURRENCY, "USD");

Airbridge.trackEvent(
    "purchase_card", // Category
    null, // Action
    null, // Label
    null, // Value
    null, // Custom Attributes
    semanticAttributes // Semantic Attributes
);

iOS SDK (v4)

1234567891011121314151617181920212223
Airbridge.trackEvent(
	category: "purchase_card",
	semanticAttributes: [
		AirbridgeAttribute.TRANSACTION_ID: "1458132a-0d09-4944-a686-fcbee81b74f7",
		AirbridgeAttribute.PRODUCTS: [
			[
				AirbridgeAttribute.PRODUCT_ID: "1234",
				AirbridgeAttribute.PRODUCT_NAME: "Nike 1",
				AirbridgeAttribute.PRODUCT_PRICE: 55,
				AirbridgeAttribute.PRODUCT_CURRENCY: "USD",
				AirbridgeAttribute.PRODUCT_QUANTITY: 1,
			],
			[
				AirbridgeAttribute.PRODUCT_ID: "1235",
				AirbridgeAttribute.PRODUCT_NAME: "Nike 2",
				AirbridgeAttribute.PRODUCT_PRICE: 44,
				AirbridgeAttribute.PRODUCT_CURRENCY: "USD",
				AirbridgeAttribute.PRODUCT_QUANTITY: 1,
			],
		],
		AirbridgeAttribute.CURRENCY: "USD",
	]
)
123456789101112131415161718192021
[Airbridge trackEventWithCategory:@"purchase_card"
	semanticAttributes:@{
		AirbridgeAttribute.TRANSACTION_ID : @"1458132a-0d09-4944-a686-fcbee81b74f7",
		AirbridgeAttribute.PRODUCTS : @[
			@{
				AirbridgeAttribute.PRODUCT_ID : @"1234",
				AirbridgeAttribute.PRODUCT_NAME : @"Nike 1",
				AirbridgeAttribute.PRODUCT_PRICE : @(55),
				AirbridgeAttribute.PRODUCT_CURRENCY : @"USD",
				AirbridgeAttribute.PRODUCT_QUANTITY : @(1),
			},
			@{
				AirbridgeAttribute.PRODUCT_ID : @"1235",
				AirbridgeAttribute.PRODUCT_NAME : @"Nike 2",
				AirbridgeAttribute.PRODUCT_PRICE : @(44),
				AirbridgeAttribute.PRODUCT_CURRENCY : @"USD",
				AirbridgeAttribute.PRODUCT_QUANTITY : @(1),
			},
		],
		AirbridgeAttribute.CURRENCY : @"USD",
}];

iOS SDK (Previous)

123456789101112131415161718192021222324252627
let event = ABInAppEvent()

event?.setCategory("purchase_card")

let semantics: [String: Any] = [
	ABSemanticsKey.transactionID: "1458132a-0d09-4944-a686-fcbee81b74f7",
	ABSemanticsKey.products: [
		[
			ABProductKey.productID: "1234",
			ABProductKey.name: "Nike 1",
			ABProductKey.price: 55,
			ABProductKey.currency: "USD",
			ABProductKey.quantity: 1,
		],
		[
			ABProductKey.productID: "1235",
			ABProductKey.name: "Nike 2",
			ABProductKey.price: 44,
			ABProductKey.currency: "USD",
			ABProductKey.quantity: 1,
		],
	],
	ABSemanticsKey.currency: "USD",
]
event?.setSemantics(semantics)

event?.send()
123456789101112131415161718192021222324
ABInAppEvent* event = [[ABInAppEvent alloc] init];
    
[event setCategory:@"purchase_card"];
    
NSDictionary* semantics = @{
	ABSemanticsKey.transactionID: @"1458132a-0d09-4944-a686-fcbee81b74f7",
	ABSemanticsKey.products: @[@{
			ABProductKey.productID: @"1234",
			ABProductKey.name: @"Nike 1",
			ABProductKey.price: @(55),
			ABProductKey.currency: @"USD",
			ABProductKey.quantity: @(1),
		}, @{
			ABProductKey.productID: @"1235",
			ABProductKey.name: @"Nike 2",
			ABProductKey.price: @(44),
			ABProductKey.currency: @"USD",
			ABProductKey.quantity: @(1),
	}],
	ABSemanticsKey.currency: @"USD"
};
[event setSemantics:semantics];
    
[event send];

12345678910111213141516171819
airbridge.events.send("purchase_card", {
  semanticAttributes: {
    transactionID: '1458132a-0d09-4944-a686-fcbee81b74f7',
    products: [{
      productID: "1234",
      name: "Nike 1",
      price: 55,
      currency: "USD",
      quantity: 1
    }, {
      productID: "1235",
      name: "Nike 2",
      price: 44,
      currency: "USD",
      quantity: 1
    }],
    currency: "USD"
  }
});

Custom Attributes

Custom Attributes can be configured by Airbridge users to collect additional event details that reflect the nature of business and marketing objectives.

Note that all data collected as Custom Attributes can be viewed in raw data exports under a single column. For instance, let's say you configured Custom Attributes to collect the user's ranking and item type. Then, both the ranking and item type data will appear under the same column.

Android SDK (v4)

1234567
Airbridge.trackEvent(
    category = "purchase_card",
    customAttributes = mapOf(
        "userRank" to "1",
        "itemType" to "sword"
    )
)
12345678
Airbridge.trackEvent(
    "purchase_card",    // Category
    null,               // Semantic Attributes
    new HashMap() {{    // Custom Attributes
        put("userRank", "1");
        put("itemType", "sword");
    }}
);

Android SDK (Previous)

1234567
Airbridge.trackEvent(
    category = "purchase_card",
    customAttributes = mapOf(
        "userRank" to "1",
        "itemType" to "sword"
    )
)
123456789101112
Map<String, Object> customAttributes = new HashMap<>();
customAttributes.put("userRank", "1");
customAttributes.put("itemType", "sword");

Airbridge.trackEvent(
    "purchase_card",    // Category
    null,               // Action
    null,               // Label
    null,               // Value
    customAttributes,   // Custom Attributes
    null                // Semantic Attributes
);

iOS SDK (v4)

12345678
Airbridge.trackEvent(
    category: "purchase_card",
    semanticAttributes: [:],
    customAttributes: [
        "userRank": "1",
        "itemType": "sword",
    ]
)
1234
[Airbridge
    trackEventWithCategory:@"purchase_card"
    semanticAttributes:@{}
    customAttributes:@{@"userRank" : @"1", @"itemType" : @"sword"}];

iOS SDK (Previous)

1234567891011
let event = ABInAppEvent()

event?.setCategory("purchase_card")

let customs: [String: Any] = [
    "userRank": "1",
    "itemType": "sword",
]
event?.setCustoms(customs)

event?.send()
1234567
ABInAppEvent *event = [[ABInAppEvent alloc] init];

[event setCategory:@"purchase_card"];
NSDictionary *customs = @{@"userRank" : @"1", @"itemType" : @"sword"};
[event setCustoms:customs];

[event send];

123456
airbridge.events.send("purchase_card", {
  "customAttributes": {
    "userRank": "1",
    "itemType": "sword"
  }
})

Limitations for Attributes

Data collected as Attributes is subject to the following limitations:

  • The data will not be collected in case of a Semantic Attribute data type mismatch. However, the data with the correct data type and the other event properties will still be collected.

  • The event will not be collected in case of a Custom Attribute data type mismatch. Keep in mind that the data types of Custom Attributes may vary.

  • Data collected as Semantic Attributes will be truncated to the maximum length, which is 1,024 characters for string data and 64 bits for integer or float data.

  • When the data collected as Custom Attributes exceeds the maximum length of 2,048 characters, ERROR_MAX_LENGTH_EXCEEDED will be recorded instead of the actual data.

Trigger

The Trigger is the point at which an event is collected. Different data could be collected depending on the data collection point. Make sure your Trigger is aligned with what you aim to measure by collecting the event.

Different data could be collected depending on how the Trigger is configured.

For instance, if you configure to collect the “Order Complete” event when the user clicks the “Buy Now” button, the event will be collected even when the payment fails.

However, if you configure to collect the "Order Complete" event when the order confirmation page is shown to the user, the event will be collected only when the payment is successful, and therefore, the event count will be more accurate.