profitroll
759e6f3703
All checks were successful
Tests / test (3.10) (push) Successful in 22s
Tests / test (3.11) (push) Successful in 23s
Tests / test (3.8) (push) Successful in 22s
Tests / test (3.9) (push) Successful in 23s
Tests / test (3.10) (pull_request) Successful in 22s
Tests / test (3.11) (pull_request) Successful in 19s
Tests / test (3.8) (pull_request) Successful in 22s
Tests / test (3.9) (pull_request) Successful in 20s
30 lines
739 B
Python
30 lines
739 B
Python
"""
|
|
## PythonRMV
|
|
|
|
Small module that makes your journey with RMV REST API somehow easier. Based fully on official RMV API reference and HAFAS documentation.
|
|
|
|
## Usage
|
|
|
|
```py
|
|
import pyrmv
|
|
|
|
# Define a Client with API key
|
|
client = pyrmv.Client("AcessId")
|
|
|
|
# Get origin's and destination's location
|
|
origin = client.stop_by_name("Frankfurt Hauptbahnhof", max_number=3)[0]
|
|
destination = client.stop_by_coords(50.099613, 8.685449, max_number=3)[0]
|
|
|
|
# Find a trip by locations got
|
|
trip = client.trip_find(origin_id=origin.id, dest_id=destination.id)
|
|
```
|
|
"""
|
|
|
|
__name__ = "pyrmv"
|
|
__version__ = "0.4.0"
|
|
__license__ = "MIT License"
|
|
__author__ = "Profitroll"
|
|
|
|
from . import classes, const, enums, errors, raw, utility
|
|
from .classes.client import Client
|