Versioning changes for Blizzard WoW Game Data APIs
https://develop.battle.net/documentation/world-of-warcraft/game-data-apis
Sergio Álvarez
4de6824f86
Traceback (most recent call last): File "updater.py", line 183, in <module> updater.iterate_links(force_groups) File "updater.py", line 167, in iterate_links self.save_raw(real_path, response, inset=api['path']) File "updater.py", line 86, in save_raw json.dump(raw.json(), tmp, indent=2) File "/usr/lib/python3/dist-packages/requests/models.py", line 898, in json return complexjson.loads(self.text, **kwargs) File "/usr/lib/python3/dist-packages/simplejson/__init__.py", line 525, in loads return _default_decoder.decode(s) File "/usr/lib/python3/dist-packages/simplejson/decoder.py", line 370, in decode obj, end = self.raw_decode(s) File "/usr/lib/python3/dist-packages/simplejson/decoder.py", line 400, in raw_decode return self.scan_once(s, idx=_w(s, idx).end()) simplejson.errors.JSONDecodeError: Expecting value: line 1 column 1 (char 0) real 40m42,726s user 1m17,962s sys 0m6,509s |
||
---|---|---|
raw | ||
.gitignore | ||
README.md | ||
blizzard.py | ||
config.py | ||
cron.sh | ||
spec.py | ||
test-modified.py | ||
updater.py |
README.md
Create a .credentials
file with client_id:secret
from https://develop.battle.net/access
With no crontab execute python3 updater.py
.
Crontab, every day at 12:30h:
30 12 * * * cron.sh
Only US
region is explored because all API are the same and this is the default API for Blizzard.
Without locale
we get all the translations, so I don't iterate through locales. If you ask for a locale, you get the value right in the field.