Schedule a demo
Segment

Pathway

Identifies a clinical pathway (care plan template) assigned to a patient, including the pathway identifier, instance identifier, and lifecycle status. It is sent in PPP (Patient Pathway) messages to communicate that a patient has been placed on, progressed through, or removed from a standardized care pathway, supporting care coordination between clinical systems.

7fields
4required
v2.9HL7 version
pth.py
from zato.hl7v2.v2_9 import PTH
from zato.hl7v2.v2_9 import CWE, EI, DTM

pth = PTH()
pth.action_code = 'AD'
pth.pathway_id = CWE(
    identifier='WEIGHT-MGMT',
    text='Weight Management Pathway'
)

Build PTH segments in Python

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

1

Weight management pathway

Fitness and nutrition care plan

from zato.hl7v2.v2_9 import PTH
from zato.hl7v2.v2_9 import CWE, EI, DTM

pth = PTH()
pth.action_code = 'AD'
pth.pathway_id = CWE(
    identifier='WEIGHT-MGMT',
    text='Weight Management Pathway'
)
pth.pathway_instance_id = EI(entity_identifier='PTH001')
pth.pathway_established_date_time = DTM('20240115')
pth.pathway_life_cycle_status = CWE(
    identifier='A',
    text='Active'
)
2

Cardiac rehabilitation pathway

Heart health fitness program

from zato.hl7v2.v2_9 import PTH
from zato.hl7v2.v2_9 import CWE, EI, DTM

pth = PTH()
pth.action_code = 'AD'
pth.pathway_id = CWE(
    identifier='CARDIAC-REHAB',
    text='Cardiac Rehabilitation'
)
pth.pathway_instance_id = EI(entity_identifier='PTH002')
pth.pathway_established_date_time = DTM('20240116')
pth.pathway_life_cycle_status = CWE(
    identifier='A',
    text='Active'
)
3

Diabetes prevention pathway

Preventive care program

from zato.hl7v2.v2_9 import PTH
from zato.hl7v2.v2_9 import CWE, EI, DTM

pth = PTH()
pth.action_code = 'AD'
pth.pathway_id = CWE(
    identifier='DPP',
    text='Diabetes Prevention Program'
)
pth.pathway_instance_id = EI(entity_identifier='PTH003')
pth.pathway_established_date_time = DTM('20240117')
pth.pathway_life_cycle_status = CWE(
    identifier='A',
    text='Active'
)

Learn by building

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

Frequently asked questions

PTH contains pathway information including pathway identifiers, status, and dates for defining wellness care plans and programs.

Common action codes include AD (add), UP (update), and DE (delete). These track changes to wellness pathways over time.

Use pathway_life_cycle_status field:

pth.pathway_life_cycle_status = CWE(
    identifier='A',
    text='Active'
)

PTH defines the overall care pathway while GOL contains goals and PRB contains problems. Pathways organize goals and address problems.

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.

PTH field reference

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

#Python nameDatatypeUsageRepeatableTable
1action_codeIDRequiredNo-
2pathway_idCWERequiredNo-
3pathway_instance_idEIRequiredNo-
4pathway_established_date_timeDTMRequiredNo-
5pathway_life_cycle_statusCWEOptionalNo-
6change_pathway_life_cycle_status_date_timeDTMOptionalNo-
7mood_codeCNEOptionalNoHL70725

Ready to build integrations?

Get started with Zato and connect your systems in minutes.

Open source In Python