A serverless application that monitors the Rad Cult BigCartel store for product updates and sends notifications via Telegram when changes are detected. Never miss a release again!
- 🕒 Hourly monitoring of the Rad Cult store
- 🔍 Detects new products
- 📱 Real-time notifications via Telegram
- ☁️ Runs serverlessly on AWS Lambda
- 💾 Tracks product history in S3
- AWS Account
- AWS SAM CLI installed
- Node.js 20.x
- Telegram Bot Token and Chat ID
- Docker (for local testing)
-
Clone the repository
git clone <repository-url> cd rad-cult-scraper
-
Create your environment file
cp example.env.json env.json
Edit
env.json
with your actual values:BUCKET_NAME
: Your S3 bucket nameOBJECT_KEY
: JSON file name for storing product dataTELEGRAM_CHAT_ID
: Your Telegram chat IDTELEGRAM_BOT_TOKEN
: Your Telegram bot token
-
Deploy to AWS
sam build sam deploy --guided
When prompted, provide your Telegram credentials as parameter overrides.
To test the function locally:
sam local invoke ScraperFunction
- AWS Lambda: Runs the scraper function every hour
- Amazon S3: Stores product data between runs
- Telegram Bot API: Sends notifications when changes are detected
- Puppeteer: Handles web scraping with headless Chrome
- Cheerio: Parses HTML content
- Defines the Lambda function, S3 bucket, and necessary IAM permissions
- Sets up CloudWatch Events for hourly execution
- Configures environment variables
BUCKET_NAME
: S3 bucket for storing product dataOBJECT_KEY
: Name of the JSON file in S3TELEGRAM_CHAT_ID
: Telegram chat/group ID for notificationsTELEGRAM_BOT_TOKEN
: Telegram bot authentication token
- Never commit
env.json
to version control - Use AWS Parameter Store or Secrets Manager for production credentials
- Keep your Telegram bot token secure
- Fork the repository
- Create your feature branch
- Commit your changes
- Push to the branch
- Create a new Pull Request
MIT License - See LICENSE file for details