Skip to main content
Glama
mcp-cliniko

mcp-cliniko

MCP Cliniko サーバー

医療機関向け管理システム「Cliniko」のAPIと連携するためのModel Context Protocol (MCP) サーバーです。

機能

ツール (アクション)

  • 患者管理

    • list_patients - 患者の検索と一覧表示

    • get_patient - IDによる患者情報の取得

    • create_patient - 新規患者の作成

    • update_patient - 患者詳細の更新

    • delete_patient - 患者のアーカイブ

  • 予約管理

    • list_appointments - 予約の検索と一覧表示

    • get_appointment - IDによる予約情報の取得

    • create_appointment - 新規予約の作成

    • update_appointment - 予約の変更

    • cancel_appointment - 予約のキャンセル

    • delete_appointment - 予約の削除

    • get_available_times - 施術者の空き状況の取得

  • 請求書管理

    • list_invoices - 請求書の一覧表示とフィルタリング

    • get_invoice - 請求書詳細の取得

    • create_invoice - 新規請求書の作成

    • update_invoice - 請求書のステータスや詳細の更新

    • delete_invoice - 下書き請求書の削除

  • 請求項目

    • list_invoice_items - 請求書内の項目一覧表示

    • add_invoice_item - 請求書への項目追加

    • update_invoice_item - 請求項目の変更

    • delete_invoice_item - 請求書からの項目削除

  • 支払い処理

    • list_payments - 支払いの一覧表示(フィルタリング可)

    • create_payment - 支払いの記録

    • delete_payment - 支払い記録の削除

  • 製品・サービス

    • list_products - 請求可能な製品/サービスの一覧表示

    • get_product - 製品詳細の取得

    • create_product - 新規製品/サービスの作成

  • 税設定

    • list_taxes - 利用可能な税率の一覧表示

    • get_tax - 税詳細の取得

  • 複雑なワークフロー

    • create_invoice_from_appointments - 予約から請求書を生成

    • bulk_invoice_generation - 指定期間の請求書を一括作成

    • list_patient_cases - 患者の症例一覧表示

    • list_invoices_for_case - 症例ごとの請求書取得

  • サポートツール

    • list_practitioners - 全施術者の一覧表示

    • list_appointment_types - 予約タイプの一覧表示

    • list_businesses - 事業所の一覧表示

  • テストデータ

    • generate_test_data - オーストラリアの医療データ(合成データ)の生成

    • cleanup_test_data - テスト用患者データの削除

リソース (データアクセス)

  • patient://{id} - 個別の患者データ

  • patients://list - 全患者

  • appointment://{id} - 個別の予約

  • appointments://list - 全予約

  • appointments://today - 今日の予約

  • practitioners://list - 全施術者

  • businesses://list - 全事業所

  • appointment-types://list - 全予約タイプ

  • openapi://spec - Cliniko API OpenAPI仕様 (YAML形式)

Related MCP server: Cliniko MCP Server

インストール

  1. リポジトリをクローンします:

git clone https://github.com/yourusername/mcp-cliniko.git
cd mcp-cliniko
  1. 依存関係をインストールします:

npm install
  1. Cliniko APIキーを設定します:

cp .env.example .env
# Edit .env and add your Cliniko API key
  1. プロジェクトをビルドします:

npm run build

設定

環境変数

  • CLINIKO_API_KEY - Cliniko APIキー (必須)

Cliniko APIキーの取得方法

  1. Clinikoアカウントにログイン

  2. 「Settings」→「Integrations」→「API Keys」へ移動

  3. 新しいAPIキーを作成

  4. キーを .env ファイルにコピー

使用方法

開発モード

npm run dev

本番モード

npm start

MCP Inspectorによるテスト

npm run inspect

Claude Desktopとの統合

Claude Desktopの設定ファイル (~/Library/Application Support/Claude/claude_desktop_config.json) に追加します:

{
  "mcpServers": {
    "cliniko": {
      "command": "node",
      "args": ["/path/to/mcp-cliniko/dist/index.js"],
      "env": {
        "CLINIKO_API_KEY": "your-api-key-here"
      }
    }
  }
}

例

ツールの使用

患者一覧:

{
  "tool": "list_patients",
  "arguments": {
    "q": "Smith",
    "per_page": 10
  }
}

患者作成:

{
  "tool": "create_patient",
  "arguments": {
    "first_name": "John",
    "last_name": "Doe",
    "email": "john.doe@example.com",
    "phone_number": "0412345678",
    "date_of_birth": "1980-01-15",
    "medicare_number": "1234567890"
  }
}

予約:

{
  "tool": "create_appointment",
  "arguments": {
    "starts_at": "2024-01-20T10:00:00Z",
    "patient_id": 123,
    "practitioner_id": 456,
    "appointment_type_id": 789,
    "business_id": 101
  }
}

テストデータ生成:

{
  "tool": "generate_test_data",
  "arguments": {
    "num_patients": 5,
    "num_appointments": 10,
    "days_ahead": 7
  }
}

リソースの使用

リソースはClinikoデータへの読み取り専用アクセスを提供します:

  • patient://123 - ID 123の患者を取得

  • patients://list - 全患者を一覧表示

  • appointments://today - 今日の予約を取得

APIレート制限

Cliniko APIのレート制限は1分間に200リクエストです。サーバー内部でレート制限の実装は行っていないため、一括操作を行う際はこの制限にご注意ください。

エラーハンドリング

サーバーは標準的なHTTPエラー規則を使用します:

  • 400 - 不正なリクエスト

  • 401 - 認証失敗 (APIキーを確認してください)

  • 404 - リソースが見つかりません

  • 429 - レート制限超過

  • 500 - サーバー内部エラー

開発

プロジェクト構造

mcp-cliniko/
├── src/
│   ├── index.ts              # Main server
│   ├── cliniko-client.ts     # API client
│   ├── types.ts              # TypeScript types
│   ├── tools/                # MCP tools
│   │   ├── patients.ts
│   │   ├── appointments.ts
│   │   └── synthetic-data.ts
│   └── resources/            # MCP resources
│       └── index.ts
├── dist/                     # Compiled JavaScript
├── package.json
├── tsconfig.json
└── .env

ビルド

npm run build

型チェック

npx tsc --noEmit

ライセンス

MIT

サポート

Cliniko APIのドキュメントについては、以下を参照してください: https://docs.api.cliniko.com/

MCPのドキュメントについては、以下を参照してください: https://modelcontextprotocol.io/

Available Tools

27 tools
cancel_appointmentC

Cancel an appointment

Inputs: appointment_id (required), cancellation_reason.

cleanup_comprehensive_test_dataC

Clean up all test data with granular control and dry-run option

Inputs: delete_patients, delete_appointments, delete_invoices, delete_products, +3 more.

cleanup_test_dataA

Delete all test patients (patients with emails ending in @gmail.com, @outlook.com, etc)

Inputs: no named parameters.

create_appointmentC

Create a new appointment

Inputs: starts_at (required), practitioner_id (required), appointment_type_id (required), business_id (required), +2 more.

create_patientC

Create a new patient

Inputs: first_name (required), last_name (required), title, preferred_name, +12 more.

delete_appointmentC

Delete an appointment completely

Inputs: appointment_id (required).

delete_patientA

Delete (archive) a patient

Inputs: patient_id (required).

demo_invoice_generationA

Demo: Generate test patients and appointments, then show how to create invoices. NOTE: Cliniko API is READ-ONLY for invoices - they must be created via the web interface.

Inputs: target_date, num_patients, num_appointments, clear_existing, +1 more.

display_invoices_for_dateB

Display all existing invoices for a specific date (READ-ONLY). Invoices must be created manually in Cliniko.

Inputs: target_date (required), display_format.

generate_comprehensive_test_dataB

Generate comprehensive synthetic test data across all Cliniko categories

Inputs: num_patients, num_contacts, num_relationships, num_appointments, +11 more.

generate_test_dataB

Generate synthetic test data for Cliniko (Australian healthcare data)

Inputs: num_patients, num_appointments, days_ahead.

get_appointmentC

Get a specific appointment by ID

Inputs: appointment_id (required).

get_appointment_invoicesA

Get invoices for a specific appointment (READ-ONLY)

Inputs: appointment_id (required).

get_available_timesC

Get available appointment times for a practitioner

Inputs: business_id (required), practitioner_id (required), from (required), to (required).

get_invoiceA

Get details of a specific invoice (READ-ONLY)

Inputs: invoice_id (required).

get_patientC

Get a specific patient by ID

Inputs: patient_id (required).

get_patient_invoicesA

Get invoices for a specific patient (READ-ONLY)

Inputs: patient_id (required).

how_to_create_invoicesB

Get instructions on how to create invoices in Cliniko (manual process)

Inputs: no named parameters.

list_appointmentsC

List or search for appointments

Inputs: patient_id, practitioner_id, business_id, starts_at, +4 more.

list_appointment_typesB

List all appointment types

Inputs: page, per_page.

list_businessesB

List all businesses

Inputs: no named parameters.

list_invoice_itemsB

List items in an invoice (READ-ONLY)

Inputs: invoice_id (required).

list_invoicesB

List invoices with filtering options (READ-ONLY - invoices must be created in Cliniko web interface)

Inputs: page, per_page, patient_id, practitioner_id, +3 more.

list_patientsC

List or search for patients

Inputs: q, page, per_page.

list_practitionersC

List all practitioners

Inputs: page, per_page.

update_appointmentC

Update an existing appointment

Inputs: appointment_id (required), starts_at, notes, patient_id.

update_patientC

Update an existing patient

Inputs: patient_id (required), first_name, last_name, title, +13 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 27 tools

    Disambiguation4/5

    Most tools target distinct resources (patients, appointments, invoices) with clear purposes. However, cleanup_test_data and cleanup_comprehensive_test_data are very similar, and demo_invoice_generation overlaps with how_to_create_invoices in providing guidance.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun pattern in snake_case (e.g., create_patient, list_appointments, delete_patient). No mixing of styles or ambiguous verbs.

    Tool Count3/5

    27 tools is slightly high for a healthcare practice server. Multiple test data generation and cleanup tools add redundancy, and several invoice tools are read-only due to API limitations, reducing effective utility. A more streamlined set (around 15-20) would be better.

    Completeness4/5

    CRUD operations are covered for patients and appointments, along with listings and searches. Invoice operations are read-only but acknowledged. Missing features like appointment notes or patient tags are minor given the domain focus.

    Maintenance

    ActivityInactive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables interaction with Athena Health's API for comprehensive healthcare practice management. Supports appointment scheduling, provider and department management, patient search, and available slot discovery through natural language.
      -
    • F
      license
      Not graded
      quality
      D
      maintenance
      Enables integration with the Cliniko practice management system through MCP tools and resources. Supports patient management, appointment scheduling, and practice data access through natural language interactions.
      -
    • F
      license
      Not graded
      quality
      C
      maintenance
      Exposes tools from the Ecuro Light API for managing clinical appointments, patient records, and clinic availability. It enables users to perform healthcare management tasks such as scheduling, patient search, and report generation through MCP-compatible clients.
      -
    • A
      license
      B
      quality
      C
      maintenance
      Provides comprehensive integration with the Cliniko API for healthcare practice management, including patient, appointment, and invoice administration. It enables tools for complex clinical workflows and direct access to practice resources through the Model Context Protocol.
      27
      2
      MIT