SkillAgentSearch skills...

MercuryBot

A bot that monitors platforms for free game promotions.

Install / Use

/learn @5okin/MercuryBot

README

<div align="center"> <a href="https://discord.com/oauth2/authorize?client_id=827564914733350942"> <img src="https://img.shields.io/endpoint?url=https://shieldsapi.fly.dev/api/stats/discordservers&style=for-the-badge&logo=discord&logoColor=%235865f2"></a> <a href="https://discord.com/api/oauth2/authorize?client_id=827564914733350942&permissions=534723885120&scope=bot"> <img src="https://img.shields.io/endpoint?url=https://shieldsapi.fly.dev/api/stats/discordusers&style=for-the-badge&logo=discord&logoColor=%235865f2"></a> <a href="https://x.com/_MercuryBot_"> <img src="https://img.shields.io/endpoint?url=https://shieldsapi.fly.dev/api/stats/twitter&style=for-the-badge&logo=x"></a> <a href="https://bsky.app/profile/mercurybot.bsky.social"> <img src="https://img.shields.io/endpoint?url=https://shieldsapi.fly.dev/api/stats/bluesky&style=for-the-badge&logo=bluesky"></a> </div>

MercuryBot

MercuryBot is a Discord, Bluesky and X, formerly known as twitter, bot that monitors various platforms to find and notify users about new free game promotions. Stay updated on the latest giveaways from Epic Games, both desktop and mobile, Steam, GOG, PS Plus and luna (prime gaming). Never miss out on the opportunity to grab titles for free. Discover more on our website.

<br> <div align="center"> <a href="https://x.com/_MercuryBot_"><img src="https://github.com/user-attachments/assets/e1d13e8e-93fc-49a0-99f1-6f03b74fae59" alt="X Link"></a> <a href="https://discord.com/oauth2/authorize?client_id=827564914733350942"><img src="https://github.com/user-attachments/assets/aaf0d3f0-eecc-4e87-9004-11171d68da00" alt="Discord Link"></a> <a href="https://bsky.app/profile/mercurybot.bsky.social"><img src="https://github.com/user-attachments/assets/64235e24-fc43-4305-b047-5e392e18c4c6" alt="Bluesky Link"></a> </div> <br> <p align='center'> <a href= "https://discord.com/oauth2/authorize?client_id=827564914733350942"> <img src="https://github.com/5okin/MercuryBot/assets/70406237/34d1a800-4dd5-4915-a02d-9c884848fcb3"></a> <p><br>

Mercury bot sends you notifications like the ones bellow every time there's a new free game available, so you never miss out again. For epic notifications on Discord, it also sends you next weeks free game (if available) all in one notification!

Discord | X | Bluesky :-------------------------:|:-------------------------:|:-------------------------: <img src="https://github.com/5okin/MercuryBot/assets/70406237/a40c122b-369f-48f1-9f31-a9e383044da0"> | <img src="https://github.com/user-attachments/assets/2aa7d6b4-d88a-44f4-a8c7-9871e760f18d" width="60%"> | <img src="https://github.com/user-attachments/assets/f8bee8bc-7f56-452c-adc0-5ba84d14fa13">

Features

  • Multi-Platform Support: MercuryBot monitors free game promotions on Epic Games, Steam, GOG, and PS Plus.

  • Online 24/7: Bot doesn't go offline ensuring you dont miss out on any deal!

  • Automated Reminders: Receive timely reminders in your Discord server, X or Bluesky feed when new free games become available.

  • Customizable Settings: Configure MercuryBot to tailor notifications to your preferences on discord.

  • Ephemeral Messages: Commands you send to the bot won't spam and clutter your channels, they stay invisible to everyone but you.

  • Privacy focused: Using slash commands the bot never has access to your messages.

Discord

Slash Commands

  • /settings: Setup and review your notification preferences.
  • /deals: Display a list of available stores and get the current available games (Ephemeral Message).
  • /feedback: Send feedback or bug reports.

How to use

  1. Invite MercuryBot to your Discord server. <img src="https://github.com/5okin/MercuryBot/assets/70406237/9fbf5218-d5bc-476a-8892-2496a1bbe1ba">

  2. Run the /settings slash command and configure the bot:

    • Test notifications: Test your settings.
    • Set channel: The channel to receive the notifications.
    • Set role: Specify the role to be pinged for notifications (optional).
    • Set stores: Set the store you wish to receive notifications for.
<p align='center'> <image src="https://github.com/user-attachments/assets/feb013c1-3f0c-4fc9-85bd-11ad140a2f57"> <p>
  1. Enjoy automatic alerts for new free games on various platforms.

Command breakdown

  • The Test notifications button sends a notification to the set channel, pinging the set role to ensure everything works correctly.
<p align='center'> <image src="https://github.com/user-attachments/assets/0806c7b4-5ddd-402a-90e1-c4ba4e6e9584"> <p>
  • The Set channel button allowes you to set the channel the channel you want the bot to send the notifications to. If its a locked channel make sure to give the bot permissions. A channel must be set.
<p align='center'> <image src="https://github.com/user-attachments/assets/000b9130-5e67-4864-a070-45f2c42184b6"> <p>
  • When setting a channel, you will be notified if you select a channel that the bot lacks permissions for.
<p align='center'> <image src="https://github.com/user-attachments/assets/29d6541a-dfb3-4456-bcf2-7db7d02b0f74"> <p>
  • The Set role button allowes you set the role that will be pinged when a notification is send, you can choose not to ping any roles.
<p align='center'> <image src="https://github.com/user-attachments/assets/36d13c17-d472-497c-bb91-f2211891cd14"> <p>
  • The Set stores button allows you change the stores for which you receive notifications.
<p align='center'> <image src="https://github.com/user-attachments/assets/c0c03f56-837b-41d5-ac51-648078bfd49d"> <p>

Project Structure

📁 MercuryBot
│── 📂 clients
│ ├── 📜 discord.py     # Discord bot implementation
│ ├── 📜 bluesky.py     # Bluesky integration
│ ├── 📜 twitter.py     # X (Twitter) integration
│── 📂 stores
│ ├── 📜 epic_mobile.py # Epic Games store handler
│ ├── 📜 epic.py        # Epic Games store handler
│ ├── 📜 gog.py         # GOG store handler
│ ├── 📜 luna.py        # luna store handler
│ ├── 📜 ps_plus.py     # PlayStation Plus store handler
│ ├── 📜 steam.py       # Steam store handler
│── 📂 utils
│ ├── 📜 logger.py      # Logging utility
│ ├── 📜 helpers.py     # Helper functions
│── 📜 main.py          # Main entry point of the bot
│── 📜 .env.example     # Environment configuration template
│── 📜 requirements.txt # Python dependencies
│── 📜 LICENSE          # License information
│── 📜 Dockerfile	    # Docker configuration
│── 📜 fly.toml         # Deployment process file
│── 📜 README.md        # Project documentation

Running it on your own

Locally

  • Make sure you have python 3.12 or higher installed. python -V
  • Install the required dependencies by running. pip install -r requirements.txt
  • Install Playwright
    python -m playwright install-deps
    python -m playwright install chromium
    
  • Run it using: python3 main.py

Docker

  • Build the Docker image docker build -t mercurybot .
  • Run the bot in a container with your .env docker run -d --env-file .env mybot

Get a discord TOKEN

Log in to https://discord.com/developers/applications/ and click on the New Application button. Go to the bot tab and click the Add Bot button to get a TOKEN.

Get twitter Keys

You can follow twitters documentation https://developer.x.com/en/docs/twitter-api/getting-started/getting-access-to-the-twitter-api to get started.

Get a Bluesky account

All you need to do is create a normal Bluesky account https://bsky.app/

MongoDB connection string

The database used is MongoDB, you can use mongodb atlas which offers a shared $0/month plan, if you don't want to host your own database. Navigate to DEPLOYMENT > Database > Connect > Drivers to obtain a connection string (eg., mongodb+srv://...)

.env file

Copy or rename the .env.example file to .env and edit it with your data.

Here is an explanation of what everything is: | Variable | What it is | | ---------------------- | ---------------------------------------------- | | DEBUG | Can be true or false. Controls log output and bot configuration (test vs. live). | | DB_CONNECTION_STRING | Your mongoDB connection string | | DISCORD_TOKEN_LIVE | Live discord TOKEN, used when DEBUG=False | | DISCORD_TOKEN_TEST | Test/Dev discord TOKEN, used when DEBUG=True | | X_ACCESS_TOKEN | Twitter/X access token | | X_ACCESS_TOKEN_SECRET | Twitter/X access token secret | | X_API_KEY | Twitter/X api key | | X_API_SECRET | Twitter/X api secret | | DISCORD_DEV_GUILD | Test Guild Id (not necessary)

View on GitHub
GitHub Stars15
CategoryDevelopment
Updated1d ago
Forks1

Languages

Python

Security Score

95/100

Audited on Mar 26, 2026

No findings