Schedule a demo
Segment

User authentication credential

Carries end-user authentication credentials, such as a Kerberos service ticket or SAML assertion, to be used by the receiving system for user identification and access control. It is defined for use with simple transport protocols like MLLP (which lack built-in authentication) and appears after MSH and SFT in interactive application messages where the receiving system must verify the identity of the requesting user.

2fields
2required
v2.9HL7 version
uac.py
from zato.hl7v2.v2_9 import UAC
from zato.hl7v2.v2_9 import CWE, ED

uac = UAC()
uac.user_authentication_credential_type_code = CWE(
    identifier='KERBEROS',
    text='Kerberos Token'
)

Build UAC segments in Python

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

1

Kerberos authentication

Kerberos token credential

from zato.hl7v2.v2_9 import UAC
from zato.hl7v2.v2_9 import CWE, ED

uac = UAC()
uac.user_authentication_credential_type_code = CWE(
    identifier='KERBEROS',
    text='Kerberos Token',
    name_of_coding_system='HL70615'
)
uac.user_authentication_credential = ED(
    source_application='BASE64',
    type_of_data='A',
    data_subtype='application/octet-stream',
    data='TOKEN123456'
)
2

SAML assertion

SAML token credential

from zato.hl7v2.v2_9 import UAC
from zato.hl7v2.v2_9 import CWE, ED

uac = UAC()
uac.user_authentication_credential_type_code = CWE(
    identifier='SAML',
    text='SAML Assertion',
    name_of_coding_system='HL70615'
)
uac.user_authentication_credential = ED(
    source_application='BASE64',
    type_of_data='A',
    data_subtype='text/xml',
    data='SAMLTOKEN789'
)
3

JWT token

JSON Web Token credential

from zato.hl7v2.v2_9 import UAC
from zato.hl7v2.v2_9 import CWE, ED

uac = UAC()
uac.user_authentication_credential_type_code = CWE(
    identifier='JWT',
    text='JSON Web Token',
    name_of_coding_system='HL70615'
)
uac.user_authentication_credential = ED(
    source_application='BASE64',
    type_of_data='A',
    data_subtype='application/jwt',
    data='JWTTOKEN456'
)

Learn by building

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

Frequently asked questions

UAC contains user authentication credential information including credential type codes and credential data for secure messaging.

Common credential types from HL70615 include KERBEROS, SAML, JWT, and other authentication token formats.

Use user_authentication_credential_type_code field:

uac.user_authentication_credential_type_code = CWE(
    identifier='JWT',
    text='JSON Web Token',
    name_of_coding_system='HL70615'
)

UAC provides authentication credentials while MSH identifies the message sender. UAC follows MSH and SFT in the message.

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.

UAC field reference

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

#Python nameDatatypeUsageRepeatableTable
1user_authentication_credential_type_codeCWERequiredNoHL70615
2user_authentication_credentialEDRequiredNo-

Ready to build integrations?

Get started with Zato and connect your systems in minutes.

Open source In Python