AutoFYI MCP
Click on "Deploy 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., "@AutoFYI MCP search for client Acme Ltd and show recent invoices"
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.
AutoFYI MCP
A standalone, safety-first MCP server over the existing AutoFYI REST API at
https://autofyi.kellyautomations.com.
It does not import, modify, or replace the current AutoFYI backend or frontend. Claude runs this project locally over stdio; this project calls the deployed API over HTTPS.
Safety contract
Financial writes are disabled by default.
Search scores rank candidates only. Claude compares names, proposes a likely non-exact match, and asks the user to confirm its stable client ID.
Ltd,Limited, punctuation, case, and extra spaces are normalized for comparison.Every allocation request contains exactly one complete service/job type. It never mixes monthly, weekly, VAT, annual, or subscription work.
Live months are classified before writes; partially allocated months are never re-split.
Every write is a two-stage operation:
prepare_*thenexecute_confirmed_action.Preparing reads current FYI jobs/interims, validates the exact payload, and returns a single-use confirmation ID plus the exact phrase the user must provide.
The executor accepts only the stored payload; it cannot be changed during execution.
Confirmations expire after 10 minutes by default and cannot be replayed.
Draft invoices are the default. Approval uses a stronger confirmation phrase.
Write failures and timeouts are never automatically retried.
Prepared allocations.lines are the operational source of truth for service NET amounts,
matching the existing frontend. Raw xero_invoices are supporting information and a source
for warnings; the server does not blindly overwrite prepared allocations from raw Xero data.
Related MCP server: expense-tracker-mcp-server
Install
cd /Users/saiganeshreddykodekandla/Documents/automatefyi/AutoFYI-MCP
cp .env.example .env
uv sync --extra dev
uv run autofyi-mcp-smoke
uv run pytestThe smoke command reads only /health and /openapi.json. It never calls a write endpoint.
Start the MCP manually:
uv run autofyi-mcpAn stdio MCP normally appears to wait silently. That is correct: it is waiting for an MCP client and writes protocol data only to stdout. Logs go to stderr.
Connect Claude Code
claude mcp add --transport stdio --scope user \
--env AUTOFYI_API_BASE=https://autofyi.kellyautomations.com \
--env AUTOFYI_ENABLE_WRITES=false \
autofyi -- /opt/homebrew/bin/uv --directory \
/Users/saiganeshreddykodekandla/Documents/automatefyi/AutoFYI-MCP \
run autofyi-mcpVerify with:
claude mcp get autofyi
claude mcp listInside Claude Code, run /mcp and ask:
Check AutoFYI health, then search for client Example Limited.
Do not make any financial changes.Connect Claude Desktop
Add this entry to the Claude Desktop MCP configuration and restart Claude Desktop:
{
"mcpServers": {
"autofyi": {
"type": "stdio",
"command": "/opt/homebrew/bin/uv",
"args": [
"--directory",
"/Users/saiganeshreddykodekandla/Documents/automatefyi/AutoFYI-MCP",
"run",
"autofyi-mcp"
],
"env": {
"AUTOFYI_API_BASE": "https://autofyi.kellyautomations.com",
"AUTOFYI_ENABLE_WRITES": "false"
}
}
}
}Use the full uv path because desktop applications may not inherit the terminal PATH.
Host on Render (shared team server)
The MCP server can run on Render over Streamable HTTP so the whole team connects to one URL. The AutoFYI backend (Playwright + FYI browser session) stays on the local machine behind the Cloudflare tunnel; Render only hosts this MCP layer in front of it.
Team Claude clients ──HTTPS──> Render (this MCP) ──HTTPS──> Cloudflare tunnel ──> local backend ──> FYIDeploy with the render.yaml blueprint; full steps, operating rules, and
troubleshooting are in docs/DEPLOY.md. The team endpoint is
https://<service>.onrender.com/mcp, protected by per-teammate bearer tokens
(AUTOFYI_MCP_AUTH_TOKENS). Per-client connection instructions — Claude Desktop, Claude
Code, Cursor, claude.ai web, ChatGPT — are in docs/HOST.md.
Enabling financial writes
Do this only after read-only testing and access protection are complete:
AUTOFYI_ENABLE_WRITES=trueRestart the MCP process after changing the environment. A confirmation prepared before the restart is intentionally lost and must be prepared again from fresh FYI information.
If Cloudflare Access is added later, the server supports service-token headers:
AUTOFYI_CF_ACCESS_CLIENT_ID=...
AUTOFYI_CF_ACCESS_CLIENT_SECRET=...It also supports an optional backend bearer token through AUTOFYI_API_TOKEN.
Documentation
The examples are illustrative only. The MCP always re-reads the selected client's actual information, prepared allocations, FYI jobs, and interim rows instead of depending on an example name, amount, tag, month, or job convention.
Client catalog analytics
The AutoFYI backend can publish a validated FYI CSV snapshot as an additive SQLite read model. This does not replace or modify the existing client JSON files, Xero invoices, allocations, frontend state, or browser automation.
get_client_catalog_statusreports the active snapshot.describe_client_cataloglists safe columns and their distinct counts. Ask for one column to receive at most its 10 most common values;values_truncated=trueis not exhaustive.query_client_catalogsupports structuredcount,list,distinct,group_count, and numericsummaryoperations. It never accepts raw SQL.Catalog answers describe the imported FYI snapshot. They do not prove that a live FYI job or an unallocated interim exists.
CSV import belongs entirely to the AutoFYI backend. Open its Swagger UI, use
POST /catalog/import, choose the complete FYI CSV, and click Execute. Each successful upload
validates the file and atomically replaces the backend SQLite catalog. MCP never reads or uploads
local CSV files; it only calls the hosted status, schema, and query endpoints.
Available Tools
18 toolsautofyi_healthARead-onlyIdempotent
Check whether the deployed backend and its FYI browser session are reachable. Makes no changes.
Inputs: no named parameters.
cancel_prepared_actionAIdempotent
Cancel a prepared action locally. No request is sent to AutoFYI or FYI.
Inputs: confirmation_id (required).
describe_autofyiARead-onlyIdempotent
Explain the AutoFYI business rules, safe tool order, and deliberately excluded admin endpoints.
Inputs: no named parameters.
describe_client_catalogBRead-onlyIdempotent
Describe queryable FYI CSV columns. Request one column for up to 10 common values; truncated is not exhaustive.
Inputs: column, include_common_values.
execute_confirmed_actionADestructive
Execute exactly one prepared financial write. Call only after the user supplies the exact preview phrase; never retry.
Inputs: confirmation_id (required), user_confirmation (required).
find_clientARead-onlyIdempotent
Load one strict identical client name; otherwise return ranked candidates for AI review and user confirmation.
Inputs: query (required), detail_level.
get_client_catalog_statusARead-onlyIdempotent
Check whether an FYI CSV catalog is published and report its version, age, rows, and columns.
Inputs: no named parameters.
get_client_informationARead-onlyIdempotent
Read a selected client's FYI information, Xero templates, and prepared allocations. Use full only when necessary.
Inputs: client_id (required), detail_level.
get_client_jobs_to_invoiceARead-onlyIdempotent
Read the live FYI jobs available to invoice and their work amounts. Browser-driven and may take minutes.
Inputs: client_id (required).
get_jobs_and_interim_tableBRead-onlyIdempotent
Read live FYI jobs plus billing-job interim dates and amounts. Makes no FYI changes but may take minutes.
Inputs: client_id (required).
get_prepared_actionARead-onlyIdempotent
Re-read an unexpired prepared action or retrieve its completed result. Never executes it.
Inputs: confirmation_id (required).
inspect_client_billing_stateARead-onlyIdempotent
Classify selected live FYI months as unsplit, split, partially allocated, ambiguous, missing, or inconsistent.
Inputs: months (required), client_id (required), invoice_key.
plan_client_billingARead-onlyIdempotent
Build a no-write billing plan from client/Xero/allocation information and identify the next safe live check.
Inputs: client_id (required), target_year (required), target_month (required), invoice_key.
prepare_direct_invoiceARead-only
Prepare a no-interim direct invoice. Repeating clients are blocked unless the duplicate-billing override is explicit.
Inputs: jobs (required), client_id (required), theme, invoice_type, +3 more.
prepare_interim_splitBRead-only
Validate live FYI interims and prepare—but do not execute—a permanent full-invoice service split.
Inputs: client_id (required), target_year (required), target_month (required), invoice_key.
prepare_job_allocationARead-only
Prepare one complete service-type allocation. Merge that service's months/jobs; never mix service types.
Inputs: jobs (required), months (required), client_id (required), service_line (required), +5 more.
query_client_catalogARead-onlyIdempotent
Safely count/filter/group the imported FYI client snapshot. Structured operations only—never raw SQL or live-job claims.
Inputs: operation (required), limit, offset, columns, +2 more.
search_clientsARead-onlyIdempotent
Rank client candidates. Claude compares names, proposes a likely non-exact match, and asks the user to confirm.
Inputs: query (required), limit.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 18 tools
Most tools have distinct purposes, but search_clients and find_client both handle client lookup with ranked candidates, and get_client_jobs_to_invoice and get_jobs_and_interim_table overlap in reading live FYI jobs. Descriptions help clarify the differences, but an agent could still misselect in some situations.
Tool names generally follow a consistent verb_noun pattern (describe_, get_, prepare_, etc.), with only autofyi_health deviating from the pattern. Minor inconsistencies like singular vs plural (client vs clients) are present but do not cause confusion.
At 18 tools, the set is slightly above the ideal 3-15 range, but each tool serves a distinct step in the billing workflow—from discovery and planning to preparation and execution. The count is justified by the complexity of the domain and the safe execution paradigm.
The tool set covers the full lifecycle for the intended use case: reading client data, inspecting billing state, planning, preparing, canceling, and executing actions. Obvious gaps include a lack of a tool to list all prepared actions, but the core workflows are well covered.
Maintenance
Related MCP Connectors
Authority, mandate, and policy checks for AI finance with replayable evidence. Not live execution.
Read-only finance and operations controls for AI agents with evidence and safe next actions.
Ask your AI about your own accounts, debts, budgets and goals. OAuth sign-in, read-only by default.
Pre-spend firewall for AI agents. Approves, blocks, flags transactions against policy rules.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables secure interaction with billing systems through comprehensive PII/PCI redaction, field allowlisting, and multi-layer security controls. Protects sensitive financial data while providing LLMs safe access to account, subscription, and invoice information.-
- FlicenseNot gradedqualityDmaintenanceEnables users to manage personal finances using natural language, including tracking expenses, income, budgets, and generating financial summaries.-
- FlicenseNot gradedqualityCmaintenanceEnables secure, read-only analytical querying of financial data through natural language, with built-in SQL injection defense and automatic query repair.-
- AlicenseNot gradedqualityBmaintenanceEnables AI assistants to carry out PayPal payments, invoice recordings, and refunds through a fail-closed firewall that enforces spending limits and trusted recipients, cross-checks requests against account records, and screens for prompt injection. Unusual or unverifiable requests are halted and escalated to a human for approval before any execution.MIT