This is a Python script that simulates a keypress or runs a function based on the gift received during a TikTok Live broadcast.
To use this script, you'll need to clone this repository to your local machine using the following command:
git clone https://github.com/BainBan/TikTokLive-Gift.git
Method 1: Install the dependencies using pip:
pip install -r requirements.txt
Method 2: Install the dependencies manually:
Python 3 pynput library (can be installed via pip: pip install pynput) requests library (can be installed via pip: pip install requests)
Launch the script by running python script.py in your terminal. Enter the broadcast ID when prompted. Sit back and watch the bot automatically respond to gifts during the broadcast.
You can customize the bot's behavior by editing the gift_dict dictionary in gift_bot.py. This dictionary maps gift IDs to the function or keypress that should be simulated when that gift is received.
Contributions are welcome! If you find a bug or have an idea for a new feature, feel free to submit an issue or a pull request.