servicetitan-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@servicetitan-mcpshow me all open jobs for customer Acme Corp"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
servicetitan-mcp
A remote Model Context Protocol (MCP) server that exposes the ServiceTitan API as MCP tools to clients like Claude. It runs as a single Cloudflare Worker, speaks MCP over Streamable HTTP at POST /mcp, and talks directly to the ServiceTitan API using your own ServiceTitan app credentials.
Unofficial — not affiliated with or endorsed by ServiceTitan, Inc. This is an independent, community-maintained connector. "ServiceTitan" is a trademark of its respective owner. See TRADEMARK.md.
Features
76 tools spanning CRM, jobs & appointments, pricebook, invoicing, estimates, dispatch, dispatch-pro, marketing, memberships, calls & forms, tasks, payroll, inventory, opportunities, and reporting — plus 6 cross-domain composites and one admin-only raw API gateway.
Bring your own credentials. No credentials are bundled. The Worker authenticates to ServiceTitan via OAuth 2.0 client-credentials using your ServiceTitan app, scoped to your tenant.
Write safety by default. State-changing tools use a two-phase
dryRun → confirmflow gated by an HMAC confirmation token. A single env var (WRITE_GATE=off) disables it;MCP_LOCKDOWN=trueforces the server fully read-only.MCP tool annotations (
readOnlyHint,destructiveHint,idempotentHint,openWorldHint) are emitted for every tool so clients can reason about effects.Built-in observability. Every call is audited to a Cloudflare D1 database (audit log + error log), with optional Analytics Engine metrics and admin inspection routes.
Per-endpoint-family rate limiting via a Durable Object, protecting your ServiceTitan API quota.
Inbound auth with a shared
X-Sync-Keyheader or an optional signed JWT.Runs at the edge on Cloudflare Workers with per-request MCP server isolation, built on the Cloudflare Agents SDK (
createMcpHandler) and the official@modelcontextprotocol/sdk(McpServer).
Related MCP server: OpenAPI MCP Server
Architecture
┌─────────────┐ Streamable HTTP ┌────────────────────────────┐
│ MCP client │ POST /mcp │ servicetitan-mcp │
│ (Claude, │ ───────────────────► │ (Cloudflare Worker) │
│ agents, │ X-Sync-Key / JWT │ │
│ scripts) │ ◄─────────────────── │ • createMcpHandler │
└─────────────┘ │ • 76 tools + annotations │
│ • write-gate (dryRun/HMAC) │
└──────────┬──────────────────┘
│
┌────────────────────────────────┼────────────────────────────┐
▼ ▼ ▼
┌──────────────────┐ ┌──────────────────────┐ ┌────────────────────┐
│ ServiceTitan API │ │ D1 (your account) │ │ Durable Object │
│ OAuth 2.0 │ │ audit_log / error_log│ │ per-endpoint-family│
│ client-creds │ │ + read cache │ │ rate limiter │
└──────────────────┘ └──────────────────────┘ └────────────────────┘Each MCP request gets an isolated McpServer instance. Read tools hit the ServiceTitan API (with optional caching); write tools route through the write-gate; every invocation is recorded to your own D1 database and, optionally, Analytics Engine.
Prerequisites
A ServiceTitan app. From the ServiceTitan developer portal, create an app and obtain:
a Client ID and Client Secret (OAuth 2.0 client-credentials),
an App Key,
your Tenant ID.
Scope the app to only the API areas you intend to use (least privilege).
A Cloudflare account with Workers enabled, plus
wranglerinstalled and authenticated.Node.js 18+ and
npm.
You provision your own Cloudflare D1 database and Durable Object bindings — see wrangler.toml for the binding names and replace the placeholder resource IDs with your own.
Quick start
# 1. Clone and install
git clone <your-fork-url> servicetitan-mcp
cd servicetitan-mcp
npm install
# 2. Set your ServiceTitan + inbound-auth secrets (never commit these)
wrangler secret put ST_CLIENT_ID
wrangler secret put ST_CLIENT_SECRET
wrangler secret put ST_APP_KEY
wrangler secret put MCP_SYNC_KEY
# 3. Edit wrangler.toml:
# - set ST_TENANT_ID under [vars]
# - replace the placeholder D1 database_id / DO bindings with your own
# 4. Run the test suite and type-check
npm test
npm run typecheck
# 5. Deploy
wrangler deployAfter deploy, confirm the Worker is live:
curl https://<your-worker>.workers.dev/healthOptional secrets — set only if you use the corresponding feature:
wrangler secret put JWT_SECRET # enable signed-JWT inbound auth
wrangler secret put ST_WEBHOOK_SECRET # enable HMAC-verified ServiceTitan webhook ingestRegistering with an MCP client
Point any Streamable-HTTP MCP client at https://<your-worker>/mcp and send your sync key in the X-Sync-Key header.
For Claude (in ~/.claude.json):
{
"mcpServers": {
"servicetitan": {
"type": "http",
"url": "https://<your-worker>.workers.dev/mcp",
"headers": {
"X-Sync-Key": "<your MCP_SYNC_KEY value>"
}
}
}
}If you enabled JWT_SECRET, you may instead send Authorization: Bearer <signed-JWT>.
Tool catalog
76 tools grouped by ServiceTitan domain. Tools marked write mutate state and pass through the write-gate (dryRun → confirm); everything else is read-only. st_call is admin-only.
CRM & customers
Tool | Purpose | Type |
| Search customers by name, phone, or email | read |
| Get a customer by ID | read |
| Get a customer by ID (thin wrapper) | read |
| List / search customers | read |
| List a customer's service locations | read |
| List a customer's jobs | read |
| Get a customer's memberships | read |
| Append a note to a customer record | write |
Jobs & appointments
Tool | Purpose | Type |
| Get a job by ID | read |
| List / search jobs | read |
| List jobs scheduled for today | read |
| List appointments for a job | read |
| List / search appointments | read |
| List configured job hold reasons | read |
| Book a new job | write |
| Reschedule an appointment | write |
| Place an appointment on hold | write |
| Assign technicians to an appointment | write |
| Append a note to a job | write |
Pricebook
Tool | Purpose | Type |
| Search across services, materials, and equipment | read |
| Search pricebook services | read |
| Search pricebook materials | read |
| Get full details for a service | read |
| List child variations of configurable equipment | read |
| List pricebook service categories | read |
| Generic pricebook fetch | read |
| Create a pricebook service | write |
| Update a pricebook service | write |
| Create a pricebook material | write |
| Update a pricebook material | write |
Invoicing
Tool | Purpose | Type |
| Get an invoice with line items and totals | read |
| List invoices for a job | read |
| Get an invoice's outstanding balance | read |
| List invoices with an outstanding balance | read |
Estimates
Tool | Purpose | Type |
| Get an estimate with line items and status | read |
| List estimates for a job | read |
| Mark an estimate sold | write |
| Revert a sold estimate to open | write |
| Dismiss an estimate | write |
Dispatch
Tool | Purpose | Type |
| Get dispatch capacity for business units over a range | read |
| Discover bookable capacity slots | read |
| List technicians available on a date | read |
| Get a technician's scheduled shifts | read |
| List non-job dispatch events (time-off, training) | read |
Dispatch Pro
Tool | Purpose | Type |
| List technician utilization metrics | read |
| List dispatch ratio metrics | read |
| List dispatch alerts | read |
Marketing
Tool | Purpose | Type |
| List marketing campaigns | read |
| Get campaign performance metrics | read |
| Create a call record attributed to a campaign | write |
Memberships
Tool | Purpose | Type |
| List active memberships | read |
| List memberships expiring within N days | read |
| Create a recurring service under a membership | write |
Calls & forms
Tool | Purpose | Type |
| Get a telecom call record | read |
| Get a form submission record | read |
Tasks
Tool | Purpose | Type |
| List open (incomplete) tasks | read |
| Create a task | write |
Payroll
Tool | Purpose | Type |
| List payrolls | read |
| List job timesheets | read |
| List non-job timesheets | read |
| List location pay rates | read |
| Get payroll settings | read |
Inventory
Tool | Purpose | Type |
| List inventory vendors | read |
| List warehouses | read |
| List inventory receipts | read |
| List inventory transfers | read |
Opportunities
Tool | Purpose | Type |
| List opportunities | read |
| Get an opportunity by ID | read |
Reporting
Tool | Purpose | Type |
| Run a ServiceTitan report and return rows | read |
Composites (cross-domain)
Tool | Purpose | Type |
| Full customer view: details, locations, jobs, memberships, estimates, invoices in one call | read |
| Margin analysis across jobs | read |
| Actual job costs (labor + materials) | read |
| Rank customers / memberships by value | read |
| Audit manual dispatch overrides | read |
| Feed of open opportunities | read |
Admin
Tool | Purpose | Type |
| Raw ServiceTitan API gateway (admin-only). GET reads; non-GET passes through the write-gate. | write (admin) |
Write safety
State-changing tools never mutate ServiceTitan in a single shot. They follow a two-phase flow:
dryRun(default). The tool validates inputs, builds the exact request it would send, and returns a preview plus a short-lived HMAC confirmation token. Nothing is written.Confirm. Call the tool again with
dryRun: falseand the returned token. The server verifies the token (HMAC over the request shape, time-bounded) and only then issues the write.
This makes accidental or hallucinated writes impossible without an explicit, verifiable second step.
The write-gate is on by default. Set
WRITE_GATE=off(var) to disable the two-phase flow.Set
MCP_LOCKDOWN=true(var) to force the server fully read-only — every write tool and the admin gateway are stripped from the catalog regardless ofWRITE_GATE.
Every tool also advertises MCP annotations so clients can pre-filter destructive operations:
Annotation | Meaning |
| Tool performs no writes |
| Tool may make irreversible changes |
| Repeated identical calls have no extra effect |
| Tool reaches an external system (always true here — the ServiceTitan API) |
Auth & roles
Inbound (client → Worker): every POST /mcp request must present either
an
X-Sync-Keyheader matching theMCP_SYNC_KEYsecret, oran
Authorization: Bearer <JWT>signed with the optionalJWT_SECRET.
Requests without valid credentials are rejected before any tool runs.
Roles determine which slice of the catalog a caller sees:
Role | Catalog |
| All tools except admin-only ( |
| Full catalog including |
| Read-only tools only (forced when |
Outbound (Worker → ServiceTitan): OAuth 2.0 client-credentials using your ST_CLIENT_ID / ST_CLIENT_SECRET / ST_APP_KEY against your ST_TENANT_ID. Tokens are obtained and refreshed by the Worker; no ServiceTitan credentials ever leave your infrastructure.
Observability & admin endpoints
All admin routes require the X-Sync-Key header.
Route | Purpose |
| Liveness probe + tool inventory |
| Effective role / catalog resolution |
| Tool-call summary from the audit log |
| Last-activity probe (detect telemetry silence) |
| Inventory of ServiceTitan endpoints each tool maps to |
| Pass/fail gate on endpoint-descriptor coverage |
| Optional HMAC-verified ServiceTitan webhook ingest (requires |
Every tool call is written to your D1 audit_log (and error_log on failure). If you bind an Analytics Engine dataset, per-call metrics are emitted there as well.
Configuration
Secrets (wrangler secret put)
Secret | Required | Purpose |
| yes | ServiceTitan OAuth client ID |
| yes | ServiceTitan OAuth client secret |
| yes | ServiceTitan app key |
| yes | Inbound shared key clients send as |
| no | Enables signed-JWT inbound auth |
| no | HMAC secret for |
Vars (wrangler.toml)
Var | Default | Purpose |
| — | Your ServiceTitan tenant ID |
|
| ServiceTitan environment: |
| — | Version string reported by |
|
| Set to |
|
| Set to |
Security
See SECURITY.md for the threat model, hardening guidance, supported versions, and how to report a vulnerability.
Contributing
Pull requests are welcome. See CONTRIBUTING.md for setup, tests, and how to add a tool.
License
MIT.
Trademark
See TRADEMARK.md. This project is an independent, unofficial connector and is not affiliated with or endorsed by ServiceTitan, Inc.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/lpeluso-dotcom/servicetitan-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server