[Integrations](https://spiral.ai/integrations) › [Cursor](https://spiral.ai/integrations/cursor) › [CMS drug spending record](https://spiral.ai/integrations/cursor/cms-drug-spending-record)

# How to Use CMS drug spending record in Cursor

Returns one CMS drug spending record for a known identifier. Use it to recheck a specific drug, manufacturer, and year behind a report or calculation.

|  |  |
| --- | --- |
| Model | CMS drug spending record |
| Available through | Alexandria |
| Category | Health |
| Price | $0.00873 per call. |
| Returns | json |
| Runs | In the background |
| Setup | About 2 minutes, no API key |

## Prompts to try with CMS drug spending record in Cursor

- Use CMS drug spending record to retrieve part_d_annual|Eliquis|Apixaban|Overall|2024 and check whether this project's 2024 Eliquis totals match the returned record.
- Use CMS drug spending record to look this up and give me the result as a table. Save the result in ./assets.
- Pull the latest numbers from CMS drug spending record and tell me what changed since last week.
- Check CMS drug spending record and summarize what you find in three bullet points.
- Pull the newest data from CMS drug spending record and give me the result as a table.

## How to set up CMS drug spending record in Cursor

Pick the way that suits you. Each takes about two minutes.

### Use Spiral's MCP server

1. **Add the hosted server**: Use Add to Cursor on the console's Agents & MCP page, or add this to `.cursor/mcp.json` (one project) or `~/.cursor/mcp.json` (every project):

```json
{
  "mcpServers": {
    "spiral": { "url": "https://api.spiral.ai/mcp" }
  }
}
```

2. **Sign in**: Open Cursor Settings › MCP, click Connect next to spiral, sign in to Spiral and click Authorize. No API key. Spiral then shows as connected, with its tools listed.

### Use the Spiral skill

1. **Send Cursor this message**: Your agent reads Spiral's skill and sets itself up.

```
set up https://spiral.ai/SKILL.md
```

2. **Sign in or paste a key**: Approve Spiral in the browser, or give the agent a key from the console.

### Use the Spiral CLI

1. **Install and sign in**: Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

```bash
npx -y spiral-cli@latest init
```

### Call the Spiral API

1. **Create an API key**: In the console, under API keys.

2. **Run CMS drug spending record**: One request; the result comes back by polling or a webhook.

```bash
curl https://api.spiral.ai/v1/runs \
  -H "Authorization: Bearer $SPIRAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "provider": "alexandria",
    "model": "data-cms-gov/drug-spending/records_get",
    "input": {
      "source_record_id": "<source_record_id>"
    }
  }'
```

Then paste one of the prompts above: Cursor finds CMS drug spending record on Spiral, shows the price and runs it.

Setup guide in the docs: https://spiral.ai/docs/quickstarts/cursor

## CMS drug spending record tools and prices

- [CMS data.cms.gov · Records get](https://spiral.ai/tools/alexandria/data-cms-gov/drug-spending/records_get) (Alexandria): $0.00873 per call.

## What can you do with CMS drug spending record in Cursor?

Build a CMS drug spending report that compares prescription fills with reported spending for named drugs. A coding agent can turn the records into project tables and charts while keeping Medicare and Medicaid measures distinct.

### Annual drug spending report

Identify the annual datasets and publication versions, collect the records, rank spending, and investigate named drugs. Recheck the exact records supporting the report's main findings.

### Diabetes drug utilization study

Compare reported spending and prescription fills for drugs such as Ozempic and Jardiance across available years. Establish coverage and publication versions first, then verify the individual records behind notable changes.

### Medicare Part B oncology spending review

Find the relevant Part B publication, rank spending, and examine Keytruda alongside other reported drugs. Collect the underlying records and verify selected results before preparing a fee-for-service spending brief.

### Prescription volume and spending comparison

Use a consistent annual publication to find high-spending drugs and compare their spending changes with prescription-fill changes. Retrieve and verify the records needed to distinguish changes in reported utilization from changes in average spending.

### Drug spending fact-check

Check a published claim about Eliquis spending against CMS results, then retrieve the exact drug and year record supporting the comparison. Explain that Part D totals exclude rebates.

### Select drugs for a policy brief

Find the highest-spending drugs or largest changes in average spending per unit, then examine named results and their underlying records. Use the findings to choose which drugs warrant a closer explanation.

## Overview

- [Alexandria](https://spiral.ai/providers/alexandria)
- [All Cursor guides](https://spiral.ai/integrations/cursor)

## CMS drug spending record in other agents

- [Amp](https://spiral.ai/integrations/amp/cms-drug-spending-record)
- [ChatGPT](https://spiral.ai/integrations/chatgpt/cms-drug-spending-record)
- [Claude](https://spiral.ai/integrations/claude-desktop/cms-drug-spending-record)
- [Claude Code](https://spiral.ai/integrations/claude-code/cms-drug-spending-record)
- [Cline](https://spiral.ai/integrations/cline/cms-drug-spending-record)
- [Codex](https://spiral.ai/integrations/codex/cms-drug-spending-record)
- [Devin](https://spiral.ai/integrations/devin/cms-drug-spending-record)
- [dots](https://spiral.ai/integrations/dots/cms-drug-spending-record)
- [Factory Droid](https://spiral.ai/integrations/factory-droid/cms-drug-spending-record)
- [Gemini](https://spiral.ai/integrations/gemini/cms-drug-spending-record)
- [Gemini CLI](https://spiral.ai/integrations/gemini-cli/cms-drug-spending-record)
- [Google Antigravity](https://spiral.ai/integrations/antigravity/cms-drug-spending-record)
- [goose](https://spiral.ai/integrations/goose/cms-drug-spending-record)
- [Grok](https://spiral.ai/integrations/grok/cms-drug-spending-record)
- [Grok Build](https://spiral.ai/integrations/grok-build/cms-drug-spending-record)
- [Hermes](https://spiral.ai/integrations/hermes/cms-drug-spending-record)
- [Instinct](https://spiral.ai/integrations/instinct/cms-drug-spending-record)
- [Manus](https://spiral.ai/integrations/manus/cms-drug-spending-record)
- [Muse](https://spiral.ai/integrations/muse/cms-drug-spending-record)
- [Muse Code](https://spiral.ai/integrations/muse-code/cms-drug-spending-record)
- [n8n](https://spiral.ai/integrations/n8n/cms-drug-spending-record)
- [Notion](https://spiral.ai/integrations/notion/cms-drug-spending-record)
- [OpenClaw](https://spiral.ai/integrations/openclaw/cms-drug-spending-record)
- [opencode](https://spiral.ai/integrations/opencode/cms-drug-spending-record)
- [Perplexity](https://spiral.ai/integrations/perplexity/cms-drug-spending-record)
- [Raycast](https://spiral.ai/integrations/raycast/cms-drug-spending-record)
- [VS Code](https://spiral.ai/integrations/vscode/cms-drug-spending-record)
- [Windsurf](https://spiral.ai/integrations/windsurf/cms-drug-spending-record)
- [Zapier](https://spiral.ai/integrations/zapier/cms-drug-spending-record)

## More Cursor guides

- [CMS drug spending rankings](https://spiral.ai/integrations/cursor/cms-drug-spending-rankings)
- [CMS drug spending records](https://spiral.ai/integrations/cursor/cms-drug-spending-records)
- [CMS drug spending publication status](https://spiral.ai/integrations/cursor/cms-drug-spending-publication-status)
- [CMS drug spending search](https://spiral.ai/integrations/cursor/cms-drug-spending-search)
- [CMS drug spending dataset catalog](https://spiral.ai/integrations/cursor/cms-drug-spending-dataset-catalog)
- [CMS home health agencies](https://spiral.ai/integrations/cursor/cms-home-health-agencies)

## Questions about CMS drug spending record in Cursor

**Can Cursor use CMS drug spending record?**

Yes. Add Spiral to Cursor as an MCP server, and Cursor can find and run CMS drug spending record like any built-in tool.

**How much does CMS drug spending record cost in Cursor?**

$0.00873 per call. You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Cursor plan is separate.

**Do I need an Alexandria account to use CMS drug spending record in Cursor?**

No. Spiral runs CMS drug spending record on its own Alexandria account. You sign in to Spiral once and never paste a key.

**How long does it take to set up CMS drug spending record in Cursor?**

About two minutes: add the hosted server, then sign in.

**Does Cursor wait while CMS drug spending record runs?**

CMS drug spending record runs in the background. Cursor starts the run, checks on it and gives you the json when it's ready.

**Does CMS drug spending cover the entire US drug market?**

No. Annual Part D data summarizes final-action claims for Part D enrollees, Part B spending excludes Medicare Advantage beneficiaries, and Medicaid spending covers outpatient drugs paid for by state Medicaid agencies.

**How often does CMS update annual drug spending data?**

CMS typically updates the annual Medicare Part D spending dataset once every 12 months. That publication schedule describes the annual dataset, rather than current prescribing activity.

**Do the spending totals include rebates?**

Part D totals exclude manufacturer rebates and other price concessions. Medicaid totals likewise are not reduced by rebates paid to states, so these figures do not establish spending after rebates.

**Can I compare spending per beneficiary across Medicare and Medicaid?**

The Medicaid spending dataset does not provide individual beneficiary counts. CMS explicitly says that per-beneficiary calculations are therefore not possible for that dataset.

**Does a Part D drug total describe one strength or dosage form?**

Annual Part D summaries combine strengths, dosage forms, and routes of administration under brand and generic names. A drug-level result therefore does not isolate a particular tablet strength or injection formulation.

