MortyCP
An MCP (Model Context Protocol) server that gives AI assistants like Claude direct, governed access to a mortgage CRM platform — turning natural language into real API actions across 93 tools and 7 business domains.
01 Overview
Mortgage Automator's platform exposes a large REST API, but using it meant writing integration code for every workflow. MortyCP wraps that API in a single Model Context Protocol server, so an AI assistant can read and act on real CRM data directly — looking up contacts, advancing deals, generating documents, and triggering automation through plain language instead of bespoke scripts.
The goal wasn't a chatbot. It was to prove an assistant could safely operate a production business system — with the same authentication, validation, and guardrails a human integration would have, exposed through one consistent tool interface.
02 How it works
MortyCP is a .NET 8 service implementing the MCP spec. Each of the platform's API capabilities is surfaced as a discrete, typed tool with a clear schema, so the assistant always knows the exact shape of every call and response. Tools are grouped into seven domains — contacts, deals, documents, tasks, automation, and more — to keep the surface navigable.
A custom authentication layer handles the platform's SHA1 token generation and
session handling, so credentials never live in prompts. The whole service is containerized
with Docker and sits behind a Traefik reverse proxy on a self-hosted VPS,
with automatic TLS — the same production posture as any other service I run.
03 Engineering highlights
- 93 tools across 7 domains with full CRUD coverage — the entire working surface of the CRM exposed through one protocol.
- Custom auth layer with
SHA1token generation and session handling, keeping secrets out of the model context entirely. - Typed tool schemas so every action is validated and self-describing — the assistant can't call a tool the wrong way.
- Dockerized + Traefik on a self-hosted VPS with automatic Let's Encrypt TLS and a production deployment workflow.
- Docusaurus documentation site covering every tool, so the server is usable by humans and agents alike.
04 Outcome
MortyCP proves AI can operate real business systems, not just chat about them — a governed, auditable bridge between natural language and a production CRM that a non-technical user can drive and an engineer can trust.