Fork of Soblow's fork of Bhumbledler, tool to manage bundles from HumbleBundle https://git.bismuth.it/Soblow/Bhumbledler/
  • Python 63.2%
  • HTML 27.7%
  • JavaScript 9.1%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-11-17 22:31:56 +01:00
.gitignore add vim files 2026-01-22 00:44:03 +01:00
cookies.py rework the tool with the new humble api, no more scraping 2026-11-17 17:06:46 +01:00
data.sample.py 🔑Add the ability to add extra keys obtained outside of HumbleBundle 2025-05-05 16:10:59 +02:00
LICENSE Add LICENSE 2024-08-09 20:40:27 +02:00
main.js Initial commit. 2019-11-01 15:54:16 +01:00
main.py fix expired date 2026-11-17 22:31:56 +01:00
models.py add expiration date 2026-01-22 00:43:30 +01:00
pdm.lock bump dependencies 2026-01-22 00:44:39 +01:00
pyproject.toml rework the tool with the new humble api, no more scraping 2026-11-17 17:06:46 +01:00
README.md update with the new workflow 2026-11-17 17:17:32 +01:00
template.html filter steam keys with type 2026-11-17 22:30:47 +01:00
utils.py fix API url to convert 2026-01-18 22:03:27 +01:00

Bhumbledler

A set of Python scripts to collect Humble bundle stats about bought games, share a list of unused keys, and ease the process of claiming them.

It outputs a single HTML file holding a "ready-to-use" list, which can be sent to a website hoster along with the provided JavaScript at main.js.

Installation

As described in the pyproject.toml file, this project requires Python 3.12 or above.

pdm (backend version) is used for dependency management.

To install dependencies in a virtual environment, run:

pdm install
$(pdm venv activate)

The last command will activate the matching venv, so that tools like Scrapy can be used from the virtual environment.

Usage

Prerequisites

Several constants must be changed across the project:

  • cookies_secret.py: Replace the SESSION_TOKEN variable content with your actual session token when you visit Humble Bundle's website.
  • data.py: As shown in the sample file, you may specify some already claimed keys in the RESERVED_GAMES dictionary. These are the link for keys claiming that will be output in a file. Ensure the CURRENCY is properly set to expected currency for your country.
  • main.py: At the top of the file, the DB_URL constant should point to a valid Database address. It will be used for data importing (from the JSON collected from Humble Bundle's website) and to make easier queries. If in doubt, you may use the provided sqlite content, which will use a local SQLite database as a file.
  • template.html: This is the actual template used for generating the resulting HTML page with the keys listing. For more infos on how to use the template, refer to Mako documentation

Retrieving the game list

python main.py download

This will output a output.json file with the required informations from your Humble Bundle.

If the download fails, make sure you properly updated the cookies as seen in the Prerequisites section

Importing the game list into the database

# Initialize the database.
# This will wipe all previous imported data.
python main.py init
# Import the data from the `output.json` file into the database
python main.py import output.json

Building the HTML listing page

python main.py gen

The default resulting file is located at /games.html.

Uploading game list to remote server

Copy the game list (located in /games.html) along with the required JavaScript on the remote server.

Claiming keys

Fill the requested keys in the data file, as explained in the prerequisite section.

Then run:

python main.py urls

The default resulting file is located at /codes.txt.

Licence

MIT