Using Tokens


Tokens

Tokens are specially formatted placeholders that can be used in any property or setting within a Bundle Profile, Bundle Template, or Email Template. During bundle execution or when an email notification is sent, tokens are automatically replaced with dynamic data from the corresponding source.

What Does a Token Look Like?

Tokens are enclosed in double dollar signs ($). The token definition is placed between these dollar signs.

For example, the token used to display a Loan Number is:

$$CONTAINER.loanNumber$$

When the bundle executes, this token is replaced with the actual loan number from the associated loan record.

Token Structure

A token definition is made up of two parts:

1. Namespace

The Namespace is the first part of the token definition and is always displayed in uppercase letters.

The namespace identifies the source of the data, often referred to as the token's scope. It tells the system where to retrieve the information.

Example:

CONTAINER

In this example, the data is being retrieved from the loan container (loan record).

2. Token Name

The Token Name is the second part of the token definition. It represents the specific field or attribute that will be retrieved from the namespace.

Example:

loanNumber

In the token $$CONTAINER.loanNumber$$, the system retrieves the Loan Number field from the CONTAINER namespace.

Token Examples

There are many different namespaces available, allowing information to be retrieved from various sources throughout the system.

Token Namespace Description
$$CONTAINER.loanNumber$$ CONTAINER Loan Number from the loan container
$$CONTAINER.borrowerName$$ CONTAINER Borrower Name from the loan container
$$USER.userName$$ USER Name of the user executing the bundle
$$PROJECT.projectName$$ PROJECT Name of the current project
$$CURRENT.date$$ CURRENT Current system date
$$DOC.names$$ DOC Properties of Document Definitions
$$NAMING.code$$ NAMING If a document naming stack is defined, then we get the info from the stack info. If not present, we get it from the doc definition

Each namespace contains its own set of available token names, providing access to different types of data that can be inserted dynamically into bundle properties, file names, paths, email subjects, email bodies, and other configurable settings.

 

Can I Format the Data Referenced by a Token?

Yes. If the value returned by a token needs to be displayed in a specific format, XDOC supports Extended Token Syntax for formatting and data cleansing.

Extended Token Syntax allows you to apply standard formatting rules to token values before they are inserted into bundle properties, file names, email subjects, email bodies, and other configurable locations.

Examples of common formatting include:

  • Date formatting
  • Number formatting
  • Text transformation (uppercase, lowercase, etc.)
  • Data cleansing and character replacement

Detailed information about available formatting options and syntax can be found in the Bundle Token Reference Spreadsheet described below.

Where Can I Learn More About Tokens?

Comprehensive token documentation is available in the following locations.

1. XDOC Server Documentation

The complete Bundle Token Reference Spreadsheet can be found on the XDOC server at:

\XDOC\doc\referenceDocs\XDoc_bundleTokenRef.xlsx

This spreadsheet contains:

  • Available namespaces
  • Token definitions
  • Token descriptions
  • Extended Token Syntax formatting options
  • Token usage examples

2. XDOC Administration Console

Token reference information is also available directly within XDOC Admin.

System-Level Access

Navigate to:

System → Help and Support → Quick Reference → Bundle Tokens

Project-Level Access

Navigate to:

Projects → Help and Support → Quick Reference → Bundle Tokens

These Quick Reference guides provide an easy way to browse available tokens and understand how they can be used when configuring Bundle Profiles, Bundle Templates, and Email Templates.

Tip: Before creating custom file names, folder paths, email notifications, or bundle configurations, review the Bundle Token Reference to identify available tokens and formatting options that can help automate data population and reduce manual configuration.