Schedule a demo
Segment

Diet tray instructions

Carries tray-level instructions for patient meal delivery, including the tray type, an optional service period, and free-text preparation notes. It accompanies the ODS segment in diet order messages (O03, O19) and provides food service departments with the information needed to assemble and deliver meal trays according to patient-specific requirements such as isolation trays, guest trays, or pediatric trays.

3fields
1required
v2.9HL7 version
odt.py
from zato.hl7v2 import ODT

odt = ODT()
odt.tray_type = 'ISO'
odt.text_instruction = 'Double wrap'

Build ODT segments in Python

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

1

Isolation tray

Tray instruction with type, service period, and preparation notes for isolation meals

from zato.hl7v2.v2_9 import ODT
from zato.hl7v2.v2_9 import CWE

odt = ODT()
odt.tray_type = CWE(
    identifier='ISO',
    text='Isolation',
    name_of_coding_system='HL70160'
)
odt.service_period = CWE(
    identifier='DIN',
    text='Dinner',
    name_of_coding_system='HL70627'
)
odt.text_instruction = (
    'Use disposable utensils'
)
2

Guest tray

Guest tray instruction with service period for visitor meal delivery

from zato.hl7v2.v2_9 import ODT
from zato.hl7v2.v2_9 import CWE

odt = ODT()
odt.tray_type = CWE(
    identifier='GST',
    text='Guest',
    name_of_coding_system='HL70160'
)
odt.service_period = CWE(
    identifier='LUN',
    text='Lunch',
    name_of_coding_system='HL70627'
)
odt.text_instruction = (
    'Deliver to room 412'
)
3

Pediatric tray

Pediatric tray type with text instruction and no service period specified

from zato.hl7v2.v2_9 import ODT
from zato.hl7v2.v2_9 import CWE

odt = ODT()
odt.tray_type = CWE(
    identifier='PED',
    text='Pediatric',
    name_of_coding_system='HL70160'
)
odt.text_instruction = (
    'Small portions only'
)

Learn by building

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

Frequently asked questions

ODT carries tray-level instructions for meal delivery, including the tray type (e.g. isolation, guest, pediatric), an optional service period, and free-text preparation notes. It accompanies ODS in diet order messages.

The tray_type field uses CWE with HL7 table 0160:

from zato.hl7v2.v2_9 import ODT, CWE

odt = ODT()
odt.tray_type = CWE(
    identifier='ISO',
    text='Isolation',
    name_of_coding_system='HL70160'
)

The service_period field uses CWE with HL7 table 0627 to indicate the meal time:

from zato.hl7v2.v2_9 import ODT, CWE

odt = ODT()
odt.service_period = CWE(
    identifier='DIN',
    text='Dinner',
    name_of_coding_system='HL70627'
)

The text_instruction field is a simple string for preparation and delivery notes:

from zato.hl7v2.v2_9 import ODT, CWE

odt = ODT()
odt.tray_type = CWE(
    identifier='ISO',
    text='Isolation',
    name_of_coding_system='HL70160'
)
odt.text_instruction = (
    'Use disposable utensils'
)

HL7 table 0160 defines tray types. Common values include isolation, guest, and pediatric trays:

from zato.hl7v2.v2_9 import ODT, CWE

odt = ODT()

# Isolation tray
odt.tray_type = CWE(identifier='ISO')

# Guest tray
odt.tray_type = CWE(identifier='GST')

# Pediatric tray
odt.tray_type = CWE(identifier='PED')

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.

ODT field reference

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

#Python nameDatatypeUsageRepeatableTable
1tray_typeCWERequiredNoHL70160
2service_periodCWEOptionalNoHL70627
3text_instructionSTOptionalNo-

Ready to build integrations?

Get started with Zato and connect your systems in minutes.

Open source In Python