Skip to content

andrewallenbruce/provider

Repository files navigation

provider provider website

Tidy Healthcare Provider API Interface

Ask DeepWiki zread Codecov test coverage CodeFactor code size

You can install provider from GitHub with:

# install.packages("pak")
pak::pak("andrewallenbruce/provider")

Overview

The provider package is a high-level interface designed to streamline access to publicly available healthcare provider data from the Centers for Medicare and Medicaid Services (CMS) and other federal sources. It provides a unified, tidy framework for querying complex datasets that are essential for medical coding, billing, and healthcare revenue cycle management.

🚀 Basic Usage Patterns

Most functions in provider follow a similar pattern: they accept identifiers (like an npi) or search criteria (like an org_name) and return a tibble.

library(provider)

🏢 Facility Affiliations

affiliations(last = "Bruce")
✔ affiliations returned 328 results.
# A tibble: 328 × 8
   first    last  middle        npi pac        prov_type prov_ccn parent_ccn
   <chr>    <chr> <chr>       <int> <chr>      <chr>     <chr>    <chr>     
 1 SIDNEY   BRUCE D      1003044520 2466795406 Hospital  150173   <NA>      
 2 SIDNEY   BRUCE D      1003044520 2466795406 Hospital  151312   <NA>      
 3 SIDNEY   BRUCE D      1003044520 2466795406 Hospital  151316   <NA>      
 4 MARGARET BRUCE E      1003444332 0840619235 Hospital  500016   <NA>      
 5 LAUREN   BRUCE C      1003863192 4385530377 Hospital  390331   <NA>      
 6 TIMOTHY  BRUCE <NA>   1013228907 7315239902 Hospital  520008   <NA>      
 7 SARAH    BRUCE <NA>   1023571882 8224498597 Hospital  390111   <NA>      
 8 SARAH    BRUCE <NA>   1023571882 8224498597 Hospital  450018   <NA>      
 9 DAVID    BRUCE S      1043213069 6406929694 Hospital  190036   <NA>      
10 DAVID    BRUCE <NA>   1043634017 0840422127 Hospital  110107   <NA>      
# ℹ 318 more rows

🤝 Reassignment of Benefits

reassignments(
  state = "GA",
  employers = greater(40, equal = TRUE))
✔ reassignments returned 86 results.
# A tibble: 86 × 13
   first   last  state specialty employers    npi pac   enid  org_name employees
   <chr>   <chr> <chr> <chr>         <int>  <int> <chr> <chr> <chr>        <int>
 1 NausheNaveGA    Diagnost42 1.51e9 8022I201Advance1
 2 NausheNaveGA    Diagnost42 1.51e9 8022I201Atlanti40
 3 NausheNaveGA    Diagnost42 1.51e9 8022I201Brooks48
 4 NausheNaveGA    Diagnost42 1.51e9 8022I201Central34
 5 NausheNaveGA    Diagnost42 1.51e9 8022I201Concord4
 6 NausheNaveGA    Diagnost42 1.51e9 8022I201Crouse6
 7 NausheNaveGA    Diagnost42 1.51e9 8022I201Diagnos19
 8 NausheNaveGA    Diagnost42 1.51e9 8022I201Donalso101
 9 NausheNaveGA    Diagnost42 1.51e9 8022I201Englewo1
10 NausheNaveGA    Diagnost42 1.51e9 8022I201Fred Sm6
# ℹ 76 more rows
# ℹ 3 more variables: org_pac <chr>, org_enid <chr>, org_state <chr>

👎 Revoked Medicare Providers

revocations(
  state = "GA", 
  org_name = not_blank())
✔ revocations returned 115 results.
# A tibble: 115 × 12
   org_name        first middle last  enid      npi multi state prov_desc reason
   <chr>           <chr> <chr>  <chr> <chr>   <int> <int> <chr> <chr>     <chr> 
 1 EMMANUEL O SOY<NA>  <NA>   <NA>  O2001.34e9     0 GA    PART B S424.52 COMPREHENSIVE<NA>  <NA>   <NA>  O2001.13e9     0 GA    PART B S424.53 RIVERSIDE FAMI<NA>  <NA>   <NA>  O2001.31e9     0 GA    PART B S424.54 PAIN MANAGEMEN<NA>  <NA>   <NA>  O2001.54e9     0 GA    PART B S424.55 DEEP SOUTH AMB<NA>  <NA>   <NA>  O2001.07e9     0 GA    PART B S424.56 SIGHT SAVERS E<NA>  <NA>   <NA>  O200NA          0 GA    PART B S424.57 SENIOR PSYCH S<NA>  <NA>   <NA>  O2001.23e9     0 GA    PART B S424.58 WALLACE STEVE<NA>  <NA>   <NA>  O2001.98e9     0 GA    PART B S424.59 FULGHUM DRUGS<NA>  <NA>   <NA>  O2001.41e9     1 GA    PART B S424.510 AGAPE PRESCRIP<NA>  <NA>   <NA>  O2001.47e9     0 GA    PART B S424.5# ℹ 105 more rows
# ℹ 2 more variables: start_date <date>, end_date <date>

🪪 Clinician Demographics

clinicians(
  state = "GA", 
  school = not("OTHER"), 
  org_name = not_blank(),
  grad_year = 2025)
✔ clinicians returned 144 results.
# A tibble: 144 × 18
   first middle last  gender cred  school grad_year specialty    npi pac   enid 
   <chr> <chr>  <chr> <chr>  <chr> <chr>      <int> <chr>      <int> <chr> <chr>
 1 ISAIANTONBOYD  M      <NA>  MERCE2025 PHYSICIA1.01e9 0042I2022 EMILY <NA>   HAUGF      PA    MERCE2025 PHYSICIA1.02e9 5496I2023 MADI<NA>   THURF      OD    ILLIN2025 OPHTHALM1.02e9 2567I2024 MADI<NA>   THURF      OD    ILLIN2025 OPHTHALM1.02e9 2567I2025 MARA  S.     DETRF      <NA>  MERCE2025 PHYSICIA1.02e9 2264I2026 BRITMARIE  STENF      <NA>  MERCE2025 PHYSICIA1.04e9 7214I2027 BRITMARIE  STENF      <NA>  MERCE2025 PHYSICIA1.04e9 7214I2028 BRITMARIE  STENF      <NA>  MERCE2025 PHYSICIA1.04e9 7214I2029 BRITMARIE  STENF      <NA>  MERCE2025 PHYSICIA1.04e9 7214I20210 BRITMARIE  STENF      <NA>  MERCE2025 PHYSICIA1.04e9 7214I202# ℹ 134 more rows
# ℹ 7 more variables: org_name <chr>, org_pac <chr>, members <int>,
#   address <chr>, city <chr>, state <chr>, zip <chr>
📤 Opt-Out Affidavits
opt_out(city = "Atlanta", state = "GA")
✔ opt_out returned 352 results.order_refer returned 148 results.order_refer returned 59 results.
# A tibble: 352 × 12
        npi first last  specialty start_date end_date   updated    address city 
 *    <int> <chr> <chr> <chr>     <date>     <date>     <date>     <chr>   <chr>
 1   1.88e9 Ana   AdelClinical2012-07-01 2026-07-01 2024-08-15 675 SEATLA2   1.68e9 SherBornClinical2012-04-01 2028-04-01 2026-04-16 990 HAATLA3   1.70e9 NichHume  Clinical2018-07-01 2026-07-01 2024-08-15 693 MOATLA4   1.31e9 KeriAnasNurse Pr2012-07-01 2026-07-01 2024-08-15 5780 PATLA5   1.60e9 Carol KranPsychiat2012-01-01 2028-01-01 2026-01-15 3133 MATLA6   1.12e9 LawrGiusPsychiat2012-07-01 2026-07-01 2024-08-15 1945 CATLA7   1.39e9 Ceana NezhObstetri2012-10-01 2026-10-01 2024-11-15 5555 PATLA8   1.07e9 Frank MataIntegrat2018-04-11 2026-04-11 2024-05-15 2296 HATLA9   1.07e9 ViktBouqGeneral2012-10-01 2026-10-01 2024-11-15 4646 NATLA10   1.79e9 WillOven  Clinical2017-01-23 2027-01-23 2025-02-15 2801 BATLA# ℹ 342 more rows
# ℹ 3 more variables: state <chr>, zip <chr>, order_refer <chr>
🧾 Order & Referral Eligibility
order_refer(first = "Jennifer", last = "Smith")
✔ order_refer returned 136 results.
# A tibble: 136 × 8
   first    last         npi   ptb   dme   hha   pmd hospice
   <chr>    <chr>      <int> <int> <int> <int> <int>   <int>
 1 JENNIFER SMITH 1346518990     1     1     1     0       1
 2 JENNIFER SMITH 1366164576     1     1     1     1       0
 3 JENNIFER SMITH 1497230395     1     1     1     1       0
 4 JENNIFER SMITH 1588617773     1     1     1     1       0
 5 JENNIFER SMITH 1073921029     1     1     1     1       0
 6 JENNIFER SMITH 1134917859     1     1     1     1       0
 7 JENNIFER SMITH 1417514035     1     1     1     1       0
 8 JENNIFER SMITH 1972574770     1     1     1     1       1
 9 JENNIFER SMITH 1316939655     1     1     1     1       0
10 JENNIFER SMITH 1265417687     0     1     0     1       0
# ℹ 126 more rows
🧑‍⚕️ Medicare Enrollments
providers(state = "GA", org_name = contains("West"))
✔ providers returned 144 results.
# A tibble: 144 × 11
   org_name      first middle last  state prov_type prov_desc    npi multi pac  
   <chr>         <chr> <chr>  <chr> <chr> <chr>     <chr>      <int> <int> <chr>
 1 WESTSIDE END<NA>  <NA>   <NA>  GA    12-49     PART B S1.49e9     0 01432 WEST GEORGIA<NA>  <NA>   <NA>  GA    12-70     PART B S1.88e9     0 02443 WEST PACES S<NA>  <NA>   <NA>  GA    12-49     PART B S1.99e9     0 03454 NORTHWEST GE<NA>  <NA>   <NA>  GA    12-70     PART B S1.57e9     0 03455 CROSSROADS T<NA>  <NA>   <NA>  GA    12-D5     PART B S1.36e9     0 03456 WEST GEORGIA<NA>  <NA>   <NA>  GA    12-70     PART B S1.84e9     0 04467 PREFERRED VA<NA>  <NA>   <NA>  GA    12-70     PART B S1.79e9     0 04468 WEST COBB SP<NA>  <NA>   <NA>  GA    12-A5     PART B S1.18e9     0 04469 NORTHWEST IO<NA>  <NA>   <NA>  GA    12-70     PART B S1.22e9     0 074910 NORTHWEST EN<NA>  <NA>   <NA>  GA    12-49     PART B S1.99e9     0 0749# ℹ 134 more rows
# ℹ 1 more variable: enid <chr>
📆 Pending Enrollments
pending(first = starts("E"), last = ends("A"))
✔ pending returned 34 results.Physician     : 12Non-Physician : 22Retrieving 2 pages...
# A tibble: 34 × 4
   prov_type first     last                     npi
   <chr>     <chr>     <chr>                  <int>
 1 Physician EDUARDO   QUINONEZ ZANABRIA 1871233668
 2 Physician EILEEN    SANTA             1952440083
 3 Physician ELEANOR   FONTANA           1851233233
 4 Physician ELIAS     SALAMA            1508660655
 5 Physician ELISSA    OTA               1487414637
 6 Physician ELIZA     LAMA              1437099082
 7 Physician ELIZABETH PERAZZA           1942230891
 8 Physician ELLEN     HUHULEA           1659219442
 9 Physician ELYSSA    MOLINA            1508624891
10 Physician EMMA      COSTANZA          1538892286
# ℹ 24 more rows
🏥 Medicare Hospitals
hospitals(city = "Valdosta", state = "GA")
✔ hospitals returned 3 results.
# A tibble: 3 × 17
  org_name     org_dba enid     npi multi ccn   pac   inc_date   org_type status
* <chr>        <chr>   <chr>  <int> <int> <chr> <chr> <date>     <chr>    <chr> 
1 GREENLEAF CGREENLO2011.54e9     0 114074162012-07-13 LLC      P     
2 SOUTH GEORGSGMC HO2021.14e9     0 110110522021-11-09 CORPORAN     
3 SOUTH GEORG<NA>    O2021.60e9     0 11T110522021-11-09 CORPORAN     
# ℹ 7 more variables: address <chr>, city <chr>, state <chr>, zip <chr>,
#   loc_type <chr>, reh_date <date>, sub_group <chr>
🧪 CLIA Laboratories
clia(fac_name = starts("SGMC"), state = "GA")
✔ clia returned 32 results.
# A tibble: 32 × 22
   fac_name   fac_ccn clia_ccn chows  labs sites address city  state zip   term 
 * <chr>      <chr>   <chr>    <int> <int> <int> <chr>   <chr> <chr> <chr> <chr>
 1 SGMC HEAL11D002110122       0     1     0 2501 NVALDGA    31602 Acti2 SGMC- SMI11D002110037       0     1     0 4280 NVALDGA    31602 Acti3 SGMC WOME11D026<NA>         0     0     0 3312 NVALDGA    31605 Acti4 SGMC VALD11D02625858920     2     0 3207 CVALDGA    31605 Acti5 SGMC- LAN11D026110097       0     3     2 116 WELAKEGA    31635 Acti6 SGMC-BERR11D02611-0112      0     8     0 1221 ENASHGA    31639 Acti7 SGMC PRIM11D06925686440     0     0 410 COVALDGA    31602 Acti8 SGMC HEAL11D091<NA>         0     0     0 138 WELAKEGA    31635 Acti9 SGMC PRIM11D093<NA>         0     1     0 4370 KVALDGA    31602 Acti10 SGMC FAMI11D094<NA>         0     0     0 1225 ENASHGA    31639 Acti# ℹ 22 more rows
# ℹ 11 more variables: cert_type <chr>, fac_type <chr>, owner <chr>,
#   action <chr>, cert_date <date>, eff_date <date>, term_date <date>,
#   elig_ind <chr>, poc_ind <chr>, multi_site <chr>, acr_org <chr>
🔎 Hospital Transparency Enforcement
transparency(action = "cap", state = "GA")
✔ transparency returned 47 results.
# A tibble: 47 × 7
    case fac_name                         address city  state action action_date
   <int> <chr>                            <chr>   <chr> <chr> <chr>  <date>     
 1  1326 Anchor Hospital                  "5454 … Atla… GA    CAP R… 2023-09-15 
 2  6510 Appling Healthcare System        "163 EBaxlGA    CAP R2025-12-10 
 3   265 Archbold Memorial                "915 G… Thom… GA    CAP R… 2023-04-14 
 4  6616 Candler County Hospital          "400 CMettGA    CAP R2025-12-19 
 5   256 Coffee Regional Medical Center   "1101 … Doug… GA    CAP R… 2023-06-15 
 6  2502 Colquitt Regional Medical Center " 3131MoulGA    CAP R2024-11-25 
 7  2759 Columbus Specialty Hospital      "616 1… Colu… GA    CAP R… 2024-10-02 
 8  2759 Columbus Specialty Hospital      "616 1ColuGA    CAP R2025-01-08 
 9  6997 Dorminy Medical Center           "200 P… Fitz… GA    CAP R… 2026-02-10 
10  1318 Emory Saint Joseph's Hospital    "550 PAtlaGA    CAP R2023-10-17 
# ℹ 37 more rows

⚖️ Code of Conduct

Please note that the provider project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.

🏛️ Governance

This project is primarily maintained by Andrew Bruce. Other authors may occasionally assist with some of these duties.

About

Public Healthcare Provider APIs 🩺

Topics

Resources

License

Unknown, MIT licenses found

Licenses found

Unknown
LICENSE
MIT
LICENSE.md

Code of conduct

Stars

Watchers

Forks

Packages

 
 
 

Contributors