Skip to content
This repository was archived by the owner on Mar 10, 2025. It is now read-only.

CatPeare/binance_price_check

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Binance Telegram Bot

This project is a Telegram bot that provides real-time cryptocurrency price updates and alerts using the Binance API.

Features

  • Get the current price of a cryptocurrency.
  • Get detailed price changes over different time intervals (2 hours, 12 hours, 24 hours). (change the symbols in the code with your willing or make it more user friendly)
  • Restrict bot access to specific admins.
  • Send alerts based on significant price changes.

Requirements

  • Python 3.11
  • The required Python packages are listed in the requirements.txt file.

Installation

  1. Clone the repository:

    git clone https://github.com/yourusername/binance-telegram-bot.git
    cd binance-telegram-bot
  2. Create a virtual environment and activate it:

    python -m venv env
    source env/Scripts/activate  # On Windows
    # source env/bin/activate    # On Unix or MacOS
  3. Install the required packages:

    pip install -r requirements.txt
  4. Create a .env file in the root directory and add your Telegram API key:

    TELEGRAM_API_KEY=your_telegram_api_key

Usage

Run the bot:

python main.py

Files

  • main.py: The main script to run the Telegram bot.
  • functions/: Directory containing helper functions and API calls.
    • binance_api.py: Functions to interact with the Binance API.
    • markdown_telegram.py: Functions to escape markdown characters.
    • math_functions.py: Functions to perform mathematical calculations.
    • telegram_commands.py: Telegram bot command handlers.

dont forget to change

ADMINS_DICT = {
    "your name": 66524162233,
}

License

This project is licensed under the MIT License.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages