Skip to content

Posts

DeepLinkCreationRequest

deep link creation request model

:ivar player_tags: list of player tags :type player_tags: list[str] :ivar clan_tag: clan tag :type clan_tag: str :ivar opponent_clan_tag: opponent clan tag :type opponent_clan_tag: str

Source code in pyclasher/api/models/misc/posts.py
16
17
18
19
20
21
class DeepLinkCreationRequest:
    def __init__(self, player_tags, clan_tag, opponent_clan_tag):
        self.player_tags = player_tags
        self.clan_tag = clan_tag
        self.opponent_clan_tag = opponent_clan_tag
        return

__init__(player_tags, clan_tag, opponent_clan_tag)

initialisation of the deep link creation request model

:param player_tags: list of player tags :type player_tags: list[str] :param clan_tag: clan tag :type clan_tag: str :param opponent_clan_tag: opponent clan tag :type opponent_clan_tag: str :return: None :rtype: None

Source code in pyclasher/api/models/misc/posts.py
17
18
19
20
21
def __init__(self, player_tags, clan_tag, opponent_clan_tag):
    self.player_tags = player_tags
    self.clan_tag = clan_tag
    self.opponent_clan_tag = opponent_clan_tag
    return

VerifyTokenRequest

verify token request model

Source code in pyclasher/api/models/misc/posts.py
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
class VerifyTokenRequest:
    def __init__(self, token):
        self.token = token
        return

    def to_dict(self):
        return {'token': self.token}

    def __str__(self):
        return f"VerifyTokenRequest({self.token})"

    def __repr__(self):
        return f"VerifyTokenRequest(token={self.token}, dict={self.to_dict()})"

__init__(token)

initialisation of the verify token request model

:return: None :rtype: None

Source code in pyclasher/api/models/misc/posts.py
2
3
4
def __init__(self, token):
    self.token = token
    return

to_dict()

function that returns the dictionary model

:return: the dictionary model :rtype: dict

Source code in pyclasher/api/models/misc/posts.py
6
7
def to_dict(self):
    return {'token': self.token}