Skip to main content

A LTA Datamall API Wrapper Library for Python

Project description

ltasg

Build Status License PyPI version Python versions

A LTA Datamall API Wrapper Library for Python

Table of Contents

Installation

Use the package manager pip to install ltasg:

pip install ltasg

Usage

  • Bus Arrival: Querying bus arrival timings
from ltasg.transport.bus import Bus

# Default base URL uses HTTPS; optionally pass a custom base_url.
api_key = "<YOUR_LTA_DATAMALL_API_KEY>"

bus = Bus(api_key=api_key)
result = bus.arrival(71111, '63')
print(result)

Features

Bus (8 APIs)

  1. Bus Arrival (v3)
  2. Bus Services (with optional ServiceNo filter)
  3. Bus Routes
  4. Bus Stops (with optional BusStopCode filter)
  5. Passenger Volume by Bus Stops (download Link)
  6. Passenger Volume by Origin-Destination Bus Stops (download Link)
  7. Planned Bus Routes
  8. Stop Services (client-side route filter)

Train (6 APIs)

  1. Train Service Alerts
  2. Facilities Maintenance (v2)
  3. Station Crowd Density Real-time
  4. Station Crowd Density Forecast
  5. Passenger Volume by Origin-Destination Train Stations (download Link)
  6. Passenger Volume by Train Stations (download Link)

Taxi (2 APIs)

  1. Taxi Availability
  2. Taxi Stands

Traffic (11 APIs)

  1. Carpark Availability (v2)
  2. Estimated Travel Times
  3. Faulty Traffic Lights
  4. Planned Road Openings
  5. Approved Road Works
  6. Traffic Images (v2)
  7. Traffic Incidents
  8. Traffic Speed Bands (v4)
  9. VMS / EMAS
  10. Traffic Flow (download Link)
  11. Flood Alerts

Other (4 APIs)

  1. Bicycle Parking (v2)
  2. Geospatial Whole Island
  3. EV Charging Points
  4. EV Charging Points Batch

Documentation

Full API reference: LTA DataMall API User Guide v6.8

For parameter details and response schemas, refer to the PDF guide.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ltasg-1.0.0.tar.gz (22.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ltasg-1.0.0-py3-none-any.whl (11.6 kB view details)

Uploaded Python 3

File details

Details for the file ltasg-1.0.0.tar.gz.

File metadata

  • Download URL: ltasg-1.0.0.tar.gz
  • Upload date:
  • Size: 22.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ltasg-1.0.0.tar.gz
Algorithm Hash digest
SHA256 879b750ba70f9a02d5bdb5b37359a68d78fbf18bdd6d143ae7a7093b8c700a4f
MD5 bd343a10daa883be397b1b9b0265c3cd
BLAKE2b-256 97d7ea949c1e4f3699ccbc37c6a1973daeabae3f88782c855691d1c515f88a23

See more details on using hashes here.

Provenance

The following attestation bundles were made for ltasg-1.0.0.tar.gz:

Publisher: release.yml on ashe0047/ltasg

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ltasg-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: ltasg-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 11.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ltasg-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5d37fd33f368fdac72ac8a98d46205346a14de95584fae312666969647b1d00b
MD5 c0735a0c511d1c6787ed452effd1fd25
BLAKE2b-256 1eefc5f030d7d868f3e7c5c781a728bec53f585cc9d1127588dfeab32d2663c3

See more details on using hashes here.

Provenance

The following attestation bundles were made for ltasg-1.0.0-py3-none-any.whl:

Publisher: release.yml on ashe0047/ltasg

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page