OrbTop

Malaysia Transit — KTMB Rail & Easybook Bus Routes

TRAVELBUSINESS

Malaysia Transit Scraper — KTMB Rail & Easybook Bus Routes

Extract structured transit reference data for Malaysia: approximately 150 KTMB (Keretapi Tanah Melayu Berhad) rail station records with station IDs and line assignments, and 400+ intercity Easybook bus routes with city pairs, distances, average durations, and operator counts. Returns static network topology — not live timetables or fare availability.

What does the Malaysia Transit Scraper do?

  • Scrapes KTMB station master data from the KTMB portal — station ID, station name, line, and state
  • Scrapes Easybook intercity bus route catalogue — city pairs, from/to place IDs, distances, average durations, and operator counts per route
  • Returns two distinct record types (ktmb_station and easybook_route) in a single dataset
  • Filterable by data source via the dataSource input
  • Uses Malaysia-based residential proxies for reliable access

What data does it extract?

KTMB station records (record_type: ktmb_station)

Field Description
record_type ktmb_station
source ktmb
station_id KTMB station ID code
station_name Station name
line KTMB rail line (ETS, Komuter, etc.)
state Malaysian state the station is in

Easybook route records (record_type: easybook_route)

Field Description
record_type easybook_route
source easybook
from_city Origin city name
from_place_id Easybook origin place ID
to_city Destination city name
to_place_id Easybook destination place ID
distance_km Route distance in kilometres
avg_duration_mins Average journey duration in minutes
operator_count Number of bus operators serving this route
route_url Easybook booking page for this route

How to use it

Set dataSource to retrieve only KTMB stations, only Easybook routes, or both. Adjust maxItems to cap total records returned across both types.

For KTMB stations only:

{
  "dataSource": "ktmb_stations",
  "maxItems": 200
}

For Easybook routes only:

{
  "dataSource": "easybook_routes",
  "maxItems": 500
}

For both data sources:

{
  "dataSource": "all",
  "maxItems": 700
}
Field Type Default Description
dataSource string all all, ktmb_stations, or easybook_routes
maxItems integer Maximum records to return across selected data sources
proxyConfiguration object MY residential Malaysia-based residential proxies

Use cases

  • KTMB booking API integration — KTMB station IDs from this actor can be passed directly to the KTMB online booking API at online.ktmb.com.my as origin and destination parameters for downstream fare and schedule queries.
  • Intercity route gap analysis — Query Easybook routes where operator_count=1 to identify monopoly routes with limited competition; useful for transport policy research or market entry analysis by bus operators.
  • Transit network mapping — Build a complete visualisation of Malaysia's intercity transit graph by combining KTMB rail station data with Easybook bus routes to map multimodal coverage across states.
  • Tourism and travel app development — Use the Easybook route_url and KTMB station_id data to populate transit option pickers in Malaysia-focused travel apps without maintaining a live booking integration.
  • Urban and logistics research — Analyze avg_duration_mins and distance_km ratios across routes to estimate effective travel times for supply chain or workforce mobility studies.

Limitations

This actor returns static network topology data — station and route reference records — not live schedules, real-time fares, or seat availability. For live timetable and booking data, use the KTMB station IDs to query online.ktmb.com.my directly, or use Easybook's route_url to open the live booking page for each route.

FAQ

Can I get live train times or bus schedules? No. The actor returns station and route reference data (names, IDs, distances, durations). Live departure times, fares, and seat availability require querying the KTMB or Easybook booking systems in real time. KTMB station IDs from this actor are compatible with the KTMB booking API as origin/destination parameters.

How many Easybook routes are available? The actor retrieves 400+ intercity routes from Easybook's route catalogue. Coverage spans peninsular Malaysia; Sabah and Sarawak intercity routes may have limited coverage depending on Easybook's catalogue.

Results are available for export in JSON, CSV, and Excel formats from the Apify dataset tab.


Further reading: How to Get Airbnb Data, Hotel Prices, and Transit Feeds in Bulk