Guides / how-to-connect-transport-nsw-api-australia
NSW State gov
How to connect Transport for NSW Open Data API
Transport for NSW
Transport for NSW (TfNSW) publishes open transport datasets and developer feeds through its Open Data portal. The catalogued machine surface is a CKAN action API for package search; some realtime feeds separately require an API key.
Use this when integrating NSW public transport schedules, GTFS-related packages, or other TfNSW open datasets from a script.
Steps
- Find the base URL. Use
https://opendata.transport.nsw.gov.au/api/3/action/package_search— docs at https://opendata.transport.nsw.gov.au/. - Auth. Catalogued as Key — some feeds need API key.
- Try an example request.
curl -s 'https://opendata.transport.nsw.gov.au/api/3/action/package_search?rows=1' - Licence. Check publisher terms — not stated on this record. Read the publisher terms before production use.
- base
- https://opendata.transport.nsw.gov.au/api/3/action/package_search
- docs
- https://opendata.transport.nsw.gov.au/
- protocol
- CKAN
- auth
- Key — some feeds need API key
- licence
- Licence unclear
- try
- curl -s 'https://opendata.transport.nsw.gov.au/api/3/action/package_search?rows=1'
- checked
- 2026-08-23 · 200 OK · 480 ms