A MagicMirror² module that displays live bus departure times for a chosen stop, using the Metlink Open Data API (Wellington, New Zealand region).
- Metlink Open Data API — requires a free API key from the Metlink developer portal. No paid tier or usage cost.
cd ~/MagicMirror/modules
git clone https://github.com/galaxatea/MMM-metlinkBus.gitcd ~/MagicMirror/modules/MMM-metlinkBus
git pullAdd this to the modules array in config/config.js:
{
module: "MMM-metlinkBus",
position: "top_right",
config: {
stopId: "6000",
apiKey: "YOUR_API_KEY",
displayedStops: "5",
showTimeUntil: true,
showClockTime: true
}
},| Option | Description | Default |
|---|---|---|
stopId |
ID of the stop to track (printed on the physical stop sign, or found on the Metlink website) | "6000" (Wellington bus interchange) |
apiKey |
Your free API key from the Metlink developer portal | — (required) |
displayedStops |
Number of upcoming departures to display | "5" |
showTimeUntil |
Show minutes until arrival (true / false) |
true |
showClockTime |
Show 24hr clock time (true / false) |
true |
Stable — working end-to-end and in daily use. Not actively seeking a co-maintainer, but bug reports and PRs are welcome via GitHub Issues. Note: This is my first public repo
Claude was used for the CSS and minor assistance in bug fixing.