Updated readme with __init__ changes and update ergast description

This commit is contained in:
Samuel Roach 2022-06-01 18:40:36 +01:00
parent 5e6a4731a4
commit 4ffbd89505
2 changed files with 30 additions and 2 deletions

View File

@ -27,9 +27,9 @@ Once ergast-py is installed on your system you can then begin using the library
Note: Whilst the package is called ``ergast-py``, you need to import ``ergast_py``
```python
from ergast_py import ergast.Ergast
import ergast_py
e = Ergast()
e = ergast_py.Ergast()
```
Queries can then be built up with function calls in a sequential manner. Once you've built up a query, finally define what data you wish to get using a ``get_xyz()`` function.

View File

@ -1,3 +1,31 @@
"""
Ergast API Python Wrapper
~~~~~~~~~~~~~~~~~~~~~~~~
A comprehensive Python wrapper for the Ergast Formula One API
Basic usage:
>>> import ergast_py
>>> e = ergast_py.Ergast()
>>> e.driver_str("alonso").get_drivers()
[Driver(
driverId=alonso,
permanentNumber=14,
code=ALO,
url=http://en.wikipedia.org/wiki/Fernando_Alonso,
givenName=Fernando,
familyName=Alonso,
dateOfBirth=1981-07-29,
nationality=Spanish)]
Full documentation can be found at https://github.com/Samuel-Roach/ergast-py.
Ergast-py extends the publicly available and free Ergast API. For more information
and a better understanding visit http://ergast.com/mrd/
"""
from ergast_py.models.average_speed import AverageSpeed
from ergast_py.models.constructor_standing import ConstructorStanding
from ergast_py.models.driver import Driver