Link Search Menu Expand Document

In Path Property Descriptions

Properties
  1. clientId
  2. country
  3. currency
  4. theme

CTSdkData Builder


clientId

A string identifier provided by CarTrawler required to use the CarTrawler API.


country

An optional two letter country code string, based on the ISO standard e.g “US”, “IE” used on the CarTrawler API. The country code associated with the device’s system region is used by default.


currency

An optional currency code string, based on the ISO standard currency codes e.g “USD”. The currency associated with the device’s system region is used by default.


theme

An @StyleRes int that is used to setup the theme for the SDK, for more details check Themes.


flightDetails

To initialise the In Path Grid View flow, it is necessary to build and set a CTFlighDetails object to the CTSdkData.

ParameterDescriptionExampleType
flightOrigin[Required] Origin flight details separated by pipes: IATA departure, IATA arrival, datetime departure, datetime arrival, flight number.DUB|LHR|2025-01-16T06:05:00|2025-01-16T07:25:00|XX8719String
flightReturn[Required] (return flights only) Return flight details separated by pipes: IATA departure, IATA arrival, datetime departure, datetime arrival, flight number.LHR|DUB|2025-01-22T21:20:00|2025-01-23T22:45:00|XX8720String
passengerBreakdownBreakdown of Adults, Teens, Children and InfantsCTFlightPassengerBreakdown(adults = 2, teens = 0, children = 0, infants = 0)CT Object
firstNameFirst name of the customer.JohnString
surNameSurname of the customer.DoeString
customerEmailEmail address of the customer.john.doe@example.comString
fareClassFlight class selected by the customer. Map to values like economy, business, etc.businessString
flightFareTotal price of the flight fare in the selected currency.175.95Float
bagsNumber of extra bags added by the customer.1Integer
loyaltyNumberLoyalty program membership ID, if applicable.ABC123456String
loyaltyTierLoyalty program tier name, if applicable.goldString
contextWhere in the flow the grid view is loaded. IN_PATH or CONFIRMATIONIN_PATHString
//Example CTFLightDetails initialisation
val flightDetails = CTFlightDetails.Builder()
        .flightOrigin("DUB|LHR|2025-01-16T06:05:00|2025-01-16T07:25:00|XX8719")
        .flightReturn("LHR|DUB|2025-01-22T21:20:00|2025-01-23T22:45:00|XX8720")
        .passengerBreakdown(CTFlightPassengerBreakdown(adults = 2, teens = 0, children = 0, infants = 0))
        .firstName("John")
        .surName("Doe")
        .customerEmail("john.doe@example.com")
        .fareClass("business")
        .flightFare(175.95)
        .bags(1)
        .loyaltyNumber("ABC123456")
        .loyaltyTier("gold")
        .context("IN_PATH")
        .build()

//Use CTFlightDetails when initialising CTSdkBuilder
val sdkData = CTSdkData.Builder(clientId = clientId).flightDetails(flightDetails).build()