# FlixBus station autocomplete API

Search FlixBus stations by text, language or country via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Apish, pass parameters such as output, q, raw, and retrieve structured data including source station UUID, parent source city UUID, station display name, source station address, and source train-station flag for station selector, and city linkage.

Documentation: https://openany.si/flixbus/flixbus-station-autocomplete-api/421457e6-2a6a-4af1-accc-8bae297bee6c/
API ID: 421457e6-2a6a-4af1-accc-8bae297bee6c
Provider: apish
Contract revision: 3
Method: GET
Endpoint: https://api.openany.si/v1/agent-apis/apish/flixbus/v1/stations
Page update time: 2026-12-03T02:47:05.546Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: none
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0.002 / billing credit
API-key calls use your shared balance. Review the published billing rules before making a paid request.
Price source: OpenAny public API contract.
Contract update time: 2026-12-03T02:47:03.379Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "rules",
  "parameters": [],
  "policy_version": 2,
  "sale": {
    "addons": [],
    "base_price_micro_usd": "0",
    "max_cost_micro_usd": "2000",
    "quantities": [
      {
        "id": "upstream_credits",
        "label": "Actual API.SH credits consumed",
        "max_quantity": "1",
        "measure": "value",
        "pointer": "/credits_used",
        "price_micro_usd": "2000",
        "quantity_scale": 0,
        "source": "response",
        "unit": "credit",
        "unit_quantity": "1"
      }
    ],
    "rounding": "ceil",
    "variants": []
  }
}
```

## Usage and limits
## FlixBus Station Search API

Pass q with at least two characters, optionally lang and country. Use the station UUID for Trip Search with search\_by=stations; city\_id is a separate parent-city reference.

## What You Can Build

- **Station selector**: Retain the station UUID and source address.
- **City linkage**: Keep parent-city references distinct from stations.

## Returned Data

| Field | Meaning |
| --- | --- |
| `stations[].id` | Source station UUID |
| `stations[].city_id` | Parent source city UUID |
| `stations[].name` | Station display name |
| `stations[].address` | Source station address |
| `stations[].is_train` | Source train-station flag |
| `stations[].legacy_id` | Source legacy station identifier |

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "FlixBus station autocomplete API request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {}
    },
    "query": {
      "type": "object",
      "properties": {
        "q": {
          "type": "string",
          "description": "At least 2 characters of a station or city name."
        },
        "lang": {
          "type": "string",
          "description": "Language code."
        },
        "country": {
          "type": "string",
          "description": "2-letter country code filter."
        },
        "raw": {
          "type": "string",
          "description": "0 leaves out the bulky `raw` source blocks (often 10-30x smaller).",
          "enum": [
            "0",
            "1"
          ]
        },
        "fields": {
          "type": "string",
          "description": "Comma-separated fields to return, e.g. `posts.id,posts.title`. Call metadata is always included."
        },
        "fresh": {
          "type": "string",
          "description": "1 skips the 24-hour cache and fetches live.",
          "enum": [
            "1"
          ]
        },
        "output": {
          "type": "string",
          "description": "JSON only for this OpenAny product. Omit output or use json; CSV and NDJSON are not supported.",
          "enum": [
            "json"
          ]
        },
        "records": {
          "type": "string",
          "description": "With output=csv|ndjson: the top-level list to turn into rows (e.g. `reviews`), or `.` for the whole object as one row."
        }
      },
      "required": [
        "q"
      ]
    },
    "headers": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "path",
    "query",
    "headers"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "cached": {
      "type": "boolean"
    },
    "count": {
      "type": "integer"
    },
    "credits_used": {
      "type": "integer"
    },
    "fetched_at": {
      "type": "string"
    },
    "q": {
      "type": "string"
    },
    "stations": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "address": {
            "type": "string"
          },
          "city": {
            "type": "string"
          },
          "city_id": {
            "type": "string"
          },
          "city_legacy_id": {
            "type": "integer"
          },
          "country": {
            "type": "string"
          },
          "country_name": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "is_train": {
            "type": "boolean"
          },
          "lat": {
            "type": "number"
          },
          "legacy_id": {
            "type": "integer"
          },
          "lng": {
            "type": "number"
          },
          "name": {
            "type": "string"
          },
          "score": {
            "type": "number"
          },
          "slug": {
            "type": "string"
          },
          "zip_code": {
            "type": "string"
          }
        }
      }
    }
  }
}
```

## Request example
Scenario: Official example · Live API.SH response · Minimal request
```bash
curl \
  'https://api.openany.si/v1/agent-apis/apish/flixbus/v1/stations?output=json&q=munich&raw=0' \
  -X GET \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json'
```

## Response example
Example from the provider's documentation. Field values in your results will differ.
Sample response · Documented HTTP 200
```json
{
  "cached": false,
  "count": 4,
  "credits_used": 1,
  "fetched_at": "2026-11-19T12:25:01.753Z",
  "q": "munich",
  "stations": [
    {
      "address": "Willy-Brandt-Allee 11",
      "city": "Munich",
      "city_id": "40d901a5-8646-11e6-9066-549f350fcb0c",
      "city_legacy_id": 94,
      "country": "DE",
      "country_name": "Germany",
      "id": "209d10df-3a5a-4355-a514-3fa1827ff9ff",
      "is_train": false,
      "lat": 48.13511678371407,
      "legacy_id": 20108,
      "lng": 11.705082896331579,
      "name": "Munich Messe",
      "score": 20.98183,
      "slug": "munich-east-bus-station-messestadt-ost",
      "zip_code": "81829"
    },
    {
      "address": "Werner-Heisenberg-Allee 21",
      "city": "Munich",
      "city_id": "40d901a5-8646-11e6-9066-549f350fcb0c",
      "city_legacy_id": 94,
      "country": "DE",
      "country_name": "Germany",
      "id": "dcc0b7f3-9603-11e6-9066-549f350fcb0c",
      "is_train": false,
      "lat": 48.210819,
      "legacy_id": 4628,
      "lng": 11.618642,
      "name": "Munich Fröttmaning",
      "score": 20.764446,
      "slug": "muenchen-froettmaning",
      "zip_code": "80939"
    },
    {
      "address": "Arnulfstraße 21",
      "city": "Munich",
      "city_id": "40d901a5-8646-11e6-9066-549f350fcb0c",
      "city_legacy_id": 94,
      "country": "DE",
      "country_name": "Germany",
      "id": "dcbabbfa-9603-11e6-9066-549f350fcb0c",
      "is_train": false,
      "lat": 48.14248,
      "legacy_id": 10,
      "lng": 11.55001,
      "name": "Munich central bus station",
      "score": 20.71884,
      "slug": "mnchen-zob",
      "zip_code": "80335"
    },
    {
      "address": "Terminalstraße Ost 2",
      "city": "Munich International Airport",
      "city_id": "40dc4639-8646-11e6-9066-549f350fcb0c",
      "city_legacy_id": 585,
      "country": "DE",
      "country_name": "Germany",
      "id": "dcbbb2f5-9603-11e6-9066-549f350fcb0c",
      "is_train": false,
      "lat": 48.355978,
      "legacy_id": 621,
      "lng": 11.790023,
      "name": "Munich Airport",
      "score": 18.427896,
      "slug": "mnchen-muc",
      "zip_code": "85356"
    }
  ]
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Common questions
### What text and country formats are accepted?
q needs at least two characters. country is a two-letter code; lang controls source language.

### How do I search journeys from a returned station?
Pass its station name or ID to Trip Search with search_by=stations.

### Can I substitute city_id for a station ID?
They identify different location scopes. Keep station and parent-city references separate.

### Does is_train describe service on a selected day?
It is a source station-type flag. Use Trip Search for the selected travel date and transport options.

### How do I bypass cached results?
Pass fresh=1. A cache bypass retrieves available source data; it does not make unpublished or restricted records available.

### Can I request CSV or NDJSON?
This OpenAny implementation serves JSON only. Omit output or set output=json.

## Available implementations
- apish: https://openany.si/flixbus/flixbus-station-autocomplete-api/421457e6-2a6a-4af1-accc-8bae297bee6c/

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
