website-status
v1.0.5
Published
A powerful Node.js package to check website availability and send optional Discord notifications.
Maintainers
Readme
Site Monitor | Check Website Status! 🚀
✅ Free to use! 🌍 A powerful Node.js package to check website availability and send iscord notifications. Supports scheduled monitoring with custom intervals!
📦 Installation
Install Globally for CLI Usage
npm install -g website-statusInstall for Node.js Projects
npm install website-status🚀 Usage
🔍 Check a Single Website Once
site-checker https://utku.berkaykoc.net📌 Output:
✅ https://utku.berkaykoc.net is UP!
or
❌ https://utku.berkaykoc.net is DOWN!
📢 Optional Discord Webhook Notifications
If you want to receive a Discord notification when a site is down or up, provide a Webhook URL:
site-checker https://utku.berkaykoc.net https://discord.com/api/webhooks/your-webhook-url📌 If no webhook is provided, it will only print the result in the terminal.
🔄 Scheduled Monitoring (Interval & Loop Count)
You can set a monitoring interval and specify how many times to repeat the check.
site-checker <URL> <Webhook (optional)> <Interval in seconds (optional)> <Loop count (optional)>Rules:
- If no interval or loop count is given, it runs only once.
- Minimum interval is 30 seconds.
- Maximum loop count is 50 times.
📌 Examples:
# Check every 30 seconds, repeat 3 times
site-checker https://utku.berkaykoc.net null 30 3
# Check every 60 seconds, repeat 10 times
site-checker https://utku.berkaykoc.net null 60 10
# Check every 45 seconds, repeat 5 times, and send Discord notifications
site-checker https://utku.berkaykoc.net https://discord.com/api/webhooks/your-webhook-url 45 5
# If no interval or loopCount is given, it runs only once
site-checker https://utku.berkaykoc.net📜 Using in a Node.js Project
Install the package
npm install website-statusImport the module
const { isSiteAvailable } = require("website-status");Check if a site is up (without webhook)
isSiteAvailable("https://example.com");Check if a site is up (with webhook)
isSiteAvailable("https://example.com", "https://discord.com/api/webhooks/your-webhook-url");Check a site with custom interval & loop count
isSiteAvailable("https://example.com", null, 60, 5); // Check every 60 seconds, 5 times🛠️ Contributing
Contributions are welcome! Fork the repository, create a branch, make changes, and submit a PR. 🚀
📜 License
This project is licensed under the MIT License.
🌟 Support & Contact
- GitHub Issues: Report Bugs or Request Features
- Give a Star: ⭐ If you like this package, consider giving it a star on GitHub!
🚀 Happy Coding! 🎮✨
