> For the complete documentation index, see [llms.txt](https://homey-nederlandse-spoorwegen.gitbook.io/docs-en/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://homey-nederlandse-spoorwegen.gitbook.io/docs-en/readme.md).

# Welcome to NS for Homey

Bring Dutch Railways (NS) live data into your Homey flows.

**The NS app for Homey turns Dutch train data into something your home can react to.** Pin a station or a daily route as a Homey device, automate flows on departures, delays, cancellations, crowdedness or disruptions, and read it all back in Insights.

The app talks to the public NS APIs ([Reisinformatie API](https://apiportal.ns.nl/api-details#api=reisinformatie-api) and [Disruptions API](https://apiportal.ns.nl/api-details#api=Disruptions-Api)) using your own subscription key — your data stays yours.

<table data-card-size="large" data-view="cards"><thead><tr><th></th><th></th><th data-hidden data-card-target data-type="content-ref"></th></tr></thead><tbody><tr><td><strong>Get started</strong></td><td>Paste your NS API key and pair your first device.</td><td><a href="/docs-en/guides/getting-started.md">Getting started</a></td></tr><tr><td><strong>Source code</strong></td><td>Browse the source on GitHub.</td><td><a href="https://github.com/lucasvdh/codes.lucasvdh.ns">https://github.com/lucasvdh/codes.lucasvdh.ns</a></td></tr><tr><td><strong>Report an issue</strong></td><td>Found a bug or want a new feature?</td><td><a href="https://github.com/lucasvdh/codes.lucasvdh.ns/issues">https://github.com/lucasvdh/codes.lucasvdh.ns/issues</a></td></tr></tbody></table>

## What you can do with it

* Get a notification 5 minutes before your last train of the night so you don't miss it.
* Turn on the lights when your train home leaves the station, dim them when it arrives at the next station.
* Have your speakers announce that the 8:19 to Utrecht is on track 5b instead of 5a.
* Automatically push your phone a warning when your usual commute has a disruption.
* Log delay minutes per route over time and visualise them in Homey Insights.

## Disclaimer

This is an unofficial, third-party Homey app. It is not affiliated with, endorsed by, or sponsored by NS Groep N.V. Train data comes from the public NS API which is provided "as is" — accuracy and uptime are out of this app's control.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://homey-nederlandse-spoorwegen.gitbook.io/docs-en/readme.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
