BookingRule

data class BookingRule(val fromZoneIds: List<String>, val toZoneIds: List<String>?, val bookingType: BookingType, val priorNoticeDurationMin: WholeMinutes? = null, val priorNoticeDurationMax: WholeMinutes? = null, val priorNoticeLastDay: Int? = null, val priorNoticeLastTime: ServiceTime? = null, val priorNoticeStartDay: Int? = null, val priorNoticeStartTime: ServiceTime? = null, val priorNoticeCalendarId: String? = null, val message: String? = null, val pickupMessage: String? = null, val dropOffMessage: String? = null, val phoneNumber: String? = null, val infoUrl: String? = null, val bookingUrl: String? = null)(source)

A single booking rule defining how to book a ride for specific zones.

Constructors

Link copied to clipboard
constructor(fromZoneIds: List<String>, toZoneIds: List<String>?, bookingType: BookingType, priorNoticeDurationMin: WholeMinutes? = null, priorNoticeDurationMax: WholeMinutes? = null, priorNoticeLastDay: Int? = null, priorNoticeLastTime: ServiceTime? = null, priorNoticeStartDay: Int? = null, priorNoticeStartTime: ServiceTime? = null, priorNoticeCalendarId: String? = null, message: String? = null, pickupMessage: String? = null, dropOffMessage: String? = null, phoneNumber: String? = null, infoUrl: String? = null, bookingUrl: String? = null)

Properties

Link copied to clipboard
@SerialName(value = "booking_type")
val bookingType: BookingType

Indicates how far in advance booking can be made.

Link copied to clipboard
@SerialName(value = "booking_url")
val bookingUrl: String?

URL to an online interface or app where the booking request can be made.

Link copied to clipboard
@SerialName(value = "drop_off_message")
val dropOffMessage: String?

Functions in the same way as message but used when riders have on-demand drop off only.

Link copied to clipboard
@SerialName(value = "from_zone_ids")
val fromZoneIds: List<String>

One or many zone IDs from zones.json that cover the area of the pickup location for this booking rule.

Link copied to clipboard
@SerialName(value = "info_url")
val infoUrl: String?

URL providing information about the booking rule.

Link copied to clipboard

Message to riders utilizing service inside a zone when booking on-demand pickup and drop off. Meant to provide minimal information to be transmitted within a user interface about the action a rider must take in order to utilize the service.

Link copied to clipboard
@SerialName(value = "phone_number")
val phoneNumber: String?

Phone number to call to make the booking request.

Link copied to clipboard
@SerialName(value = "pickup_message")
val pickupMessage: String?

Functions in the same way as message but used when riders have on-demand pickup only.

Link copied to clipboard
@SerialName(value = "prior_notice_calendar_id")
val priorNoticeCalendarId: String?

Indicates the service days on which prior_notice_last_day or prior_notice_start_day are counted. If empty, prior_notice_start_day=2 will be two calendar days in advance. If defined as a calendar_id containing only business days (weekdays without holidays), prior_notice_start_day=2 will be two business days in advance. Optional if booking_type=2. Forbidden otherwise.

Link copied to clipboard
@SerialName(value = "prior_notice_duration_max")
val priorNoticeDurationMax: WholeMinutes?

Maximum number of minutes before travel to make the booking request. Optional for same-day booking with advance notice (booking_type=1). Forbidden otherwise.

Link copied to clipboard
@SerialName(value = "prior_notice_duration_min")
val priorNoticeDurationMin: WholeMinutes?

Minimum number of minutes before travel to make the request. Required for same-day booking with advance notice (booking_type=1). Forbidden otherwise.

Link copied to clipboard
@SerialName(value = "prior_notice_last_day")
val priorNoticeLastDay: Int?

Last day before travel to make the booking request (e.g. "Ride must be booked 1 day in advance before 5PM" will be encoded as prior_notice_last_day=1). Required for prior day(s) booking (booking_type=2). Forbidden otherwise.

Link copied to clipboard
@SerialName(value = "prior_notice_last_time")
val priorNoticeLastTime: ServiceTime?

Last time on the last day before travel to make the booking request (e.g. "Ride must be booked 1 day in advance before 5PM" will be encoded as prior_notice_last_time=17:00:00). Required if prior_notice_last_day is defined. Forbidden otherwise.

Link copied to clipboard
@SerialName(value = "prior_notice_start_day")
val priorNoticeStartDay: Int?

Earliest day before travel to make the booking request (e.g. "Ride can be booked at the earliest one week in advance at midnight" will be encoded as prior_notice_start_day=7). Forbidden for real-time booking (booking_type=0). Forbidden for same-day booking with advance notice (booking_type=1) if prior_notice_duration_max is defined. Optional otherwise.

Link copied to clipboard
@SerialName(value = "prior_notice_start_time")
val priorNoticeStartTime: ServiceTime?

Earliest time on the earliest day before travel to make the booking request (e.g. "Ride can be booked at the earliest one week in advance at midnight" will be encoded as prior_notice_start_time=00:00:00). Forbidden for real-time booking (booking_type=0). Required if prior_notice_start_day is defined. Forbidden otherwise.

Link copied to clipboard
@SerialName(value = "to_zone_ids")
val toZoneIds: List<String>?

One or many zone IDs from zones.json that cover the area of the destination for this booking rule.