#NEWLINE# def get_top_champion_masteries( summoner_id , count = 3 ) : #NEWLINE# #INDENT# "\n    https://developer.riotgames.com/api/methods#!/1034/3540\n\n    Args:\n        summoner_id (int): the summoner ID to get champion masteries for\n        count (int): the maximum number of entires to retrieve (default 3)\n\n    Returns:\n        list<ChampionMastery>: the summoner's top champion masteries\n    " #NEWLINE# region = cassiopeia . type . core . common . Region ( cassiopeia . dto . requests . region ) #NEWLINE# platform = cassiopeia . type . core . common . Platform [ request . name ] #NEWLINE# request = 'https://{server}.api.pvp.net/championmastery/location/{platform}/player/{summonerId}/topchampions' . format ( server = cassiopeia . dto . requests . region , platform = platform . value , summonerId = summoner_id ) #NEWLINE# response = cassiopeia . dto . requests . get ( request , { #NEWLINE# #INDENT# 'count' : count , #NEWLINE# #UNINDENT# } , include_base = False ) #NEWLINE# return [ cassiopeia . type . dto . championmastery . ChampionMastery ( cm ) for cm in response ]