A Python wrapper for the csfloat API
Project description
csfloat.py
An API wrapper for the CSFloat API written in Python.
Installing
Python 3.10 or higher is required
To install the library, you can just run the following command:
# Linux/macOS
$ python3 -m pip install -U csfloat.py
# Windows
> py -3 -m pip install -U csfloat.py
To install the development version, do the following:
$ git clone https://github.com/PaxxPatriot/csfloat.py.git
$ cd csfloat.py
$ python3 -m pip install -U .
Quick Example
import asyncio
import csfloat
async def main():
client = csfloat.Client()
# Set your personal API key, which you can get from https://csfloat.com/profile -> Developers -> + New Key
client.set_api_key(api_key="YOUR API KEY HERE")
# Get all listed CS2 items on csfloat.com and print the name to the console
listings = await client.fetch_all_listings()
async for listing in listings:
print(listing.item.name)
if __name__ == "__main__":
asyncio.run(main())
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 Distribution
csfloat_py-0.0.1.tar.gz
(11.0 kB
view hashes)
Built Distribution
csfloat.py-0.0.1-py3-none-any.whl
(17.4 kB
view hashes)
Close
Hashes for csfloat.py-0.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1594c44cc2334baefdff64f1b8a822615d00cf82404f51b8f5b2d5841a84fcb2 |
|
MD5 | dd9dd1b9e0ec0e8936e3ef50f0bde579 |
|
BLAKE2b-256 | 61dbc71f24e3840910dbcd3c8078b4824bd1e390669ae6e8a6f0a144b9173f8f |