chore(backend): remove relayer balance-alert Telegram bot#286
Merged
Conversation
Removes the daily relayer low-balance Telegram alert and its orphaned config wiring. This is replaced by an external scheduled agent that checks the relayer balance on Base + Horizen mainnet (plus ETH/BTC prices) and posts to Telegram. - Delete src/balance-alert/* (module, scheduler, TelegramService) - Unregister BalanceAlertModule from app.module; keep ScheduleModule (still used by transaction-reconciler + price schedulers) - Delete src/config/telegram.config.ts and drop its load entry - Remove TELEGRAM_* config keys, env validation, and .env.example block Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
304899f to
c905bf8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Removes the backend's daily relayer low-balance Telegram alert bot and its now-orphaned config wiring.
Why
This functionality is now handled by an external scheduled agent (
polypay-relayer-balance-weekly) that checks the relayer wallet balance on Base + Horizen mainnet, includes ETH/BTC USD prices, and posts to Telegram — making the in-backend scheduler redundant.Changes
src/balance-alert/*—BalanceAlertModule,BalanceAlertScheduler(the@Cron('0 0 * * *')job), andTelegramService.BalanceAlertModulefromapp.module.ts.src/config/telegram.config.tsand remove it from theConfigModuleload array.TELEGRAM_BOT_TOKEN/TELEGRAM_CHAT_IDentries fromconfig.keys.ts,env.validation.ts, and.env.example.Safety notes
ScheduleModule.forRoot()is kept — still required bytransaction-reconciler.scheduler(unsticks stuck txs) andprice.scheduler(weekly ZEN price capture).TelegramServicehad no other consumers (onlybalance-alertused it).balance-alert,TelegramService, orTELEGRAM_*.TELEGRAM_*env vars on the Cloud Run service are managed out-of-band and unaffected by this PR; they can be cleaned up separately by devops.Validation
tsc/build not run (nonode_modulesin working checkout). Change is deletion-only with verified-clean references; CIyarn build(lint.yaml) will compile-check.🤖 Generated with Claude Code