Draft dQM CMS Content Implementation Guide
2025.1.0 - CI Build
Draft dQM CMS Content Implementation Guide, published by cqframework. This guide is not an authorized publication; it is the continuous build for version 2025.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/cqframework/dqm-content-cms-2025/ and changes regularly. See the Directory of published versions
| Draft as of 2026-09-19 |
{
"resourceType" : "Library",
"id" : "CMS68FHIRDocumentationCurrentMeds",
"text" : {
"status" : "extensions",
"div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n <table class=\"narrative-table\">\n <tbody>\n<tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"metadata\"> </a>Metadata</th>\n\n\n</tr>\n\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Version</th>\n\n\n\n<td class=\"content-container\">1.1.000</td>\n\n\n</tr>\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Status</th>\n\n\n\n<td class=\"content-container\">Draft</td>\n\n\n</tr>\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Type</th>\n\n\n\n<td class=\"content-container\">\n <a href=\"http://terminology.hl7.org/7.1.0/CodeSystem-library-type.html\">http://terminology.hl7.org/CodeSystem/library-type</a>#logic-library\n\n\n</td>\n\n\n</tr>\n\n\n\n\n\n\n\n\n\n\n\n\n\n<tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"parameters\"> </a>Parameters</th>\n\n\n</tr>\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Parameter</th>\n\n\n\n<td class=\"content-container\">None</td>\n\n\n</tr>\n\n\n\n\n\n\n\n\n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Library Content</th>\n\n\n</tr>\n \n \n <tr>\n <th scope=\"row\" class=\"row-header\">CQL Content</th>\n <td>\n <a name=\"cql-content\"> </a>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\nNOTE: For use by March 2026 US Realm Connectathon participants for internal use only. Not for use or distribution in commercial products.\n*/\nlibrary CMS68FHIRDocumentationCurrentMeds version '1.1.000'\n\nusing USQualityCore version '0.1.0-cibuild'\nusing USCore version '6.1.0-derived'\nusing FHIR version '4.0.1'\n\ninclude hl7.fhir.uv.cql.FHIRHelpers version '4.0.1' called FHIRHelpers\ninclude hl7.fhir.uv.cql.FHIRCommon version '2.0.0' called FHIRCommon\ninclude hl7.fhir.us.cql.USCoreCommon version '2.0.0-ballot' called USCoreCommon\ninclude hl7.fhir.us.cql.USCoreElements version '2.0.0-ballot' called USCoreElements\n\ninclude USQualityCoreCommon version '0.1.0-cibuild' called USQualityCoreCommon\ninclude SupplementalDataElements version '6.1.000' called SDE\ninclude Status version '2.1.000' called Status\n\ncodesystem "SNOMEDCT": 'http://snomed.info/sct'\n\nvalueset "Encounter to Document Medications": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.600.1.1834'\n\ncode "Acute health crisis (finding)": '705016005' from "SNOMEDCT" display 'Acute health crisis (finding)'\ncode "Documentation of current medications (procedure)": '428191000124101' from "SNOMEDCT" display 'Documentation of current medications (procedure)'\n\nparameter "Measurement Period" Interval<DateTime>\n default Interval[@2026-01-01T00:00:00.000Z, @2027-01-01T00:00:00.000Z)\n\ncontext Patient\n\ndefine "SDE Ethnicity":\n SDE."SDE Ethnicity"\n\ndefine "SDE Payer":\n SDE."SDE Payer"\n\ndefine "SDE Race":\n SDE."SDE Race"\n\ndefine "SDE Sex":\n SDE."SDE Sex"\n\ndefine "Denominator":\n "Initial Population"\n\ndefine "Qualifying Encounter During Day of Measurement Period":\n ["Encounter": "Encounter to Document Medications"] ValidEncounter\n where ValidEncounter.status = 'finished'\n and ValidEncounter.period during day of "Measurement Period"\n\ndefine "Initial Population":\n "Qualifying Encounter During Day of Measurement Period" QualifyingEncounter\n\ndefine "Numerator":\n "Qualifying Encounter During Day of Measurement Period" QualifyingEncounter\n with [Procedure: "Documentation of current medications (procedure)"] MedicationsDocumented\n such that MedicationsDocumented.performed.toInterval ( ) starts during day of QualifyingEncounter.period\n and MedicationsDocumented.performed.toInterval ( ).hasEnd ( )\n and MedicationsDocumented.status = 'completed'\n\ndefine "Denominator Exceptions":\n "Qualifying Encounter During Day of Measurement Period" QualifyingEncounter\n with [ProcedureNotDone: code ~ "Documentation of current medications (procedure)"] MedicationsNotDocumented\n such that MedicationsNotDocumented.recorded ( ) during day of QualifyingEncounter.period\n and MedicationsNotDocumented.status = 'not-done'\n and exists ( MedicationsNotDocumented.reasonCode reasonItem\n where reasonItem ~ "Acute health crisis (finding)"\n )</code></pre>\n </td>\n </tr>\n \n \n\n\n\n<tr>\n <th colspan=\"2\" scope=\"row\" class=\"row-header\">Generated using version 0.5.6 of the sample-content-ig Liquid templates</th>\n</tr>\n\n </tbody>\n </table>\n</div>"
},
"extension" : [
{
"url" : "http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-softwaresystem",
"valueReference" : {
"reference" : "Device/cqf-tooling"
}
}
],
"url" : "https://madie.cms.gov/Library/CMS68FHIRDocumentationCurrentMeds",
"version" : "1.1.000",
"name" : "CMS68FHIRDocumentationCurrentMeds",
"status" : "draft",
"type" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/library-type",
"code" : "logic-library"
}
]
},
"date" : "2026-09-19T16:31:14+00:00",
"content" : [
{
"contentType" : "text/cql",
"data" : "LyoKTk9URTogRm9yIHVzZSBieSBNYXJjaCAyMDI2IFVTIFJlYWxtIENvbm5lY3RhdGhvbiBwYXJ0aWNpcGFudHMgZm9yIGludGVybmFsIHVzZSBvbmx5LiBOb3QgZm9yIHVzZSBvciBkaXN0cmlidXRpb24gaW4gY29tbWVyY2lhbCBwcm9kdWN0cy4KKi8KbGlicmFye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