Results 1 to 2 of 2

Thread: Python Dota 2 API Wrapper

  1. #1
    Basic Member
    Join Date
    Jan 2016
    Posts
    4

    Python Dota 2 API Wrapper

    So, I've been using the WebAPI for mining games and realized that the response format was severely inconsistent across all the endpoints.
    I made a Python3 wrapper for it, with a rather nitpicky parser and I've attempted to unify the response results across all the endpoints to make its usage as uniform as possible.

    Link to source: https://github.com/whoophee/d2api

    As of now, I've dealt with fairly obvious inconsistencies such as https://wiki.teamfortress.com/wiki/W...s#Tower_Status and https://wiki.teamfortress.com/wiki/W...es#Tower_state, as well as fixing inconsistent naming. I've also added a few QOL functions to relieve the user from manually parsing some stuff.

    One of the more aggravating problem that I had to fix, was that the WebAPI returned json data with repeating keys (see: https://github.com/whoophee/d2api/bl.../livegame.json). The repeating "abilities" key is something inbuilt json parsers miss.

    I feel like the documentation is fairly decent (although it could be more contributor friendly) and was hoping to get feedback/criticism on it.

  2. #2
    Basic Member
    Join Date
    Sep 2015
    Posts
    3
    Thanks for making a Python Wrapper! I was also looking to create one, cant criticize yours since I dont have a lot of experience on doing this kind of things (binds/wrappers). So I will do my own first while learning things and then I might get back to you to give you so I can compare both

    Good work! #LongLivePython

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •