Skip to content

mochyusufdev/url-shortener-bot

Repository files navigation

Url Shortener Telegram Bot Nodejs 🤖


Try it out now! @GetShortUrlBot

Available Bot Commands

  • /start Start bot
  • /help How to use bot

Required

Get Started

  1. Create a bot from Telegram, sending this message to @BotFather | Reference
/newbot
  1. Clone this repo
git clone https://github.com/jabjabrik/url-shortener-bot.git
cd url-shortener-bot
npm install
  1. cp .env.example .env to create the env file
  2. Edit the .env file and set the Bot token & API keys
BOT_TOKEN = YOUR_BOT_TOKEN
API_KEY_TINYURL = YOUR_API_KEY_TINYURL
API_KEY_BITLY = YOUR_API_KEY_BITLY
API_KEY_CUTTLY = YOUR_API_KEY_CUTTLY
  1. Run locally
npm run dev

Deploy on Cyclic

  1. Login to Cyclic using github account
  2. Click "New App" to create the project
  3. On tab "Link your own" Select your repository
  4. Connect..

    connect to repo

  5. Add some variables like this

    Variables environment

  6. set webhook https://api.telegram.org/bot{BOT_TOKEN}/setWebhook?url={URL_PROD}
  7. Bot deployed!!

Star this Repo if you Liked it ⭐⭐⭐

About

🤖 Url Shortener telegram bot with telegraf.js library

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published