GTFS-RT

De Lijn: bus and tram operator in flanders, with lines into brussels

Format
GTFS-RT
Updates
Every 20 seconds
Latest snapshot
Snapshots stored
about 3,310,305
curl -H "Authorization: Bearer $MOBILITYTWIN_TOKEN" -o gtfs-realtime.pb "https://api.mobilitytwin.brussels/de-lijn/gtfs-realtime"

De Lijn's own GTFS-RT feed, as published.

A binary GTFS Realtime message (Protocol Buffers). Decode it with gtfs-realtime-bindings.

Which days have data

Data from 21 Aug 2024 to 2 Nov 2026, on 799 days. 30 of the last 30 days have data. A typical day holds 4038 snapshots. Days are in UTC.

2026
JanFebMarAprMayJunJulAugSepOctNovDec
2025
JanFebMarAprMayJunJulAugSepOctNovDec
2024
JanFebMarAprMayJunJulAugSepOctNovDec
  • Full day
  • Partial, 50–90% of a typical day
  • Low, under 50%
  • No snapshot
  • Not expected

Click a day above, or pick a date, to get its requests.

Parameters

NameMeaning
timestampReturn the last snapshot at or before this moment, in Unix seconds or ISO 8601 (e.g. 2026-05-06T12:00:00Z). Without it, the latest snapshot is returned.

Python example

import requests
from google.transit import gtfs_realtime_pb2

from datetime import datetime, timedelta, timezone

yesterday_noon = (datetime.now(timezone.utc) - timedelta(days=1)).replace(
    hour=12, minute=0, second=0, microsecond=0
)
params = {
    "timestamp": yesterday_noon.isoformat(),   # ISO accepted; epoch also works
}

url = "https://api.mobilitytwin.brussels/de-lijn/gtfs-realtime"

data = requests.get(url, headers={
        'Authorization': 'Bearer [MY_API_KEY]'
}, params=params).content

feed = gtfs_realtime_pb2.FeedMessage()
feed.ParseFromString(data)

# The feed mixes trip updates, vehicle positions and alerts: dispatch on the entity type
for entity in feed.entity:
    if entity.HasField('vehicle'):
        v = entity.vehicle
        pos = v.position
        print(f"Vehicle {v.vehicle.id} on trip {v.trip.trip_id} at ({pos.latitude:.4f}, {pos.longitude:.4f})")
    elif entity.HasField('trip_update'):
        tu = entity.trip_update
        print(f"Trip {tu.trip.trip_id}: {len(tu.stop_time_update)} stop time updates")
    elif entity.HasField('alert'):
        texts = entity.alert.header_text.translation
        print(f"Alert: {texts[0].text if texts else ''}")