36 KiB
Twitch Drops Miner
Automated Twitch Drops farming bot - Focus on collecting drops efficiently
🔗 https://gitea.majjoduran.app/majjo/Twitch-Drops-Miner
Forked From: Twitch-Channel-Points-Miner-v2 by rdavydov
Original Credits:
- Main idea: https://github.com/gottagofaster236/Twitch-Channel-Points-Miner
- Based on: https://github.com/Tkd-Alex/Twitch-Channel-Points-Miner-v2
This fork focuses on Twitch Drops farming - automatically watches streams to collect drops efficiently.
Read more about Twitch Drops here.
README Contents
- 🤝 Community
- 🚀 Main differences from the original repository
- 🧾 Logs feature
- 🧐 How to use
- 🔧 Settings
- 🍪 Migrating from an old repository (the original one)
- 🪟 Windows
- 📱 Termux
- ⚠️ Disclaimer
Community
If you want to help with this project, please leave a star 🌟 and share it with your friends! 😎
If you have any issues or want to contribute, feel free to open an issue or pull request on the Gitea repository.
Support the Original Authors: If you appreciate the original work this project is based on, consider supporting rdavydov's original project.
Main differences from the original repository:
- Improved logging: emojis, colors, files and much more ✔️
- Final report with all the data ✔️
- Rewritten codebase now uses classes instead of modules with global variables ✔️
- Automatic downloading of the list of followers and using it as an input ✔️
- Better 'Watch Streak' strategy in the priority system #11 ✔️
- Auto claiming game drops from the Twitch inventory #21 ✔️
- Switchable analytics chart that shows the progress of your points with various annotations #96 ✔️
- Joining the IRC Chat to increase the watch time and get StreamElements points #47 ✔️
- Moments claiming #182 ✔️
- Notifying on
@nicknamemention in the Twitch chat #227 ✔️
Logs feature
Full logs
%d/%m/%y %H:%M:%S - INFO - [run]: 💣 Start session: '9eb934b0-1684-4a62-b3e2-ba097bd67d35'
%d/%m/%y %H:%M:%S - INFO - [run]: 🤓 Loading data for x streamers. Please wait ...
%d/%m/%y %H:%M:%S - INFO - [set_offline]: 😴 Streamer(username=streamer-username1, channel_id=0000000, channel_points=67247) is Offline!
%d/%m/%y %H:%M:%S - INFO - [set_offline]: 😴 Streamer(username=streamer-username2, channel_id=0000000, channel_points=4240) is Offline!
%d/%m/%y %H:%M:%S - INFO - [set_offline]: 😴 Streamer(username=streamer-username3, channel_id=0000000, channel_points=61365) is Offline!
%d/%m/%y %H:%M:%S - INFO - [set_offline]: 😴 Streamer(username=streamer-username4, channel_id=0000000, channel_points=3760) is Offline!
%d/%m/%y %H:%M:%S - INFO - [set_online]: 🥳 Streamer(username=streamer-username, channel_id=0000000, channel_points=61365) is Online!
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +12 → Streamer(username=streamer-username, channel_id=0000000, channel_points=61377) - Reason: WATCH.
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +12 → Streamer(username=streamer-username, channel_id=0000000, channel_points=61389) - Reason: WATCH.
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +12 → Streamer(username=streamer-username, channel_id=0000000, channel_points=61401) - Reason: WATCH.
%d/%m/%y %H:%M:%S - INFO - [claim_bonus]: 🎁 Claiming the bonus for Streamer(username=streamer-username, channel_id=0000000, channel_points=64230)!
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +60 → Streamer(username=streamer-username, channel_id=0000000, channel_points=64290) - Reason: CLAIM.
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +12 → Streamer(username=streamer-username, channel_id=0000000, channel_points=64326) - Reason: WATCH.
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +400 → Streamer(username=streamer-username, channel_id=0000000, channel_points=64326) - Reason: WATCH_STREAK.
%d/%m/%y %H:%M:%S - INFO - [claim_bonus]: 🎁 Claiming the bonus for Streamer(username=streamer-username, channel_id=0000000, channel_points=64326)!
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +60 → Streamer(username=streamer-username, channel_id=0000000, channel_points=64386) - Reason: CLAIM.
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +12 → Streamer(username=streamer-username, channel_id=0000000, channel_points=64398) - Reason: WATCH.
%d/%m/%y %H:%M:%S - INFO - [update_raid]: 🎭 Joining raid from Streamer(username=streamer-username, channel_id=0000000, channel_points=64398) to another-username!
%d/%m/%y %H:%M:%S - INFO - [on_message]: 🚀 +250 → Streamer(username=streamer-username, channel_id=0000000, channel_points=6845) - Reason: RAID.
Less logs
%d/%m %H:%M:%S - 💣 Start session: '9eb934b0-1684-4a62-b3e2-ba097bd67d35'
%d/%m %H:%M:%S - 🤓 Loading data for 13 streamers. Please wait ...
%d/%m %H:%M:%S - 😴 streamer-username1 (xxx points) is Offline!
%d/%m %H:%M:%S - 😴 streamer-username2 (xxx points) is Offline!
%d/%m %H:%M:%S - 😴 streamer-username3 (xxx points) is Offline!
%d/%m %H:%M:%S - 😴 streamer-username4 (xxx points) is Offline!
%d/%m %H:%M:%S - 🥳 streamer-username (xxx points) is Online!
%d/%m %H:%M:%S - +12 → streamer-username (xxx points) - Reason: WATCH.
%d/%m %H:%M:%S - 🚀 +12 → streamer-username (xxx points) - Reason: WATCH.
%d/%m %H:%M:%S - 🚀 +60 → streamer-username (xxx points) - Reason: CLAIM.
%d/%m %H:%M:%S - 🚀 +12 → streamer-username (xxx points) - Reason: WATCH.
%d/%m %H:%M:%S - 🚀 +400 → streamer-username (xxx points) - Reason: WATCH_STREAK.
%d/%m %H:%M:%S - 🚀 +60 → streamer-username (xxx points) - Reason: CLAIM.
%d/%m %H:%M:%S - 🚀 +12 → streamer-username (xxx points) - Reason: WATCH.
%d/%m %H:%M:%S - 🎭 Joining raid from streamer-username (xxx points) to another-username!
%d/%m %H:%M:%S - 🚀 +250 → streamer-username (xxx points) - Reason: RAID.
Final report:
%d/%m/%y %H:%M:%S - 🛑 End session 'f738d438-cdbc-4cd5-90c4-1517576f1299'
%d/%m/%y %H:%M:%S - 📄 Logs file: /.../path/Twitch-Channel-Points-Miner-v2/logs/username.timestamp.log
%d/%m/%y %H:%M:%S - ⌛ Duration 10:29:19.547371
%d/%m/%y %H:%M:%S - 🤖 Streamer(username=streamer-username, channel_id=0000000, channel_points=67247), Total points gained (after farming - before farming): 1243
%d/%m/%y %H:%M:%S - 💰 CLAIM(11 times, 550 gained), WATCH(35 times, 350 gained)
%d/%m/%y %H:%M:%S - 🤖 Streamer(username=streamer-username2, channel_id=0000000, channel_points=61365), Total points gained (after farming - before farming): 977
%d/%m/%y %H:%M:%S - 💰 CLAIM(4 times, 240 gained), REFUND(1 times, 605 gained), WATCH(11 times, 132 gained)
%d/%m/%y %H:%M:%S - 🤖 Streamer(username=streamer-username5, channel_id=0000000, channel_points=25960), Total points gained (after farming - before farming): 1680
%d/%m/%y %H:%M:%S - 💰 CLAIM(17 times, 850 gained), WATCH(53 times, 530 gained)
%d/%m/%y %H:%M:%S - 🤖 Streamer(username=streamer-username6, channel_id=0000000, channel_points=9430), Total points gained (after farming - before farming): 1120
%d/%m/%y %H:%M:%S - 💰 CLAIM(14 times, 700 gained), WATCH(42 times, 420 gained), WATCH_STREAK(1 times, 450 gained)
How to use:
First of all please create a run.py file. You can just copy example.py and modify it according to your needs.
# -*- coding: utf-8 -*-
import logging
from colorama import Fore
from TwitchChannelPointsMiner import TwitchChannelPointsMiner
from TwitchChannelPointsMiner.logger import LoggerSettings, ColorPalette
from TwitchChannelPointsMiner.classes.Chat import ChatPresence
from TwitchChannelPointsMiner.classes.Discord import Discord
from TwitchChannelPointsMiner.classes.Webhook import Webhook
from TwitchChannelPointsMiner.classes.Telegram import Telegram
from TwitchChannelPointsMiner.classes.Gotify import Gotify
from TwitchChannelPointsMiner.classes.Settings import Priority, Events, FollowersOrder
from TwitchChannelPointsMiner.classes.entities.Streamer import Streamer, StreamerSettings
twitch_miner = TwitchChannelPointsMiner(
username="your-twitch-username",
password="write-your-secure-psw", # If no password will be provided, the script will ask interactively
claim_drops_startup=False, # If you want to auto claim all drops from Twitch inventory on the startup
priority=[ # Custom priority in this case for example:
Priority.STREAK, # - We want first of all to catch all watch streak from all streamers
Priority.DROPS, # - When we don't have anymore watch streak to catch, wait until all drops are collected over the streamers
Priority.ORDER # - When we have all of the drops claimed and no watch-streak available, use the order priority (POINTS_ASCENDING, POINTS_DESCENDING)
],
enable_analytics=False, # Disables Analytics if False. Disabling it significantly reduces memory consumption
disable_ssl_cert_verification=False, # Set to True at your own risk and only to fix SSL: CERTIFICATE_VERIFY_FAILED error
disable_at_in_nickname=False, # Set to True if you want to check for your nickname mentions in the chat even without @ sign
logger_settings=LoggerSettings(
save=True, # If you want to save logs in a file (suggested)
console_level=logging.INFO, # Level of logs - use logging.DEBUG for more info
console_username=False, # Adds a username to every console log line if True. Also adds it to Telegram, Discord, etc. Useful when you have several accounts
auto_clear=True, # Create a file rotation handler with interval = 1D and backupCount = 7 if True (default)
time_zone="", # Set a specific time zone for console and file loggers. Use tz database names. Example: "America/Denver"
file_level=logging.DEBUG, # Level of logs - If you think the log file it's too big, use logging.INFO
emoji=True, # On Windows, we have a problem printing emoji. Set to false if you have a problem
less=False, # If you think that the logs are too verbose, set this to True
colored=True, # If you want to print colored text
color_palette=ColorPalette( # You can also create a custom palette color (for the common message).
STREAMER_online="GREEN", # Don't worry about lower/upper case. The script will parse all the values.
streamer_offline="red", # Read more in README.md
BET_wiN=Fore.MAGENTA # Color allowed are: [BLACK, RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE, RESET].
),
telegram=Telegram( # You can omit or set to None if you don't want to receive updates on Telegram
chat_id=123456789, # Chat ID to send messages @getmyid_bot
token="123456789:shfuihreuifheuifheuifhiu34578347", # Telegram API token @BotFather
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.CHAT_MENTION], # Only these events will be sent to the chat
disable_notification=True, # Revoke the notification (sound/vibration)
),
discord=Discord(
webhook_api="https://discord.com/api/webhooks/0123456789/0a1B2c3D4e5F6g7H8i9J", # Discord Webhook URL
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.CHAT_MENTION], # Only these events will be sent to the chat
),
webhook=Webhook(
endpoint="https://example.com/webhook", # Webhook URL
method="GET", # GET or POST
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.CHAT_MENTION], # Only these events will be sent to the endpoint
),
matrix=Matrix(
username="twitch_miner", # Matrix username (without homeserver)
password="...", # Matrix password
homeserver="matrix.org", # Matrix homeserver
room_id="...", # Room ID
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE], # Only these events will be sent
),
pushover=Pushover(
userkey="YOUR-ACCOUNT-TOKEN", # Login to https://pushover.net/, the user token is on the main page
token="YOUR-APPLICATION-TOKEN", # Create a application on the website, and use the token shown in your application
priority=0, # Read more about priority here: https://pushover.net/api#priority
sound="pushover", # A list of sounds can be found here: https://pushover.net/api#sounds
events=[Events.CHAT_MENTION, Events.DROP_CLAIM], # Only these events will be sent
),
gotify=Gotify(
endpoint="https://example.com/message?token=TOKEN",
priority=8,
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.CHAT_MENTION],
)
),
streamer_settings=StreamerSettings(
follow_raid=True, # Follow raid to obtain more points
claim_drops=True, # We can't filter rewards base on stream. Set to False for skip viewing counter increase and you will never obtain a drop reward from this script. Issue #21
claim_moments=True, # If set to True, https://help.twitch.tv/s/article/moments will be claimed when available
watch_streak=True, # If a streamer go online change the priority of streamers array and catch the watch screak. Issue #11
community_goals=False, # If True, contributes the max channel points per stream to the streamers' community challenge goals
chat=ChatPresence.ONLINE, # Join irc chat to increase watch-time [ALWAYS, NEVER, ONLINE, OFFLINE]
)
)
# You can customize the settings for each streamer. If not settings were provided, the script would use the streamer_settings from TwitchChannelPointsMiner.
# If no streamer_settings are provided in TwitchChannelPointsMiner the script will use default settings.
# The streamers array can be a String -> username or Streamer instance.
# The settings priority are: settings in mine function, settings in TwitchChannelPointsMiner instance, default settings.
# For example, if in the mine function you don't provide any value but you have set it on TwitchChannelPointsMiner instance, the script will take the value from here.
# If you haven't set any value even in the instance the default one will be used
#twitch_miner.analytics(host="127.0.0.1", port=5000, refresh=5, days_ago=7) # Start the Analytics web-server (replit: host="0.0.0.0")
twitch_miner.mine(
[
Streamer("streamer-username01", settings=StreamerSettings(follow_raid=False , claim_drops=True , watch_streak=True , community_goals=False )),
Streamer("streamer-username02", settings=StreamerSettings(follow_raid=True , claim_drops=False )),
Streamer("streamer-username03", settings=StreamerSettings(follow_raid=False , watch_streak=True , community_goals=True )),
Streamer("streamer-username04", settings=StreamerSettings(follow_raid=True , watch_streak=True )),
Streamer("streamer-username05", settings=StreamerSettings(follow_raid=True , claim_drops=True , watch_streak=True , community_goals=True )),
Streamer("streamer-username06"),
Streamer("streamer-username07"),
Streamer("streamer-username08"),
"streamer-username09",
"streamer-username10",
"streamer-username11"
], # Array of streamers (order = priority)
followers=False, # Automatic download the list of your followers
followers_order=FollowersOrder.ASC # Sort the followers list by follow date. ASC or DESC
)
You can also use all the default values except for your username obv. Short version:
from TwitchChannelPointsMiner import TwitchChannelPointsMiner
from TwitchChannelPointsMiner.classes.Settings import FollowersOrder
twitch_miner = TwitchChannelPointsMiner("your-twitch-username")
twitch_miner.mine(["streamer1", "streamer2"]) # Array of streamers OR
twitch_miner.mine(followers=True, followers_order=FollowersOrder.ASC) # Automatic use the followers list OR
twitch_miner.mine(["streamer1", "streamer2"], followers=True, followers_order=FollowersOrder.DESC) # Mixed
If you follow so many streamers on Twitch, but you don't want to mine points for all of them, you can blacklist the users with the blacklist keyword. #94
from TwitchChannelPointsMiner import TwitchChannelPointsMiner
twitch_miner = TwitchChannelPointsMiner("your-twitch-username")
twitch_miner.mine(followers=True, blacklist=["user1", "user2"]) # Blacklist example
By cloning the repository
- Clone this repository
git clone https://gitea.majjoduran.app/majjo/Twitch-Drops-Miner.git - Install all the requirements
pip install -r requirements.txt. If you have problems with requirements, make sure to have at least Python3.6. You could also try to create a virtualenv and then install all the requirements
pip install virtualenv
virtualenv -p python3 venv
source venv/bin/activate
pip install -r requirements.txt
Start mining! python run.py 🥳
Docker
Docker Hub
Official Docker images are on https://hub.docker.com/r/rdavidoff/twitch-channel-points-miner-v2 for linux/amd64, linux/arm64 and linux/arm/v7.
The following file is mounted :
- run.py : this is your starter script with your configuration
These folders are mounted :
- analytics : to save the analytics data
- cookies : to provide login information
- logs : to keep logs outside of container
Example using docker-compose:
version: "3.9"
services:
miner:
image: rdavidoff/twitch-channel-points-miner-v2
stdin_open: true
tty: true
environment:
- TERM=xterm-256color
volumes:
- ./analytics:/usr/src/app/analytics
- ./cookies:/usr/src/app/cookies
- ./logs:/usr/src/app/logs
- ./run.py:/usr/src/app/run.py:ro
ports:
- "5000:5000"
Example with docker run:
docker run \
-v $(pwd)/analytics:/usr/src/app/analytics \
-v $(pwd)/cookies:/usr/src/app/cookies \
-v $(pwd)/logs:/usr/src/app/logs \
-v $(pwd)/run.py:/usr/src/app/run.py:ro \
-p 5000:5000 \
rdavidoff/twitch-channel-points-miner-v2
$(pwd) Could not work on Windows (cmd), please use the absolute path instead, like: /path/of/your/cookies:/usr/src/app/cookies.
The correct solution for Windows lies in the correct command line: docker run -v C:\Absolute\Path\To\Twitch-Channel-Points-Miner-v2\run.py:/usr/src/app/run.py:ro rdavidoff/twitch-channel-points-miner-v2.
run.py MUST be mounted as a volume (-v).
If you don't mount the volume for the analytics (or cookies or logs) folder, the folder will be automatically created on the Docker container, and you will lose all the data when it is stopped.
If you don't have a cookie or it's your first time running the script, you will need to login to Twitch and start the container with -it args. If you need to run multiple containers you can bind different ports (only if you need also the analytics) and mount dirrent run.py file, like
docker run --name user1 -v $(pwd)/user1.py:/usr/src/app/run.py:ro -p 5001:5000 rdavidoff/twitch-channel-points-miner-v2
docker run --name user2 -v $(pwd)/user2.py:/usr/src/app/run.py:ro -p 5002:5000 rdavidoff/twitch-channel-points-miner-v2
Portainer
Link to the illustrated guide on how to deploy a Docker container in Portainer.
Limits
Twitch has a limit - you can't watch more than two channels at one time. We take the first two streamers from the list as they have the highest priority.
Make sure to write the streamers array in order of priority from left to right. If you use followers=True you can choose to download the followers sorted by follow date (ASC or DESC).
Settings
Most of the settings are self-explained and are commented on in the example.
You can watch only two streamers per time. With priority settings, you can select which streamers watch by use priority. You can use an array of priority or single item. I suggest using at least one priority from ORDER, POINTS_ASCENDING, POINTS_DESCENDING because, for example, If you set only STREAK after catch all watch streak, the script will stop to watch streamers.
Available values are the following:
STREAK- Catch the watch streak from all streamersDROPS- Claim all drops from streamers with drops tags enabledSUBSCRIBED- Prioritize streamers you're subscribed to (higher subscription tiers are mined first)ORDER- Following the order of the listPOINTS_ASCENDING- On top the streamers with the lowest pointsPOINTS_DESCENDING- On top the streamers with the highest points
You can combine all priority but keep in mind that use ORDER and POINTS_ASCENDING in the same settings doesn't make sense.
LoggerSettings
| Key | Type | Default | Description |
|---|---|---|---|
save |
bool | True | If you want to save logs in file (suggested) |
less |
bool | False | Reduce the logging format and message verbosity #10 |
console_level |
level | logging.INFO | Level of logs in terminal - Use logging.DEBUG for more helpful messages. |
console_username |
bool | False | Adds a username to every log line in the console if True. #602 |
time_zone |
str | None | Set a specific time zone for console and file loggers. Use tz database names. Example: "America/Denver" https://github.com/rdavydov/Twitch-Channel-Points-Miner-v2/issues/205 |
file_level |
level | logging.DEBUG | Level of logs in file save - If you think the log file it's too big, use logging.INFO |
emoji |
bool | For Windows is False else True | On Windows, we have a problem printing emoji. Set to false if you have a problem |
colored |
bool | True | If you want to print colored text #45 #82 |
auto_clear |
bool | True | Create a file rotation handler with interval = 1D and backupCount = 7 #215 |
color_palette |
ColorPalette | All messages are Fore.RESET except WIN and LOSE bet (GREEN and RED) | Create your custom color palette. Read more above. |
telegram |
Telegram | None | (Optional) Receive Telegram updates for multiple events list #233 |
discord |
Discord | None | (Optional) Receive Discord updates for multiple events list #320 |
Color Palette
Now you can customize the color of the terminal message. We have created a default ColorPalette that provide all the message with DEFAULT (RESET) color and the BET_WIN and BET_LOSE message GREEN and RED respectively. You can change the colors of all Events enum class. The colors allowed are all the Fore color from Colorama: BLACK, RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE, RESET.
The script was developed to handle all the human error, lower-case upper case and more, but I want to suggest using the following code-style
from colorama import Fore
ColorPalette(
STREAMER_ONLINE = Fore.GREEN,
STREAMER_OFFLINE = Fore.RED,
GAIN_FOR_RAID = Fore.YELLOW,
GAIN_FOR_CLAIM = Fore.YELLOW,
GAIN_FOR_WATCH = Fore.YELLOW,
GAIN_FOR_WATCH_STREAK = Fore.YELLOW,
)
Telegram
If you want to receive logs update on Telegram, initiate a new Telegram class, else omit this parameter or set as None.
- Create a bot with @BotFather
- Get you
chat_idwith @getmyid_bot
| Key | Type | Default | Description |
|---|---|---|---|
chat_id |
int | Chat ID to send messages @getmyid_bot | |
token |
string | Telegram API token @BotFather | |
events |
list | Only these events will be sent to the chat. Array of Event. or str | |
disable_notification |
bool | false | Revoke the notification (sound/vibration) |
Telegram(
chat_id=123456789,
token="123456789:shfuihreuifheuifhiu34578347",
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.CHAT_MENTION],
disable_notification=True,
)
Discord
If you want to receive log updates on Discord initialize a new Discord class, else leave omit this parameter or set it as None YT Video
- Go to the Server you want to receive updates
- Click "Edit Channel"
- Click "Integrations"
- Click "Webhooks"
- Click "New Webhook"
- Name it if you want
- Click on "Copy Webhook URL"
| Key | Type | Default | Description |
|---|---|---|---|
webhook_api |
string | Discord webhook URL | |
events |
list | Only these events will be sent to the chat. Array of Event. or str |
Discord(
webhook_api="https://discord.com/api/webhooks/0123456789/0a1B2c3D4e5F6g7H8i9J",
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.CHAT_MENTION],
)
Generic Webhook
You can use generic webhook
| Key | Type | Default | Description |
|---|---|---|---|
endpoint |
string | webhook url | |
method |
string | POST or GET |
|
events |
list | Only these events will be sent to the endpoint. Array of Event. or str |
Webhook(
endpoint="https://example.com/webhook",
method="GET",
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.CHAT_MENTION],
)
Events
STREAMER_ONLINESTREAMER_OFFLINEGAIN_FOR_RAIDGAIN_FOR_CLAIMGAIN_FOR_WATCHBONUS_CLAIMMOMENT_CLAIMJOIN_RAIDDROP_CLAIMDROP_STATUSCHAT_MENTION
StreamerSettings
| Key | Type | Default | Description |
|---|---|---|---|
follow_raid |
bool | True | Choose if you want to follow raid +250 points |
claim_drops |
bool | True | If this value is True, the script will increase the watch-time for the current game. With this, you can claim the drops from Twitch Inventory #21 |
claim_moments |
bool | True | If set to True, moments will be claimed when available |
watch_streak |
bool | True | Choose if you want to change a priority for these streamers and try to catch the Watch Streak event #11 |
community_goals |
bool | False | If True, contributes the max channel points per stream to the streamers' community challenge goals |
chat |
ChatPresence | ONLINE | Join IRC-Chat to appear online in chat and attempt to get StreamElements channel points and increase view-time #47 |
Allowed values for chat are:
ALWAYSJoin in IRC chat and never leaveNEVERNever join IRC chatONLINEPartecipate to IRC chat if the streamer is online (leave if offline)OFFLINEPartecipate to IRC chat if the streamer is offline (leave if online)
Migrating from an old repository (the original one):
If you already have a twitch-cookies.pkl and you don't want to log in again, please create a cookies/ folder in the current directory and then copy the .pkl file with a new name your-twitch-username.pkl
.
+-- run.py
+-- cookies
| +-- your-twitch-username.pkl
Windows
Other users have find multiple problems on Windows. Suggestions are:
- Stop using Windows 😝
- Suppress the emoji in logs with
logger_settings=LoggerSettings(emoji=False)
Other useful info can be found here:
- https://github.com/gottagofaster236/Twitch-Channel-Points-Miner/issues/31
- https://github.com/Tkd-Alex/Twitch-Channel-Points-Miner-v2/issues/55
You can also follow this video tutorial.
Termux
1. Upgrade packages
pkg upgrade
2. Install packages to Termux
pkg install python git rust libjpeg-turbo libcrypt ndk-sysroot clang zlib binutils tur-repo python-cryptography
LDFLAGS="-L${PREFIX}/lib/" CFLAGS="-I${PREFIX}/include/" pip install --upgrade wheel pillow
Note: pkg install tur-repo will basically enable the user repository (Very similar to Arch AUR) and python-pandas pre-compiled package comes exactly from this repository.
3. Install pandas
pkg install python-pandas
4. Clone this repository
git clone https://gitea.majjoduran.app/majjo/Twitch-Drops-Miner.git
5. Go to the miner's directory
cd Twitch-Drops-Miner
6. Configure your miner on your preferences by typing
nano example.py
7. Rename file name (optional)
mv example.py run.py
8. Install packages
pip install -r requirements.txt
9. Run the miner!
python run.py
Note
If you can't install cryptography, please try:
export RUSTFLAGS=" -C lto=no" && export CARGO_BUILD_TARGET="$(rustc -vV | sed -n 's|host: ||p')" && pip install cryptography
⚠️ Installation of pandas, maturin and cryptography takes a long time.
Disclaimer
This project comes with no guarantee or warranty. You are responsible for whatever happens from using this project. It is possible to get soft or hard banned by using this project if you are not careful. This is a personal project and is in no way affiliated with Twitch.