APIs / Travel / FlixBus

1 credit per call9 endpoints10 datapointsChecked working 6 Dec 2026

FlixBus API

FlixBus API for bus trips and fares by route and date, fare calendars, routes, cities and stations as JSON. 9 endpoints, 1 credit per call.

FlixBus
GET/v1/flixbus/city-catalog
{
  "success": true,
  "data": {
    "limit": 50,
    "offset": 0,
    "count": 50,
    "has_more": true,
    "next_offset": 50,
    "cities": [
      {
        "id": "40d8f682-8646-11e6-9066-549f350fcb0c",
        "legacy_id": 88,
        "name": "Berlin",
        "slug": "berlin",
        "country_code": "DE",
        "description": "Visit iconic landmarks like the Brandenburg Gate and Museum Island; experience vibrant nightlife.",
        "location": {
          "lat": 52.525017,
          "lon": 13.369474
        },
        "search_volume": 29397800,
        "activities": [
          "nightlife-and-entertainment",
          "arts-and-culture",
          "luxury-experiences"
        ],
        "transport_modes": [
          "bus",
          "flixtrain"
        ]
      },
      {
        "id": "40d901a5-8646-11e6-9066-549f350fcb0c",
        "legacy_id": 94,
        "name": "Munich",
        "slug": "muenchen",
        "country_code": "DE",
        "description": "Attend Oktoberfest, explore Nymphenburg Palace, and shop along Maximilianstrasse.",
        "location": {
          "lat": 48.135124,
          "lon": 11.581981
        },
        "search_volume": 13680800,
        "activities": [
          "arts-and-culture",
          "festivals-and-events",
          "luxury-experiences"
        ],
        "transport_modes": [
          "bus"
        ]
      },
      {
        "id": "40d91e53-8646-11e6-9066-549f350fcb0c",
        "legacy_id": 118,
        "name": "Hamburg",
        "slug": "hamburg",
        "country_code": "DE",
        "description": "Discover the Elbphilharmonie, stroll the Reeperbahn, and relax at Elbstrand beach.",
        "location": {
          "lat": 53.551765,
          "lon": 10.011657
        },
        "search_volume": 12560000,
        "activities": [
          "nightlife-and-entertainment",
          "arts-and-culture",
          "beaches-and-waterfronts"
        ],
        "transport_modes": [
          "bus",
          "flixtrain",
          "train"
        ]
      }
    ]
  },
  "meta": {
    "endpoint_family": "city_catalog"
  }
}
200 OKJSONX-Credits-Used: 1
Recorded 12 Nov 2026 and shortened.

Sample data

What one call returns

A recorded run of city-catalog: the fields and shapes you will get, shortened to 3 items.

#idstringlegacy_idintegernamestringslugstringcountry_codestringdescriptionstringlocationobjectsearch_volumeintegeractivitiesstring[]transport_modesstring[]
140d8f682-8646-11e6-9066-549f350fcb0c88BerlinberlinDEVisit iconic landmarks like the Brandenburg Gate and Museum Island; experience vibrant nightlife.{2 fields}29397800[3 items][2 items]
240d901a5-8646-11e6-9066-549f350fcb0c94MunichmuenchenDEAttend Oktoberfest, explore Nymphenburg Palace, and shop along Maximilianstrasse.{2 fields}13680800[3 items][1 item]
340d91e53-8646-11e6-9066-549f350fcb0c118HamburghamburgDEDiscover the Elbphilharmonie, stroll the Reeperbahn, and relax at Elbstrand beach.{2 fields}12560000[3 items][3 items]

Recorded 12 Nov 2026 · 3 items shown · 10 datapoints per itemGET /v1/flixbus/city-catalog

10 datapoints

Identity

  • idstring
  • legacy_idinteger
  • namestring
  • slugstring

Location

  • country_codestring
  • locationobject

Other

  • descriptionstring
  • search_volumeinteger
  • activitiesstring[]
  • transport_modesstring[]

Playground

Run this API

cURLshell
curl "https://api.perceptlayer.com/v1/flixbus/city-catalog" \
  -H "X-API-Key: $API_KEY"

FlixBus · 9 endpoints

Endpoints

Every endpoint takes the same key. Open one for its parameters, the fields it returns and an example request.

EndpointRequired parametersReturnsCost
GET/v1/flixbus/calendar
from_city_idto_city_idstart_date+3 optional
from_city_idto_city_idstart_datedaysadultscurrency+2 more
1 credit
GET/v1/flixbus/cities
query
idlegacy_idnamecountry_codedistrictlocation+4 more
1 credit
GET/v1/flixbus/city
city_id
city
1 credit
GET/v1/flixbus/city-catalog
none+2 optional
idlegacy_idnameslugcountry_codedescription+4 more
1 credit
GET/v1/flixbus/routes
city_id+1 optional
idlegacy_idnameslugcountry_codelocation+7 more
1 credit
GET/v1/flixbus/search
from_city_idto_city_iddeparture_date+8 optional
from_city_idto_city_iddeparture_dateadultscurrencytrips+4 more
1 credit
GET/v1/flixbus/station
station_id
station
1 credit
GET/v1/flixbus/stations
query
idlegacy_idnameslugis_trainaddress+6 more
1 credit
GET/v1/flixbus/trip
trip_id
trip
1 credit

Overview

About the FlixBus API

Is there an official FlixBus API?

Not publicly. FlixBus offers API integration to distribution partners under an agreement, and runs its affiliate programme separately. As of December 2026.

Perceptlayer returns FlixBus data as JSON with one Perceptlayer key and no FlixBus approval: 1 credit per successful call, and failed calls are free.

What you can get

The FlixBus API returns bus connections, prices by date, routes, cities and stations through 9 endpoints, all as JSON.

  • Search: trips between two cities on a departure_date, with an optional return_date, sorted by departure, price or duration, with filters for max_price, max_transfers and a departure time window.
  • Calendar: prices across a range of days from a start_date, to find the cheapest day to travel.
  • Trips: the details of one trip by its trip_id.
  • Network: the routes served from a city, the city catalogue, and cities and stations by name.

Prices come back in EUR or USD (currency), for the number of adults you set.

How a call works

FlixBus identifies places by ID. Call GET /v1/flixbus/cities?query=Berlin to get a city's city_id, do the same for the destination, then pass both as from_city_id and to_city_id to search or calendar. Every successful call costs 1 credit; failed calls cost nothing.

TravelJSONRESTMCP

More travel APIs

Use cases

Compare bus fares and journey times between two cities

Use the FlixBus API to compare bus fares and journey times between two cities

Find the cheapest travel day with the price calendar

Use the FlixBus API to find the cheapest travel day with the price calendar

Map the FlixBus network from a city's routes

Use the FlixBus API to map the FlixBus network from a city's routes

Feed bus options into a trip-planning agent

Use the FlixBus API to feed bus options into a trip-planning agent

FAQ

Questions

How much does the FlixBus API cost?

Each successful call costs one credit. New accounts get free credits to start, and credit packs bring the price down as you scale.

How do I find the city IDs for a search?

Call the cities endpoint with a city name in `query`. It returns matching cities with their IDs, which you then use as `from_city_id` and `to_city_id`.

What format are responses in?

Every endpoint returns JSON, with no HTML parsing on your side.

How do I search FlixBus trips with the API?

`search` takes a `from_city_id`, `to_city_id` and `departure_date`, with `return_date`, `adults`, `currency` (EUR or USD), `sort` (departure, price or duration), `max_price` and `max_transfers`. `calendar` takes the same city IDs with a `start_date` and `days`. Each successful call costs 1 credit.

Is this the official FlixBus API?

No. Perceptlayer is an independent service and is not affiliated with FlixBus. It returns FlixBus data as JSON with a Perceptlayer key, so there is no FlixBus developer account, app review or partner approval to get first. It only reads data: if FlixBus has an official API and you need to act on your own FlixBus account, such as posting, managing orders or reading private data, use that one.

Should I build a FlixBus scraper instead?

You can, but a FlixBus scraper is code you maintain: page changes break it, requests get blocked, and FlixBus's terms govern how you collect data. The FlixBus API gives you 9 endpoints of named JSON fields for 1 credit per successful call, and failed calls cost nothing. A scraper makes sense only for data these endpoints don't return, so check the response in the playground on this page first.

Try the FlixBus API with 100 free credits

No credit card. Failed calls are never billed.