logBeginCheckout method
Logs the standard begin_checkout
event.
This event signifies that a user has begun the process of checking out.
Add this event to a funnel with your logEcommercePurchase event to
gauge the effectiveness of your checkout process. Note: If you supply the
value
parameter, you must also supply the currency
parameter so that
revenue metrics can be computed accurately.
Implementation
Future<void> logBeginCheckout({
double? value,
String? currency,
String? transactionId,
int? numberOfNights,
int? numberOfRooms,
int? numberOfPassengers,
String? origin,
String? destination,
String? startDate,
String? endDate,
String? travelClass,
}) {
_requireValueAndCurrencyTogether(value, currency);
return logEvent(
name: 'begin_checkout',
parameters: filterOutNulls(<String, Object?>{
_VALUE: value,
_CURRENCY: currency,
_TRANSACTION_ID: transactionId,
_NUMBER_OF_NIGHTS: numberOfNights,
_NUMBER_OF_ROOMS: numberOfRooms,
_NUMBER_OF_PASSENGERS: numberOfPassengers,
_ORIGIN: origin,
_DESTINATION: destination,
_START_DATE: startDate,
_END_DATE: endDate,
_TRAVEL_CLASS: travelClass,
}),
);
}