Skip to main content

A Python wrapper which is capable of fetching information relating to Valorant utilizing local authorization

Project description

Python Valorant Wrapper

A Valorant wrapper written in Python, built to be used on a local machine

Weekly download count Total download count

Installation

pip install valorant-wrapper

Usage

Documentation is coming soon, but here is a quickstart guide for those getting started:

from valorant.session import Session

# Before beginning, make sure that the Riot Client is open
# This will not work otherwise

session = Session() # get session
local_account = session.get_local_account() # get the local account
rank = local_account.get_rank() # get our local account's rank

# print the name of the local account and its rank
print("[Rank]", local_account.get_name(), rank.to_string())

# get the local account's friends, then print all their names
friends = local_account.get_friends()
print("[Friends]", friends.get_names())

# get the active match (does not include pregame), and print all player names
current_game = local_account.get_current_game()

# check to see if the player is in a game
if current_game is None: print("[Game] Not in a game")
else: print("[Game]", current_game.players.get_names())

# get the current party and print the raw information (not yet complete)
party = local_account.get_party()

# check to see if the player is in a party
if party is None: print("[Party] Not in a party")
else: print("[Party]", party.get_information_raw())

# get the storefront and print the first item's cost
storefront = session.store.get_storefront()
print("[Store]", storefront.daily_shop[0].cost)

Resources used

Legal

This project is not affiliated with Riot Games or any of its employees and therefore does not reflect the views of said parties.

Riot Games does not endorse or sponsor this project. Riot Games, and all associated properties are trademarks or registered trademarks of Riot Games, Inc.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

valorant_wrapper-0.1.0.tar.gz (34.0 kB view hashes)

Uploaded Source

Built Distribution

valorant_wrapper-0.1.0-py3-none-any.whl (41.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page