getAccountByRiotId method

Future<AccountDto> getAccountByRiotId(
  1. RegionRoutingValue region,
  2. RiotId rid
)

Implementation

Future<AccountDto> getAccountByRiotId(
  RegionRoutingValue region,
  RiotId rid,
) async {
  final url =
      'https://${REGION_ROUTING_VALUES[region]}/riot/account/v1/accounts/by-riot-id/${rid.gameName}/${rid.tagLine}';
  final response = await get(url);

  return AccountDto.fromJson(response!.data);
}