Menu

Post image 1
Post image 2
1 / 2
0

How I automated stop-loss monitoring with Claude Code and Telegram (no broker API needed)

DEV Community·tellmefrankie·19 days ago
#s2UeNbmD
Reading 0:00
15s threshold

The problem with manual stop-loss monitoring: you check your phone, the market moves while you're not watching, and you exit a position three points below where you meant to. Here's how I built an automated stop-loss monitor that sends a Telegram alert within 2 seconds of a threshold breach — using Claude Code, Yahoo Finance's free API, and a SKILL.md file. No broker API. No paid data service. No authentication flow. How it works The skill polls Yahoo Finance's undocumented quote endpoint every 5 minutes during market hours: https://query1.finance.yahoo.com/v8/finance/chart/{ticker}?range=1d&interval=1m Enter fullscreen mode Exit fullscreen mode When the current price crosses a configured threshold, it fires a Telegram alert and logs to a 30-minute deduplication cache (so you don't get spammed if a stock bounces around a level). Market hours detection No point running the monitor at 3am or on weekends.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.

Read More