# MCP Server 🏥

Streamline insurance workflows with AI assistance through the Model Context Protocol (MCP). Connect Claude to your healthcare systems for automated insurance card scanning, eligibility verification, and claims contact extraction.

## Introduction

The Healthcare MCP Server provides HIPAA-compliant AI assistance for common healthcare administrative tasks. By connecting Claude to CardScan.ai's proven insurance processing APIs, healthcare practices can reduce manual verification work and streamline patient intake workflows.

**Key Benefits:**

* **Reduce Manual Work**: Automate insurance verification and card data extraction
* **HIPAA Compliant**: Secure processing with enterprise-grade data protection
* **Real-time Results**: Instant eligibility checks and benefit information
* **Proven Accuracy**: Built on CardScan.ai's battle-tested ML pipeline

**Target Audience:**

* Healthcare practices and billing departments
* Healthcare technology integrators
* Medical practice management systems
* Revenue cycle management companies

## Use Cases & Workflows

### Real-time Eligibility Verification

{% @mermaid/diagram content="sequenceDiagram
participant User
participant Claude
participant Healthcare MCP
participant CardScan API

```
User->>Claude: "Check eligibility for John Doe, member ID 12345"
Claude->>Healthcare MCP: eligibility_lookup()
Healthcare MCP->>CardScan API: POST /eligibility
CardScan API-->>Healthcare MCP: Coverage details
Healthcare MCP-->>Claude: Structured eligibility data
Claude-->>User: "John has active PPO coverage, $500 deductible remaining, 20% coinsurance for office visits..."" %}
```

**Business Impact**: Staff can instantly verify patient coverage without logging into multiple insurance portals, reducing verification time from 5-10 minutes to under 30 seconds.

### Insurance Card Scanning & Contact Extraction

{% @mermaid/diagram content="sequenceDiagram
participant User
participant Claude
participant Healthcare MCP
participant CardScan API

```
User->>Claude: "Extract claims phone number from this insurance card"
Claude->>Healthcare MCP: extract_card_info(image_url)
Healthcare MCP->>CardScan API: POST /cards
Healthcare MCP->>CardScan API: POST /cards/{id}/upload
CardScan API-->>Healthcare MCP: Extracted card data
Healthcare MCP-->>Claude: Claims phone: (800) 555-0123
Claude-->>User: "Claims contact: Aetna Claims (800) 555-0123"
Note over User: Can immediately call or save contact" %}
```

**Business Impact**: Eliminates manual card data entry and reduces phone number lookup time. Perfect for prior authorization calls and claims inquiries.

### Patient Card Update Requests

{% @mermaid/diagram content="sequenceDiagram
participant User
participant Claude
participant Healthcare MCP
participant CardScan API
participant Patient

```
User->>Claude: "Jane's insurance card expired, send her an update link"
Claude->>Healthcare MCP: create_card_update_link(patient_id)
Healthcare MCP->>CardScan API: POST /generate-magic-link
CardScan API-->>Healthcare MCP: Secure upload URL
Healthcare MCP-->>Claude: Generated secure link
Claude-->>User: "Sent Jane a secure link to upload her new card"
Claude->>Patient: SMS/Email with upload link
Note over Patient: Uploads new card securely" %}
```

**Business Impact**: Streamlines patient card collection with secure, time-limited upload links. Reduces staff phone calls and improves patient experience.

## Available Tools & Resources

### Core Tools

#### `eligibility_lookup`

Real-time insurance eligibility verification with comprehensive benefit details.

**Parameters:**

* `member_id` (string, required): Insurance member identification number
* `subscriber_first_name` (string, required): Primary member first name
* `subscriber_last_name` (string, required): Primary member last name
* `date_of_birth` (string, required): Format YYYYMMDD (e.g., "19850315")
* `provider_npi` (string, required): 10-digit National Provider Identifier
* `provider_name` (string, optional): Provider first/last name or organization name
* `service_codes` (array, optional): Specific medical service codes to check

**Returns:**

* Coverage status (active/inactive)
* Deductible information (individual/family, remaining amounts)
* Co-pay amounts by service type
* Co-insurance percentages
* Out-of-pocket maximums
* Prior authorization requirements
* Network status for provider

#### `extract_card_info`

Scan insurance cards and extract structured data including contact information.

**Parameters:**

* `image_url` (string, required): URL of insurance card image (front/back)
* `enable_backside_scan` (boolean, optional): Process both card sides for complete data
* `enable_payer_match` (boolean, optional): Match to canonical payer database

**Returns:**

* Member information (name, ID, DOB, gender)
* Payer details (name, address, phone numbers)
* Plan information (group number, plan name, effective dates)
* Prescription details (BIN, PCN, issuer, plan)
* Claims contact phone numbers
* Customer service contacts
* Confidence scores for each extracted field

#### `create_card_update_link`

Generate secure, time-limited upload links for patients to submit new insurance cards.

**Parameters:**

* `patient_identifier` (string, required): Internal patient ID or email
* `expiration_hours` (integer, optional): Link expiration time (default: 24 hours, max: 168)
* `notification_method` (string, optional): "email" or "sms" for automated delivery
* `custom_message` (string, optional): Personalized message for the patient

**Returns:**

* Secure upload URL (single-use)
* Expiration timestamp
* Magic link identifier for tracking
* Optional notification confirmation

#### `search_member_cards`

Find existing insurance card records by member information or payer details.

**Parameters:**

* `query` (string, required): Search term (member name, payer name, member ID)
* `limit` (integer, optional): Maximum results to return (default: 20, max: 100)
* `date_range` (object, optional): Filter by card scan date
  * `start_date` (string): ISO date format
  * `end_date` (string): ISO date format

**Returns:**

* Array of matching card records
* Card metadata (scan date, processing state)
* Basic member and payer information
* Card IDs for detailed data retrieval

### Available Resources

#### `eligibility/recent`

Browse recent eligibility verification requests across your account.

**Access Pattern:** List recent verifications with pagination support.

#### `eligibility/by_patient/{patient_id}`

Retrieve eligibility verification history for a specific patient.

**Access Pattern:** Get all eligibility checks for a given patient identifier.

#### `card_scans/pending`

Monitor insurance card uploads currently being processed.

**Access Pattern:** Check status of pending card scans and processing queue.

## Getting Started

### Prerequisites

Before integrating the Healthcare MCP Server, ensure you have:

* **HIPAA Compliance**: Your organization must have appropriate HIPAA safeguards in place
* **CardScan.ai Account**: Active account with eligibility verification feature enabled
* **Provider Information**: National Provider Identifier (NPI) for your practice
* **Patient Demographics**: Basic patient information for eligibility requests

{% hint style="info" %}
**NPI Lookup**: Find provider NPIs using the [NPPES NPI Registry](https://npiregistry.cms.hhs.gov/search).
{% endhint %}

### Integration Overview

The Healthcare MCP Server acts as a secure bridge between Claude and CardScan.ai's healthcare APIs:

1. **Authentication**: Server-side API key management with JWT token generation
2. **Data Processing**: HIPAA-compliant handling of protected health information
3. **Real-time Updates**: WebSocket notifications for eligibility and card processing status
4. **Error Handling**: Healthcare-specific error codes and retry logic

### Security & Compliance

* **HIPAA Compliance**: All data processing follows HIPAA requirements
* **Encryption**: End-to-end encryption for all PHI transmission
* **Access Controls**: Role-based access with audit logging
* **Data Retention**: Configurable retention policies for different data types

### Contact for Access

The Healthcare MCP Server is currently in limited preview. To request access:

**Contact the CardScan team** for integration details, pricing, and deployment assistance.

* Include your use case and expected volume
* Specify any custom requirements or integrations needed
* We'll work with you to set up a pilot deployment

{% hint style="success" %}
**Early Access**: We're actively seeking healthcare partners to help refine the MCP server capabilities. Contact us to discuss pilot opportunities.
{% endhint %}

## Example Integration

Here's how the MCP server integrates with your existing workflow:

```python
# Example: Staff uses Claude for eligibility check
claude_query = """
Check eligibility for Sarah Johnson, DOB 03/15/1985, 
member ID SJ123456789, using our main NPI 1234567890.
"""

# MCP server handles the API calls automatically
# Returns formatted eligibility summary in natural language
```

The MCP server abstracts away API complexity while providing rich, structured healthcare data that Claude can interpret and present in user-friendly formats.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cardscan.ai/ai-and-automation/healthcare-mcp-server.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
