Skip to main content

MNotify MCP server: expose MNotify SMS tools over the Model Context Protocol

Project description

MNotify MCP Server

Production-ready Model Context Protocol (MCP) server exposing MNotify SMS tools for use in MCP-compatible clients (Cursor, Claude, etc.).

Requirements

  • Python 3.10+
  • Environment variable: MNOTIFY_API_KEY

Install dependencies (development) with uv or pip

  • Using uv (recommended):
    curl -LsSf https://astral.sh/uv/install.sh | sh  # install uv if needed
    uv venv                                          # create .venv
    uv pip install -r requirements.txt               # install deps
    
  • Using any virtualenv manager + pip:
    python -m venv .venv && source .venv/bin/activate
    pip install -r requirements.txt
    

Start the server

export MNOTIFY_API_KEY=sk_mnotify_...

# Preferred (matches Cursor config below once published)
mnotify_mcp server

# Alternatives if needed locally
mnotify-mcp
python -m mnotify_mcp.server

Test quickly with the MCP Inspector

npx @modelcontextprotocol/inspector@latest
  • Add server → Process
    • Command: mnotify_mcp
    • Args: server
    • Ensure MNOTIFY_API_KEY is set in the Inspector process environment
  • Try tools: check_sms_balance, get_group_list, then resolve_group_name({ group_name: "Youth", fetch: true }).

Connect to Cursor

  • Option A: Project config .cursor/mcp.json (recommended)
{
  "mcpServers": {
    "mnotify": {
      "command": "mnotify_mcp",
      "args": ["server"]
    }
  }
}
  • Option B: Manual add in Cursor (Settings → MCP → Add Custom Server → Process)
    • Command: mnotify_mcp
    • Args: server
    • Ensure MNOTIFY_API_KEY is set in the environment where Cursor launches the process

Using the server after PyPI install

Once published and installed globally or in a venv:

pip install mnotify_mcp
export MNOTIFY_API_KEY=sk_mnotify_...
mnotify_mcp server

Then connect from Cursor/Claude using the config above (no repo checkout required).

MNotify Agent (interactive CLI)

Run a local chat agent that can call all MNotify tools directly.

Setup

  • Create a virtual environment and install dependencies with uv or pip (see above).
  • Add a .env file with:
OPENROUTER_API_KEY=sk-or-v1-...
MNOTIFY_API_KEY=...
AGNO_API_KEY=ag-...   # optional, if required by your agno setup

Start the agent

python mnotify_agent.py

CLI commands

  • help: list commands
  • history: show recent messages
  • tools: list available tools
  • test: run a quick tool-call test
  • clear: clear conversation context

Example prompts:

  • "Check my SMS balance"
  • "Send 'Hello' to group 'Youth' from sender 'CHURCH'"
  • "Create a group named Ushers"

Tools exposed

  • SMS: send_quick_bulk_sms, send_bulk_group_sms, update_scheduled_sms
  • Reports: sms_delivery_report, specific_sms_delivery_report, periodic_sms_delivery_report
  • Contacts: add_contact, update_contact, delete_contact, get_contact_details, get_contact_list, get_group_contacts
  • Groups: add_group, update_group, delete_group, get_group_details, get_group_list
  • Templates: get_template_list, get_message_template, add_message_template, update_message_template, delete_message_template
  • Utilities: register_sender_id, check_sender_id, check_sms_balance
  • Helpers: get_context_snapshot, resolve_group_name

Validation & guardrails

  • message length ≤ 460; sender_id length ≤ 11.
  • schedule=true requires schedule_time (YYYY-MM-DD HH:MM).
  • recipient/recipients and group_id/groups accept string, list, or comma-separated values.
  • Optional: verify_sender=true performs a best‑effort sender status check before sending.

Security

  • Never pass secrets as tool arguments. The server reads MNOTIFY_API_KEY from the environment.
  • The server does not log secrets.

Preparing for PyPI

Before publishing:

  • Project metadata in pyproject.toml:
    • Update [project] fields: name, version, description, readme, license, authors, keywords, classifiers, urls.
    • Ensure dependency on mcp>=1.1.1 is present.
    • Ensure console script entry exists:
      [project.scripts]
      mnotify-mcp = "mnotify_mcp.server:main"
      
  • Package contents:
    • Include mnotify_mcp package (has __init__.py) and the functions.py module used by the server.
      • If using Setuptools, configure packages and py_modules = ["functions"] (or move functions.py under the package and import accordingly).
    • Verify imports work when installed into a clean environment.
  • Versioning: bump __version__ in mnotify_mcp/__init__.py and match pyproject.toml.
  • Build & upload:
    # build
    python -m pip install -U build twine
    python -m build    # or: uv build
    
    # check the tarball/wheel
    twine check dist/*
    
    # upload (use testpypi first if desired)
    twine upload dist/*
    # or
    twine upload --repository testpypi dist/*
    
  • Post‑publish test:
    python -m venv /tmp/v
    /tmp/v/bin/pip install my-agent  # your package name
    MNOTIFY_API_KEY=sk... /tmp/v/bin/mnotify-mcp
    

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mnotify_mcp_server-0.1.0.tar.gz (17.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mnotify_mcp_server-0.1.0-py3-none-any.whl (17.0 kB view details)

Uploaded Python 3

File details

Details for the file mnotify_mcp_server-0.1.0.tar.gz.

File metadata

  • Download URL: mnotify_mcp_server-0.1.0.tar.gz
  • Upload date:
  • Size: 17.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.6

File hashes

Hashes for mnotify_mcp_server-0.1.0.tar.gz
Algorithm Hash digest
SHA256 f8ef61266de0c7de7da388d8d158e793dbdd6857cc144dc3cb8e75df5f8824db
MD5 6779bfbff8aebf999a416698ecd5300f
BLAKE2b-256 43a00845d924b62ec14ab5ef7c843682238b0b49acfce843e44ff3c531303522

See more details on using hashes here.

File details

Details for the file mnotify_mcp_server-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mnotify_mcp_server-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6ff34f874d37ba72a6b999a7c94d0794794d3a9844a9f7807e516c87876b6f1b
MD5 65fcad1c45ca72be31bdec2d6b3ec3ed
BLAKE2b-256 07c74cdea3cf223078c9dfd8051cae1736a01896cbd697f735da463ed672a575

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page