digoxin-cyclosporine-cds-sign
type: PlanDefinition
node role: treeRoot
id:
  v: digoxin-cyclosporine-cds-sign
language:
  v: en
text:
  status:
    v: extensions
  div:
    v: Metadata Title Digoxin Cyclosporine Order Sign Recommendation Version 1.0.0 Experimental true Jurisdiction 001 from http://unstats.un.org/unsd/methods/m49/m49.htm Topic Digoxin Cyclosporine Prescribing Steward (Publisher) HL7 International / Clinical Decision Support Description Drug-drug interaction recommendation for use on order sign of a digoxin or cyclosporine Type ECA Rule PlanDefinition Action Trigger Type Named Event Trigger Name order-sign Condition Kind: Applicability Logic Definition: Inclusion Criteria PlanDefinition Sub-Action Title Potential Drug-Drug Interaction between digoxin (product) and cyclosporine (product) Description Increased risk of digoxin toxicity. Assess risk and take action if necessary. Digoxin toxicity is potentially serious. The clinical consequences may include anorexia, nausea, vomiting, visual changes, and cardiac arrhythmias. The mechanism of this interaction appears to be mediated through P-glycoprotein inhibition by cyclosporine. P-glycoprotein is a major transporter for digoxin efflux. unknown. unknown. Dynamic Value Path: action.title Logic Definition: Get Base Summary Dynamic Value Path: action.description Logic Definition: Get Base Detail Dynamic Value Path: activity.extension Logic Definition: Get Base Indicator PlanDefinition Sub-Action (Parent Action Title: Potential Drug-Drug Interaction between digoxin (product) and cyclosporine (product)) Title Consultation Description Request communication with digoxin prescriber Condition Kind: Applicability Logic Definition: Is Context medication digoxin Type create from http://terminology.hl7.org/CodeSystem/action-type Definition ActivityDefinition AD201 PlanDefinition Sub-Action (Parent Action Title: Potential Drug-Drug Interaction between digoxin (product) and cyclosporine (product)) Title Consultation Description Request communication with cyclosporine prescriber Condition Kind: Applicability Logic Definition: Is Context medication cyclosporine Type create from http://terminolo…
contained: Library
  id:
    v: effective-data-requirements
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Digoxin Prescription
    extension:
      url:
        v: statement
      value: string
        v: define "Digoxin Prescription": ContextPrescriptions P where P.medication in "Digoxin" return P.medication as CodeableConcept
    extension:
      url:
        v: displaySequence
      value: integer
        v: 0
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Is Context medication digoxin
    extension:
      url:
        v: statement
      value: string
        v: define "Is Context medication digoxin": exists ("Digoxin Prescription")
    extension:
      url:
        v: displaySequence
      value: integer
        v: 1
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Digoxin Rx
    extension:
      url:
        v: statement
      value: string
        v: define "Digoxin Rx": ( [MedicationRequest: "Digoxin"] MR where MR.authoredOn.toInterval() during Interval[Today() - 100 days, null] return MR.medication as CodeableConcept ) union ( [MedicationAdministration: "Digoxin"] MA where MA.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MA.medication as CodeableConcept ) union ( [MedicationDispense: "Digoxin"] MD where MD.whenHandedOver.toInterval() during Interval[Today() - 100 days, null] return MD.medication as CodeableConcept ) union ( [MedicationStatement: "Digoxin"] MS where MS.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MS.medication as CodeableConcept )
    extension:
      url:
        v: displaySequence
      value: integer
        v: 2
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Is digoxin in prefetch
    extension:
      url:
        v: statement
      value: string
        v: define "Is digoxin in prefetch": exists ("Digoxin Rx")
    extension:
      url:
        v: displaySequence
      value: integer
        v: 3
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Is continuation order for digoxin
    extension:
      url:
        v: statement
      value: string
        v: define "Is continuation order for digoxin": "Is Context medication digoxin" and "Is digoxin in prefetch"
    extension:
      url:
        v: displaySequence
      value: integer
        v: 4
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Cyclosporine Prescription
    extension:
      url:
        v: statement
      value: string
        v: define "Cyclosporine Prescription": ContextPrescriptions P where P.medication in "Cyclosporine" return P.medication as CodeableConcept
    extension:
      url:
        v: displaySequence
      value: integer
        v: 5
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Is Context medication cyclosporine
    extension:
      url:
        v: statement
      value: string
        v: define "Is Context medication cyclosporine": exists ("Cyclosporine Prescription")
    extension:
      url:
        v: displaySequence
      value: integer
        v: 6
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic
    extension:
      url:
        v: name
      value: string
        v: Cyclosporine Rx
    extension:
      url:
        v: statement
      value: string
        v: define "Cyclosporine Rx": ( [MedicationRequest: "Cyclosporine"] MR where MR.authoredOn.toInterval() during Interval[Today() - 100 days, null] return MR.medication as CodeableConcept ) union ( [MedicationAdministration: "Cyclosporine"] MA where MA.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MA.medication as CodeableConcept ) union ( [MedicationDispense: "Cyclosporine"] MD where MD.whenHandedOver.toInterval() during Interval[Today() - 100 days, null] return MD.medication as CodeableConcept ) union ( [MedicationStatement: "Cyclosporine"] MS where MS.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MS.medication as CodeableConcept )
    extension:
      url:
        v: displaySequence
      value: integer
        v: 7
    url:
      v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition
  extension:
    extension:
      url:
        v: libraryName
      value: string
        v: DigoxinCyclosporineCDSLogic

url:
  v: name
value: string
  v: Is cyclosporine in prefetch

url:
  v: statement
value: string
  v: define "Is cyclosporine in prefetch": exists ("Cyclosporine Rx")

url:
  v: displaySequence
value: integer
  v: 8

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Is continuation order for cyclosporine
extension:
  url:
    v: statement
  value: string
    v: define "Is continuation order for cyclosporine": "Is Context medication cyclosporine" and "Is cyclosporine in prefetch"
extension:
  url:
    v: displaySequence
  value: integer
    v: 9
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Normal Digoxin Observation
extension:
  url:
    v: statement
  value: string
    v: define "Normal Digoxin Observation": Last ( [Observation: "Digoxin LOINC"] O where O.effective.toInterval() during Interval[Today() - 30 days, null] and O.value < 0.9 'ng/mL' sort by start of effective.toInterval() )
extension:
  url:
    v: displaySequence
  value: integer
    v: 10
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Is there a normal digoxin level in prefetch
extension:
  url:
    v: statement
  value: string
    v: define "Is there a normal digoxin level in prefetch": "Normal Digoxin Observation" is not null
extension:
  url:
    v: displaySequence
  value: integer
    v: 11
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Aldosterone Antagonists Rx
extension:
  url:
    v: statement
  value: string
    v: define "Aldosterone Antagonists Rx": ( [MedicationRequest: "Aldosterone Antagonists"] MR where MR.authoredOn.toInterval() during Interval[Today() - 100 days, null] return MR.medication as CodeableConcept ) union ( [MedicationAdministration: "Aldosterone Antagonists"] MA where MA.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MA.medication as CodeableConcept ) union ( [MedicationDispense: "Aldosterone Antagonists"] MD where MD.whenHandedOver.toInterval() during Interval[Today() - 100 days, null] return MD.medication as CodeableConcept ) union ( [MedicationStatement: "Aldosterone Antagonists"] MS where MS.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MS.medication as CodeableConcept )
extension:
  url:
    v: displaySequence
  value: integer
    v: 12
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Loop Diuretics Rx
extension:
  url:
    v: statement
  value: string
    v: define "Loop Diuretics Rx": ( [MedicationRequest: "Loop Diuretics"] MR where MR.authoredOn.toInterval() during Interval[Today() - 100 days, null] return MR.medication as CodeableConcept ) union ( [MedicationAdministration: "Loop Diuretics"] MA where MA.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MA.medication as CodeableConcept ) union ( [MedicationDispense: "Loop Diuretics"] MD where MD.whenHandedOver.toInterval() during Interval[Today() - 100 days, null] return MD.medication as CodeableConcept ) union ( [MedicationStatement: "Loop Diuretics"] MS where MS.effective.toInterval() overlaps Interval[Today() - 100 days, null] return MS.medication as CodeableConcept )
extension:
  url:
    v: displaySequence
  value: integer
    v: 13
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Are diuretics in prefetch
extension:
  url:
    v: statement
  value: string
    v: define "Are diuretics in prefetch": exists ("Aldosterone Antagonists Rx") or exists("Loop Diuretics Rx")
extension:
  url:
    v: displaySequence
  value: integer
    v: 14
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Normal Potassium Observation
extension:
  url:
    v: statement
  value: string
    v: define "Normal Potassium Observation": Last ( [Observation: "Potassium LOINC"] O where O.effective.toInterval() during Interval[Today() - 365 days, null] and O.value > 3.5 'meq/L' and O.value < 5.0 'meq/L' sort by start of effective.toInterval() )
extension:
  url:
    v: displaySequence
  value: integer
    v: 15
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Normal Magnesium Observation
extension:
  url:
    v: statement
  value: string
    v: define "Normal Magnesium Observation": Last ( [Observation: "Magnesium LOINC"] O where O.effective.toInterval() during Interval[Today() - 365 days, null] and O.value > 0.7 'mmol/L' and O.value < 1.1 'mmol/L' sort by start of effective.toInterval() )
extension:
  url:
    v: displaySequence
  value: integer
    v: 16
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Normal Calcium Observation
extension:
  url:
    v: statement
  value: string
    v: define "Normal Calcium Observation": Last ( [Observation: "Calcium LOINC"] O where O.effective.toInterval() during Interval[Today() - 365 days, null] and O.value > 8.5 'mg/dL' and O.value < 10.2 'mg/dL' sort by start of effective.toInterval() )
extension:
  url:
    v: displaySequence
  value: integer
    v: 17
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Is there a normal electrolyte observation in prefetch
extension:
  url:
    v: statement
  value: string
    v: define "Is there a normal electrolyte observation in prefetch": "Normal Potassium Observation" is not null and "Normal Magnesium Observation" is not null and "Normal Calcium Observation" is not null
extension:
  url:
    v: displaySequence
  value: integer
    v: 18
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Normal Renal Observation
extension:
  url:
    v: statement
  value: string
    v: define "Normal Renal Observation": Last ( [Observation: "Renal LOINC"] O where O.effective.toInterval() during Interval[Today() - 365 days, null] and O.value > 0.6 'mg/dL' and O.value < 1.2 'mg/dL' sort by start of effective.toInterval() )
extension:
  url:
    v: displaySequence
  value: integer
    v: 19
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Is there a normal renal observation in prefetch
extension:
  url:
    v: statement
  value: string
    v: define "Is there a normal renal observation in prefetch": "Normal Renal Observation" is not null
extension:
  url:
    v: displaySequence
  value: integer
    v: 20
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Is there a normal electrolyte and renal observation in prefetch
extension:
  url:
    v: statement
  value: string
    v: define "Is there a normal electrolyte and renal observation in prefetch": "Is there a normal electrolyte observation in prefetch" and "Is there a normal renal observation in prefetch"
extension:
  url:
    v: displaySequence
  value: integer
    v: 21
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Are diuretics or abnormal electrolyte or abnormal renal observations in prefetch
extension:
  url:
    v: statement
  value: string
    v: define "Are diuretics or abnormal electrolyte or abnormal renal observations in prefetch": "Are diuretics in prefetch" or not "Is there a normal electrolyte and renal observation in prefetch"
extension:
  url:
    v: displaySequence
  value: integer
    v: 22
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Base Indicator
extension:
  url:
    v: statement
  value: string
    v: define "Get Base Indicator": if "Is continuation order for digoxin" or "Is continuation order for cyclosporine" then if "Is there a normal digoxin level in prefetch" then if "Are diuretics or abnormal electrolyte or abnormal renal observations in prefetch" then 'warning' else 'info' else 'warning' else 'warning'
extension:
  url:
    v: displaySequence
  value: integer
    v: 23
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Card 2 Summary
extension:
  url:
    v: statement
  value: string
    v: define "Get Card 2 Summary": if "Is there a normal digoxin level in prefetch" then 'Patient has digoxin level within 30 days that is below 0.9 ng/mL (SI: 1.2 nmol/L)' else 'Patient does not have digoxin level on record within the last 30 days. '
extension:
  url:
    v: displaySequence
  value: integer
    v: 24
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Inclusion Criteria
extension:
  url:
    v: statement
  value: string
    v: /* ** ** Digoxin Cyclosporine CDS Recommendation ** */ define "Inclusion Criteria": ( "Is Context medication cyclosporine" and "Is digoxin in prefetch" ) or ( "Is Context medication digoxin" and "Is cyclosporine in prefetch" )
extension:
  url:
    v: displaySequence
  value: integer
    v: 25
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Card 3 Summary
extension:
  url:
    v: statement
  value: string
    v: define "Get Card 3 Summary": if "Is there a normal electrolyte and renal observation in prefetch" then 'Within 100 days, the patient has had electrolyte and serum creatinine levels checked, and they are not on a potassium sparing or loop diuretic.' else 'Within 100 days, the patient has not had an electrolyte panel. The patient does have serum creatinine level and is not on a potassium sparing or loop diuretic.'
extension:
  url:
    v: displaySequence
  value: integer
    v: 26
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Card 2 Detail
extension:
  url:
    v: statement
  value: string
    v: define "Get Card 2 Detail": if "Is there a normal digoxin level in prefetch" then '(Digoxin: ' + Common.GetLevelAndDate("Normal Digoxin Observation") + '). \nFor patients with a reliable plasma digoxin concentration in normal range, it is reasonable to anticipate an increase in plasma concentrations after the initiation of cyclosporine. Following initiation, close monitoring and adjusting the digoxin dose as needed is recommended' else 'Initiating cyclosporine is expected to increase digoxin levels. For patients without a reliable plasma digoxin concentration in normal range, use only if benefits outweight risks. Extreme caution and close monitoring is necessary.'
extension:
  url:
    v: displaySequence
  value: integer
    v: 27
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Is new order for digoxin
extension:
  url:
    v: statement
  value: string
    v: define "Is new order for digoxin": "Is Context medication digoxin" and not "Is digoxin in prefetch"
extension:
  url:
    v: displaySequence
  value: integer
    v: 28
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Card 3 Detail
extension:
  url:
    v: statement
  value: string
    v: define "Get Card 3 Detail": if "Is there a normal electrolyte and renal observation in prefetch" then '(Potassium: ' + Common.GetLevelAndDate("Normal Potassium Observation") + ')\n (Magnesium: ' + Common.GetLevelAndDate("Normal Magnesium Observation") + ')\n (Calcium: ' + Common.GetLevelAndDate("Normal Calcium Observation") + ')\n' else '' + '(Serum creatinine: ' + Common.GetLevelAndDate("Normal Renal Observation") + ')\n Hypokalemia, hypomagnesemia, and hypercalcemia may potentiate digoxin toxicity. 50-70% of digoxin is excreted unchanged in the urine. Changing renal function may increase serum concentrations and risk of toxicity.'
extension:
  url:
    v: displaySequence
  value: integer
    v: 29
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Card 3 Indicator
extension:
  url:
    v: statement
  value: string
    v: // Card 3 define "Get Card 3 Indicator": if "Is there a normal electrolyte and renal observation in prefetch" then 'info' else 'warning'
extension:
  url:
    v: displaySequence
  value: integer
    v: 30
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Base Detail
extension:
  url:
    v: statement
  value: string
    v: define "Get Base Detail": 'Increased risk of digoxin toxicity. Assess risk and take action if necessary. \nDigoxin toxicity is potentially serious. The clinical consequences may include anorexia, nausea, vomiting, visual changes, and cardiac arrhythmias. \nThe mechanism of this interaction appears to be mediated through P-glycoprotein inhibition by cyclosporine. P-glycoprotein is a major transporter for digoxin efflux. \nunknown. \nunknown.'
extension:
  url:
    v: displaySequence
  value: integer
    v: 31
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Need to reduce Digoxin dose
extension:
  url:
    v: statement
  value: string
    v: define "Need to reduce Digoxin dose": "Is Context medication cyclosporine" or not "Is there a normal digoxin level in prefetch"
extension:
  url:
    v: displaySequence
  value: integer
    v: 32
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Is new order for cyclosporine
extension:
  url:
    v: statement
  value: string
    v: define "Is new order for cyclosporine": "Is Context medication cyclosporine" and not "Is cyclosporine in prefetch"
extension:
  url:
    v: displaySequence
  value: integer
    v: 33
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Card 2 Indicator
extension:
  url:
    v: statement
  value: string
    v: // Card 2 define "Get Card 2 Indicator": if "Is new order for cyclosporine" then if "Is there a normal digoxin level in prefetch" then 'warning' else 'critical' else if "Is there a normal digoxin level in prefetch" then 'info' else 'warning'
extension:
  url:
    v: displaySequence
  value: integer
    v: 34
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: DigoxinCyclosporineCDSLogic
extension:
  url:
    v: name
  value: string
    v: Get Base Summary
extension:
  url:
    v: statement
  value: string
    v: // Card 1: Base define "Get Base Summary": 'Potential Drug-Drug Interaction between digoxin (' + ( if "Is Context medication digoxin" then Common.GetDrugNames("Digoxin Prescription") else Common.GetDrugNames("Digoxin Rx") ) + ') and cyclosporine (' + ( if "Is Context medication cyclosporine" then Common.GetDrugNames("Cyclosporine Prescription") else Common.GetDrugNames("Cyclosporine Rx") ) + ')'
extension:
  url:
    v: displaySequence
  value: integer
    v: 35
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToConcept
extension:
  url:
    v: statement
  value: string
    v: /* @description: Converts the given FHIR [CodeableConcept](https://hl7.org/fhir/datatypes.html#CodeableConcept) value to a CQL Concept. */ define function ToConcept(concept FHIR.CodeableConcept): if concept is null then null else System.Concept { codes: concept.coding C return ToCode(C), display: concept.text.value }
extension:
  url:
    v: displaySequence
  value: integer
    v: 36
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToCode
extension:
  url:
    v: statement
  value: string
    v: /* @description: Converts the given FHIR [Coding](https://hl7.org/fhir/datatypes.html#Coding) value to a CQL Code. */ define function ToCode(coding FHIR.Coding): if coding is null then null else System.Code { code: coding.code.value, system: coding.system.value, version: coding.version.value, display: coding.display.value }
extension:
  url:
    v: displaySequence
  value: integer
    v: 37
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToString
extension:
  url:
    v: statement
  value: string
    v: define function ToString(value string): value.value
extension:
  url:
    v: displaySequence
  value: integer
    v: 38
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRCommon
extension:
  url:
    v: name
  value: string
    v: toInterval
extension:
  url:
    v: statement
  value: string
    v: /* @description: Normalizes a value that is a choice of timing-valued types to an equivalent interval @comment: Normalizes a choice type of FHIR.dateTime, FHIR.Period, FHIR.Timing, FHIR.instance, FHIR.string, FHIR.Age, or FHIR.Range types to an equivalent interval. This selection of choice types is a superset of the majority of choice types that are used as possible representations for timing-valued elements in FHIR, allowing this function to be used across any resource. The input can be provided as a dateTime, Period, Timing, instant, string, Age, or Range. The intent of this function is to provide a clear and concise mechanism to treat single elements that have multiple possible representations as intervals so that logic doesn't have to account for the variability. More complex calculations (such as medication request period or dispense period calculation) need specific guidance and consideration. That guidance may make use of this function, but the focus of this function is on single element calculations where the semantics are unambiguous. If the input is a dateTime, the result a DateTime Interval beginning and ending on that dateTime. If the input is a Period, the result is a DateTime Interval. If the input is a Timing, an error is raised indicating a single interval cannot be computed from a Timing. If the input is an instant, the result is a DateTime Interval beginning and ending on that instant. If the input is a string, an error is raised indicating a single interval cannot be computed from a string. If the input is an Age, the result is a DateTime Interval beginning when the patient was the given Age, and ending immediately prior to when the patient was the given Age plus one year. If the input is a Range, the result is a DateTime Interval beginning when the patient was the Age given by the low end of the Range, and ending immediately prior to when the patient was the Age given by the high end of the Range plus one year. NOTE: Due to the complexity of dete…
extension:
  url:
    v: displaySequence
  value: integer
    v: 39
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToDateTime
extension:
  url:
    v: statement
  value: string
    v: define function ToDateTime(value dateTime): value.value
extension:
  url:
    v: displaySequence
  value: integer
    v: 40
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToInterval
extension:
  url:
    v: statement
  value: string
    v: /* @description: Converts the given [Period](https://hl7.org/fhir/datatypes.html#Period) value to a CQL DateTime Interval @comment: If the start value of the given period is unspecified, the starting boundary of the resulting interval will be open (meaning the start of the interval is unknown, as opposed to interpreted as the beginning of time). */ define function ToInterval(period FHIR.Period): if period is null then null else if period."start" is null then Interval(period."start".value, period."end".value] else Interval[period."start".value, period."end".value]
extension:
  url:
    v: displaySequence
  value: integer
    v: 41
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToDateTime
extension:
  url:
    v: statement
  value: string
    v: define function ToDateTime(value instant): value.value
extension:
  url:
    v: displaySequence
  value: integer
    v: 42
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToDate
extension:
  url:
    v: statement
  value: string
    v: define function ToDate(value date): value.value
extension:
  url:
    v: displaySequence
  value: integer
    v: 43
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToQuantity
extension:
  url:
    v: statement
  value: string
    v: /* @description: Converts the given FHIR [Quantity](https://hl7.org/fhir/datatypes.html#Quantity) value to a CQL Quantity @comment: If the given quantity has a comparator specified, a runtime error is raised. If the given quantity has a system other than UCUM (i.e. `http://unitsofmeasure.org`) or CQL calendar units (i.e. `http://hl7.org/fhirpath/CodeSystem/calendar-units`) an error is raised. For UCUM to calendar units, the `ToCalendarUnit` function is used. @seealso: ToCalendarUnit */ define function ToQuantity(quantity FHIR.Quantity): case when quantity is null then null when quantity.value is null then null when quantity.comparator is not null then Message(null, true, 'FHIRHelpers.ToQuantity.ComparatorQuantityNotSupported', 'Error', 'FHIR Quantity value has a comparator and cannot be converted to a System.Quantity value.') when quantity.system is null or quantity.system.value = 'http://unitsofmeasure.org' or quantity.system.value = 'http://hl7.org/fhirpath/CodeSystem/calendar-units' then System.Quantity { value: quantity.value.value, unit: ToCalendarUnit(Coalesce(quantity.code.value, quantity.unit.value, '1')) } else Message(null, true, 'FHIRHelpers.ToQuantity.InvalidFHIRQuantity', 'Error', 'Invalid FHIR Quantity code: ' & quantity.unit.value & ' (' & quantity.system.value & '|' & quantity.code.value & ')') end
extension:
  url:
    v: displaySequence
  value: integer
    v: 44
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: FHIRHelpers
extension:
  url:
    v: name
  value: string
    v: ToCalendarUnit
extension:
  url:
    v: statement
  value: string
    v: /* @description: Converts a UCUM definite duration unit to a CQL calendar duration unit using conversions specified in the [quantities](https://cql.hl7.org/02-authorsguide.html#quantities) topic of the CQL specification. @comment: Note that for durations above days (or weeks), the conversion is understood to be approximate */ define function ToCalendarUnit(unit System.String): case unit when 'ms' then 'millisecond' when 's' then 'second' when 'min' then 'minute' when 'h' then 'hour' when 'd' then 'day' when 'wk' then 'week' when 'mo' then 'month' when 'a' then 'year' else unit end
extension:
  url:
    v: displaySequence
  value: integer
    v: 45
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: PDDICDSCommon
extension:
  url:
    v: name
  value: string
    v: GetLevelAndDate
extension:
  url:
    v: statement
  value: string
    v: define function GetLevelAndDate(observation Observation): if observation is not null then ToString(ToQuantity(observation.value as Quantity)) + ' and ' + ToString(observation.effective.value) else 'NA'
extension:
  url:
    v: displaySequence
  value: integer
    v: 46
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: PDDICDSCommon
extension:
  url:
    v: name
  value: string
    v: ToQuantity
extension:
  url:
    v: statement
  value: string
    v: define function ToQuantity(quantity FHIR.Quantity): System.Quantity { value: quantity.value.value, unit: quantity.unit.value }
extension:
  url:
    v: displaySequence
  value: integer
    v: 47
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: PDDICDSCommon
extension:
  url:
    v: name
  value: string
    v: GetDrugNames
extension:
  url:
    v: statement
  value: string
    v: define function GetDrugNames(codes List<FHIR.CodeableConcept>): Combine( flatten( codes C return C.coding coding return ToCode(coding).display ) ,', ' )
extension:
  url:
    v: displaySequence
  value: integer
    v: 48
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

extension:
  url:
    v: libraryName
  value: string
    v: PDDICDSCommon
extension:
  url:
    v: name
  value: string
    v: ToCode
extension:
  url:
    v: statement
  value: string
    v: define function ToCode(coding FHIR.Coding): System.Code { code: coding.code.value, system: coding.system.value, version: coding.version.value, display: coding.display.value }
extension:
  url:
    v: displaySequence
  value: integer
    v: 49
url:
  v: http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition

v: EffectiveDataRequirements

v: active

coding:
  system:
    v: http://terminology.hl7.org/CodeSystem/library-type
  code:
    v: module-definition

type:
  v: depends-on
display:
  v: FHIR model information
resource:
  v: http://hl7.org/fhir/uv/cql/Library/FHIR-ModelInfo|4.0.1
  link: 4.0
  link: .1

type:
  v: depends-on
display:
  v: Library FHIRHelpers
resource:
  v: http://hl7.org/fhir/uv/cql/Library/FHIRHelpers|4.0.1
  link: 4.0
  link: .1

type:
  v: depends-on
display:
  v: Library FHIRCommon
resource:
  v: http://hl7.org/fhir/uv/cql/Library/FHIRCommon|2.0.0
  link: 2.0
  link: .0

type:
  v: depends-on
display:
  v: Library Common
resource:
  v: http://hl7.org/fhir/uv/pddi/Library/PDDICDSCommon|1.0.0
  link: 1.0
  link: .0

type:
  v: depends-on
display:
  v: Value set Digoxin
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin

type:
  v: depends-on
display:
  v: Value set Cyclosporine
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine

type:
  v: depends-on
display:
  v: Value set Digoxin LOINC
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin-LOINC
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin-LOINC

type:
  v: depends-on
display:
  v: Value set Aldosterone Antagonists
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS

type:
  v: depends-on
display:
  v: Value set Loop Diuretics
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC

type:
  v: depends-on
display:
  v: Value set Potassium LOINC
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-potassium-LOINC
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-potassium-LOINC

type:
  v: depends-on
display:
  v: Value set Magnesium LOINC
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-magnesium-LOINC
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-magnesium-LOINC

type:
  v: depends-on
display:
  v: Value set Calcium LOINC
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-calcium-LOINC
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-calcium-LOINC

type:
  v: depends-on
display:
  v: Value set Renal LOINC
resource:
  v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-renal-LOINC
  link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-renal-LOINC

name:
  v: ContextPrescriptions
use:
  v: in
min:
  v: 0
max:
  v: *
type:
  v: MedicationRequest

name:
  v: Get Base Indicator
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Get Card 2 Summary
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Inclusion Criteria
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: boolean

name:
  v: Get Card 3 Summary
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Is Context medication cyclosporine
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: boolean

name:
  v: Get Card 2 Detail
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Is digoxin in prefetch
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: boolean

name:
  v: Is new order for digoxin
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: boolean

name:
  v: Get Card 3 Detail
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Get Card 3 Indicator
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Get Base Detail
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Need to reduce Digoxin dose
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: boolean

name:
  v: Is Context medication digoxin
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: boolean

name:
  v: Get Card 2 Indicator
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

name:
  v: Get Base Summary
use:
  v: out
min:
  v: 0
max:
  v: 1
type:
  v: string

type:
  v: Patient
profile:
  v: http://hl7.org/fhir/StructureDefinition/Patient
  link: http://hl7.org/fhir/StructureDefinition/Patient

type:
  v: MedicationRequest
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationRequest
  link: http://hl7.org/fhir/StructureDefinition/MedicationRequest
must support:
  v: medication
must support:
  v: authoredOn
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin

type:
  v: MedicationRequest
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationRequest
  link: http://hl7.org/fhir/StructureDefinition/MedicationRequest
must support:
  v: medication
must support:
  v: authoredOn
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine

type:
  v: MedicationRequest
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationRequest
  link: http://hl7.org/fhir/StructureDefinition/MedicationRequest
must support:
  v: medication
must support:
  v: authoredOn
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS

type:
  v: MedicationRequest
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationRequest
  link: http://hl7.org/fhir/StructureDefinition/MedicationRequest
must support:
  v: medication
must support:
  v: authoredOn
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC

type:
  v: MedicationRequest
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationRequest
  link: http://hl7.org/fhir/StructureDefinition/MedicationRequest
must support:
  v: medication.reference
must support:
  v: medication
must support:
  v: authoredOn

type:
  v: Medication
profile:
  v: http://hl7.org/fhir/StructureDefinition/Medication
  link: http://hl7.org/fhir/StructureDefinition/Medication
must support:
  v: id
must support:
  v: code

type:
  v: MedicationAdministration
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
  link: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin

type:
  v: MedicationAdministration
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
  link: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine

type:
  v: MedicationAdministration
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
  link: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS

type:
  v: MedicationAdministration
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
  link: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC

type:
  v: MedicationAdministration
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
  link: http://hl7.org/fhir/StructureDefinition/MedicationAdministration
must support:
  v: medication.reference
must support:
  v: effective
must support:
  v: medication

type:
  v: MedicationDispense
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationDispense
  link: http://hl7.org/fhir/StructureDefinition/MedicationDispense
must support:
  v: medication
must support:
  v: whenHandedOver
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin

type:
  v: MedicationDispense
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationDispense
  link: http://hl7.org/fhir/StructureDefinition/MedicationDispense
must support:
  v: medication
must support:
  v: whenHandedOver
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine

type:
  v: MedicationDispense
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationDispense
  link: http://hl7.org/fhir/StructureDefinition/MedicationDispense
must support:
  v: medication
must support:
  v: whenHandedOver
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS

type:
  v: MedicationDispense
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationDispense
  link: http://hl7.org/fhir/StructureDefinition/MedicationDispense
must support:
  v: medication
must support:
  v: whenHandedOver
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC

type:
  v: MedicationDispense
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationDispense
  link: http://hl7.org/fhir/StructureDefinition/MedicationDispense
must support:
  v: medication.reference
must support:
  v: whenHandedOver
must support:
  v: medication

type:
  v: MedicationStatement
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationStatement
  link: http://hl7.org/fhir/StructureDefinition/MedicationStatement
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin

type:
  v: MedicationStatement
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationStatement
  link: http://hl7.org/fhir/StructureDefinition/MedicationStatement
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-cyclosporine

type:
  v: MedicationStatement
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationStatement
  link: http://hl7.org/fhir/StructureDefinition/MedicationStatement
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-AAS

type:
  v: MedicationStatement
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationStatement
  link: http://hl7.org/fhir/StructureDefinition/MedicationStatement
must support:
  v: medication
must support:
  v: effective
code filter:
  path:
    v: medication
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-LOOPDIURETIC

type:
  v: MedicationStatement
profile:
  v: http://hl7.org/fhir/StructureDefinition/MedicationStatement
  link: http://hl7.org/fhir/StructureDefinition/MedicationStatement
must support:
  v: medication.reference
must support:
  v: effective
must support:
  v: medication

type:
  v: Observation
profile:
  v: http://hl7.org/fhir/StructureDefinition/Observation
  link: http://hl7.org/fhir/StructureDefinition/Observation
must support:
  v: code
must support:
  v: effective
must support:
  v: value
code filter:
  path:
    v: code
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-potassium-LOINC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-potassium-LOINC

type:
  v: Observation
profile:
  v: http://hl7.org/fhir/StructureDefinition/Observation
  link: http://hl7.org/fhir/StructureDefinition/Observation
must support:
  v: code
must support:
  v: effective
must support:
  v: value
code filter:
  path:
    v: code
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-magnesium-LOINC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-magnesium-LOINC

type:
  v: Observation
profile:
  v: http://hl7.org/fhir/StructureDefinition/Observation
  link: http://hl7.org/fhir/StructureDefinition/Observation
must support:
  v: code
must support:
  v: effective
must support:
  v: value
code filter:
  path:
    v: code
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-calcium-LOINC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-calcium-LOINC

type:
  v: Observation
profile:
  v: http://hl7.org/fhir/StructureDefinition/Observation
  link: http://hl7.org/fhir/StructureDefinition/Observation
must support:
  v: code
must support:
  v: effective
must support:
  v: value
code filter:
  path:
    v: code
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin-LOINC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-digoxin-LOINC

type:
  v: Observation
profile:
  v: http://hl7.org/fhir/StructureDefinition/Observation
  link: http://hl7.org/fhir/StructureDefinition/Observation
must support:
  v: code
must support:
  v: effective
must support:
  v: value
code filter:
  path:
    v: code
  value set:
    v: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-renal-LOINC
    link: http://hl7.org/fhir/uv/pddi/ValueSet/valueset-renal-LOINC

extension:
  url:
    v: code
  value: string
    v: filter-out-repeated-alerts
extension:
  url:
    v: type
  value: string
    v: boolean
extension:
  url:
    v: name
  value: string
    v: Filter out repeated alerts
extension:
  url:
    v: description
  value: string
    v: Only works if both this configuration option is set to 'true' and cache-for-order-sign-filtering was set to 'true' in an order-select request. Uses information about this CDS call to filter aparently repititious card. Currently, this only supports filtering out cards that were triggered by the same knowledge artifact when the physician reference display, encounter id, and patient id match between the order-select and order-sign requests.
url:
  v: http://hl7.org/fhir/uv/pddi/StructureDefinition/pddi-cds-configuration-options

extension:
  url:
    v: code
  value: string
    v: alert-non-serious
extension:
  url:
    v: type
  value: string
    v: boolean
extension:
  url:
    v: name
  value: string
    v: Alert for non-serious potential drug-drug interactions
extension:
  url:
    v: description
  value: string
    v: Serious potential drug-drug interactions could result in death; requires hospitalization or extension of hospital stay; results in persistent or significant disability or incapacity; is life-threatening (see https://www.w3.org/2019/05/pddi/index.html). If set to True, this configuration option tells the CDS service to alerts for potential drug-drug interactions that do not meet this criterion.
url:
  v: http://hl7.org/fhir/uv/pddi/StructureDefinition/pddi-cds-configuration-options

extension:
  url:
    v: code
  value: string
    v: show-evidence-support
extension:
  url:
    v: type
  value: string
    v: boolean
extension:
  url:
    v: name
  value: string
    v: Show evidence support
extension:
  url:
    v: description
  value: string
    v: If this options is set to True, CDS response cards will provide more complete information about the evidence that supports the potential drug-drug interaction alert.
url:
  v: http://hl7.org/fhir/uv/pddi/StructureDefinition/pddi-cds-configuration-options

url:
  v: http://hl7.org/fhir/StructureDefinition/structuredefinition-wg
value: code
  v: cds

url:
  v: http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-effectiveDataRequirements
value: canonical
  v: #effective-data-requirements

v: 1.0.0

v: DigoxinCyclosporineOrderSignRecommendation

v: Digoxin Cyclosporine Order Sign Recommendation

coding:
  system:
    v: http://terminology.hl7.org/CodeSystem/plan-definition-type
  code:
    v: eca-rule
  display:
    v: ECA Rule

v: active

v: true

v: 2026-06-17T14:03:14+00:00

v: HL7 International / Clinical Decision Support

telecom:
  system:
    v: url
  value:
    v: http://www.hl7.org/Special/committees/dss

v: Drug-drug interaction recommendation for use on order sign of a digoxin or cyclosporine

coding:
  system:
    v: http://unstats.un.org/unsd/methods/m49/m49.htm
  code:
    v: 001

text:
  v: Digoxin Cyclosporine Prescribing

type:
  v: documentation
display:
  v: Potential Drug-Drug Interaction Clinical Decision Support
url:
  v: http://hl7.org/fhir/uv/pddi/STU1/
document:
  url:
    v: http://hl7.org/fhir/uv/pddi/STU1/

trigger:
  type:
    v: named-event
  name:
    v: order-sign
condition:
  kind:
    v: applicability
  expression:
    language:
      v: text/cql-identifier
    expression:
      v: Inclusion Criteria
action:
  title:
    v: Potential Drug-Drug Interaction between digoxin (product) and cyclosporine (product)
  description:
    v: Increased risk of digoxin toxicity. Assess risk and take action if necessary. Digoxin toxicity is potentially serious. The clinical consequences may include anorexia, nausea, vomiting, visual changes, and cardiac arrhythmias. The mechanism of this interaction appears to be mediated through P-glycoprotein inhibition by cyclosporine. P-glycoprotein is a major transporter for digoxin efflux. unknown. unknown.
  dynamic value:
    path:
      v: action.title
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Base Summary
  dynamic value:
    path:
      v: action.description
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Base Detail
  dynamic value:
    path:
      v: activity.extension
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Base Indicator
  action:
    title:
      v: Consultation
    description:
      v: Request communication with digoxin prescriber
    condition:
      kind:
        v: applicability
    definition: canonical
      v: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad201
      link: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad201
  action:
    title:
      v: Consultation
    description:
      v: Request communication with cyclosporine prescriber
    condition:
      kind:
        v: applicability
    definition: canonical
      v: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad202
      link: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad202
  action:
    title:
      v: Cancel digoxin
    description:
      v: Discontinue digoxin order
    condition:
      kind:
        v: applicability
  action:
    title:
      v: Cancel cyclosporine
    description:
      v: Discontinue cyclosporine order
    condition:
      kind:
        v: applicability
  action:
    title:
      v: Digoxin Level
    description:
      v: Order digoxin trough within 24 hours from initiation
    condition:
      kind:
        v: applicability
    definition: canonical
      v: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad203
      link: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad203
action:
  title:
    v: Patient does (not) have digoxin level within 30 days that is below 0.9 ng/mL (SI: 1.2 nmol/L)
  description:
    v: (Digoxin: level and date). For patients with a reliable plasma digoxin concentration in normal range, it is reasonable to anticipate an increase in plasma concentrations after the initiation of cyclosporine. Following initiation, close monitoring and adjusting the digoxin dose as needed is recommended. Initiating cyclosporine is expected to increase digoxin levels. For patients without a reliable plasma digoxin concentration in normal range, use only if benefits outweight risks. Extreme caution and close monitoring is necessary.
  documentation:
    type:
      v: citation
    display:
      v: Dorian et al. Clin Invest Med 1988; 11(2):108-112
  documentation:
    type:
      v: citation
    display:
      v: Dorian et al. Transplant Proc. 1987; 19(1):1825-1827
  condition:
    kind:
      v: applicability
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Is digoxin in prefetch
  dynamic value:
    path:
      v: action.title
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Card 2 Summary
  dynamic value:
    path:
      v: action.description
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Card 2 Detail
  dynamic value:
    path:
      v: activity.extension
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Card 2 Indicator
  action:
    title:
      v: Digoxin Level
    description:
      v: Order digoxin trough within 24 hours from the initiation of cyclosporine
    definition: canonical
      v: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad203
      link: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad203
  action:
    title:
      v: New Digoxin
    description:
      v: Preemptively reduce digoxin dose with new order
    condition:
      kind:
        v: applicability
    definition: canonical
      v: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad204
      link: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad204
action:
  title:
    v: Within 100 days, the patient has had electrolyte and serum creatinine levels checked, and they are not on a potassium sparing or loop diuretic.
  description:
    v: (Potassium: level and date) (Magnesium: level and date) (Calcium: level and date) (Serum creatinine: level and date) Hypokalemia, hypomagnesemia, and hypercalcemia may potentiate digoxin toxicity. 50-70% of digoxin is excreted unchanged in the urine. Changing renal function may increase serum concentrations and risk of toxicity.
  documentation:
    type:
      v: citation
    display:
      v: Lip et al. Postgrad Med J. 1993; 69(811):337
  documentation:
    type:
      v: citation
    display:
      v: Digoxin-FDA [prescribing information] NDA 20405/S-004
  dynamic value:
    path:
      v: action.title
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Card 3 Summary
  dynamic value:
    path:
      v: action.description
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Card 3 Detail
  dynamic value:
    path:
      v: activity.extension
    expression:
      language:
        v: text/cql-identifier
      expression:
        v: Get Card 3 Indicator
  action:
    title:
      v: Serum Creatinine
    description:
      v: Order for serum creatinine
    definition: canonical
      v: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad205
      link: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad205

v: text/cql-identifier

v: Is Context medication digoxin

v: create

v: text/cql-identifier

v: Is Context medication cyclosporine

v: create

v: text/cql-identifier

v: Is Context medication digoxin

v: remove

v: text/cql-identifier

v: Is Context medication cyclosporine

v: remove

v: text/cql-identifier

v: Is new order for digoxin

v: create

v: create

v: text/cql-identifier

v: Need to reduce Digoxin dose

v: create

v: create

title:
  v: Electrolyte Panel
description:
  v: Order for electrolyte panel
type:
  coding:
    system:
      v: http://terminology.hl7.org/CodeSystem/action-type
    code:
      v: create
definition: canonical
  v: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad206
  link: http://hl7.org/fhir/uv/pddi/ActivityDefinition/ad206