Build a Medicare Part B drug payment lookup with ASP data
- Data
- Medicare ASP, HCPCS
- Endpoints
- /v1/drugs/asp/{hcpcs}/v1/drugs/asp
- MCP tools
- get_medicare_asp
- Plan
- Runs on the Free plan
How it works
- Look up the drug's HCPCS code (or find it from an NDC through CMS's crosswalk).
- Read the payment limit in effect on the date of service and its dosage unit.
- Multiply by billed units for the expected Medicare allowable.
The code
TypeScript with @healthcare.dev/sdk. Set HDEV_API_KEY to a free key and run it. Every response carries its source, release and license in meta.
import { HealthcareDev } from "@healthcare.dev/sdk"; const hdev = new HealthcareDev(); export async function partBAllowable(hcpcs: string, units: number, date: string) { const { data } = await hdev.drugs.asp(hcpcs, { date }); const limit = data.in_effect; if (!limit) return null; return { drug: data.short_description, perUnit: Number(limit.payment_limit), dosage: limit.dosage_descriptor, quarter: limit.quarter, allowable: Number(limit.payment_limit) * units, }; } await partBAllowable("J9271", 20, "2026-10-15");
Or ask your agent
Connect the MCP server and ask in plain language. It calls get_medicare_asp and cites what it found.
What's the Medicare Part B payment limit for HCPCS J9271 this quarter, and what dosage does it apply to?
Take it further
- Search by NDC with
GET /v1/drugs/asp?ndc=when you only have the vial's NDC. - Show the quarter-over-quarter
historyto explain reimbursement changes. - Check the HCPCS code itself with the code lookup for its status and description.
Reference data only, not medical advice or a coverage determination. Send codes, NDCs and NPIs, never patient information.
More examples
Claim code checker
Catch non-billable, retired and mistyped ICD-10-CM and HCPCS codes before a claim goes out. One batch call checks up to 100 codes, with the release each answer came from.
Recall and shortage alerts
Watch a list of NDCs for FDA recalls and drug shortages and alert when one appears. Class I recalls first, with the recalling firm, reason and lot codes.
NPI verification
Verify a provider's NPI at sign-up: check digit, whether CMS issued it, active or deactivated, and the name, specialty and license state on record.