Skip to contents

Read a small overview of one local Hospital Price Transparency JSON file without creating a database or extracting relational records. Inspection describes the source; it is not a CMS compliance assessment or a dry run of mrf_parse().

Usage

mrf_inspect(path)

Arguments

path

Path to one local JSON file.

Value

A named list of small source facts. file_size_bytes and count values are numeric; availability and support flags are logical. No custom class or persistent database is created.

Details

The result reports file identity and bytes, hospital name, declared version, update date, counts of root location names, addresses, NPIs, and service occurrences, and whether selected optional root fields are present. Counts describe source arrays, not materialized database rows. Availability flags indicate field presence after projection, not successful extraction or validation. supported_version compares the declared version with the package's current HPT JSON schema version from mrf_specification(). An unsupported version can be inspected, but mrf_parse() will not treat it as supported v3 data. Unreadable JSON produces an error.

See also

mrf_example() for a bundled source to inspect, and mrf_parse() for extraction into a database.

Examples

mrf_inspect(mrf_example("basic"))
#> $file_path
#> [1] "/home/runner/work/_temp/Library/cmsmrf/examples/hospital-basic.json"
#> 
#> $file_name
#> [1] "hospital-basic.json"
#> 
#> $file_size_bytes
#> [1] 2775
#> 
#> $hospital_name
#> [1] "Fictional Willowmere Community Hospital"
#> 
#> $declared_version
#> [1] "3.0.0"
#> 
#> $supported_schema_version
#> [1] "3.0.0"
#> 
#> $supported_version
#> [1] TRUE
#> 
#> $last_updated_on
#> [1] "2026-11-15"
#> 
#> $location_name_count
#> [1] 1
#> 
#> $hospital_address_count
#> [1] 1
#> 
#> $type_2_npi_count
#> [1] 1
#> 
#> $service_count
#> [1] 2
#> 
#> $has_financial_aid_policy
#> [1] FALSE
#> 
#> $has_contract_provisions
#> [1] FALSE
#> 
#> $has_modifiers
#> [1] FALSE
#>