Unofficial valorant client to interact with riot's valorant game api.
MIT License
valorant_client is a library to interact with VALORANT Game API's to fetch user specific data such as matches played, user info, store info etc.
valorant_client
as a dependency on pubspec.yaml
file on your project root. At the time of this writing, the latest package version is 1.1.0. Do check Package Page to get latest version.dependencies:
valorant_client: ^1.1.3
import 'package:valorant_client/valorant_client.dart';
ValorantClient
class.ValorantClient client = ValorantClient(
UserDetails(userName: {'your_username'}, password: {'your_password'}, region: {your_region}),
callback: Callback(
onError: (String error) {
print(error);
},
onRequestError: (DioError error) {
print(error.message);
},
),
);
NOTE: Passing the callback here is optional. However, to know if your request failed internally due to wrong status code etc, you will require the callback.
Boolean
parameter can be set as true if you want to handle re-authorization if session becames invalid.await client.init(true);
NOTE: This is an async function, it authorizes this client to valorant API's. without calling this, you will not get results from the api.
final currentPlayer = await client.playerInterface.getPlayer();
Authorization (RSO authorization flow)
Player Endpoint
Assets Endpoint