Medicaid MCP Server
The Medicaid MCP Server provides programmatic access to public Medicaid data including state formularies, drug pricing, enrollment trends, and utilization statistics for analysis and decision-making.
Core Capabilities:
State Formulary Access: Search drug formularies for California, New York, Ohio, Texas, and Illinois (163K+ drugs, covering 43% of US Medicaid beneficiaries) with filters for NDC codes, prior authorization requirements, cost tiers, preferred drug status, step therapy, and program eligibility. Includes automatic NADAC pricing integration and cross-state NDC enrichment for Illinois (61.7% coverage).
Drug Pricing Intelligence: Access National Average Drug Acquisition Costs (NADAC) for 1.5M NDC codes with weekly updates, Federal Upper Limits for generic drug maximum reimbursements (2.1M records), and multi-drug price comparisons with date range and price threshold filtering.
Enrollment & Demographics: Track monthly Medicaid/CHIP enrollment trends across all 50 states and territories with multi-state comparisons and filtering by enrollment type (total, Medicaid, CHIP, adult, child segments).
Drug Rebate & Utilization: Access manufacturer product information and rebate agreements (~3M records) with filtering by labeler or drug name and year. Query state prescription volume by drug and quarter (5.3M records) to analyze prescribing patterns.
Dataset Discovery: Browse available datasets and execute custom queries using Socrata Query Language (SoQL) WHERE clauses with flexible pagination (up to 5,000 records).
Performance Features: Hybrid architecture with in-memory caching for frequently accessed data (<100ms response), streaming API for large datasets (1-2s), low memory footprint (~215 MB), and automatic data refresh (weekly/monthly/quarterly).
Use Cases: Market access strategy, pricing intelligence, policy analysis, economic forecasting, and state-level aggregate analysis (not provider-level data).
Uses DuckDB to query provider-level Medicaid claims data from local Parquet files, enabling high-performance analysis of HCPCS codes, NPI-specific spending, and service summaries.
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., "@Medicaid MCP Serversearch for Ozempic in California formulary"
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.
Unofficial Medicaid MCP Server
Model Context Protocol (MCP) server for Medicaid public data access via data.medicaid.gov and state formularies
Features
State Formulary Coverage
Access Medicaid formularies for 5 states covering 43% of US Medicaid beneficiaries (32M of 74M):
California - 40K drugs with NDC codes, prior authorization requirements, tier-based pricing
New York - 37K drugs with MRA pricing, daily updates, preferred drug lists
Ohio - 76K drugs with comprehensive step therapy and quantity limit data
Texas - 4.7K drugs with multi-program pricing (Medicaid, CHIP, specialty programs)
Illinois - 5.7K drugs with intelligent cross-state NDC enrichment (61.7% coverage)
Pricing & Utilization Data
NADAC Drug Pricing - National average drug acquisition costs (1.5M NDCs, weekly updates)
Federal Upper Limits - Generic drug maximum reimbursement (2.1M records, monthly updates)
Drug Rebate Program - Manufacturer product information and rebate agreements (~3M records)
State Drug Utilization - Prescription volume by state, drug, and quarter (5.3M records)
Enrollment Trends - Monthly Medicaid/CHIP enrollment by state (all 50 states + territories)
Provider-Level Spending (DuckDB Extension)
Provider-level Medicaid claims data from the HHS T-MSIS dataset (2018-2024, 227M rows). Queried locally via DuckDB on a 2.9 GB Parquet file — no API, reads only columns/rows needed per query (~50-500ms).
get_provider_spending- Filter by NPI, HCPCS code, and/or date rangeget_provider_top_services- Top HCPCS codes by total payment for a providerget_hcpcs_top_providers- Top providers by total payment for a HCPCS codeget_provider_spending_summary- Aggregate stats for a provider NPI
Setup: Download the Parquet file first:
python scripts/download_medicaid_provider_spending.pyNote: Provider spending methods are handled by the Python wrapper layer (DuckDB on local Parquet), not the Node.js MCP server. The wrapper routes these methods locally and forwards all other methods to Node.js as before.
Technical Features
Hybrid Architecture - Optimized data access: in-memory caching for small datasets, streaming API for large datasets
Automatic Pricing Integration - Formulary queries auto-enrich with NADAC pricing data
Intelligent Enrichment - Illinois formulary enhanced via cross-state NDC matching (CA/NY/OH sources)
Related MCP server: OpenFDA MCP Server
Usage
{
"mcpServers": {
"medicaid": {
"command": "node",
"args": ["/path/to/medicaid-mcp-server/build/index.js"]
}
}
}API Reference
Unified Tool: medicaid_info
The server provides a single tool with multiple methods:
State Formulary Search
{
"method": "search_state_formulary",
"state": "CA", // CA, NY, OH, TX, IL
"label_name": "OZEMPIC",
"limit": 10
}Parameters:
state(required): State code (CA, NY, OH, TX, IL)label_name: Brand/trade namegeneric_name: Generic drug namendc: 11-digit NDC coderequires_pa: Prior authorization filter (true/false)has_ndc: Filter for drugs with NDC codes (Illinois only)limit: Max results (default: 10)
State-Specific Parameters:
California:
tier: Cost ceiling tier ("Brand" or "Generic")extended_duration: Extended duration eligibility (true/false)
Texas:
pdl_pa: PDL prior authorization (true/false)clinical_pa: Clinical prior authorization (true/false)program: Program filter (medicaid, chip, cshcn, etc.)max_price/min_price: Price range filters
New York:
preferred: Preferred drug status (true/false)is_brand: Brand vs generic filter (true/false)max_price/min_price: MRA cost range
Drug Pricing
{
"method": "get_nadac_pricing",
"drug_name": "ibuprofen",
"limit": 10
}Parameters:
drug_name: Drug name (fuzzy match)ndc: Specific 11-digit NDC codelimit: Max results (default: 10)
Enrollment Trends
{
"method": "get_enrollment_trends",
"state": "CA",
"start_date": "2023-01-01",
"end_date": "2024-12-31"
}Federal Upper Limits
{
"method": "get_federal_upper_limits",
"ingredient": "NYSTATIN",
"limit": 10
}Drug Rebate Information
{
"method": "get_drug_rebate_info",
"drug_name": "ozempic", // or labeler_name: "novo nordisk"
"limit": 10
}State Drug Utilization
{
"method": "get_drug_utilization",
"state": "CA",
"drug_name": "OZEMPIC",
"year": 2024,
"quarter": 4,
"limit": 10
}Provider Spending (DuckDB)
// Filter by HCPCS code
{
"method": "get_provider_spending",
"hcpcs_code": "J3490",
"month_from": "2024-01",
"month_to": "2024-06",
"limit": 20
}
// Top services for a provider
{
"method": "get_provider_top_services",
"npi": "1730491945",
"limit": 10
}
// Top providers for a procedure code
{
"method": "get_hcpcs_top_providers",
"hcpcs_code": "99213",
"limit": 10
}
// Provider aggregate summary
{
"method": "get_provider_spending_summary",
"npi": "1730491945"
}Common Parameters:
npi_role:"billing"(default) or"servicing"— selects which NPI column to filter on
Architecture
The server uses a hybrid data access strategy optimized for performance and memory efficiency:
Cached Datasets - Small, frequently accessed data loaded into memory:
State formularies (CA, NY, OH, TX, IL) - Excel/CSV/JSON/Text parsing with TTL-based refresh
NADAC pricing (123 MB) - Weekly CSV download, cached for fast lookups
State enrollment (3.6 MB) - Monthly snapshots, cached for trend analysis
Streaming API - Large datasets queried on-demand via CMS DKAN API:
Federal Upper Limits (196 MB, 2.1M records)
Drug Rebate Program (291 MB, ~3M records)
State Drug Utilization (192 MB, 5.3M records)
Memory Footprint: ~215 MB total for cached datasets, minimal for API queries
Performance Characteristics
Dataset | Access Method | Typical Response Time |
State Formularies | In-memory cache | <100ms |
NADAC Pricing | In-memory cache | <100ms (20-30s initial load) |
State Enrollment | In-memory cache | <50ms |
Federal Upper Limits | DKAN API streaming | 1-2s |
Drug Rebate Program | DKAN API streaming | 1-2s |
State Drug Utilization | DKAN API streaming | 1-2s |
Provider Spending | DuckDB on Parquet | 300-700ms |
Data Sources
Dataset | Update Frequency | Coverage | Authority |
NADAC | Weekly | 1.5M NDC codes | CMS |
State Formularies | Daily-Monthly | 43% of US Medicaid | State agencies |
Federal Upper Limits | Monthly | 2.1M records | CMS |
Drug Rebate | Quarterly | ~3M records | CMS |
Drug Utilization | Quarterly | 5.3M records | CMS |
Enrollment | Monthly | All states | CMS |
Provider Spending | Periodic | 227M rows, 2018-2024 | HHS T-MSIS |
Query Examples
State Formulary Search with Automatic Pricing
// Find GLP-1 drugs in California
{
"method": "search_state_formulary",
"state": "CA",
"generic_name": "semaglutide",
"limit": 10
}
// Returns formulary data with automatic NADAC pricing integrationMulti-State Enrollment Comparison
{
"method": "compare_state_enrollment",
"states": ["CA", "TX", "NY", "FL"],
"month": "2024-09"
}Cross-State NDC Enrichment
// Illinois formulary with intelligent enrichment
{
"method": "search_state_formulary",
"state": "IL",
"label_name": "OZEMPIC",
"limit": 10
}
// Returns IL formulary enriched with NDC codes from CA/NY/OH (61.7% coverage)Use Cases
Market Access & Strategy
State formulary coverage analysis and prioritization
Prior authorization landscape mapping
Competitive tier placement assessment
Pricing Intelligence
NADAC price trend analysis and forecasting
Multi-state pricing comparisons
Rebate program eligibility verification
Provider Analytics
Cross-payer provider analysis (Medicaid + Medicare provider-level data)
Medicaid-specific prescriber targeting by HCPCS code
Provider-level geographic hotspot identification
HCPCS utilization patterns across billing vs servicing NPIs
Policy & Economics
Medicaid expansion impact analysis
State enrollment forecasting and growth trends
Utilization pattern analysis by geography
Limitations
Individual beneficiary claims require CMS Data Use Agreement (T-MSIS/TAF)
Provider spending data requires local Parquet download (2.9 GB) — not served by the Node.js MCP server directly
Available Tools
1 toolmedicaid_infoC
Unified tool for Medicaid data operations: access enrollment trends, drug pricing (NADAC), quality measures, and program performance from data.medicaid.gov via Socrata SODA API. Provides state-level aggregates (NOT provider-level like Medicare).
| Name | Required | Description | Default |
|---|---|---|---|
| method | Yes | The operation to perform: get_nadac_pricing (drug pricing), compare_drug_pricing (multi-drug comparison), get_enrollment_trends (state enrollment), compare_state_enrollment (multi-state comparison), get_drug_rebate_info (rebate program), search_state_formulary (CA/NY/TX/OH/IL formularies), get_drug_utilization (state prescriptions), get_federal_upper_limits (FUL pricing), list_available_datasets (catalog), search_datasets (custom query) | |
| state | No | State abbreviation (e.g., "CA", "TX", "NY") - required for get_enrollment_trends | |
| states | No | Array of state abbreviations for compare_state_enrollment | |
| ndc_code | No | National Drug Code (11-digit) for get_nadac_pricing | |
| drug_name | No | Drug name (partial match supported) for get_nadac_pricing or get_drug_rebate_info | |
| price_date | No | Specific pricing date (YYYY-MM-DD) for get_nadac_pricing - defaults to latest | |
| start_date | No | Start date (YYYY-MM-DD) for time-range queries | |
| end_date | No | End date (YYYY-MM-DD) for time-range queries | |
| enrollment_type | No | Type of enrollment data for enrollment methods | |
| month | No | Specific month (YYYY-MM) for compare_state_enrollment | |
| ndc_codes | No | Array of NDC codes for compare_drug_pricing | |
| drug_names | No | Array of drug names for compare_drug_pricing | |
| labeler_name | No | Manufacturer name for get_drug_rebate_info | |
| rebate_year | No | Year for get_drug_rebate_info | |
| dataset_id | No | Dataset identifier for search_datasets | |
| where_clause | No | SoQL WHERE clause for search_datasets | |
| limit | No | Maximum results to return (default: 100, max: 5000) | |
| offset | No | Pagination offset (default: 0) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions the data source and scope but fails to describe critical behavioral traits: whether operations are read-only or mutative, authentication requirements, rate limits, error handling, or response formats. The description adds minimal context beyond stating the API source, leaving significant gaps in understanding how the tool behaves.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is appropriately concise with two sentences that efficiently convey the tool's scope and data source. It's front-loaded with the main purpose and avoids unnecessary details. However, it could be slightly more structured by explicitly listing the key operations or use cases.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity (18 parameters, no annotations, no output schema), the description is incomplete. It covers the general purpose and scope but lacks essential context: behavioral traits, usage guidelines, output information, and practical constraints. For a multi-operation tool with many parameters, this minimal description leaves too many unanswered questions for effective agent use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so the schema already documents all 18 parameters thoroughly. The description adds no parameter-specific information beyond what's in the schema. It mentions general data types but doesn't explain parameter relationships, dependencies, or usage patterns. The baseline score of 3 reflects adequate coverage by the schema alone.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose as a 'unified tool for Medicaid data operations' that accesses specific data types (enrollment trends, drug pricing, quality measures, program performance) from a specific source (data.medicaid.gov via Socrata SODA API). It distinguishes scope by noting 'state-level aggregates (NOT provider-level like Medicare).' However, with no sibling tools, the differentiation aspect is less critical, and the description could be more specific about the exact operations.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no explicit guidance on when to use this tool versus alternatives. It mentions the data source and scope but lacks information about prerequisites, performance characteristics, or typical use cases. With no sibling tools, there's no need to differentiate from alternatives, but the absence of any usage context or constraints leaves the agent without practical guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
1 tool update
v1.0.0- Changed
medicaid_info3 fields changed- changed
Input schema / properties / method / descriptionPrevious value: -"The operation to perform: get_nadac_pricing (NADAC drug pricing lookup), compare_drug_pricing (multi-drug or temporal comparison), get_enrollment_trends (state monthly enrollment), compare_state_enrollment (multi-state comparison), get_drug_rebate_info (rebate program data), list_available_datasets (dataset catalog), search_datasets (custom SoQL query)"New value: +"The operation to perform: get_nadac_pricing (drug pricing), compare_drug_pricing (multi-drug comparison), get_enrollment_trends (state enrollment), compare_state_enrollment (multi-state comparison), get_drug_rebate_info (rebate program), search_state_formulary (CA/NY/TX/OH/IL formularies), get_drug_utilization (state prescriptions), get_federal_upper_limits (FUL pricing), list_available_datasets (catalog), search_datasets (custom query)" - changed
Input schema / properties / method / enumPrevious value: -[ - "get_nadac_pricing", - "compare_drug_pricing", - "get_enrollment_trends", - "compare_state_enrollment", - "get_drug_rebate_info", - "list_available_datasets", - "search_datasets" -]New value: +[ + "get_nadac_pricing", + "compare_drug_pricing", + "get_enrollment_trends", + "compare_state_enrollment", + "get_drug_rebate_info", + "search_state_formulary", + "get_drug_utilization", + "get_federal_upper_limits", + "list_available_datasets", + "search_datasets" +] - changed
Input schema / properties / method / examplesPrevious value: -[ - "get_nadac_pricing", - "get_enrollment_trends", - "compare_state_enrollment" -]New value: +[ + "get_nadac_pricing", + "search_state_formulary", + "get_drug_rebate_info" +]
1 tool update
- First observed
medicaid_info
TDQS
With only one tool, there is no ambiguity or overlap between tools, as there are no other tools to compare it against. The tool's purpose is clearly defined as a unified interface for Medicaid data operations.
Since there is only one tool, naming consistency is inherently perfect. The tool name 'medicaid_info' follows a clear and consistent pattern, though no pattern can be established across multiple tools.
A single tool for a server named 'Medicaid MCP Server' suggests a very thin surface. While it unifies multiple data operations, the scope of Medicaid data (enrollment, drug pricing, quality measures) likely warrants more granular tools for better agent usability and flexibility.
The tool covers multiple aspects (enrollment, pricing, quality) in a unified way, but this approach may lead to gaps in specific operations like filtering, updating, or detailed queries. For a Medicaid data domain, a single tool is likely insufficient for comprehensive coverage, as agents might need more targeted actions.
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
CMS Open Payments, with annual dataset discovery through the official DKAN API.
Live US drug acquisition costs (CMS NADAC) for AI assistants. Free, no auth, weekly data.
Medicaid drug utilization by NDC, managed-care enrollment and state enrollment operations from CMS
HealthData.gov MCP — wraps HealthData.gov CKAN API (free, no auth)
Related MCP Servers
- AlicenseBqualityCmaintenanceProvides comprehensive access to CMS Medicare data including physician services, prescriber information, hospital quality metrics, drug spending, formulary coverage, and ASP pricing for healthcare analysis and decision-making.18MIT
- FlicenseBqualityCmaintenanceA comprehensive MCP server that provides access to U.S. FDA public datasets via the openFDA API, enabling querying of drug adverse events, labeling, recalls, approvals, shortages, NDC directory, and medical device regulatory data.1021-
- FlicenseNot gradedqualityCmaintenanceProvides unified access to drug formulary data from US ACA marketplace health insurance plans, enabling drug search, coverage details, restriction info, and plan comparison across thousands of plans.-
- AlicenseNot gradedqualityCmaintenanceEnables searching the CMS Open Payments dataset for physician, company, product, and research payments using structured filters, with annual dataset discovery through the official DKAN API.11MIT
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/openpharma-org/medicaid-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server