Skip to main content

A python package to download CSGO Demo Files from Match Share Code

Project description

CSGO-DemoURL

The easy way to develop your next CSGO Project

GitHub issues Build Status Version

Simply get demo file URL of a CSGO Match (which happens to be the toughest part, for some!)

Tech

This projects uses a number of open source projects to work properly:

  • Steam - ValvePython/Steam
  • CSGO - ValvePython/CSGO
  • Gevent - gevent is a coroutine -based Python networking library that uses greenlet to provide a high-level synchronous API on top of the libev or libuv event loop.

And of course this project itself is open source with a public repository on GitHub.

Installation

This project requires Python >3.0 to run.

git clone https://github.com/botent/CSGO-DemoURL.git

or

pip install csgo-demourl

Usage

  1. Initialize the SteamWorker() instance from core.py
  2. Get SteamAuthenticator Code from authenticatorCode(secrets=PATH_TO_SECRETS.JSON FILE) method
  3. Login using pr_login(uname=USERNAME, pword=PASSWORD, code=STEAM_AUTHENTICATOR_CODE) method
  4. Now it is optional but advised to define a function to return Match Demo File URL as ---
def matchInfo():
    matchinfo = worker.getSharecodeInfo(matchcode=MATCH_SHARE_CODE)
    matchid = matchinfo['matchid']
    outcomeid = matchinfo['outcomeid']
    token = matchinfo['token']

    info = worker.getMatchInfo(matchid=matchid, outcomeid=outcomeid, token=token)
    result = json.loads(MessageToJson(info))['matches'][0]['roundstatsall'][23]['map']
    worker.close() # Optional (to logout and disconnect from Steam Account)
    return result
    
resp = matchInfo() # This gives you the demo URL

License

MIT

Free Software, Hell Yeah!

Project details


Release history Release notifications | RSS feed

This version

1.11

Download files

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

Source Distribution

CSGO-DemoURL-1.11.tar.gz (3.0 kB view hashes)

Uploaded Source

Built Distribution

CSGO_DemoURL-1.11-py3-none-any.whl (3.1 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