Skip to content

Clan war league group

ClanWarLeagueClan

Bases: BaseClan

clan war league clan model

Source code in pyclasher/api/models/clan_war_league_group.py
38
39
40
41
42
43
44
45
46
47
48
49
class ClanWarLeagueClan(BaseClan):
    def __init__(self, data):
        super().__init__(data)
        return

    @property
    def clan_level(self):
        return self._get_data('clanLevel')

    @property
    def members(self):
        return ClanWarLeagueClanMemberList(self._get_data('members'))

clan_level: int property

clan level

:return: the clan level :rtype: int

members: ClanWarLeagueClanMemberList property

clan members

:return: the list of clan members :rtype: ClanWarLeagueClanMemberList

ClanWarLeagueClanList

Bases: IterBaseModel

clan war league clan list model

can be iterated over

Source code in pyclasher/api/models/clan_war_league_group.py
52
53
54
55
56
57
58
59
class ClanWarLeagueClanList(IterBaseModel):
    _iter_rtype = ClanWarLeagueClan

    def __getitem__(self, item):
        return super().__getitem__(item)

    def __next__(self):
        return super().__next__()

ClanWarLeagueClanMember

Bases: BaseClanMember

clan war league clan member model

Source code in pyclasher/api/models/clan_war_league_group.py
22
23
24
25
class ClanWarLeagueClanMember(BaseClanMember):
    @property
    def townhall_level(self):
        return self._get_data('townhallLevel')

townhall_level: int property

town hall level of the player

:return: the player's town hall level :rtype: int

ClanWarLeagueClanMemberList

Bases: IterBaseModel

clan war league clan member list model

can be iterated over

Source code in pyclasher/api/models/clan_war_league_group.py
28
29
30
31
32
33
34
35
class ClanWarLeagueClanMemberList(IterBaseModel):
    _iter_rtype = ClanWarLeagueClanMember

    def __getitem__(self, item: int):
        return super().__getitem__(item)

    def __next__(self):
        return super().__next__()

ClanWarLeagueGroup

Bases: BaseModel

clan war league group model

Source code in pyclasher/api/models/clan_war_league_group.py
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
class ClanWarLeagueGroup(BaseModel):
    def __init__(self, data):
        super().__init__(data)
        return

    @property
    def tag(self):
        return self._get_data('tag')

    @property
    def state(self):
        return ClanWarLeagueGroupState(self._get_data('state'))

    @property
    def season(self):
        return self._get_data('season')

    @property
    def clans(self):
        return ClanWarLeagueClanList(self._get_data('clans'))

    @property
    def rounds(self):
        return ClanWarLeagueRoundList(self._get_data('rounds'))

clans: ClanWarLeagueClanList property

group clans

:return: the list of group clans :rtype: ClanWarLeagueClanList

rounds: ClanWarLeagueRoundList property

group rounds

:return: the list of group rounds :rtype: ClanWarLeagueRoundList

season: str property

clan war league season

:return: the clan war league season :rtype: str

state: ClanWarLeagueGroupState property

group state

:return: the group state :rtype: ClanWarLeagueGroupState

tag: str property

group tag

:return: the group tag :rtype: str

ClanWarLeagueRound

Bases: BaseModel

clan war league round model

Source code in pyclasher/api/models/clan_war_league_group.py
6
7
8
9
class ClanWarLeagueRound(BaseModel):
    @property
    def war_tags(self):
        return self._get_data('warTags')

war_tags: list[str] property

war tags of the CWL round

:return: the list of war tags :rtype: list[str]

ClanWarLeagueRoundList

Bases: IterBaseModel

clan war league round list model

can be iterated over

Source code in pyclasher/api/models/clan_war_league_group.py
12
13
14
15
16
17
18
19
class ClanWarLeagueRoundList(IterBaseModel):
    _iter_rtype = ClanWarLeagueRound

    def __getitem__(self, item: int):
        return super().__getitem__(item)

    def __next__(self):
        return super().__next__()