diff --git a/README.md b/README.md index b840b75..358dae7 100644 --- a/README.md +++ b/README.md @@ -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. diff --git a/ergast_py/__init__.py b/ergast_py/__init__.py index 37ade4a..2660a9c 100644 --- a/ergast_py/__init__.py +++ b/ergast_py/__init__.py @@ -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