rcm-mcp
Healthcare Revenue Cycle Management (RCM) Multi-Agent MCP Server
AIネイティブなマルチエージェントRevenue Cycle Management (RCM) MCPサーバーで、適格性確認、事前承認、および共有推論トレースを実装し、Supabaseとpgvectorをバックエンドとしています。
アーキテクチャ概要
┌────────────────────────────┐
│ RCM Multi-Agent System │
│ (Eligibility / PriorAuth)│
└─────────────┬──────────────┘
│ (SSE / HTTP / stdio)
┌─────────────▼──────────────┐
│ FastMCP Server (Port 8000)│
│ trace.* | eligibility.* │
│ priorauth.* │
└─────────────┬──────────────┘
│
┌──────────────────────┴──────────────────────┐
▼ ▼
┌────────────────────────┐ ┌────────────────────────┐
│ Supabase Relational │ │ pgvector / Semantic │
│ (Payers, Coverage, │ │ (Historical Clinical │
│ Rules, Traces) │ │ Precedents & Cases) │
└────────────────────────┘ └────────────────────────┘Related MCP server: mymedi-ai-mcp-server
1. Supabaseデータベースのセットアップ
ステップ1.1: Supabaseプロジェクトを作成する
Supabaseにログインし、新しいプロジェクトを作成します。
プロジェクト設定 -> データベースで、プロジェクトURLとAPIキー(
anonまたはservice_role)を確認します。
ステップ1.2: pgvectorを有効にしてスキーマを適用する
SupabaseダッシュボードでSQLエディタを開きます。
supabase/schema.sqlの内容をコピーして貼り付け、実行します:vector拡張機能を有効にします(CREATE EXTENSION IF NOT EXISTS vector;)。テーブルを作成します:
payers、appointments、patient_coverage、benefit_accumulators、payer_pa_rules、pa_requests、agent_trace(追記専用)、およびescalations。match_pa_casesコサイン類似度ベクトル検索関数を作成します。
ステップ1.3: シードデータを読み込む
以下のいずれかの方法で、Supabaseに合成データをシードできます。
オプションA(Pythonシーダースクリプト):
.envにSUPABASE_URLとSUPABASE_KEYを設定したら:
python seed_data.pyオプションB(SQLエディタ):
SQLエディタで、supabase/seed.sqlの内容をコピーして貼り付け、実行します。
これにより、以下がシードされます:
5つの支払者: Aetna Commercial、Blue Cross Blue Shield、UnitedHealthcare、Medicare Part B、Cigna。
5つの予約: 対象サービス日(DOS)を含む予定された訪問。
適用範囲レコード: エッジケーステスト用の有効なポリシーと終了したポリシー。
給付累積: 特定のCPTコードに対する控除額、自己負担金、共同保険。
PAルールと先例: 事前承認ガイドラインと、埋め込みを含む過去のケース。
2. 環境設定
.env.exampleを.envにコピーします:
cp .env.example .env.envファイルを自分の認証情報で更新します:
# Supabase Configuration
SUPABASE_URL=https://<your-project-ref>.supabase.co
SUPABASE_KEY=<your-supabase-service-role-or-anon-key>
# Server Configuration
MCP_SERVER_HOST=0.0.0.0
MCP_SERVER_PORT=8000
# Optional Embedding Key
OPENAI_API_KEY=3. インストール
プロジェクトの依存関係をインストールします:
pip install -r requirements.txt4. MCPツールリファレンス
A. 共有トレースツール(trace.*)
すべてのエージェントで使用され、追記専用で監査可能な意思決定ログを維持します。
ツール名 | 説明 | 主な入力 | 出力 |
| トレースログに意思決定レコードを追加します |
|
|
| エンカウンターの時系列の意思決定履歴を取得します |
|
|
| 人間の監督者によるレビューのためにケースをキューに入れます |
|
|
B. 適格性ツール(eligibility.*)
実際の予約サービス日(DOS)における患者の適用範囲を検証し、患者の費用を見積もります。
ツール名 | 説明 | 主な入力 | 出力 |
| 対象サービス日に対して有効なポリシー期間を検証します |
|
|
| 累積残高を取得します |
|
|
| 検出された適用範囲のギャップをトレースに記録します |
|
|
C. 事前承認ツール(priorauth.*)
手順ルールの検索、先例の検索、および臨床的正当性の提出を自動化します。
ツール名 | 説明 | 主な入力 | 出力 |
| 手順コードが事前承認を必要とするかどうかを確認します |
|
|
| 臨床的正当性を提出し、ステータスを受け取ります |
|
|
| 提出された承認ステータスをポーリングします |
|
|
| 過去のPAケースに対するセマンティックベクトル検索 |
|
|
5. MCPサーバーの実行
オプションA: SSEトランスポート(デフォルト)
Server-Sent Events(SSE)を介してFastMCPサーバーを起動します:
python run_server.pySSEエンドポイントは
http://localhost:8000/sseで利用可能になります。
オプションB: カスタムホスト/ポートまたはStdio
トランスポートパラメータを直接カスタマイズできます:
# Run over stdio (e.g. for Claude Desktop / CLI clients)
python src/mcp_server/server.py --transport stdio
# Run over SSE on custom port
python src/mcp_server/server.py --transport sse --port 80806. テストと検証
pytestでテストスイートを実行します:
pytest tests/期待される出力:
tests\test_mcp_tools.py .......... [100%]
============================= 10 passed in 0.07s ==============================7. エージェントクライアントへの接続
Claude Desktopの設定
claude_desktop_config.jsonに以下を追加します:
{
"mcpServers": {
"rcm-server": {
"command": "python",
"args": ["<path-to-repo>/src/mcp_server/server.py", "--transport", "stdio"]
}
}
}Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
No tool schema history has been recorded yet.
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.
Related MCP Connectors
Deterministic compliance and vertical knowledge bases for autonomous agents. Free 24hr trial.
AI routing, memory, guardrails, and governance. Routes across Claude, GPT, Gemini.
Build agents to automate any background task. Works with your ChatGPT/Claude subscription.
Enterprise AI Control Plane: governance, guardrails, spend tracking, compliance & smart routing.
Related MCP Servers
- AlicenseAqualityDmaintenanceEnables LLM-based agents to interact with FHIR healthcare data through natural language prompts, providing full CRUD operations on FHIR resources, document processing, and semantic search capabilities.1398MIT
- AlicenseAqualityBmaintenanceHealthcare billing AI for agents — 12 tools for ICD-10/CPT/HCPCS code lookup (80K+ codes), prior auth prediction, medical NER, claims validation, HIPAA compliance auditing, and provider/drug enrichment. Pay-per-call via credits or USDC.202182MIT
- FlicenseNot gradedqualityDmaintenanceEnd-to-end Prior Authorization decision-support system with a multi-agent AI pipeline, MCP Tool Registry, and PostgreSQL backend.1-
- AlicenseAqualityCmaintenanceEnables AI assistants to look up medical billing codes, denial reasons, and payer rules for faster claim resolution.66MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/mr-rsr/rcm-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server