Giter Site home page Giter Site logo

nuhmanpk / crypto-bot Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 0.0 17.81 MB

Open source free Telegram bot that can fetch crypto related details

License: MIT License

Procfile 0.08% Python 99.92%
bitcoin crypto cryptocurrency dogecoin hamster-python-bot pyrogram pyrogram-bot telegram telegram-bot telegram-crypto

crypto-bot's Introduction

Crypto-Bot

Crypto-Bot is a Ope source Telegram bot built using Pyrogram that allows users to fetch the latest cryptocurrency prices, trending cryptocurrencies, and historical data. The bot also supports user-specific settings such as preferred currency for price display.

Features

  • Fetch Current Prices: Get the latest price of any cryptocurrency in your preferred currency.
  • Trending Cryptocurrencies: View the top 10 trending cryptocurrencies.
  • Historical Data: Fetch historical price data for cryptocurrencies by day or hour.
  • User Settings: Set and update your preferred currency for price displays.
  • Live Price Fetching : Get live datas instantly.
  • Inline Keyboard Support: Use inline keyboards for easy navigation and settings adjustments.

Installation

  1. Clone the repository:

    git clone https://github.com/nuhmanpk/crypto-bot.git
    cd crypto-bot
  2. Install the required packages:

    pip install -r requirements.txt
  3. Set up your environment variables:

    Create a .env file in the root directory of the project and add your bot token, API ID, and API hash:

    BOT_TOKEN=your-bot-token
    API_ID=your-api-id
    API_HASH=your-api-hash
    DATABASE_URL=your-database-url
    DATABASE_NAME=your-database-name
    SESSION_STRING=your-session-string
    ADMINS = 1234556
    • Generate SESSION_STRING from here
    • Get DATABASE_URL url from here
    • Get API_ID and API_HASH from here
    • Give a DATABASE_NAME as you wish
    • Get BOT_TOKEN from here
    • Add user id of admins as ADMINS serperated by whitespaces.

Usage

  1. Run the bot:

    python main.py

  1. Interact with the bot:

    • /start: Start the bot and see the welcome message.
    • /help: Get help information about the bot's commands.
    • /price [symbol]: Get the current price of the specified cryptocurrency.
    • /trending: View the top 10 trending cryptocurrencies.
    • /historical [symbol] [timeframe]: Get historical data for the specified cryptocurrency and timeframe (day or hour).
    • /live_prices - Fetch Live Price
    • /exchange [symbol] - Get exchange details.
    • /exchange_rates - Get all exchange dates.
    • /exchanges - Get all exchanges.
    • /coin - Get all coin details.
    • /setcurrency [currency_code]: Set your preferred currency for price displays.
    • Settings โš™๏ธ: Use the settings button to change preferences like your preferred currency.
    • And more ...
  • If you find this bot useful mark your star and fell free to contribute

Happy Coding! ๐Ÿš€

Built with โค๏ธ by Nuhman Pk ยฉ 2024

crypto-bot's People

Contributors

nuhmanpk avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.