This project is a simple telegram storage example. You can upload files up to 20MB and store them in any telegram chat.
These instructions will get you a copy of the project up. You can run the project on any machine with nodejs installed.
You need to have nodejs installed on your machine. You can download it from here.
curl -fsSL https://deb.nodesource.com/setup_20.x | sudo bash -
sudo apt-get install -y nodejs
First, you need to clone the repository.
git clone https://github.com/Qurbonsaid/telegram-storage.git
Then, you need to install the dependencies.
npm install
After that, you need to create a .env
file in the root directory of the project. You need to add the following variables to the file.
PORT=8080
# Get the token from the [BotFather](https://t.me/botfather)
BOT_TOKEN=1234567890:ABCDEFGHIJKLMNOPQRSTUVWXYZ
# Get the chat id of the chat you want to store files in
CHAT_ID=-100234567890
Finally, you can run the project. For development:
npm run dev
For production:
npm run build
npm start
Open your browser and go to http://localhost:8080/api-docs
. You will see swagger documentation. You can test the endpoints from there.