Skip to content
Back to skills

Mvg Cli

ASecurity

Munich public transport (MVG) CLI and S-Bahn live tracking. Use for departure times, route planning, nearby stations, service alerts, and real-time S-Bahn positions. Trigger when the user mentions MVG, S-Bahn, U-Bahn, Munich transit, departures, connections, Abfahrten, Verbindungen, or specific line names like S8, U3, etc.

  • 21 stars
  • 0 votes
  • 0 copies
  • 5 views
  • Added September 7, 2026
toolspythonbashnodeapi

Works with

  • terminal
  • cli
  • api

Security analysis

A100/100

Pro scans all 4 files and shows the line behind each finding

Scanned September 7, 2026

npx -y skills add modbender/skill-library-mcp --skill mvg-cli --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Mvg Cli?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Mvg Cli
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/modbender-mvg-cli/badge)](https://www.skillsdirectory.com/skills/modbender-mvg-cli)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: mvg
description: Munich public transport (MVG) CLI and S-Bahn live tracking. Use for departure times, route planning, nearby stations, service alerts, and real-time S-Bahn positions. Trigger when the user mentions MVG, S-Bahn, U-Bahn, Munich transit, departures, connections, Abfahrten, Verbindungen, or specific line names like S8, U3, etc.
---

# MVG CLI

Munich public transport from the terminal. Uses the unofficial MVG API (`bgw-pt/v3`) — no auth needed.

## Setup

- **CLI**: `python3 <skill_dir>/mvg_cli.py`
- **Dependencies**: Python 3, `urllib` (stdlib only)
- **S-Bahn Live**: Requires `node` + `ws` module for WebSocket connection

## Commands

```bash
# Station search
mvg search "Marienplatz"

# Departures
mvg departures "Marienplatz"
mvg departures "Marienplatz" --type ubahn --limit 20
mvg departures "Daglfing" --offset 5          # +5min walking time

# Route planning (stations or addresses)
mvg route "Marienplatz" "Garching"
mvg route "Hauptstr. 1, München" "Flughafen"  # address support
mvg route "Pasing" "Ostbahnhof" --time "08:30" --mode less-changes

# Nearby stations
mvg nearby                                     # default coords
mvg nearby 48.1351 11.5820

# Service alerts
mvg alerts
mvg alerts --station "Marienplatz"

# Lines
mvg lines --type sbahn

# S-Bahn live tracking (real-time via geOps WebSocket)
mvg live                                       # all S-Bahn lines
mvg live --line S3                             # specific line
```

All commands support `--json` for machine-readable output.

## Transport Type Filters

Use with `--type` or `--exclude`: `ubahn`, `sbahn`, `bus`, `tram`, `bahn` (RE/RB), `regionalbus`, `ruftaxi`

## Route Options

- `--mode`: `fast` (default), `less-changes`, `less-walking`
- `--walk-speed`: `slow`, `normal` (default), `fast`
- `--accessible`: wheelchair-accessible routes only
- `--via "Station"`: route via intermediate stop
- `--arrive`: interpret `--time` as arrival time

## API Notes

- Base URL: `https://www.mvg.de/api/bgw-pt/v3/`
- Endpoints: `/locations`, `/departures`, `/routes`, `/stations/nearby`, `/lines`, `/messages`
- Arrival time in route responses: use `to.plannedDeparture` (not `plannedArrival`)
- S-Bahn live: `wss://api.geops.io/realtime-ws/v1/` with `GET sbm_full` + `SUB sbm_full` + `BBOX`
- Delays from geOps are in milliseconds

Files in this skill

  • README.md3.7 KB
  • SKILL.md2.4 KB
  • mvg_cli.py51.1 KB
  • pyproject.toml1021 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in tools →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.