def runes(summoner_ids, api_key=None, region=None, **kwargs): """ Get rune pages mapped by summoner ID for a given list of summoner IDs. https://developer.riotgames.com/api/methods#!/1079/3719 :param summoner_ids: can be both list or string in valid format """ region = get_region(region) ids = to_comma_separated(summoner_ids) url = '{}{}/{}/summoner/{}/runes'.format(api_url, region, version, ids) url = url.format(region) return get_data_from_api(api_key, url, **kwargs)
def by_name(summoner_names, api_key=None, region=None, **kwargs): """ Get summoner objects mapped by standardized summoner name for a given list of summoner names. https://developer.riotgames.com/api/methods#!/1079/3722 :param summoner_names: can be both list or string in valid format """ region = get_region(region) names = to_comma_separated(summoner_names) url = '{}{}/{}/summoner/by-name/{}'.format(api_url, region, version, names) url = url.format(region) return get_data_from_api(api_key, url, **kwargs)
def by_teams(team_ids, api_key=None, region=None, **kwargs): """ Get teams mapped by team ID for a given list of team IDs. https://developer.riotgames.com/api/methods#!/986/3357 :param team_ids: can be both list or string in valid format """ region = get_region(region) ids = to_comma_separated(team_ids) url = '{}{}/{}/team/{}'.format(api_url, region, version, ids) url = url.format(region) return get_data_from_api(api_key, url, **kwargs)
def by_summoners_entry(summoner_ids, api_key=None, region=None, **kwargs): """ Get league entries mapped by summoner ID for a given list of summoner IDs. https://developer.riotgames.com/api/methods#!/985/3356 :param summoner_ids: can be both list or string in valid formats """ region = get_region(region) ids = to_comma_separated(summoner_ids) url = '{}{}/{}/league/by-summoner/{}/entry'.format(api_url, region, version, ids) url = url.format(region) return get_data_from_api(api_key, url, **kwargs)