Blog
COURIER

How I Used Raspberry Pi to Detect Water Leaks in My Home

Suhas Deshpande

April 14, 2022

raspberry-pi-leaks-header

Table of contents

A leak can become an expensive problem

Building alerts for water leaks using Raspberry Pi

How to use potential-octo-lamp to get alerts

Alerts are your answer to urgent situations

When I realized there was a leak in my home, I knew it was time to put my expertise to work. I needed to call on my years of experience and passion for my job - as a software engineer? While at first glance, it may appear that a plumber would have been a better option, my argument is that there is a step to be taken before a plumber is even involved to fix a leak. And that is to detect the leak when it first happens.

Sure, I could have a plumber on call who checks for leaks every day, but seeing as that’s not an effective use of time or money, we needed to find an alternative to waiting for the problem to become bad enough to become a major problem. So if a 24/7 plumber-butler wasn’t an option, I thought some kind of automated system would be more realistic.

As it turns out, I had been thinking for some time about how to use a Raspberry Pi with Courier to bring notifications to life. This happened to be a perfect use case to try it out, so I decided to invest in the appropriate hardware and make use of my own software development skills to make sure that I would get a notification any time there was even a small leak in my home. This way, I’d know to call the plumber and handle the problem before it became too big to handle.

A leak can become an expensive problem

I myself had a water leak in my apartment some time ago. Because I didn’t know there was a problem until it was already too late, I had to call for a plumber when the damage was already done. Even for a simple leak like this, I ended up spending more than $500 to fix it.

But things could have been much worse. Major damage is often caused by mold spores. Water leaks may also cause structural damage to property. Walls start swelling and warping, leading to cracks and holes in them. Furthermore, water leaks may negatively impact the value of a home.

I never wanted to deal with the complications, so I decided to take matters into my own hands. But of course, it was important to find a solution that would be fun and interesting as well as useful.

Building alerts for water leaks using Raspberry Pi

During my research for a solution in the form of alerts for water leaks, I found that I could use a small, affordable Raspberry Pi single-board computer to achieve my goal. With this tiny computer, I could read signals from my water sensor and then send those signals to my monitor.

To develop the project, which I called potential-octo-lamp, I first got all the hardware I needed to detect water leaks and connect to my computer. These devices included:

With Courier, I could create custom alerts and define their titles and body text. I could also specify the communication channels through which the alerts should go and the recipients of these alerts. I also added a Twilio integration on Courier to deliver the contents of my alerts through the channels I specified — in this case, SMS and email.

How to use potential-octo-lamp to get alerts

Luckily, I’m a really nice guy and have made potential-octo-lamp open source. You can use my program to protect your own home from water leaks. Once you have all the hardware requirements listed above, connect your Raspberry to your water sensor. If you need help setting them up, this tutorial will help. Then you can begin using potential-octo-lamp to receive alerts for water leaks in five easy steps:

1. Create Your Courier and Twilio Accounts

If you don’t already have Courier and Twilio accounts, you’ll need to sign up for both to configure your alert system. You may sign up for free on Courier and Twilio using an email address. Courier also allows you to use your Google or GitHub account to create an account.

2. Add Your Twilio Integration in Courier

Start by getting your Account SID, Auth Token, and messaging service SID from Twilio. Then log into your Courier account and go to Integrations. Add the Twilio info to their corresponding fields in Courier.

3. Retrieve Your Courier Authorization Token

When you create an account with Courier, you get an Auth Token so that you can safely make requests to and from Courier. Once logged in, you may retrieve your Courier Auth Token from the API keys page in Settings.

4. Clone potential-octo-lamp and Add Your Courier Auth Token

Next, go to GitHub and clone potential-octo-lamp. Because it’s unsafe to input your Courier Auth Token directly in your code, create a .env file and add it there. That way, it’s only visible to you.

5. Start the App

Finally, run the following commands one after the other to install dependencies and start checking for water leaks:

npm install

npm run build

npm run start

As soon as your floor water sensor detects leaks, potential-octo-lamp sends alerts for water leaks to the recipients you added on Courier. Then you can quickly repair the leak to prevent further damage.

Alerts are your answer to urgent situations

Potential-octo-lamp is open-source, so you can clone it and use it yourself. Any improvements or suggestions you may have are also welcome. You can raise an issue or reach out to me if you’d like to contribute to the project!

Create custom alerts like mine. Sign up for a free Courier account and explore.

Similar resources

a guide for ai assisted development: Notification infrastructure
CourierNotifications LandscapeEngineering

Vibe Coding Notifications: How to Use Courier with Cursor or Claude Code

Courier's MCP server lets AI coding tools like Cursor and Claude Code interact directly with your notification infrastructure. Unlike Knock and Novu's MCP servers that focus on API operations, Courier's includes embedded installation guides for Node, Python, Flutter, React, and other platforms. When you prompt "add Courier to my app," your AI assistant pulls accurate setup instructions rather than relying on outdated training data. OneSignal's MCP is community-maintained, not official. Courier supports 50+ providers, native Slack/Teams integration, drop-in inbox and preference components, and a free tier of 10,000 notifications/month. Configure in Cursor with "url": "https://mcp.courier.com" and "headers": { "api_key": "YOUR_KEY" }.

By Kyle Seyler

January 22, 2026

b2b customer engagement guide
Notifications LandscapeCourier

The Complete Guide to B2B Customer Engagement

Courier provides the notification infrastructure layer for B2B customer engagement, routing messages across email, SMS, push, in-app, Slack, and Teams based on user preferences and product events. Unlike building notification systems in-house—which takes months of engineering time for features like multi-channel routing, preference management, and delivery tracking—Courier handles this infrastructure so product teams can focus on engagement strategy. B2B customer engagement requires multiple layers: notification infrastructure (Courier), customer data platforms (Segment), product analytics (Mixpanel/Amplitude), and channel-specific tools. Companies with strong engagement programs see 15-25% churn reduction. The key is connecting product events to customer communication at the right moment through the right channel, handling complexity like multiple users per account with different notification needs across work channels.

By Kyle Seyler

January 20, 2026

what is a customer engagement platform
Product ManagementNotifications LandscapeCourier

Customer Engagement Platform vs CRM: Key Differences Explained

A CRM stores customer data: contacts, purchases, support tickets, and pipeline. It answers "who are our customers?" A customer engagement platform (CEP) orchestrates communication across email, push, SMS, in-app, and chat. It answers "what should we tell them next?" CRMs focus on historical records. CEPs process real-time behavior and trigger messages based on actions. Most teams need both, plus a third layer: notification infrastructure for reliable multi-channel delivery. Courier bridges CEP and infrastructure by combining routing, failover, and delivery tracking with engagement features like preference management, visual templates, and in-app notification centers.

By Kyle Seyler

January 07, 2026

Multichannel Notifications Platform for SaaS

Products

Platform

Integrations

Customers

Blog

API Status

Subprocessors


© 2026 Courier. All rights reserved.