Skip to content

Comments

Feature/missing rate limiting 267#320

Open
sr-857 wants to merge 6 commits intoGauravKarakoti:mainfrom
sr-857:feature/missing-rate-limiting-267
Open

Feature/missing rate limiting 267#320
sr-857 wants to merge 6 commits intoGauravKarakoti:mainfrom
sr-857:feature/missing-rate-limiting-267

Conversation

@sr-857
Copy link
Contributor

@sr-857 sr-857 commented Feb 20, 2026

PR 3: Missing Rate Limiting on Bot (#267)

Technical Analysis

The Telegram bot lacked rate limiting, making it vulnerable to spam and potential API flooding. This could lead to service degradation and increased costs.

Proposed Solution

Integrate telegraf-ratelimit middleware to restrict the frequency of messages from a single user.

Changes

  • Installed telegraf-ratelimit and added it to the bot's middleware stack in bot/src/bot.ts.
  • Configured a rate limit of 1 message per 3 seconds per user.

Verification

  • Verified the middleware is correctly applied to the Telegraf instance.

@vercel
Copy link
Contributor

vercel bot commented Feb 20, 2026

@sr-857 is attempting to deploy a commit to the Gaurav's projects Team on Vercel.

A member of the Team first needs to authorize it.

@netlify
Copy link

netlify bot commented Feb 20, 2026

Deploy Preview for swapsmithminiapp canceled.

Name Link
🔨 Latest commit 1bace30
🔍 Latest deploy log https://app.netlify.com/projects/swapsmithminiapp/deploys/699988691b1eec00085b51c2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant