Skip to main content

Pytelematics-oasa

Pytelematics-oasa is a simple API wrapper for python.

Installation

pip install pytelematics-oasa

Requirements: requests

Usage

from pytelematics_oasa import OasaTelematics, Line, Route, Stop

##### Line #####

# example using linecode 962 (A1 ΠΕΙΡΑΙΑΣ-ΒΟΥΛΑ)
line = Line('962')

line.ID        # Α1
line.linecode  # 962
line.name      # ΠΕΙΡΑΙΑΣ - ΒΟΥΛΑ
line.name_en   # PEIRAIAS - VOYLA

line.routes()
line.schedule_days()

##### Route #####

# example using routecode 1884 (845 ΠΕΙΡΑΙΑΣ - ΕΛΕΥΣΙΝΑ, route: ΕΛΕΥΣΙΝΑ ==> ΠΕΙΡΑΙΑΣ)
route = Route('1884')

route.name      # ΕΛΕΥΣΙΝΑ - ΠΕΙΡΑΙΑΣ
route.name_en   # ELEFSINA - PEIRAIAS
route.routecode # 1884

route.stops()
route.bus_location()
route.details()

##### Stop #####

# example using stopcode 400075 (στάση ΗΣΑΠ Ν.ΦΑΛΗΡΟΥ)
stop = Stop('400075')

stop.name     # ΗΣΑΠ Ν.ΦΑΛΗΡΟΥ
stop.name_en  # ISAP.N.FALIROY
stop.lat      # 37.9445913
stop.lng      # 23.6671421
stop.stopcode # 400075

stop.arrivals()

###### Oasa ######

# Use the get method for getting data. 
# 1st arg: action, 2nd~ arg: params
# More info at the documentation page.
# https://oasa-telematics-api.readthedocs.io/en/latest/index.html

oasa = OasaTelematics()

oasa.get('getRoutesForLine', 962)
oasa.get('getClosestStops', 37.9445913, 23.6671421)

# Custom methods
oasa.get_all_lines()
oasa.closest_stops(x, y) 
oasa.linecodes(lineID)

API Documentation

Oasa-Telematics-API

License

MIT License

Metadata

Release files for pytelematics-oasa 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pytelematics-oasa 1.0.0
File Size Uploaded Provenance Actions
pytelematics-oasa-1.0.0.tar.gz 3.5 kB Without provenance Details for pytelematics-oasa-1.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pytelematics-oasa 1.0.0
File Interpreter ABI Platform Actions
pytelematics_oasa-1.0.0-py3-none-any.whl Python 3 none any Details for pytelematics_oasa-1.0.0-py3-none-any.whl

Total release size: 8.5 kB

Release files / pytelematics-oasa-1.0.0.tar.gz

Download URL pytelematics-oasa-1.0.0.tar.gz
Size 3.5 kB
Tags Source
SHA-256 checksum
How to use checksums
8e40974c202ad34eb2c9e32a9f2127fe0234487fc27c974c263c9b91062f4d76
BLAKE2b-256 checksum
How to use checksums
803f9c7ce33235ee75840ba13405a15a2456cf24f7e580e3e381211d4a214c8e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

Release files / pytelematics_oasa-1.0.0-py3-none-any.whl

Download URL pytelematics_oasa-1.0.0-py3-none-any.whl
Size 4.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
dd801b96b40bb2474dec1425d2efb031c66435467ed0bb9c77fc37c2baffe111
BLAKE2b-256 checksum
How to use checksums
0a758b568ab6430002863a50e90b8e7251a8b424727df52c1c48214aff9ecccb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3

Security for pytelematics-oasa 1.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page