Carries the requesting party's preferences for appointment scheduling, including preferred time window, preferred resource selection criteria, and filler override criteria. It is used in SRM (Schedule Request Message) messages from the placer application, providing the scheduling system with flexible constraints for finding a suitable appointment slot rather than specifying an exact time.
from zato.hl7v2.v2_9 import APR
from zato.hl7v2.v2_9 import CWE
apr = APR()
apr.apr_primary_key_value = '1'
apr.apr_set_id_apr = '1'
apr.apr_scheduling_activity_id = 'APT202401150900'
apr.apr_reason_code = CWE(
identifier='ROUTINE',
text='Routine',
name_of_coding_system='HL70276'
)
apr.apr_reason_description = 'Annual wellness check-up'How to construct and work with real-world APR segments.
Annual preventive care visit reason
from zato.hl7v2.v2_9 import APR
from zato.hl7v2.v2_9 import CWE
apr = APR()
apr.apr_primary_key_value = '1'
apr.apr_set_id_apr = '1'
apr.apr_scheduling_activity_id = 'APT202401150900'
apr.apr_reason_code = CWE(
identifier='ROUTINE',
text='Routine',
name_of_coding_system='HL70276'
)
apr.apr_reason_description = 'Annual wellness check-up'
apr.apr_action_code = [
CWE(
identifier='WELLNESS',
text='Wellness Program',
name_of_coding_system='HL70464'
),
CWE(
identifier='ACTIVE',
text='Active Member',
name_of_coding_system='HL70464'
),
]Dietary consultation visit reason
from zato.hl7v2.v2_9 import APR
from zato.hl7v2.v2_9 import CWE
apr = APR()
apr.apr_primary_key_value = '2'
apr.apr_set_id_apr = '1'
apr.apr_scheduling_activity_id = 'APT20240116140000'
apr.apr_reason_code = CWE(
identifier='NUTRITION',
text='Nutrition Counseling',
name_of_coding_system='HL70276'
)
apr.apr_reason_description = 'Dietary counseling for wellness goals'
apr.apr_action_code = [
CWE(
identifier='NUTRITION',
text='Nutrition Services',
name_of_coding_system='HL70464'
),
CWE(
identifier='REFERRED',
text='Referred by Provider',
name_of_coding_system='HL70464'
),
]Wellness program group activity reason
from zato.hl7v2.v2_9 import APR
from zato.hl7v2.v2_9 import CWE
apr = APR()
apr.apr_primary_key_value = '3'
apr.apr_set_id_apr = '1'
apr.apr_scheduling_activity_id = 'APT20240117180000'
apr.apr_reason_code = CWE(
identifier='GROUP',
text='Group Class',
name_of_coding_system='HL70276'
)
apr.apr_reason_description = 'Group fitness class participation'
apr.apr_action_code = [
CWE(
identifier='FITNESS',
text='Fitness Program',
name_of_coding_system='HL70464'
),
CWE(
identifier='SCHEDULED',
text='Scheduled by Member',
name_of_coding_system='HL70464'
),
]Step-by-step guides for working with HL7 v2 in Zato.
APR contains appointment reason information including visit purposes, referral details, authorization codes, and clinical indications. It's used to document the purpose of wellness appointments and preventive care visits.
Use HL70276 table values for appointment reasons like ROUTINE, NUTRITION, or GROUP:
apr.apr_reason_code = CWE(
identifier='ROUTINE',
text='Routine',
name_of_coding_system='HL70276'
)Use HL70464 table values for action codes like WELLNESS, NUTRITION, or FITNESS to indicate the program or service related to the appointment reason.
Include clear, concise descriptions that explain the purpose of the wellness appointment or preventive care visit. This helps with scheduling and clinical documentation.
APR contains the confirmed appointment reason while ARQ contains the requested appointment reason. Both segments work together to track appointment from request to completion in wellness center scheduling systems.
Zato connects to any system that speaks HL7v2 over MLLP or FHIR over REST. This includes Epic, Cerner, Meditech, Allscripts, and other EHR platforms.
Yes, Zato has built-in MLLP support for sending and receiving HL7v2 messages. MLLP channels handle the framing protocol automatically.
Zato supports HL7 v2.9, which is backward compatible with earlier versions including v2.3, v2.5, and v2.7. Standard segments and datatypes are available as typed Python classes.
Yes. Zato handles both HL7v2 and FHIR natively, so you can parse v2 messages and build FHIR resources with IG-specific extensions in the same service. Typed Python classes are available for both protocols, including extensions from US Core, UK Core, Da Vinci, and other Implementation Guides.
Complete list of fields in the APR segment, HL7 v2.9.
| # | Python name | Datatype | Usage | Repeatable | Table |
|---|---|---|---|---|---|
| 1 | time_selection_criteria | SCV | Optional | Yes | HL70294 |
| 2 | resource_selection_criteria | SCV | Optional | Yes | HL70294 |
| 3 | location_selection_criteria | SCV | Optional | Yes | HL70294 |
| 4 | slot_spacing_criteria | NM | Optional | No | - |
| 5 | filler_override_criteria | SCV | Optional | Yes | - |
Get started with Zato and connect your systems in minutes.