Skip to content

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

XLA Stats Bot

Python Version License Telegram

Telegram bot for monitoring Scala (XLA) mining pool statistics in real-time.

Example bot: @xlastatsbot

Features

  • 📊 Real-time pool statistics - Network difficulty, hashrate, pool stats
  • Periodic notifications - Automatic updates every N minutes
  • 🚨 Threshold alerts - Custom alerts for hashrate, difficulty, miners count
  • 💰 Wallet statistics - Check balance, hashrate, workers, payments
  • 🔄 Auto-refresh data - Always up-to-date information
  • 📱 Inline keyboard interface - Easy navigation without commands
  • 🛡️ Tor/Proxy support - Optional proxy support for privacy

Commands

Command Description
/start Launch the bot and see welcome message
/stats Get current pool statistics
/wallet Check wallet balance and mining stats
/menu Show main menu
/help Show help message with all links
/delete_alert <id> Delete an existing alert

Links

Official Scala (XLA) Resources

Platform Link
🌐 GitHub Scala-Network
💬 Discord XLA Community
📱 Matrix #scala:unredacted.org
✈️ Telegram Scala Chat
🔍 Explorer Scala Explorer
⛏️ Pool pool.scalaproject.io

Bot Resources

Platform Link
🐙 Bot GitHub XLA-stats-bot
🤖 Example Bot @xlastatsbot

Installation

Requirements

  • Python 3.9+
  • SQLite3
  • Telegram Bot Token (from @BotFather)

Setup

  1. Clone the repository:
git clone https://github.com/post-hum/XLA-stats-bot.git
cd XLA-stats-bot
  1. Install dependencies:
pip install -r requirements.txt
  1. Create .env file:
BOT_TOKEN=your_telegram_bot_token_here
ADMIN_IDS=123456789,987654321
DB_PATH=sqlite+aiosqlite:///xla_bot.db
POLL_INTERVAL=300
USE_PROXY=False
# PROXY_URL=socks5://127.0.0.1:9050  # For Tor/SOCKS5 proxy
  1. Run the bot:
python bot.py

Running with Tor (optional)

torsocks python3 bot.py

Project Structure

XLA-stats-bot/
├── bot.py              # Main entry point
├── config.py           # Configuration
├── fetcher.py          # Pool API fetcher
├── keyboards.py        # Inline keyboards
├── scheduler.py        # Alert scheduler
├── db/
│   ├── models.py       # SQLAlchemy models
│   └── crud.py         # Database operations
└── handlers/
    ├── common.py       # Common commands (start, help, stats)
    ├── alerts.py       # Alert management
    ├── stats.py        # Statistics display
    └── wallet.py       # Wallet statistics

Usage Examples

Get pool statistics

/stats

Check wallet balance

/wallet
Send: SvkFweFR7GeAGus6pt7jpg5ZYEvZgqjaUEnYnkqqBRQg57LUuKCMY849e79oVsmDbH9jYH5BVyLJMSweBAQ6YdPB1ekUGaPwc

Set periodic alert

  1. Click "⏰ Periodic Alert"
  2. Send interval in minutes (5-1440)

Delete an alert

/delete_alert 2

Troubleshooting

API timeout issues

If you experience slow API responses, increase timeout in handlers/wallet.py:

async with session.get(url, timeout=120) as resp:

Proxy connection issues

Make sure Tor is running and USE_PROXY=True in .env

Database errors

Delete xla_bot.db and restart the bot to recreate database

Donations

If you find this bot useful, you can support its development:

XLA (Scala) address:

SvkFweFR7GeAGus6pt7jpg5ZYEvZgqjaUEnYnkqqBRQg57LUuKCMY849e79oVsmDbH9jYH5BVyLJMSweBAQ6YdPB1ekUGaPwc

License

MIT License - see LICENSE file for details

❤️ Thanks for using XLA Stats Bot!

About

Telegram bot for real-time monitoring of Scala (XLA) mining pool statistics with customizable alerts

Resources

Stars

2 stars

Watchers

0 watching

Forks

Packages

Contributors

Languages