Coder Social home page Coder Social logo

teamflock_file_store_bot's Introduction

teamflock_file_store_bot

Here's a README.md file for your GitHub repository:

# TeamFlock File Store Bot

A Telegram bot that allows authorized users to upload files to a private channel and generate unique links for others to access those files. 

## Features

- Upload single or multiple files.
- Store files in a private Telegram channel.
- Generate unique links for accessing stored files.
- Only authorized users can upload and share files.
- Sends a welcome message with a thumbnail image.

## Prerequisites

- Python 3.6+
- Telegram Bot API token
- Private Telegram channel ID

## Getting Started

### Clone the Repository

```sh
git clone https://github.com/yourusername/teamflock_file_store_bot.git
cd teamflock_file_store_bot

Setting Up Environment Variables

Create a .env file in the root directory and add your bot token and channel ID:

BOT_TOKEN=your_bot_token_here
CHANNEL_ID=your_channel_id_here

Alternatively, you can directly modify the main.py file to include your bot token and channel ID:

BOT_TOKEN = 'your_bot_token_here'
CHANNEL_ID = 'your_channel_id_here'

Install Dependencies

Install the required Python packages using pip:

pip install -r requirements.txt

Running the Bot Locally

Run the bot using the following command:

./start.sh

Deploying on Render

  1. Create an Account on Render:

  2. Create a New Web Service:

    • Go to your Render dashboard.
    • Click on the "New" button and select "Web Service."
    • Connect your GitHub account and select the repository teamflock_file_store_bot.
  3. Configure the Service:

    • Environment: Select Python 3.
    • Build Command: Leave it blank (Render automatically installs dependencies from requirements.txt).
    • Start Command: ./start.sh.
  4. Set Environment Variables:

    • After the service is created, go to the "Environment" tab.
    • Add the environment variables BOT_TOKEN and CHANNEL_ID.
  5. Deploy the Service:

    • Render will automatically start the deployment process.
    • Once the deployment is complete, your bot will be up and running.

Usage

  1. Start the Bot:

    • Open Telegram and start a chat with your bot using the username provided during bot creation.
  2. Upload Files:

    • Authorized users can send files directly to the bot.
    • After uploading files, use the /done command to finalize and get a shareable link.
  3. Access Files:

    • Share the generated link with others to allow them to access the files via the bot.

Owners

To restrict file uploads to specific users, update the OWNERS list in main.py with the Telegram user IDs of the authorized users:

OWNERS = [6804487024, 930652019]

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing

Contributions are welcome! Please open an issue or submit a pull request.

Acknowledgments


### Final Steps

1. **Update Repository URL:**
   Replace `https://github.com/yourusername/teamflock_file_store_bot.git` with the actual URL of your GitHub repository.

2. **Add License:**
   Add a `LICENSE` file if you wish to include a license for your project.

3. **Customize as Needed:**
   Modify any sections as needed to better fit your specific use case or additional setup instructions.

Once you've completed these steps, you can commit the `README.md` file to your repository. This will help other developers and users understand how to use and contribute to your project.

teamflock_file_store_bot's People

Contributors

nehapj143 avatar

Watchers

Kostas Georgiou avatar  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.