Schedule a demo
Segment

Appointment location preference

Identifies the healthcare personnel (physician, nurse, or technician) assigned to the appointment, carrying the person identifier, resource type, start date and time, and duration. It appears in SIU and SRM/SRR messages and is used by scheduling systems to communicate provider assignments to EHR, notification, and departmental workflow systems.

12fields
1required
v2.9HL7 version
aip.py
from zato.hl7v2.v2_9 import AIP
from zato.hl7v2.v2_9 import XON, CWE

aip = AIP()
aip.aip_primary_key_value = '1'
aip.aip_set_id_aip = '1'
aip.aip_scheduling_activity_id = 'APT202401150900'
aip.aip_location_resource_id = XON(
    organization_name='Active Life Wellness',
    id_number='FIT001'
)
aip.aip_location_preference_code = CWE(
    identifier='PREFERRED',
    text='Preferred Location',
    name_of_coding_system='HL70464'
)
aip.aip_location_description = 'Fitness Center Room 101'

Build AIP segments in Python

How to construct and work with real-world AIP segments.

1

Preferred fitness center location

Patient preference for specific wellness facility

from zato.hl7v2.v2_9 import AIP
from zato.hl7v2.v2_9 import XON, CWE

aip = AIP()
aip.aip_primary_key_value = '1'
aip.aip_set_id_aip = '1'
aip.aip_scheduling_activity_id = 'APT202401150900'
aip.aip_location_resource_id = XON(
    organization_name='Active Life Wellness',
    id_number='FIT001'
)
aip.aip_location_preference_code = CWE(
    identifier='PREFERRED',
    text='Preferred Location',
    name_of_coding_system='HL70464'
)
aip.aip_location_description = 'Fitness Center Room 101'
aip.aip_location_characteristic = CWE(
    identifier='ACCESSIBLE',
    text='Accessible',
    name_of_coding_system='HL70464'
)
2

Nutrition services preference

Patient preference for specific nutrition office

from zato.hl7v2.v2_9 import AIP
from zato.hl7v2.v2_9 import XON, CWE

aip = AIP()
aip.aip_primary_key_value = '2'
aip.aip_set_id_aip = '1'
aip.aip_scheduling_activity_id = 'APT20240116140000'
aip.aip_location_resource_id = XON(
    organization_name='River Valley Wellness',
    id_number='NUT002'
)
aip.aip_location_preference_code = CWE(
    identifier='PREFERRED',
    text='Preferred Location',
    name_of_coding_system='HL70464'
)
aip.aip_location_description = 'Nutrition Services Office 203'
aip.aip_location_characteristic = CWE(
    identifier='PRIVATE',
    text='Private Room',
    name_of_coding_system='HL70464'
)
3

Group fitness studio preference

Patient preference for group activity location

from zato.hl7v2.v2_9 import AIP
from zato.hl7v2.v2_9 import XON, CWE

aip = AIP()
aip.aip_primary_key_value = '3'
aip.aip_set_id_aip = '1'
aip.aip_scheduling_activity_id = 'APT20240117180000'
aip.aip_location_resource_id = XON(
    organization_name='Harmony Health Center',
    id_number='GRP003'
)
aip.aip_location_preference_code = CWE(
    identifier='PREFERRED',
    text='Preferred Location',
    name_of_coding_system='HL70464'
)
aip.aip_location_description = 'Group Fitness Studio A'
aip.aip_location_characteristic = CWE(
    identifier='SPACIOUS',
    text='Spacious',
    name_of_coding_system='HL70464'
)

Learn by building

Step-by-step guides for working with HL7 v2 in Zato.

Frequently asked questions

AIP contains appointment location preference information including preferred facilities, room preferences, accessibility requirements, and location-specific needs. It's used to accommodate patient preferences for wellness appointments.

Use HL70464 table values for location preferences like PREFERRED, ACCESSIBLE, or PRIVATE:

aip.aip_location_preference_code = CWE(
    identifier='PREFERRED',
    text='Preferred Location',
    name_of_coding_system='HL70464'
)

Use HL70464 table values for location characteristics like ACCESSIBLE for wheelchair access, PRIVATE for private rooms, or SPACIOUS for larger areas. These help match patients with appropriate wellness center facilities.

Include specific room numbers, building names, or descriptive details that help scheduling systems match patients with their preferred wellness center locations.

AIP provides location preferences while AIL provides actual location details. Both segments work together to match patient preferences with available wellness center facilities and rooms.

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.

AIP field reference

Complete list of fields in the AIP segment, HL7 v2.9.

#Python nameDatatypeUsageRepeatableTable
1set_id_aipSIRequiredNo-
2segment_action_codeIDOptionalNoHL70206
3personnel_resource_idXCNOptionalYes-
4resource_typeCWEOptionalNoHL70182
5resource_groupCWEOptionalNo-
6start_date_timeDTMOptionalNo-
7start_date_time_offsetNMOptionalNo-
8start_date_time_offset_unitsCNEOptionalNo-
9durationNMOptionalNo-
10duration_unitsCNEOptionalNo-
11allow_substitution_codeCWEOptionalNoHL70279
12filler_status_codeCWEOptionalNoHL70278

Ready to build integrations?

Get started with Zato and connect your systems in minutes.

Open source In Python