OHSU Hypertension Implementation Guide
0.1.0 - CI Build Unknown region code '840'

OHSU Hypertension Implementation Guide, published by Oregon Health and Science University. This guide is not an authorized publication; it is the continuous build for version 0.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/OHSUCMP/htnu18ig/ and changes regularly. See the Directory of published versions

Library: Therapy - Medicines Logic

Official URL: http://fhir.org/guides/ohsuhypertensionig/Library/Pharma Version: 0.1.0
Draft as of 2026-04-24 Computable Name: Pharma

Copyright/Legal: Published by OHSU under an Apache 2.0 License

Decision logic for recommendations concerning hypertension medications

Metadata
Title Therapy - Medicines Logic
Version 0.1.0
Status Draft
Jurisdiction 840 from http://unstats.un.org/unsd/methods/m49/m49.htm
Steward (Publisher) Oregon Health and Science University
Steward Contact Oregon Health and Science University
Description

Decision logic for recommendations concerning hypertension medications

Copyright

Published by OHSU under an Apache 2.0 License

Dependency Description: FHIR model information
Resource: http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1
Canonical URL: http://fhir.org/guides/cqf/common/Library/FHIR-ModelInfo|4.0.1
Dependency Description: Library FHIRHelpers
Resource: http://fhir.org/guides/ohsuhypertensionig/Library/FHIRHelpers|4.0.1
Canonical URL: http://fhir.org/guides/ohsuhypertensionig/Library/FHIRHelpers|4.0.1
Dependency Description: Library Common
Resource: Common Logic version: 0.1.0
Canonical URL: http://fhir.org/guides/ohsuhypertensionig/Library/OHSUHTNCommon|0.1
Dependency Description: Code system ConditionVerificationStatusCodes
Resource: ConditionVerificationStatus
Canonical URL: http://terminology.hl7.org/CodeSystem/condition-ver-status
Dependency Description: Code system ConditionCategorySystem
Resource: Condition Category Codes
Canonical URL: http://terminology.hl7.org/CodeSystem/condition-category
Dependency Description: Code system Medication request status
Resource: Medicationrequest status
Canonical URL: http://hl7.org/fhir/CodeSystem/medicationrequest-status
Dependency Description: Value set Hypertension
Resource: Hypertension
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.104.12.1016
Dependency Description: Value set Non essential Hypertension SNOMEDCT
Resource: Non essential Hypertension SNOMEDCT
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1032.10
Dependency Description: Value set End Stage Renal Disease
Resource: End Stage Renal Disease
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.2.590
Dependency Description: Value set Pregnancy
Resource: Pregnancy
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.378
Dependency Description: Value set Systolic Blood Pressure
Resource: Systolic blood pressure
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1104.2
Dependency Description: Value set Diastolic Blood Pressure
Resource: Diastolic Blood Pressure
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.2.1045
Dependency Description: Value set Blood Pressure Measured
Resource: Blood Pressure Measured
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.600.2012
Dependency Description: Value set Antihypertensive Medications 1
Resource: Antihypertensive Medications
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1178.10
Dependency Description: Value set Antihypertensive Medications 2
Resource: Anti Hypertensive Drugs
Canonical URL: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1200.242
Data Requirement Type: Patient
Profile(s): Patient
Data Requirement Type: Condition
Profile(s): Condition
Must Support Elements: code
Data Requirement Type: Observation
Profile(s): Observation
Must Support Elements: code
Data Requirement Type: Goal
Profile(s): Goal
Must Support Elements: target
Data Requirement Type: MedicationRequest
Profile(s): MedicationRequest
Must Support Elements: status, status.value, id, intent, category, subject, authoredOn, recorder, dosageInstruction, dispenseRequest
Parameters
Name Use Card. Type Documentation
Patient Out 0..1 Patient
Meets Inclusion Criteria Out 0..1 boolean
Meets Exclusion Criteria Out 0..1 boolean
In Population Out 0..1 boolean
Receive Therapy Out 0..1 boolean
Enter Workflow Out 0..1 boolean
Recommendation Out 0..1 string
Rationale Out 0..1 string
Suggestions Out 0..1 string
Selection Behavior Out 0..1 string
Links Out 0..1 string
Rationale Combined Data Out 0..1 string
Indicator Status Out 0..1 string
Test Antihypertensive Medications Out 0..1 boolean
Library Content
CQL Content
library Pharma version '0.1'

using FHIR version '4.0.1'

include FHIRHelpers version '4.0.1' called FHIRHelpers
include OHSUHTNCommon version '0.1' called Common

context Patient

define "Meets Inclusion Criteria":
  exists Common."Condition Indicating Preexisting Hypertension"

define "Meets Exclusion Criteria":
  Common."Patient Under Age 18"
    or Common."Patient Over Age 100"
    or exists Common."Condition Indicating End Stage Renal Disease"
    or exists Common."Condition Indicating Pregnancy"
    or Common."HTN Crisis"

define "In Population":
  // Preserve this ordering so excluded patients fail fast
  not "Meets Exclusion Criteria" and "Meets Inclusion Criteria"

// Pharma Therapy should be received if there are 12 home BPs and goal has not been achieved
define "Receive Therapy":
  Common."Has 12 Home BPs" and Common."Patient has a BP Goal" and Common."Above Goal Average Most Recent"

// Tests conditions from other workflows needed for Pharma intervention to proceed
define "Enter Workflow":
    "In Population" and "Receive Therapy"

define "Recommendation":
  'Blood Pressure is not at goal'

define "Rationale Combined Data":
  "Rationale" + '|' + "Suggestions" + '|' + "Selection Behavior" + '|' + "Links"

define "Rationale":
  if Common."Patient is Using Antihypertensive Medications" then 'Your blood pressure is not at goal despite continuous monitoring. You may want to consider starting or changing antihypertensive medication. Other factors that can contribute to BP not being at goal include excessive stress, new over the counter remedies. Contact your care team to discuss options.'
  else 'Your blood pressure is not at goal despite continuous monitoring. You may want to consider starting or changing antihypertensive medication. Other factors that can contribute to BP not being at goal include excessive stress, new over the counter remedies. Contact your care team to discuss options.'

define "Suggestions":
  if Common."Patient is Using Antihypertensive Medications" then '[ { "id": "contact-suggestion", "label": "Contact care team", "type": "suggestion-link", "actions": [{"label":"Contact your care team about options to control your high blood pressure.", "url":"/contact?token=recommend-advancing-treatment"}] } ]'
  else '[ { "id": "contact-suggestion", "label": "Contact care team", "type": "suggestion-link", "actions": [{"label":"Contact your care team about options to control your high blood pressure.", "url":"/contact?token=recommend-pharma"}] } ]'

define "Indicator Status":
  'warning'

define "Selection Behavior":
  'at-most-one'

define "Links":
  ''

define "Test Antihypertensive Medications":
  Common."Patient is Using Antihypertensive Medications"
ELM XML Content
Encoded data 
ELM JSON Content
Encoded data 
Generated using version 0.5.4 of the sample-content-ig Liquid templates