Downloading CMS Data
Downloading CMS Data is a bit tricky.
The base site is here: https://data.cms.gov/provider-data/docs
After beating my head against the wall, I discovered that the data key is embedded on the web page. For example, the Provider data I am using to discover how to better serve mental health needs is found as mj5m-pzi6 in the URL path https://data.cms.gov/provider-data/dataset/mj5m-pzi6.
The documentation of the data is https://data.cms.gov/provider-data/api/1/metastore/schemas/dataset/items/mj5m-pzi6/docs.
I downloaded the published file and found out there are 2376411 records, but I'm struggling to find the data profile via api.
Code for the download though is here: https://github.com/timowlmtn/bigdataplatforms/tree/master/src/cms
Here is a bit of advice though: Code reuse is overrated. Don't rely on others' code. If hand-wringers worried about no reinventing the wheel, we would still be using stone wheels. Write you own, you can do better. That's why any idea of code as IP is nonsense. No one gives a shit about your code. Data, on the other hand, is actually valuable. That's why I'm thrilled to discover this much current data in the public domain.