Package-level declarations

Types

Link copied to clipboard
data class Alert(val alertId: String, val type: AlertType, val times: List<AlertTime>? = null, val stationIds: List<String>? = null, val regionIds: List<String>? = null, val url: Url? = null, val summary: String, val description: String? = null, val lastUpdated: EpochSeconds? = null)

An alert about changes to the system.

Link copied to clipboard
data class AlertTime(val start: EpochSeconds, val end: EpochSeconds? = null)

Time period when an alert is in effect.

Link copied to clipboard
value class AlertType(val value: String)

Type of system alert.

Link copied to clipboard
data class Bike(val bikeId: String, val lat: Double, val lon: Double, val isReserved: IntBoolean, val isDisabled: IntBoolean, val rentalUris: RentalUris? = null)

Represents a vehicle that is currently not part of an active rental.

Link copied to clipboard
value class FeedType(val value: String)

Types of feeds that can be published in a GBFS system.

Link copied to clipboard

Describes all vehicles that are not currently in active rental. Required of systems that don't utilize docks or offer bikes for rent outside of stations.

Link copied to clipboard
sealed interface GbfsFeedData

A possible value of GbfsFeedResponse.data.

Link copied to clipboard
data class GbfsFeedResponse<T : GbfsFeedData>(val lastUpdated: EpochSeconds, val ttl: WholeSeconds, val version: String? = null, val data: T)

Standard GBFS feed response wrapper.

Link copied to clipboard

HTTP client for fetching GBFS v1 feeds.

Link copied to clipboard
data class PricingPlan(val planId: String, val url: Url? = null, val name: String, val currency: CurrencyCode, val price: Double, val isTaxable: IntBoolean, val description: String)

A pricing plan for renting vehicles.

Link copied to clipboard
data class Region(val regionId: String, val name: String)

A geographic or administrative region within the system.

Link copied to clipboard
data class RentalAppPlatformUris(val storeUri: Uri, val discoveryUri: Uri)

Rental app download and discovery information for a specific platform.

Link copied to clipboard
data class RentalAppUris(val android: RentalAppPlatformUris? = null, val ios: RentalAppPlatformUris? = null)

Contains rental app information for different platforms.

Link copied to clipboard
value class RentalMethod(val value: String)

Payment methods accepted at a station.

Link copied to clipboard
data class RentalUris(val android: Uri? = null, val ios: Uri? = null, val web: Url? = null)

Contains rental URIs for different platforms to support deep linking.

Link copied to clipboard
data class Service(val feeds: Map<FeedType, Url>) : Map<FeedType, Url>

A collection of GBFS feeds for a specific language.

Link copied to clipboard
data class Station(val stationId: String, val name: String, val shortName: String? = null, val lat: Double, val lon: Double, val address: String? = null, val crossStreet: String? = null, val regionId: String? = null, val postalCode: String? = null, val rentalMethods: List<RentalMethod>? = null, val capacity: Int? = null, val rentalUris: RentalUris? = null)

Information about a single station.

Link copied to clipboard

Information about stations in the system.

Link copied to clipboard

Describes the capacity and rental availability of a station.

Link copied to clipboard
data class StationStatusEntry(val stationId: String, val numBikesAvailable: Int, val numBikesDisabled: Int? = null, val numDocksAvailable: Int, val numDocksDisabled: Int? = null, val isInstalled: IntBoolean, val isRenting: IntBoolean, val isReturning: IntBoolean, val lastReported: EpochSeconds)

Real-time status information for a single station.

Link copied to clipboard
data class SystemAlerts(val alerts: List<Alert>) : GbfsFeedData, List<Alert>

Informs customers about changes to the system that do not fall within the normal system operations.

Link copied to clipboard

Describes the operating calendar for a system.

Link copied to clipboard
data class SystemCalendarEntry(val startYear: Int? = null, val startMonth: MonthNumber, val startDay: Int, val endYear: Int? = null, val endMonth: MonthNumber, val endDay: Int)

A calendar entry defining an operating period for the system.

Link copied to clipboard

Describes hours and days of operation when vehicles are available for rental.

Link copied to clipboard
data class SystemHoursEntry(val userTypes: List<UserType>, val days: List<AbbreviatedWeekday>, val startTime: ServiceTime, val endTime: ServiceTime)

Hours of operation for specific user types and days of the week.

Link copied to clipboard
data class SystemInformation(val systemId: String, val language: LanguageCode, val name: String, val shortName: String? = null, val operator: String? = null, val url: Url? = null, val purchaseUrl: Url? = null, val startDate: ExtendedLocalDate? = null, val phoneNumber: String? = null, val email: String? = null, val feedContactEmail: String? = null, val timezone: TimeZone, val licenseUrl: Url? = null, val rentalApps: RentalAppUris? = null) : GbfsFeedData

Details about the vehicle share system including system operator, system location, year implemented, URL, contact info, time zone.

Link copied to clipboard

The gbfs.json auto-discovery file that represents a single system or geographic area in which vehicles are operated.

Link copied to clipboard

Describes pricing for the system.

Link copied to clipboard

Describes regions for a system.

Link copied to clipboard
value class UserType(val value: String)

Type of user (member or non-member).

Link copied to clipboard
data class VersionInfo(val version: String, val url: Url)

Information about a specific version of a GBFS feed.

Link copied to clipboard

Lists all available versions of a GBFS feed.

Properties

Link copied to clipboard

Pre-configured JSON instance for parsing GBFS feeds.