Toast Notifications MCP server

Provides cross-platform desktop notifications for important events or task completions using native Windows and macOS APIs.
Back to servers
Provider
Naru Sensei
Release date
Apr 06, 2025
Language
Python
Stats
3 stars

The MCP Server is designed to display desktop notifications triggered by Model Context Protocol (MCP) clients like VSCode Cline. It supports both Windows 10 (using win10toast) and macOS (using osascript) notification systems, allowing customizable notification parameters and handling multiple client connections simultaneously.

Installation

Prerequisites

  • Python 3.8 or later
  • Operating system: Windows 10 or macOS

Setup Instructions

  1. Clone or download the MCP server code to your local machine

  2. Install the required dependencies:

pip install -r requirements.txt

For Windows users, this will install the win10toast library needed for desktop notifications. Mac users don't need additional libraries as the server uses the built-in osascript functionality.

Usage

Starting the Server

To start the MCP server with default settings (localhost on port 8000):

python mcp_server.py

To customize the host and port:

python mcp_server.py --port 8000 --host 0.0.0.0

Command Line Arguments

The server supports the following command line arguments:

  • --port: Set the port number (default: 8000)
  • --host: Set the host interface (default: 127.0.0.1)
    • Use 127.0.0.1 for localhost only
    • Use 0.0.0.0 to listen on all network interfaces

Environment Variables

You can also configure the server using environment variables:

  • MCP_SERVER_PORT: Port number
  • MCP_SERVER_HOST: Host interface

Client Connection

Once the server is running, MCP clients (such as VSCode Cline) can connect to it using the specified host and port. The server handles the MCP protocol communication automatically.

Notification Features

Windows Notifications

On Windows 10, the server uses the win10toast library to display desktop notifications with these customizable parameters:

  • Title
  • Message content
  • Display duration
  • Icon (optional)
  • Notification type (information, warning, error, success)

macOS Notifications

On macOS, the server uses osascript to display notifications with these customizable parameters:

  • Title
  • Message content
  • Subtitle (optional)
  • Sound (optional)
  • Notification type (information, warning, error, success)

Troubleshooting

Common Connection Issues

If you experience connection problems:

  • Check that the server is running and listening on the correct port
  • Ensure your firewall allows connections to the specified port
  • Verify that the client is configured to connect to the correct host and port

Notification Issues

If notifications aren't displaying:

  • On Windows: Ensure win10toast is properly installed
  • On macOS: Check that notification permissions are enabled for Terminal or your Python environment
  • Review the server logs for any error messages related to notification delivery

Logging

The server implements comprehensive logging for debugging purposes. Check the console output for connection status, received commands, and potential errors.

How to add this MCP server to Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "cursor-rules-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "cursor-rules-mcp"
            ]
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later