updates to use pyteamsnap module
This commit is contained in:
@@ -108,7 +108,8 @@ An unoffical python wrapper for the [TeamSnap API](https://www.teamsnap.com/docu
|
||||
## Usage Example
|
||||
|
||||
```python
|
||||
from pyteamsnap.api import TeamSnap, Me, Event, EventLineupEntry, Member
|
||||
from pyteamsnap.client import TeamSnap
|
||||
from pyteamsnap.objects import Me, Event, EventLineupEntry, Member
|
||||
client = TeamSnap(token=TOKEN)
|
||||
|
||||
# get authenticated user
|
||||
@@ -121,7 +122,7 @@ managed_team_ids = me.data['managed_teams']
|
||||
managed_team_id = me.data['managed_teams'][0]
|
||||
events = Event.search(client, team_id=managed_team_id)
|
||||
|
||||
# get an object with the object id of EVENT_ID
|
||||
# get an object with the object id of EVENT_ID
|
||||
event = Event.get(client, id=EVENT_ID)
|
||||
|
||||
# get some information about the event
|
||||
@@ -143,7 +144,7 @@ member.delete()
|
||||
# perform a bulk load
|
||||
list_of_ts_objects = client.bulk_load(team_id = TEAM_ID, types = [Event, Member], event__id=EVENT_ID)
|
||||
```
|
||||
|
||||
|
||||
|
||||
<p style="text-align:right;">(<a href="#top">back to top</a>)</p>
|
||||
|
||||
@@ -236,4 +237,4 @@ Project Link: [https://github.com/anthonyscorrea/pyteamsnap](https://github.com/
|
||||
[license-url]: https://github.com/anthonyscorrea/pyteamsnap/blob/master/LICENSE.txt
|
||||
[linkedin-shield]: https://img.shields.io/badge/-LinkedIn-black.svg?style=for-the-badge&logo=linkedin&colorB=555
|
||||
[linkedin-url]: https://linkedin.com/in/anthonyscorrea
|
||||
[product-screenshot]: images/screenshot.png
|
||||
[product-screenshot]: images/screenshot.png
|
||||
|
||||
Reference in New Issue
Block a user