# Hospital Cost-to-Charge Ratio Benchmark (CMS HCRIS) (`kevinserver24/hcris-hospital-cost-benchmark`) Actor

Cross-hospital cost-to-charge ratio benchmark, computed live from CMS's own HCRIS Hospital 2552-10 cost report release. Charged only per hospital-per-fiscal-year benchmark backed by at least 2 hospitals -- never a single hospital's fact billed as a comparison.

- **URL**: https://apify.com/kevinserver24/hcris-hospital-cost-benchmark.md
- **Developed by:** [Kevin](https://apify.com/kevinserver24) (community)
- **Categories:** Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$200.00 / 1,000 hospital\_cost\_benchmarks

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Hospital Cost-to-Charge Ratio Benchmark (CMS HCRIS)

*An independent tool. It is not affiliated with, endorsed by, or operated
by CMS or any hospital whose cost report it reads. All data is read live
from CMS's own published HCRIS Hospital 2552-10 cost report release,
never scraped from any patient-facing site.*

Give it a batch of hospitals (each named by its own CMS Certification
Number, CCN) and a fiscal year; get back, for each hospital, its own
cost-to-charge ratio for that year -- how much it costs the hospital to
deliver a dollar of billed charges -- and where that ratio sits against
every other hospital in your batch: a percentile rank, plus the batch
median/min/max.

### What is a CCN, and how do I find one?

The CMS Certification Number is the 6-character public identifier every
Medicare-participating hospital has, e.g. `010001`. It is the same
identifier CMS's own Hospital Compare / Care Compare site, cost reports,
and most healthcare-price-transparency tooling already use. To look one
up: search "`<hospital name>` CMS certification number" or check CMS's
own Provider of Services file / Care Compare site
(`https://www.medicare.gov/care-compare/`), which lists each hospital's
CCN alongside its name and address.

### Why this is hard, and why that is the point

CMS ships one bulk release covering every hospital's cost report at
once -- there is no per-hospital lookup endpoint, so this Actor
downloads and joins the whole release on every run. About 1 in 5
hospitals in a typical fiscal year (Critical Access Hospitals and other
providers not paid under a Prospective Payment System) simply do not
have a cost figure in this extract, and this Actor tells you so plainly
rather than guessing. A hospital's own fiscal year does not always align
to the calendar, so some hospitals have more than one report row in the
same fiscal-year bucket; this Actor always picks the most recent filing
period and tells you exactly which one it used. The ratio itself is not
handed over directly by CMS -- it is derived from two raw columns and
checked against a plausibility range, because a small share of real cost
reports contain data-entry errors (a charges figure near zero, or a
misplaced decimal) that would otherwise produce a nonsensical ratio.

### What it returns

For each hospital: `hospital_ccn`, `hospital_label` (a name you choose,
falling back to CMS's own registered name) and
`hospital_registered_label` (CMS's own registered facility name,
verbatim), `street_address`/`city`/`state`/`zip_code`/`county`,
`fiscal_year`/`fiscal_year_begin_date`/`fiscal_year_end_date`/
`report_status` (so you can see exactly which filing period and
settlement status the figure came from), `cost_to_charge_ratio`, and the
shared benchmark figures: `peer_percentile_rank` (0 = cheapest in your
batch, 100 = most expensive), `batch_median`, `batch_min`, `batch_max`,
and `batch_sample_size` (how many hospitals in your batch actually had a
usable ratio).

### What it does not do, on purpose

It never charges for a single hospital's ratio as if it were a
comparison -- a batch with only one hospital having a usable ratio is
delivered free, with the reason; add more hospitals to turn it into a
real benchmark. It never fabricates a ratio for a hospital whose cost
report does not support one (a Critical Access Hospital with a blank
cost column, a hospital with zero reported charges, or a computed ratio
outside a plausible range) -- each is delivered free, with the specific
reason, rather than silently dropped or guessed at. It does not attempt
`number_of_beds`, `fte_employees` or `total_discharges` -- those live on
a different worksheet of the cost report not included in this release,
and this Actor will not invent a number it cannot trace to a real,
verified source column.

# Actor input Schema

## `hospitals` (type: `array`):

Each entry needs hospital\_ccn: the 6-character CMS Certification Number (CCN) of the hospital, e.g. "010001". hospital\_label is optional (a name you choose); if omitted, the hospital's own registered name from CMS's own file is used. A benchmark needs at least 2 hospitals with a usable cost-to-charge ratio for the same fiscal\_year; fewer than that is delivered free, with the reason, never billed. Up to 25 hospitals per run. Don't know a CCN? See this Actor's README for how to look one up.

## `fiscal_year` (type: `integer`):

The cost-report fiscal year to benchmark (CMS buckets each hospital's own fiscal year into the calendar year it falls in). 2015-2025, default 2023 (a mature, fully populated year as of this Actor's build).

## Actor input object example

```json
{
  "hospitals": [
    {
      "hospital_ccn": "010005",
      "hospital_label": "Example Hospital A"
    },
    {
      "hospital_ccn": "010007",
      "hospital_label": "Example Hospital B"
    }
  ],
  "fiscal_year": 2023
}
```

# Actor output Schema

## `results` (type: `string`):

Hospital identity, fiscal year, cost-to-charge ratio, and the batch percentile/median/min/max/sample size.

## `resultsCsv` (type: `string`):

The same rows as a spreadsheet.

## `summary` (type: `string`):

How many hospitals were requested, how many benchmarks were charged, free, or left untouched by the spending limit.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "hospitals": [
        {
            "hospital_ccn": "010005",
            "hospital_label": "Example Hospital A"
        },
        {
            "hospital_ccn": "010007",
            "hospital_label": "Example Hospital B"
        }
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("kevinserver24/hcris-hospital-cost-benchmark").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "hospitals": [
        {
            "hospital_ccn": "010005",
            "hospital_label": "Example Hospital A",
        },
        {
            "hospital_ccn": "010007",
            "hospital_label": "Example Hospital B",
        },
    ] }

# Run the Actor and wait for it to finish
run = client.actor("kevinserver24/hcris-hospital-cost-benchmark").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "hospitals": [
    {
      "hospital_ccn": "010005",
      "hospital_label": "Example Hospital A"
    },
    {
      "hospital_ccn": "010007",
      "hospital_label": "Example Hospital B"
    }
  ]
}' |
apify call kevinserver24/hcris-hospital-cost-benchmark --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,kevinserver24/hcris-hospital-cost-benchmark"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/Z7h6FYO7mLbzSMOfu/builds/VLZng3KW7tpfKRQS0/openapi.json
