Collapse AllExpand All

3.2.1. EDI Tokens

Tokens are used in EDI Profiles as a means for automatically placing specific information in an email when the email is actually created. There are a few basic tokens available for all supported Document Types. For example, note the </docnumber> in the File Name field of the EDI Form window in Section 3.2, “Create a Simple EDI Profile”—this will be replaced with the actual invoice number when an Invoice is about to be sent.

The following tokens are available to support EDI Profiles wherever they are used:

</docnumber>

The document number (e.g., 60096)

</doctype>

The Document Type (e.g., IN)

</docid>

The primary key id for the document—this is a number used internally by xTuple ERP and not normally shown to users (e.g., 157)

</doctypefull>

A human-meaningful version of the Document Type (e.g., Invoice)

a document-type-specific token

The primary key id for the document, named for the primary key field of that document (e.g., </invchead_id>)

You can also define your own tokens to build more interesting and general EDI Profiles. See Section 1.2.2, “Defining New EDI Tokens” in Chapter 5, Advanced EDI for more information on how to do this.