Skip to content

Get teams

To list the teams that the user has access to use the get_teams method:

from pyholdsport import Holdsport, HoldsportTeam

holdsport = Holdsport(
    holdsport_username="username",
    holdsport_password="password",
)

teams: list[HoldsportTeam] = holdsport.get_teams()
for team in teams:
    print(team)

Learn more about the HoldsportTeam object.