Schema Elements for Outbound EDI

In the outbound EDI use case, the input to the B2B action has the XML form of the EDI document and the output has the document assembled into the EDI format.

Description of edi-translate-outbound.png follows
Description of the illustration edi-translate-outbound.png

The following tables describe each element contained in TranslateInput and TranslateOutput for the Outbound EDI scenario.

Elements in TranslateInput

Element Description
edi-xml-document

The XML form of the data to use to form the output EDI message during translation.

At the minimum, you must assign values to the following child XML elements in the input:

  • headers > interchange-ctrl:
    • The attribute sender-id-qualifier must contain a value for the interchange sender ID qualifier. This value is inserted into the ISA05 element.
    • The attribute sender-id must contain a value for the interchange sender ID qualifier. This value is inserted into the ISA06 element.
    • The attribute receiver-id-qualifier must contain a value for the interchange receiver ID qualifier. This value is inserted into the ISA07 element.
    • The attribute receiver-id must contain a value for the interchange receiver ID qualifier. This value is inserted into the ISA08 element.
  • headers > group:
    • The attribute app-senders-code must contain a value for the application sender's code. This value is inserted into the GS02 element.
    • The attribute app-receivers-code must contain a value for the application receiver's code. This value is inserted into the GS03 element.
  • transaction-data:
    • The child elements inside it represent the structure of the business message, such as a purchase order. Mapping these elements require knowledge of the EDI X12 segments and elements that form the business message. You must assign values to mandatory segments and elements, and assign values to conditional elements based on the presence of other elements defined by the syntax rules specified for each segment.

    Other elements and attributes inside headers and trailers are assigned default values, so these are optional.

Note:

The B2B action automatically generates unique control numbers for the interchange, group, and transaction set.

Note:

Customizing Delimiters for Outbound EDI

By default, the element-separator is *, the segment-delimiter is ~, and the subelement-separator is :. You can override them by specifying values in the input XML as follows:

  • headers > interchange-ctrl > attribute 'element-separator'
  • headers > interchange-ctrl > attribute 'subelement-separator'
  • headers > interchange-ctrl > attribute 'segment-terminator'
  • headers > interchange-ctrl > attribute 'repetition-separator' (only applies to X12 4020 or later versions)

If the delimiter character you want to use is an ASCII printable character, simply assign a string value such as "|" to the corresponding attribute. If you want to use a special character as a delimiter, specify it in a hexadecimal format. For example, 0xA, where 0x is a fixed prefix and A is the hexadecimal representation of the ASCII line-feed character.

If your EDI payload uses a different encoding such as UTF-8, you can use the hexadecimal format to specify a Unicode character as a delimiter. For example, specify 0x03A60 to use the Unicode character Φ as a delimiter. Note that the receiving trading partner should be prepared to receive a UTF-8 EDI payload for this to work correctly.

Note that the delimiter string value you specify must equate to only a single character. Multiple characters are not allowed. The only exception is the segment-terminator, which allows one character plus an optional ASCII carriage-return and a line-feed character at the end. For example, a segment-terminator value of ~0xd0xa uses ~ followed by <CR> and <LF> as a segment-terminator, which means each EDI segment is output on a separate line, making it more readable.

accept-message-on-errors

See Accept Message on Errors.

reject-message-on-errors

See Reject Message on Errors.

validate

See Validate.

input-source-context

See Input Source Context.

Elements in TranslateOutput

Element Description
edi-payload

This element is returned with the translated message in the EDI format, starting with the X12 ISA header envelope and ending with the IEA trailer envelope. The control numbers are automatically generated and inserted in the EDI content. Note that the EDI content is Base64 encoded.

validation-errors-present

See Validation Errors Present.

validation-errors > error

validation-errors > validation-error-report

See Validation Errors - Error and Error Report.

tracking-info

This element is returned with a string representing a unique transmission identifier occurring in the output EDI. This string includes control numbers used in the output EDI message (interchange/group/transaction-set control numbers). This value is useful for tracking purposes.

translation-status

See Translation Status.

input-source-context

See Input Source Context.