A Python wrapper for SteamCharts
Reason this release was yanked:
Wrong README
Project description
SteamCharts
This module makes it possible to get the player count of a game on Steam using the Steamcharts website. It uses aiohttp, BeautifulSoup and http modules.
Installation
pip install SteamPlayerCharts
Example
import asyncio
import SteamPlayerCharts as SteamCharts
async def main():
steamgameID = "4000"
player_count = await SteamCharts.playercount(steamgameID)
print(player_count)
try:
current_players = player_count['Current Players']
day_peak = player_count['Peak Players 24h']
all_time_peak = player_count['Peak Players All Time']
except:
error_code = player_count['error']['code']
error_message = player_count['error']['message']
asyncio.run(main())
The playercount function returns a Python dict containing the current player counts, as well as the peak values for the last 24 hours and all time.
If the query fails, an error dict is returned that contains the HTTP error code and message.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file SteamPlayerCharts-0.2.1-py3-none-any.whl.
File metadata
- Download URL: SteamPlayerCharts-0.2.1-py3-none-any.whl
- Upload date:
- Size: 2.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a4480f92bd3ef6b6dd0e060e826935e2d584c68e29080df0064f4b4406aee40c
|
|
| MD5 |
6476d50ca95fdf47393406b321ad6ae0
|
|
| BLAKE2b-256 |
7cd47602ee79eb829348f27cb3b035d285bd7728b20989637f866e2987bf1695
|