Discover/redBus API
live

redBus APIredbus.in

Search buses and trains on redBus.in via API. Get seat layouts, schedules, boarding points, fares, and city/station suggestions across 7 endpoints.

Endpoint health
verified 9h ago
get_city_suggestions
get_bus_seat_layout
search_trains
get_bus_details
search_buses
7/7 passing latest checkself-healing
Endpoints
7
Updated
15d ago

What is the redBus API?

The redBus.in API covers 7 endpoints for querying bus and train services listed on redBus.in, returning operator details, seat-level availability, boarding/dropping points, and complete train schedules. The search_buses endpoint returns paginated inventories with fare lists, available seat counts, departure and arrival times per operator. The get_bus_seat_layout endpoint maps each seat by X/Y coordinates along with per-seat fares and availability status.

Try it
Max results to return
Search query for city name (e.g. 'Mumbai', 'Pune', 'Bangalore')
api.parse.bot/scraper/35a9b6fe-4009-43dd-89e2-993f11b60ad0/<endpoint>
Ready to send
Fill in the parameters and hit sign in to send to see live response data here.
Call it over HTTPgrab a free API key at signup
curl -X GET 'https://api.parse.bot/scraper/35a9b6fe-4009-43dd-89e2-993f11b60ad0/get_city_suggestions?limit=10&query=Mumbai' \
  -H 'X-API-Key: $PARSE_API_KEY'
Python SDK · recommended

Typed, relational, agent-ready

A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.

  • Fully typed · autocompletes
  • Objects link to objects
  • Typed errors & pagination

Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:

uv add parse-sdk
uv run parse init
uv run parse add --marketplace redbus-in-api

uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.

"""Walkthrough: redBus API — search cities, buses, trains, get details and schedules."""
from parse_apis.redBus_Bus_and_Train_API import RedBus, NotFoundError

client = RedBus()

# Search cities to get IDs for bus search
for city in client.cities.search(query="Mumbai", limit=5):
    print(city.name, city.location_name, city.region)

# Search buses between two cities on a future date
bus = client.bus_services.search(
    from_city_id="462", to_city_id="130", doj="26-Jun-2026", limit=1
).first()
if bus:
    print(bus.travels_name, bus.bus_type, bus.available_seats, bus.fare_list)

    # Get detailed boarding/dropping points for this bus
    detail = bus.details(doj="26-Jun-2026", from_city_id="462", to_city_id="130")
    for bp in detail.boarding_points[:3]:
        print(bp.name, bp.time, bp.address)

    # Get seat layout for this bus
    layout = bus.seat_layout(doj="26-Jun-2026")
    for svc in layout.services[:1]:
        print(svc.bus_type, svc.available_seats)

# Search trains between stations
for result in client.train_results.search(src="MMCT", dst="NDLS", doj="20260625", limit=3):
    print(result.train_name, result.train_number, result.duration, result.distance)

# Construct a train by number and get its full schedule
try:
    sched = client.train(train_no="22209").schedule()
    print(sched.train_name, sched.source, sched.destination)
    for stop in sched.stops[:3]:
        print(stop.station_name, stop.station_code, stop.departure_time)
except NotFoundError as exc:
    print(f"Not found: {exc}")

# Search trains by name
train = client.trains.search(query="Rajdhani", limit=1).first()
if train:
    print(train.train_name, train.train_no, train.src_station_name)

print("exercised: cities.search / bus_services.search / bus.details / bus.seat_layout / train_results.search / train.schedule / trains.search")
All endpoints · 7 totalmissing one? ·

Get city suggestions and IDs for bus search autocomplete. Returns matching cities with their IDs, location names, and boarding point lists. Use the returned city ID to feed into search_buses, get_bus_details, or get_bus_seat_layout endpoints.

Input
ParamTypeDescription
limitintegerMax results to return
queryrequiredstringSearch query for city name (e.g. 'Mumbai', 'Pune', 'Bangalore')
Response
{
  "type": "object",
  "fields": {
    "docs": "array of city objects with ID, Name, locationName, region, BpList",
    "numFound": "integer - number of matching cities found"
  },
  "sample": {
    "data": {
      "docs": [
        {
          "ID": 462,
          "cc": "IND",
          "Name": "Mumbai",
          "rank": 111266,
          "BpList": [
            {
              "ID": 66545,
              "Name": "Borivali East, Mumbai",
              "locationName": "Borivali East"
            }
          ],
          "region": "Maharashtra and Goa",
          "locationName": "Mumbai (All Locations)",
          "locationType": "CITY"
        }
      ],
      "numFound": 1
    },
    "status": "success"
  }
}

About the redBus API

Bus Search and Route Data

Use get_city_suggestions with a query string to retrieve matching city objects, each carrying an ID, locationName, region, and a BpList of boarding points. Pass the returned ID values as from_city_id and to_city_id in search_buses, along with a doj (date of journey in DD-Mon-YYYY format). The response includes a metaData object with totalCount for pagination and an inventories array containing travelsName, busType, fareList, availableSeats, departureTime, and arrivalTime per service. Use offset and limit parameters to page through results.

Bus Details and Seat Layouts

get_bus_details accepts a route_id from the search response and returns two separate arrays: BPLt (boarding points) and DPLt (dropping points), each with Id, Address, BpTm, and name. It also returns services objects that include operator info, amenities, and cancellation policy. For seat-level data, get_bus_seat_layout takes the same route_id plus an operator_id and returns a seatlist where each entry has Id, IsAvailable, fares, and X/Y grid coordinates — enough to reconstruct the physical seat map. Boarding and dropping point details with LatLong coordinates are also included in BPInformationList and DPInformationList.

Train Search and Schedules

get_train_suggestions searches by train name or number and returns trainNo, trainName, srcStationCode, and destStationCode. Feed station codes into search_trains using src, dst, and a doj in YYYYMMDD format. Results come back in trainBtwnStnsList with departureTime, arrivalTime, duration, distance, avlClasses, and tbsAvailability. For a full stop-by-stop itinerary, get_train_schedule accepts a train_no and returns a Schedule array where each stop includes StationName, StationCode, ArrivalTime, DepartureTime, Day, and DistanceFromOrigin.

Reliability & maintenanceVerified

The redBus API is a managed, monitored endpoint for redbus.in — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when redbus.in changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.

This isn't an official redbus.in API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.

Last verified
9h ago
Latest check
7/7 endpoints passing
Maintenance
Monitored & self-healing
Will this API break when the source site changes?+
It's built not to. Every endpoint is health-checked on a schedule with automated test probes. When the source site changes and a check fails, the API is automatically queued for repair and re-verified — that's the self-healing layer. Each API page shows when its endpoints were last verified. And because marketplace APIs are shared, any fix reaches everyone using it.
Is this an official API from the source site?+
No — Parse APIs are independent, managed REST wrappers over publicly available data. That is the point: where a site has no official API (or only a limited one), Parse gives you a maintained, monitored endpoint for that data and keeps it working as the site changes — so you get a stable contract over a source that never promised one.
Can I fix or extend this API myself if I need a new endpoint or field?+
Yes — and you don't have to wait on us. This API was generated by the Parse agent, which stays attached. Describe the change in plain English ("add an endpoint that returns reviews", "fix the price field") in the revise box on the API page or via the revise_api MCP tool, and the agent rebuilds it against the live site in minutes. Contributing the change back to the public API is free.
What happens if I call an endpoint that has an issue?+
Errors are machine-readable: a bad call returns a clean status with the list of available endpoints and a repair hint, so an agent (or you) can recover or trigger a fix instead of failing silently. Confirmed failures feed the automatic repair queue.
Common use cases
  • Build a bus fare comparison tool using fareList and availableSeats from search_buses
  • Render an interactive seat-selection map using X/Y coordinates from get_bus_seat_layout
  • Show boarding and dropping point locations on a map using LatLong from BPInformationList
  • Display a complete train route with all stops and timings using get_train_schedule
  • Autocomplete city or station inputs in a travel app using get_city_suggestions or get_train_suggestions
  • Monitor seat availability across multiple bus operators for a given route and date
  • Build a train class availability checker using avlClasses and tbsAvailability from search_trains
Pricing & limitsSee full pricing →
TierPriceCredits/monthRate limit
Free$0/mo1005 req/min
Hobby$30/mo1,00020 req/min
Developer$100/mo5,000100 req/min

One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.

Frequently asked questions
Does redBus.in have an official public developer API?+
redBus does not offer a publicly documented developer API for general access. Their integration programs are partner-facing and not openly available to independent developers.
What does `get_bus_seat_layout` return beyond seat availability?+
It returns a seatlist array where each seat object includes Id, IsAvailable, per-seat fares, and X/Y grid coordinates. It also returns BPInformationList and DPInformationList with stop names, addresses, times, and LatLong values for boarding and dropping points.
Does the API support booking or ticketing on redBus?+
No booking or payment endpoints are included. The API covers search, schedule, seat layout, and suggestion data only. You can fork the API on Parse and revise it to add an endpoint covering booking-related data if that surface becomes accessible.
How does pagination work in `search_buses`?+
The endpoint accepts limit and offset integer parameters. The metaData object in the response includes totalCount, which tells you how many total results exist for the route and date so you can calculate how many pages to fetch.
Does the API return live PNR status or train running status?+
Not currently. The API covers train search between stations, class availability, and full stop-by-stop schedules via get_train_schedule. Live running status and PNR lookup are not included. You can fork the API on Parse and revise it to add those endpoints.
Page content last updated . Spec covers 7 endpoints from redbus.in.
Related APIs in TravelSee all →
railyatri.in API
Search trains between stations and get real-time information including live train status, timetables, seat availability, and PNR confirmation details. Find the perfect journey by autocompleting station and train names while checking current availability and train schedules.
megabus.com API
Search for coach trips and compare fares across Megabus UK routes, view available stops and route information, and check real-time seat availability and fare calendars. Retrieve cheapest-price calendars and vacancy data across multiple departure dates and destinations.
enquiry.indianrail.gov.in API
Search for trains between Indian stations, check schedules, and look up station details to plan your rail journeys. Get real-time train information with support for captcha-protected searches to ensure reliable access to Indian Railways data.
amtrak.com API
Search for Amtrak trains across stations, compare fares, and discover discounts to plan your rail journey with current pricing and availability. Get detailed train information, autocomplete station names, and find the cheapest routes for your travel dates.
omio.com API
Search and compare train, bus, and flight trips across multiple providers in real-time, with detailed pricing breakdowns and the ability to view fares across different dates. Find the best deals by exploring popular destinations, autocompleting location searches, and analyzing price variations to plan your ideal journey.
bahn.com API
Search German train schedules and stations, find connections between destinations, and compare ticket prices across Deutsche Bahn routes. Get real-time station information and transit association details to plan your train journey efficiently.
skyscanner.co.in API
Search for flights worldwide and compare prices with autocomplete suggestions for airports and destinations. View price calendars to find the cheapest travel dates and explore real-time flight availability and pricing.
expedia.com API
Search for hotels and flights across Expedia while viewing detailed property information to compare prices and amenities for your travel plans. Get comprehensive travel options all from one integration without manually browsing the website.