4.3.5. Message definition formats
This list shows main message formats supported by the application.
A CSV or comma-separated values file is used for the digital storage of data organized in a table form. Each line in the CSV file corresponds to a row in the table, and within a line, fields are separated by commas (or semicolons, colons or tabs), each field belonging to one column of the source table.
As this is a very common and simple file format, CSV files are often used to move tabular data between different computer programs, such as between a database and a spreadsheet program.
Note: When using a CSV as a Message IN definition, each line will be identified in a separate record at the same level and the Message IN after transformation to XML will not have any hierarchical structure.
File sample
Following is a sample CSV file.
NAV Date,ISIN,Fund Name,Share Typ,Fund Ccy,NAV in Fund Ccy,Bid Price in Fund Ccy,Offer Price in Fund Ccy,TNA,Outstanding,Publication Ccy,NAV in Publication Ccy,Bid Price in Publication Ccy,Offer Price in Publication Ccy,Equity Profit,WKN Code,Zwischengewinn,TIS,TID 06/13/2008,LU0223208157,HSBC GIF EMERGING EUROPE EQUITY,AC,EUR,15.088,15.088,15.924,12190498.17,807980.236,GBP,11.96,11.96,12.623,37.650,A0ER9A,0.001,,
The following properties are available:
The character that is used to separate the fields in the csv. It can be a comma, colon, semicolon or tab. |
|
The character that is used to quote the specials characters in the csv. It can be a single quote (') or a double quote ("). |
|
Tells you if the csv file begins with a line that contains headers of the columns, or directly begins with the lines of data. |
|
The encoding of the csv file. |
|
An example of CSV file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
Introduction
United Nations / Electronic Data Interchange for Administration, Commerce and Transport (UN/EDIFACT) is the international EDI standard developed under the United Nations impulse. This standard is maintained and further developed by a UN body. EDIFACT has now been adopted by the International Organization for Standardization (ISO) as the ISO standard ISO 9735.
The EDIFACT standard provides a set of syntax rules to structure data, an interactive exchange protocol (I-EDI), and standard messages which allow multi-country and multi-industry exchange.
You can find more information about Edifact on its offical site ( http://www.unece.org/cefact/edifact/welcome.html ) or on Wikipedia ( https://en.wikipedia.org/wiki/EDIFACT ). See how Walmart and Amazon use Edifact to connect with their suppliers.
Below is a sample EDIFACT file.
UNB+UNOA:1+005435656:1+006415160:1+060515:1434+00000000000778' UNH+00000000000117+INVOIC:D:97B:UN' BGM+380+342459+9' DTM+3:20060515:102' RFF+ON:521052' NAD+BY+792820524::16++CUMMINS MID-RANGE ENGINE PLANT' NAD+SE+005435656::16++GENERAL WIDGET COMPANY' CUX+1:USD' LIN+1++157870:IN' IMD+F++:::WIDGET' QTY+47:1020:EA' ALI+US' MOA+203:1202.58' PRI+INV:1.179' LIN+2++157871:IN' IMD+F++:::DIFFERENT WIDGET' QTY+47:20:EA' ALI+JP' MOA+203:410' PRI+INV:20.5' UNS+S' MOA+39:2137.58' ALC+C+ABG' MOA+8:525' UNT+24+00000000000117' UNZ+1+00000000000778'
Extensive support
Babelway supports all Edifact messages, and knows all the definitions of the different norms. This knowledge of these definitions will allow additional functionalities when you work with Edifact. Amongst other things :
-
By just loading a sample Edifact file, Babelway will be able to deduce the structure, find the definition of the elements, calculate human-readable labels, ... You can see on the following screenshot the result when you load the sample above.
-
Adding or removing segment elements is very easy, as the interface knows precisely which elements may take place in the selected segment.
-
In the same way, segments can be easily added. The interface will offer you segments and elements that may take place at this location.
-
Messages can be validated deeply (structure, mandatory fields, values, ...) automatically, without having to define any validation manually.
-
For all the runtime messages, comments are added in the internal representation to ease the reading of the file.
Note: For some specific segment if the position is changed in the "Message In" tree and/or if the position of the segment is changed in the input message this will leads to a different naming in the "Message IN after transformation to XML" file for this segment and then in this case the mapping will not generate the values in the output message.
Properties
The following properties are available:
Only for messages OUT. If yes, an error will be generated if your message has an incorrect structure. Deactivate only if you really want to send messages with incorrect structures. |
|
If yes, all values will be checked against their definition. Deactivate only if you really want to receive/send messages with values that do not respect the Edifact standard. |
|
If yes, all segments will be checked against their definition (mandatory fields must exist, no field can be present if not in definition). Deactivate only if you really want to receive/send messages with values that do not respect the Edifact standard. |
|
If checked, you will be able to configure the settings for a signed edifact. |
|
If set, signature will be applied to the edifact generated file and security segments will be inserted (USH, UST, USR, USA, USC, UNO and UNP). |
|
Which certificate will be used for security segments. |
|
An example of Edifact file handled by this message definition. |
|
Only for messages OUT. The UNA segment to be used in your output message. If you asked for an empty UNA segment, it will not be printed, and default separators will be used. If you specify one, the rest of the file will be written accordingly, adapting to the separators defined in the segment. |
|
Only for messages OUT. If yes, an additional line break will be added in the output message between every segment. Only for human readability. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
Note:
ASC X12 (also known as ANSI ASC X12) is the official designation of the U.S. national standards body for the development and maintenance of Electronic Data Interchange (EDI) standards. ASC X12 has sponsored more than 315 X12-based EDI standards for health care, insurance, government, transportation, finance, and many other industries (see how Walmart,Amazon, Rite Aid, and Wayfair use X12).
Babelway supports all X12 messages, and offers the same extensive support as for Edifact.
File sample
Below is a sample X12 file.
ISA*00* *00* *ZZ*SENDERISA *ZZ*RECEIVERISA *960807*1548*U*00401*000000020*0*T*~ GS*IN*SENDERDEPT*007326879*19960807*1548*000001*X*004010~ ST*810*000000001~ BIG*20090927*00027**A00027-01~ N1*ST*CHOCOLATE IMPORT*9*1234567890~ N3*1000 N. NORTH HIGHWAY~ N4*NEW YORK*NY*10310~ N1*BT*RETAILER INC.*9*1098765432~ N3*P.O. BOX 0000~ N4*LAKE*VA*20120~ N1*RE*FOODSELLER*9*12345QQQQ~ N3*P.O. BOX 222222~ N4*FAIRFAX*VA*94978~ ITD*01*3*1**15**16~ FOB*PP~ IT1**16*CA*12.34**UA*006540022222~ PID*F****BELGIUM CHOCOLATE~ IT1**13*CA*12.34**UA*006540033333~ PID*F****SWISS CHOCOLATE~ TDS*35786~ CAD*****FREEFORM~ ISS*29*CA~ CTT*2~ SE*22*000000001~ GE*1*000001~ IEA*1*000000020~
Babelway supports X12 messages. This knowledge of these definitions will allow additional functionalities when you work with X12. Amongst other things :
- By just loading a sample X12 file, Babelway will be able to deduce the structure, find the definition of the elements, calculate human-readable labels, ... You can see on the following screenshot the result when you load the sample above.
X12 tree just after having loaded a Sample.
- Adding or removing segment elements is very easy, as the interface knows precisely which elements may take place in the selected segment.
Edit segment shows all the possible elements.
- In the same way, segments can be easily added. The interface will offer you segments and elements that may take place at this location.
Edit segment shows all the possible elements.
- Messages can be validated deeply (structure, mandatory fields, values, ...) automatically, without having to define any validation manually.
- For all the runtime messages, comments are added in the internal representation to ease the reading of the file.
Internal representation of X12.
Note: For some specific segment if the position is changed in the "Message In" tree and/or if the position of the segment is changed in the input message this will leads to a different naming in the "Message IN after transformation to XML" file for this segment and then in this case the mapping will not generate the values in the output message.
The following properties are available:
Only for messages OUT. If yes, an error will be generated if your message has an incorrect structure. Deactivate only if you really want to send messages with incorrect structures. |
|
If yes, all values will be checked against their definition. Deactivate only if you really want to receive/send messages with values that do not respect the X 12 standard. |
|
If yes, all segments will be checked against their definition (mandatory fields must exist, no field can be present if not in definition). Deactivate only if you really want to receive/send messages with values that do not respect the X 12 standard. |
|
An example of X 12 file handled by this message definition. |
|
Template of output file, that will be used to choose delimiters. If no template is selected and the message IN was a X12, the system will reuse the delimiters from the message IN. Otherwise the default delimiters are '~' '*' ':'. |
|
Output Charset is used to encode the file. |
|
Input Charset is used to decode the file. |
|
Automatically generate a 997 functional acknowledgement upon receiving a message. This will not work for messages which are themselves 997s. See 997 Acknowledgements for more information. |
|
Additional metadata and universal routing metadata are always attached to the new 997 message generated. This option allows you to additionally attach the user metadata of the original message to the 997. |
|
997 messages will be sent into a channel through this gateway IN. |
|
If selected, the message remains 'In delivery' until a matching 997 is received or until the timeout is reached. The message status will change to 'Success' upon reception of an 'Accepted' 997. The message status will change to 'Error' upon reception of a 'Rejected' 997 or no 997 received before time out. See 997 Acknowledgements for more information. |
|
Indicates how long the message will await the 997 before the message status is changed from 'In delivery' to 'Error'. See 997 Acknowledgements for more information. |
|
Lists the gateways for which a channel was identified or created which correlates incoming acknowledgements. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
Note:
-
There is no escaping character for the X12 message, For example if you defined the X12 segment separator as ^ character and for one of the element has the ^ character in it's value then the Babelway system will replace this ^ character by a space for the value of this element.
-
Regarding the "Message In" we can't disable the "Validate structure" because it is mandatory, Regarding the "Message Out" we can disable the "Validate structure" from the "Properties".
-
Below are different ways to define the segment separator for X12 message regarding the "Message Out".
- The maximum filename supported for the "Message In" and "Message Out" is 255 characters.
1-By uploading X12 message template to the "Edi template" then Babelway will use the segment separator that you have defined in this template.
2-If you didn't define Edi template and the "Message Out" definition is of type X12 then Babelway will use the separator character from the X12 message.
3-If you are using "Message Out" definition that isn't of type X12 then Babelway will use the standard separator for the X12 message.
The Organization for Data Exchange by Tele Transmission (ODETTE) in Europe is a group that represents the interests of the automotive industry in Europe. They are the equivalent of the Automotive Industry Action Group (AIAG) in North America.
ODETTE has been responsible for developing communication standards such as OFTP and OFTP2.0.
Babelway supports all following ODETTE Messages:
AVIEXP, AVIGRU, AVIREX, BASDAT, CONFOR, CONTRL, CREDIT, DEBNOT, DELINS, ENQIRY, FORDIS, GRUDES, INVOIC, KANBAN, MODPRI, OFFERR, ORDERR, OSTENQ, PRILST, REMADV, REPDEL, REPINV, REPORD, STATAC, STOACT, SYNCRO, SYNPAC
File sample
Below is a sample ODETTE file.
UNB+UNOA:1+1111:OD+2222:OD+980611:1723+888++KANBAN' UNH+1+KANBAN:2::OD' MID+0000001266+040331:0001' CDT+::::::2474' BDT+0931955500293' CSG+0931955500293+I' ARD+190569' KDE+:336+3840++040402:1648' ARD+192209' KDE+:492+1600++040402:2057' UNT+10+1' UNZ+1+888'
The following properties are available:
The template is used by the EdiWriter in order to define the proper layout of the odette and follows the syntax of the template. |
|
Check this to skip the UNA section in ODETTE. |
|
Output Charset is used to encode the file. |
|
Input Charset is used to decode the file. |
|
An example of ODETTE file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
XML stands for eXtensible Markup Language and is a very common type of files.
File sample
Below is a sample XML file.
<?xml version="1.0"?> <Document> <SenderID>5420008199981</SenderID> <ReceiverID>5400102000086</ReceiverID> <DocumentDate>20080531170538</DocumentDate> <DocumentNumber>VK20084010</DocumentNumber> <TestIndicator>P</TestIndicator> <DocumentLanguage>NL</DocumentLanguage> <Version>1.1/Food</Version> <Invoice> <MessageReferenceNumber>VK20084010</MessageReferenceNumber> <InvoiceHeader> <MessageType>INV</MessageType> <MessageNumber>VK20084010</MessageNumber> <MessageFunction>ORI</MessageFunction> <InvoiceCurrency>EUR</InvoiceCurrency> <Dates> <InvoiceDate>20080531170538</InvoiceDate> <AccountingValueDate>20080531170538</AccountingValueDate> <DeliveryDate>20080530170738</DeliveryDate> <OrderDate>20080530170538</OrderDate> </Dates> </InvoiceHeader> <InvoiceDetail> <InvoiceItem> <ItemType>GDS</ItemType> <LineItemNumber>1</LineItemNumber> <EANArticleNumber>95400102057205</EANArticleNumber> </InvoiceItem> </InvoiceDetail> </Invoice> </Document>
The following properties are available:
Charset to use to encode the file. |
|
Charset to use to decode the file. |
|
Xsd definition file corresponding to the XML message. |
|
Xsd Imports that the Xsd definition depends on. |
|
An example of XML file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
If you want to create and XML message definition, we advise you to provide a complete XML sample and XSD file(s) defining the structure of the XML. You will get validation, documentation, loop generation from XSD files and the resulting message definition will be limited to fields present in the XML sample.
If you provide XSD files only, be aware that, if XSD structure is fairly complex, the resulting message definition will be very difficult to use.
If you provide an XML sample file only, you will need to manually edit the message definition to add the 'loops' where it makes sense.
Note: The maximum filename supported for the "Message In" and "Message Out" is 255 characters.
File sample
Below is a sample Excel file having headers at the first row of the Excel sheet.
The following properties are available:
Which Excel format is used (XLS or XLSX). |
|
Check this to ignore empty lines. |
|
Check this to remove all spaces from text except for single spaces between words. |
|
Used date format. |
|
Single/Multiple sheets? If not selected, only the first sheet of the workbook is considered. |
|
This action allows to list all the tickets, optionally filtered by some search criteria. Note: This only support xls format. |
|
Select if first row contains field headers. |
|
Charset used to encode/decode the file. |
|
An example of Excel file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
File sample
Babelway Excel wizard only supports the Excel files with extension ".XLS"
So if the Excel file you are intended to use has an extension ".XLSX", you will have to change the Excel extension to ".XLS" before uploading it in the Excel wizard. Here is the procedure.
*Excel file extension modification procedures.
1- Open your Excel file with extension ".XLSX" and click on "save as".
2- Open the "Save As type" drop down menu and choose the extension XLS and click on save.
Note: The maximum filename supported for the "Message In" and "Message Out" is 255 characters.
Creating "Message In" of type PDF
1-From the "Message In" Select "PDF" for the "Your message is of type" field, as shown below.
2-For the "PDF Sample" field click on the "Choose File" button and upload your PDF sample file, as shown below.
3-For the "Template name" write your template name in this case it will be "Invoice_Template_1", as shown below.
Note: You can name the Template name any name you want and it only can contain characters from A to Z in upper case and/or a to z characters in lower case and/or numbers between 0 to 9 and _ character, This is the only allowed characters.
4-If you want to receive a notification email when the message fell in a validation error regarding the PDF then you will need to enable the "Trigger based on message definition validation errors" and then for the "Recipients" enter the email address that will receive the notification, as shown below.
Note: For the "Trigger based on message definition validation errors" you can use one or more email addresses to receive the notification emails, To add more than one email address you will click on the + icon, as shown below.
After the "Message In" is created then from "Properties" you can update the configuration in the future when needed.
5-Now the Template will be created in the templates section, and the "Message In" structure will be empty for now because we will need to define it in the below steps in the "Extracting Fields" section, as shown below.
Note: The template allows you to define multiple templates that will match the same message definition, The template is very helpful when there is more than one PDF message sharing the same message definition by creating a template for each PDF message then you can process all them in one channel.
Note For Processing New Templates:
- If a PDF is processed but the template has not been found, have the possibility to add it directly as a new PDF template.
- If a PDF is processed, and the template has been found, have the possibility to add the pdf as a sample of the PDF template.
PDF Template Settings
The Template matching conditions is used to indicate which elements are static elements that are used to define the PDF file which will allow the system to know how to make a link between the PDF template and the input PDF message.
Note: This is the ID of the document, For the incoming PDF messages if this matches the ID then the message will be processed by its corresponding template based on the set of rules defined in the Template matching conditions.
For example, you can use one of the following (Company logo, Company address, Document type, … etc) and when this elements is used to identify the PDF file then this element must be provided in all of the input PDF message in order to the system to be able to identify the message, If for example you used the Company logo with the Document type to identify the message then you will need to provide this two fields in all of the processed PDF input messages in order for the system to be able to identify the PDF message.
1-At the bottom of the "Message In" click on the "Edit PDF template" button to begin editing the template, as shown below.
2-Click on the gear icon to open the "PDF Template Settings" pop-up page, as shown below.
Note:
-
- The below section has all of the template names, In this case, we only have one template which name is "Invoice_Template_1", as shown below.
3-We will see in this case that the system automatically has selected the Company logo to identify this PDF Template, as shown below.

Note: You can remove the automatically created rule if this will achieve your logic and then you can add the needed rules.
4-To add more elements click on the "Add Rule" button, as shown below.

5-Select a unique element in this PDF to identify the PDF, In this case, we will use the "INVOICE" label, as shown below.

6-Now you will need to click on the "Confirm" button to save these changes, as shown below.

How to process PDF input message which will contain multiple Invoices as an example in this case?
1-From the "Message In" click on the "Edit PDF template" button, as shown below.
2- Click on the gear icon to open the "PDF Template Settings" pop-up page, as shown below.
3-From the "PDF Template Settings" in the "Can this pdf include several documents of the same template?" click on "Yes" to inform the system that this PDF input message will have several messages, as shown below.

Note: The system will split the input message and process each message in a separate PDF file.
4- Now you will need to click on the "Confirm" button to save these changes, as shown below.
Extracting Fields
To extract fields from the PDF Template you have three options to select one of them based on your need.
1-Stand alone (Fixed or relative to label/image)
2-Within a table
Below is an explanation for each option:
1-Stand alone
(Fixed)
The value always starts at the same position within the PDF template (exact same coordinates each time). The value can then vary in length as long as the start position is consistent.
(Relative to a label/image)
The position of this value can vary, but it is always close to a label (field name) or image. Ex. The value 12/08/2017 is always to the right of the label 'Date'.
In fact, we only care to find the exact text of the value and from there we look to the right/left/above/below depending on how the rule is set to find the value, as shown below.
The field which has the value "101" is relative to the label "INVOICE #:".
Note:
- As advanced feature, We added ability to also say it is relative to (Text equals to, Text starts with, Text ends with, Text contains, Text matches regex).
- In Babelway, we're using the standard Java version of REGEX, and it's the same used all over the system.
2- Within a table
This will extract the line values from the table and the table can either be displayed on a single page or is divided into multiple pages.
The below steps will describe how to use the "Fixed" extraction method.
A-For extracting one line you will click on it to select it, For extracting more than one line you will click and drag the mouse around the text you want to extract, as shown below.
B-From the pop-up window "How to find field value?" click on "Standalone", as shown below.

C-Now the "Extracted Value" will show the Extract data from the field "6, Rue Louis de Geer 1348 L", as shown below.

D-We can rename the field from the bar Beside "details of extractor for" and rename it, as shown below.

Note: After you finish click on the "Confirm" button to save these changes.
E-Now the "Field name" and the "Field value" will be extracted, as shown below.
The below steps will describe how to use the "Relative to a label/image" extraction method.
A-Click on the field then, "How to find this field value?" pop-up will be displayed, as shown below.
B-Select the "Standalone"
C-Then select the relative label in this case it is "INVOICE #:", as shown below.

D-In this case the PDF has two "INVOICE #:" so we will need to select a strategy for it, as shown below.

E-From the "Strategy when we find multiple labels or images :" select in this case "Pick first", as shown below.

Note:
-
Pick first: This strategy means we will always pick the first key encountered on the PDF.
-
Pick last: This strategy means we will always pick the last key encountered on the PDF.
-
Surrounding field: Choose a label/image that is close to the key you want to pick.
F- Now the "Extracted fields" will show the field name which in this case it is "field2" and the value "101", as shown below.

G- We can rename the field by clicking on it and then renaming it, as illustrated in the previous section(Standalone/Fixed).
H- Now the "Field name" and the "Field value" will be extracted, as shown below.
Some enhancements applied for the PDF (V2)
1- Adapt multiple labels strategy when user change relativeTo field:
Editor will choose for Fax: label, and automatically adapt strategy to pickLast to point to the right 'Fax:', and not the first one of the page. Until here, everything is great:
But then, user want to change label to 'GLN' at the left of the field, Offset will be correctly updated, but not pickLast. And as GLN label is also present at multiple places in teh page, it will lead to the wrong one being selected :
If user just changes to pickFirst, everything is perfect, but it should have been adapted automatically.
2- It should not be possible to save invalid field names (ex: with spaces):
If you edit a pdfTemplate, change the name of a field to something containing a space, it was accepted before, but save will not work.
Now it is not accepted anymore and produce proper error message as shown:
When adding space.
Proper error message appear.
The below steps will describe how to use the "Within a table" extraction method.
A-Click on the field then the "How to find this field value?" pop-up will be displayed,
B-Select the "Within a table", as shown below.

C-Select the start of the table, as shown below.
D-From the "START OF lINE ITEMS"/ "Relative to a label/image" then in this case select "Quantity", as shown below.

E-Select the end of the table, as shown below.
F-From the "End of LINE Items?"/ "Relative to a label/image" then in this case select "Subtotal", as shown below.
G-Select the start of the table on next pages, as shown below.
H-From the "MULTI-PAGES TABLE - START PAGE 2?" "Fixed position", as shown below.
I-Select the end of the table on the first page, as shown below.
From "MULTI_PAGES TABLE- END PAGE1" / "Fixed position"
K-Select the Item that will inform the system that will determine the line delimiter, as shown below.
L-From the "alignment?"/ "Align Left", as shown below.

M-Select all of the items you want to extract them from the table, as shown below.
N-Now you will find four fields created in this example from "Item1" to "Item4"m as shown below.
O-Now rename the fields to be clearer for the mapping, as shown below.
P-For the Table name change its name to be "Lines" for example, as shown below.
Q-Now when we open the "Message In" we will see the structure is created, as shown below.
Note: When hovering over an extracted item in table , all the items extracted on this table will be highlighted in the pdf, and the item you hovering over will appear with more highlithining .
Monitoring message details options available for PDF "Message In"
1-When the PDF input message is processed by a channel which is using the PDF "Message In" and no template has been found for this PDF and the message is in one of the status (ERROR, ERROR_CLOSED or WAIT_FOR_HUMAN_INTERACTION) and the error is related to "No template found" then the user can click on the "Save Template" button to create a new template for this PDF "Message In" to create a new template using this PDF input message then starts the extraction definition process, as shown below.
Note: The name of the template will be the PDF file name without ".PDF" extension and if the PDF file name is valid which is only alphanumeric and underscore, And if the filename is not valid then the message key will be used and the user can change it afterwards using the rename functionality.
2-When the PDF input message is processed by a channel which is using the PDF "Message In" and the template has been found for this PDF, The user can save this input PDF message as a sample for this template by using the "Save Template" button, as shown below.
Note: The name of the template will be the PDF file name.
Row limits / Auto-detect lines
The system will try to calculate limits of the rows automatically, This algorithm is based on the detection of the lines between the rows, and will not work if there are no lines, as shown below.
Fields to extract / Smart column detection
The system will automatically find the zone for the selected column, as shown below.
the extraction mode (positional or column-based) was also called at the end of the process for the more/resize of the positional zone.
To be able to reproduce, you had to resize to a zone that is small enough to be fully included in the cell.
Pdf text extraction settings
The merge characters tolerance number which can be used to define the merge character tolerance spaces between the columns when there are barely wider than the spaces between the words in a single column, as shown below.
The merge characters tolerance number from 0.01 to 2.00.
This is a percentage of space width that is needed to consider two characters to be split.
For example: 1.00 means we look for maximum 1.00 * spaceWidth after character A to find the next character, If we find it, we merge, otherwise, we finish the text extraction here.
The following properties are available:
This file is Babelway's internal representation of your message definition tree. |
|
The validation mode describes how strictly messages need to comply with your definition in order to be processed. |
|
Babelway allows you to define multiple templates that will match the same message definition. Please choose the name of the first template you will create. |
|
If you check this, whenever some extracted fields will cause validation errors, you'll be notified by e-mail and able to fix the message. |
|
List of emails where the error notification is sent. |
|
This will split texts in two when a double space is detected. |
|
Sometimes, PDFs contains texts that are separated by position only and don't contain the actual space ' ' character. This will add those space character. |
|
Number from 0.01 to 2.00. This is the percentage of a space width that the difference between two letters must not exceed to generate a space character. For example, 0.7 means : we create a space between A and B if posX(A)+ spaceWidth - posX(B) less than spaceWidth * 0.7. The actual space width can vary a lot from PDF to PDF. This a magical number to find. |
|
Number from 0.01 to 2.00. This is a percentage of space width that is needed to consider two characters to be split. For example, 1.00 means we look for maximum 1.00 * spaceWidth after character A to find the next character. If we find it, we merge, otherwise, we finish the text extraction here. |
PDF Wizard screen allows you to define your PDF message format based on your XHTML template file.
To define a message in PDF format, select an existing template or make a copy of the generic PDF template in the catalog and the following screen will be displayed.
Wizard screen
When you create a new message format, you must first configure it using the following wizard.
A PDF message can only be set up using a template file in XHTML format. Select your template file using the Choose File button next to the XHTML file, then click on the Confirm command.
File sample
Below is a sample PDF file.
<?xml version="1.0" encoding="UTF-8"?> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>PDF output</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <style> @page { size: A4; margin: 3cm 1.5cm 2cm 1.5cm; border: none; padding: 1em; } @page { @top-left{content: ""; }} @page { @top-right{content: "Page " counter(page) " on " counter(pages);}} @page { @bottom-left{content: element(footer);border-top: solid 0.01mm #000; }} #footer{display: block; position: running(footer); } </style> </head> <body style="font-size: 12pt; font-family: 'Nobile'"> <center> <h1 >PDF output example</h1> </center> <br/> <div style="font-size: small"> <span>Date :</span> <span id="invoiceDate">25-08-2009</span> </div> <br/> <center style="font-size: large">Example</center> <br/> <table style="width: 100%" > <tr> <td rowspan="1" style="width: 200px; height: 20px;"> <span>Invoice number :</span> <span id="invoiceNumber">field1</span> </td> <td style="width: 300px; height: 20px;"> <span>Contact Name :</span> <span id="firstName">field2</span> <span id="lastName">field3</span> </td> </tr> </table> <br/> <center> <span>Some static info</span> </center> <table style="width: 100%" dir="ltr" frame="box"> <tbody> <tr> <td bgcolor="#cdd5cb" rowspan="1" style="width: 120px; height: 30px;">Description</td> <td bgcolor="#cdd5cb" style="width: 80px; height: 30px;">Unit price</td> <td bgcolor="#cdd5cb" style="width: 40px; height: 30px;">Qty</td> <td bgcolor="#cdd5cb" style="width: 80px; height: 30px;">Vat rate</td> <td bgcolor="#cdd5cb" style="width: 100px; height: 30px;">Tax free price</td> <td bgcolor="#cdd5cb" style="width: 80px; height: 30px;">Tax</td> <td bgcolor="#cdd5cb" style="width: 80px; height: 30px;">Total price</td> </tr> <tr id="product-loop"> <td style="width: 120px; height: 20px;" rowspan="0"><span id="itemDescription">Support pack 5h</span> </td> <td style="width: 80px; height: 20px" align="right"><span id="itemUnitPrice">425.00</span> </td> <td style="width: 40px; height: 20px" align="right"><span id="itemQuantity">1</span> </td> <td style="width: 80px; height: 20px" align="right"><span id="itemVatRate">21.00</span> </td> <td style="width: 100px; height: 20px" align="right"><span id="itemTaxFreePrice">425.00</span> </td> <td style="width: 80px; height: 20px" align="right"><span id="itemTax">89.25</span> </td> <td style="width: 80px; height: 20px" align="right"><span id="itemTotalPrice">514.25</span> </td> </tr> </tbody> </table> <br /> <center style="page-break-before:always"> <span>second page</span> </center> <br/> You can upload images or css sheets as file properties and use a simple relative url in your xhtml. <br/> <br/> For specific print css options, see http://www.w3schools.com/css/css_reference.asp for all css options <br/> <br/> <h2>Barcode Integration</h2> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="EAN13">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="EAN8">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="UPCA">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="UPCE">01234133</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="CODABAR">A123456789A</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="CODE39">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="CODE39_EXTENDED">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="CODE128">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="CODE128_UCC">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="CODE128_RAW">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="EAN8">123456789012345675</barcode> <br/> <barcode style="display: inline-block; width: 300px; height: 200px;" type="POSTNET">123456789012345675</barcode> <br/> <div id="footer"> Footer line#1<br/>Footer line#2 </div> </body> </html>
Edit screen
Once the message format template has been uploaded, or when it is used or copied from a saved format, you have the possibility to go on the created element. If you want to edit the properties of that message definition, switch to "Properties".
The following properties are available:
The Xhtml template which defines structure of the requested PDF. |
|
Resources used inside the Xhtml template such as images, css files,... |
|
An example of PDF file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
|
If you check this, whenever some extracted fields will cause validation errors, you'll be notified by e-mail and able to fix the message. |
|
List of emails where the error notification is sent. |
In order to ease the navigation, the xhtml attribute id is used as the name in the resulting message definition. These elements are visible by default. Mapping to these elements will be preserved if you upload another template containing the element with the same id. The attribute id needs to be using valid xml syntax (e.g.: spaces are not allowed).
If you need to add a loop to your xhtml, you can simply name the element with a suffix -loop like in the example above. The system will create a loop and a corresponding element. Mapping to these elements will also be preserved if you upload another template.
All elements without id in the xhtml will be hidden by default. If you cannot add an id to your element, you have to manually show any element you need in the transformation step. Additionally, you should edit and rename the element label for easier management during transformation step.
To ease the search of the fields you need, the values uploaded from your example file are displayed in the field tooltip descriptions.
See Message Definition to change show/hide settings and edit the element label.
For Message Definition OUT of type PDF, we can generate bar code from a value. To do this, we have to add a <object type=”image/barcode” field in the xhtml representation. The attribute “value” must be filled by the transformation. value can use only characters from “0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ-. $/+%
"
Here is a sample xhtml code with a barcode
<body>
<table id="Facure" class="MyTable" style="font-family:Arial, sans-serif; font-size:10px;width: 100%">
<tr>
<td colspan="10" class="BorderPadding05 FontSize10px">
<span class="FBold">DE (auteur de la facture)</span><br/>
</td>
<td colspan="5" class="BorderPadding05 FontSize10px">
<span class="FBold">A (Client)</span><br/>
</td>
<td colspan="5" class="BorderPadding05 FontSize10px">
<object type="image/barcode" style="width:50px;height:20px;" value="HERE THE MAPPING SHOULD PUT THE VALUE TO BE BARCODED" format="CODE_39"></object>
</td>
</tr>
</table>
</body>
Multirecord Wizard screen allows you to define your Multirecord message format (delimited or a fixed-length) according to your own file format.
What is an mr file?
An mr file is a multirecord definition file used by the Self-Service MultiRecord wizard to generate the corresponding message definition and also build the corresponding serving xml resource file.
How to build an mr file?
(1) Specify if the message is a delimited or a fixed-length message:
For fixed-length messages, the mr file header looks like this:
<multirecord name="mymultirecord" type="fixed-length" lineDelimited="true" recordDelimiter="\r\n" quoteSymbol-character=""" quoteSymbol-escapeSequence="\"" xmlns="http://xmlns.babelway.com/2007/multi-record">
For delimited messages the mr file header looks like this:
<multirecord name="mymultirecord" type="delimited" fieldDelimiter="," recordDelimiter="\r\n" quoteSymbol-character=""" quoteSymbol-escapeSequence="\"" xmlns="http://xmlns.babelway.com/2007/multi-record">
* recordDelimiter defines the delimiter between each record, it is usually the ending line character represented on windows by \r\n, on Unix/Linux by \n and on Macintosh by \r.
Note: It is recommended when creating Multirecord for the "Message In" to remove the LineDelimited in order to support all EOL "End Of Line" for any of those operating systems.
* lineDelimited specifies if the system uses a record delimiter. If set to false, the record will be based on the sum of the fields length for fixed length or the number of fields for delimited multirecords.
* trim specifies if the white spaces at the beginning and the end of the fields should be removed.
* fieldDelimiter is only used with a delimited message, defines the field delimiter.
* quoteSymbol-character is the character used to quote a field (often ")
* quoteSymbol-escapeSequence is the sequence that displays the quote symbol character in a quoted field (often \")
Tip:
For multirecord as Message In, do not specify recordDelimiter; the system will catch the \r or \n or \r\n. For multirecord as Message Out, DO specify recordDelimiter as being for instance "\r\n"; this will generate windows compliant file and let you change the delimiter from the advanced properties later on.
(2) Write the message records definitions:
You should specify the name for the record and for each of its fields. Each record should have at least one field with a static value which is used to identify the record.
<record name="Record1"> <field name="recordType" value="R1" width="2"/> <field name="field1" width="5"/> <field name="field2" width="3"/> </record>
* the width is only mandatory for fixed-length messages
* value is used to specify a static value of the field that never changes.
By default all first fields with a static value are used to identify a record. But, you can also manually define which fields must be used to identify a record using the identifier parameter.
Note: The identifier is case sensitive, so identifier="true" is not equal to identifier="True".
<record name="Record1">
<field name="recordType" value="R1" width="2" />
<field name="fieldA" width="5"/>
<field name="fieldB" width="3" value="BBB" identifier="true"/>
<field name="fieldC" width="7" />
<field name="fieldD" width="2" value="DD" identifier="true"/>
</record>
In this case, only the third and fifth fields (fieldB & fieldD), with identifier equals to "true", is used to identify the record. The default (without identifier="true") is only using recordType field as the identifier.
Remark:
For fixed-length messages, the fields used to identify a record should have the same position and length in each record. No overlap between identifiers is allowed between records, If there is only one field used to define the records, it should have the same position and can have a different length in each record.
If fixed-length messages have variable length identifiers per record, the only way to define it in the mr files is to first define the smallest common length identifier for all records and then for each record that has a longer identifier, add as many smaller fields as needed to unambiguously identify each record.
Note: if the multi-record file has a leading spaces, it must be taken into account while defining the mr file and make sure that the identifiers are at the same position, so you can remove the leading spaces by using the "Replacement based on regular-expressions" Extra Processing and add the following regex (?m)^[\s]+ to match all the leading spaces and replace them with empty values as shown below:

Regular expression to remove the leading spaces
Note: In Babelway, we're using the standard Java version of REGEX, and it's the same used all over the system.
For example, if we have a message where AAAAA, 111 and 2222 are identifiers as shown below:
AAAAA contentcontent anothercontent 1112222 this and that
The following definition is not valid since the fieldA is bigger than field1 and moreover, fieldA also overlaps with field2 and only the first record will be read:
<record name="Record1">
<field name="fieldA" width="5" value="AAAAA" identifier="true"/>
<field name="fieldB" width="16" />
<field name="fieldC" width="16" />
</record>
It should be replaced by using the "Replacement based on regular-expressions" Extra Processing as indicated before:
<record name="Record1">
<field name="fieldA" width="3" value="AAA" identifier="true"/>
<field name="fieldA" width="2" value="AA" identifier="true"/>
<field name="fieldB" width="16" />
<field name="fieldC" width="16" />
</record>
<record name="Record2">
<field name="field1" width="3" value="111" identifier="true"/>
<field name="field2" width="2" value="22" identifier="true"/>
<field name="field2" width="2" value="22" identifier="true"/>
<field name="field3" width="15" />
</record>
We had to split fieldA in two in order to have one fieldA 3 characters long (the same as field1) and another fieldA with the 2 remaining characters.
Then field2 (length 4) was also bigger than the second fieldA (length 2) so we also need to split it in two field2 of 2-character length.
All corresponding identifiers now have the same length (3 and 2) and there is no overlap between them.
It is also possible to add 4 extra settings (label, description, justify & padCharacters) to each field:
<field name="myField" label="My Field" description="My field description" justify="right" padCharacter="x" width="10"/>
* label and description are used to display the message tree.
* justify can be center, left or right.
* padCharacter is the character used to fill an empty space in the field width.
(3) Define the message structure at the end of the mr file:
<xml>
<group name="Transaction" maxOccurs="unbounded">
<group name="headers">
<record name="header" minOccurs="1" maxOccurs="unbounded"/>
</group>
<record name="record1" maxOccurs="unbounded"/>
<group name="footers">
<record name="footer" />
</group>
</group>
</xml>
*Each element can define the minOccurs and the maxOccurs setting with either 0, a positive number or 'unbounded'.
* Records defined in the records simplesect can only appear once in the message structure.
* Records can be grouped using the group element. The name of the group is mandatory.
* Records in a group should be ordered in the same way they appeared in the message.
Sample of a multirecord fixed-length message:
HH00123 AB HH00045 CDE R1one 100 R1two 101 R1four 103 FF3
Sample of a multirecord definition file:
<?xml version="1.0" encoding="UTF-8"?>
<multirecord name="mymultirecord" type="fixed-length" recordDelimiter="\r\n" quoteSymbol-character=""" quoteSymbol-escapeSequence="\"" xmlns="http://xmlns.babelway.com/2007/multi-record">
<records>
<record name="header">
<field name="recordType" value="HH" width="2"/>
<field name="header1" width="5" justify="right" padCharacter="0" />
<field name="header2" width="4" justify="right" padCharacter=" " />
</record>
<record name="record1">
<field name="recordType" value="R1" width="2"/>
<field name="field1" width="5" label="My field" description="My field Descritpion" />
<field name="field2" width="3"/>
</record>
<record name="footer">
<field name="recordType" value="FF" width="2" />
<field name="footer1" width="1"/>
</record>
</records>
<xml>
<group name="Transaction" maxOccurs="unbounded">
<group name="headers">
<record name="header" minOccurs="1" maxOccurs="unbounded"/>
</group>
<record name="record1" maxOccurs="unbounded"/>
<group name="footers">
<record name="footer" />
</group>
</group>
</xml>
</multirecord>
Note: When updating the MultiRecord structure, you must update it from the "MultiRecord definition" file first (not from the message tree) and then by using the "Rerun creation wizard" button, upload the updated "MultiRecord definition" file from the "Message In" or "Message Out".
The following properties are available:
Output charset is used to encode the file. |
|
Input Charset is used to decode the file. |
|
The MultiRecord definition file. |
|
The ServingXml code generated based on the Multirecord defintion file. |
|
An example of Multirecord file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
File sample
Below is a sample of Serving Xml file:
<sx:resources xmlns:sx="http://www.servingxml.com/core"> <sx:service id="countries"> <sx:serialize> <sx:transform> <sx:content ref="countries"/> </sx:transform> </sx:serialize> </sx:service> <sx:recordContent id="countries"> <sx:flatFileReader> <sx:urlSource url="data/countries.csv"/> <sx:flatFile ref="countriesFile"/> </sx:flatFileReader> <sx:recordMapping ref="countriesToXmlMapping"/> </sx:recordContent> <sx:flatFile id="countriesFile"> <sx:flatFileHeader lineCount="1"/> <sx:flatFileBody> <sx:flatRecordType name="country"> <sx:fieldDelimiter value=","/> <sx:delimitedField name="code"/> <sx:delimitedField name="name"/> </sx:flatRecordType> </sx:flatFileBody> </sx:flatFile> <sx:recordMapping id="countriesToXmlMapping"> <countries> <sx:onRecord> <country> <sx:fieldElementMap field="name" element="countryName"/> <sx:fieldAttributeMap field="code" attribute="countryCode"/> </country> </sx:onRecord> </countries> </sx:recordMapping> </sx:resources>
Below is a sample of an Xml file:
<?xml version="1.0" encoding="utf-8"?> <countries> <country countryCode="BE"> <countryName>Belgium</countryName> </country> <country countryCode="FR"> <countryName>France</countryName> </country> <country countryCode="IT"> <countryName>Italy</countryName> </country> </countries>
The following properties are available:
Output Charset is used to encode the file. |
|
Charset to use to decode the file |
|
Xsd definition file corresponding to the XML message. |
|
The ServingXml code file. |
|
An example of FLATFILE handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
TRADACOM is an early standard for EDI (Electronic Data Interchange) primarily used in the UK retail sector. It was introduced in 1982 as an implementation of the UN/GTDI syntax, one of the precursors of EDIFACT, and was maintained and extended by the UK Article Numbering Association (now called GS1 UK).
As Babelway supports all TRADACOM transaction sets of the TRADACOM standard, you can use any of them in your own gateway setup.
Babelway supports all following TRADACOM documents:
1.ACKHDR, ACKMNT, ACKTLR, AVLDET, AVLHDR, AVLTLR, CORDER, CORHDR, CORTLR, CRAHDR, CRAINF, CRATLR, CREDIT, CREHDR, CRETLR, CUSHDR, CUSINF, CUSTLR, DELHDR, DELIVR, DELTLR, DLCDET, DLCHDR, DLCTLR, DRAHDR, DRAINF, DRATLR, EXCHDR, EXCINF, EXCTLR, GENHDR, GENRAL, GENTLR, INVFIL, INVOIC, INVTLR, LPRDET, LPRHDR, LPRTLR, ORDERS, ORDHDR, ORDTLR, PAYHDR, PAYINF, PAYTLR, PICHDR, PICKER, PICTLR, PPRDET, PPRHDR, PPRTLR, PRIHDR, PRIINF, PRITLR, PROHDR, PROINF, PROINF, PROTLR, RSGRSG, SADDET, SADHDR, SADTLR, SNPHDR, SNPHDR, SNPSTS, SNPTLR, SRMHDR, SRMINF, SRMTLR, UCNDET, UCNHDR, UCNTLR, UCNTLR, UPLHDR, UPLIFT, UPLTLR, UTLBIL, UTLHDR, UTLTLR, UVATLR, VATTLR
File sample
Below is a sample of TRADACOM invoice file.
STX=ANAA:1+501xxxxxxxxxx:name+501xxxxxxxxxx:NAME SERVICES (U.K.)LTD.+040316:184411+00001++INVTES' MHD=1+INVFIL:9' TYP=0700+INVOICES' SDT=501xxxxxxxxxx:053752CF01STDD+Tenprl Fnsrjnl Sbbqfreivpr+221 UvyyunyyRoad:Yvfohea:Co. Antrim:N.Ireland:OG27 5WQ+412557175' CDT=501xxxxxxxxx+NAMESERVICES (U.K.) LTD.+Cnexynaqf Pbheg:OvezvatunzTerng Cnex:Ehorel:Birmingham:OG45 9CM' FIL=1+1+040316' FDT=040302+040302' MTR=7' MHD=2+INVOIC:9' CLO=0000000100007: ++PNEEVPX GOLF CLUB:ABEGU ROAD:PNEEVPX SRETHF::OG388YC' IRF=01000589M+040302+040302' ODD=1+::040302+:040302' ILD=1+1+:8408++:31266+0+2:2500:KG+54300+135800+Z+0+++SILVERSIDE 1-5 KG' STL=1+Z+0+0+1358+++++1358++0+0++1358' TLR=1+1358+++++1358++1358+0++1358' MTR=8' MHD=3+VATTLR:9' VRS=1+Z+0+1358+1358+0+1358+1358' MTR=3' MHD=4+INVTLR:9' TOT=1358+1358+0+1358+1358+1' MTR=3' MHD=5+RSGRSG:2' RSG=00001+501xxxxxxxxxx' MTR=3' END=5'
The following properties are available:
JSON Wizard screen allows you to define your JSON message format according to your own file format.
JSON (JavaScript Object Notation) is a lightweight text-based open standard designed for human-readable data interchange. It is derived from the JavaScript scripting language for representing simple data structures and associative arrays, called objects. Despite its relationship to JavaScript, it is language-independent, with parsers available for many languages. JSON format is often used for serializing and transmitting structured data for web applications.
The following properties are available:
To define a message in JSON format, select an existing template or make a copy of the generic JSON wizard in the catalogue and the following screen will be displayed.
File sample
Below is a sample of JSON file:
{ "id": "0001", "type": "donut", "name": "Cake", "ppu": 0.55, "batters": { "batter": [ { "id": "1001", "type": "Regular" }, { "id": "1002", "type": "Chocolate" }, { "id": "1003", "type": "Blueberry" }, { "id": "1004", "type": "Devil's Food" } ] }, "topping": [ { "id": "5001", "type": "None" }, { "id": "5002", "type": "Glazed" }, { "id": "5005", "type": "Sugar" }, { "id": "5007", "type": "Powdered Sugar" }, { "id": "5006", "type": "Chocolate with Sprinkles" }, { "id": "5003", "type": "Chocolate" }, { "id": "5004", "type": "Maple" } ] }
The following properties are available:
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
Note: Regarding the Messages Out of type JSON each field in the last level of the tree will have a "type" attribute that will store the type to this field that will be used to validate the generated output message.
For example: Below is the tree of the above mentioned JSON file. The "type" attribute for the field "ppu" is float. This means that the generated output message for the "ppu" field will be validated if its value is a float value, as shown below:
If the input message for this field has a value of "75" or "8.5", the messages will be processed successfully. If the message has "Cake" value, which is a string, then the processed message will fail in error: Unparseable number: "Cake". This is because the value of "Cake" is string, not a float.
Below are the values that can be used in the "type" attribute (int, float, string, boolean, array).
Note: The maximum filename supported for the "Message In" and "Message Out" is 255 characters.
REST message definition allows you to define easily a typical response for a REST request. The main particularity of this message definition is that it can generate json, xml or csv responses based on the request. This allows to define easily rest apis that supports the 3 formats with just one channel.
The output format (json, xml or csv) will be chosen according to the metadata rest_output_format. Note that this metadata is automatically set if you use a REST Gateway IN in your channel.
The following properties are available:
The character that is used to separate the fields, when generating CSVs. |
|
The character that is used to quote the special characters, when generating CSVs. |
|
Tells if the csv files must begin with a line that contains the headers of the columns. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
In order to use them in any output format, there are some limitations about the message definition tree that you can use:
- Only the first two levels of the tree is used when asking for CSV output format. If the tree has at least 2 levels (beside the root node), the first level tags will be mapped into rows of the CSV, and the second level into columns. If the tree has only one level, fields will be only mapped into columns.
- If you use a CSV with headers, headers will be automatically calculated based on the element names of the first row.
Here is an example of an output file in the 3 formats:
<?xml version="1.0" encoding="UTF-8"?> <root> <country><code>BE</code><name>Belgium</name></country> <country><code>FR</code><name>France</name></country> </root>
[ "country" : { "code" : "BE", "name" : "Belgium" }, "country" : { "code" : "FR", "name" : "France" } ]
code,name BE,Belgium FR,France
SAP IDOC are the well-known SAP interchange format. You can obtain the definition parser directly from SAP. In order to do this, select the transaction WE63. Select Basic type or Extended Type according IDoc extensions usage.
IDOC parser sample
Below is a sample of SAP IDOC file:
BEGIN_RECORD_SECTION BEGIN_CONTROL_RECORD BEGIN_FIELDS NAME TABNAM TEXT Name of external structure TYPE CHARACTER LENGTH 000010 FIELD_POS 0001 CHARACTER_FIRST 000001 CHARACTER_LAST 000010 NAME MANDT TEXT Client TYPE CHARACTER LENGTH 000003 FIELD_POS 0002 CHARACTER_FIRST 000011 CHARACTER_LAST 000013 NAME DOCNUM TEXT IDoc number TYPE CHARACTER LENGTH 000016 FIELD_POS 0003 CHARACTER_FIRST 000014 CHARACTER_LAST 000029 NAME DOCREL ...
The following properties are available:
The Idoc parser. |
|
Output Charset is used to encode the file. |
|
Input Charset is used to decode the file.. |
|
An example of SAP IDOC file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
Not Defined message format is used when there is no need to define the format of Message In and Out, because no processing will be performed on it as no change is required.
For formats not natively supported by Babelway: Advanced users have the option to upload programmatic code that provides support to proprietary message formats, such as specific binary ERP format (for example idoc of SAP...)
If the Message In format is "Not defined", so should be the Message Out. Otherwise the output may return an unexpected result or an empty message.
Usually, this setting is used in combination with No Transformation in a channel that simply transfers an unchanged and unprocessed message from one gateway to another.
Output Charset is used to encode the file. Leave empty to keep the file as is. |
|
Input Charset is used to decode the file. Leave empty to keep the file as is. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
Generic Wizard screen allows you to define your generic message format according to your own file format.
The following properties are available:
Output Charset is used to encode the file. |
|
Input Charset is used to decode the file. |
|
ConverterClass is used to parse the file. |
|
An example of the file handled by this message definition. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
OASIS Universal Business Language (UBL) is the product of an international effort to define a royalty-free library of standard electronic XML business documents such as purchase orders and invoices.
File sample
Below is a sample of UBL file:
<?xml version="1.0" encoding="UTF-8"?> <Catalogue xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2" xmlns="urn:oasis:names:specification:ubl:schema:xsd:Catalogue-2" xsi:schemaLocation="urn:oasis:names:specification:ubl:schema:xsd:Catalogue-2 ../UBL%202.1%20schema/maindoc/UBL-Catalogue-2.1.xsd"> <cbc:UBLVersionID>2.1</cbc:UBLVersionID> <cbc:CustomizationID>urn:www.cenbii.eu:transaction:biicoretrdm019:ver2.0:extended:urn:www.peppol.eu:bis:peppol1a:ver2.0</cbc:CustomizationID> <cbc:ProfileID>urn:www.cenbii.eu:profile:bii01:ver2.0</cbc:ProfileID> <cbc:ID>1234</cbc:ID> <cbc:ActionCode listID="ACTIONCODE:PEPPOL">Add</cbc:ActionCode> <cbc:Name>Peppol Catalogue</cbc:Name> <cbc:IssueDate>2013-08-01</cbc:IssueDate> <cbc:VersionID>1</cbc:VersionID> <cac:ValidityPeriod> <cbc:StartDate>2013-09-01</cbc:StartDate> <cbc:EndDate>2014-12-31</cbc:EndDate> </cac:ValidityPeriod> <cac:ReferencedContract> <cbc:ID>3299-8RA</cbc:ID> <cbc:ContractType>Framework</cbc:ContractType> </cac:ReferencedContract> <cac:ProviderParty> <cac:PartyIdentification> <cbc:ID schemeID="GLN">579000123002</cbc:ID> </cac:PartyIdentification> <cac:PartyName> <cbc:Name>Office AS</cbc:Name> </cac:PartyName> </cac:ProviderParty> <cac:ReceiverParty> <cbc:EndpointID schemeID="NO:ORGNR">99156827</cbc:EndpointID> <cac:PartyIdentification> <cbc:ID schemeID="NO:ORGNR">99572527</cbc:ID> </cac:PartyIdentification> <cac:PartyName> <cbc:Name>DIFI</cbc:Name> </cac:PartyName> </cac:ReceiverParty> <cac:CatalogueLine> <cbc:ID>1</cbc:ID> <cbc:ActionCode listID="ACTIONCODE:BII2">Add</cbc:ActionCode> <cbc:OrderableIndicator>true</cbc:OrderableIndicator> <cbc:OrderableUnit>BX</cbc:OrderableUnit> <cbc:OrderQuantityIncrementNumeric>1</cbc:OrderQuantityIncrementNumeric> <cbc:MinimumOrderQuantity>1</cbc:MinimumOrderQuantity> <cac:RequiredItemLocationQuantity> <cac:Price> <cbc:PriceAmount currencyID="NOK">20.00</cbc:PriceAmount> </cac:Price> </cac:RequiredItemLocationQuantity> <cac:Item> <cbc:Description>Ballpoint pen comes in different colours and tip sizes</cbc:Description> ...
The following properties are available:
An example of UBL file handled by this message definition. |
|
Type and version of the UBL document. Automatically detected from the provided sample |
|
UBL Profile and UBL customization reference used to validate the UBL document. Automatically detected from the provided sample |
|
Some business rules related to the document profile and customization are automatically validated. Click here to disable this validation. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
By using UBL message definition, you will get benefit of UBL XSD validation and schematron validation for some of the UBL Profile and Customization (OpenPEPPOL, ePrior...)
Note: The maximum filename supported for the "Message In" and "Message Out" is 255 characters.
The RosettaNet standard is based on XML and defines message guidelines, interfaces for business processes, and implementation frameworks for interactions between companies. Mostly addressed is the supply chain area, but also manufacturing, product and material data, and service processes are within scope.
The following properties are available:
The message definition will represent a PIP action or a RNIF signal. Please select it in the list. |
|
Some business rules related to the process type are automatically validated. Click here to disable this validation. |
|
The filename of the output message [with extension if applicable]. When empty, we apply the default settings. |
Note: The maximum filename supported for the "Message In" and "Message Out" is 255 characters.