CSV, XML, and JSON list parameters populate a selection from an external data file on the OptimiDoc server. They suit lists that are large, change often, or are maintained by another system — and, like the inline List type, they support multi-level (tree) grouping so the operator can drill down to a choice.
Overview
When the options are too many for an inline List, or are produced by another system, an external list parameter reads them from a file. OptimiDoc supports three formats:
|
Type |
File format |
Best for |
|---|---|---|
|
CSV |
Comma-separated values ( |
Simple key/value data, exports from databases or spreadsheets |
|
JSON |
JSON array ( |
Structured data, exports from web systems |
|
XML |
XML document ( |
Enterprise and legacy system exports |
All three present the same selection interface to the operator — only the source format differs — and all three support hierarchical (tree) lists.
How It Renders on the Terminal
The device panel shows a selection control labelled with the parameter's Title. As with the inline List type, lists of more than 20 items become searchable, and hierarchical lists are navigated by drilling down through their groups. Each item has a stored key and a displayed value; the operator sees the value, and the key is what the workflow receives.
Hierarchy (Tree) Support
Each format expresses parent/child relationships by giving an item the key of its parent:
-
CSV — an optional third column holds the parent key.
-
JSON — an optional
parentKeyproperty on each object. -
XML — an optional Parent element or attribute, configured alongside Key and Value.
Items with no parent are top-level; items whose parent key matches another item's key become its children. The Allow selecting group items option decides whether a parent (group) item can be chosen directly, or acts only as a navigation folder.
CSV List Parameter
Configuration
|
Field |
Description |
|---|---|
|
File Path |
Full path to the CSV file on the OptimiDoc server, e.g. |
|
Prefetch Data |
Load and cache the list ahead of time (see Prefetch below) |
|
Allow selecting group items |
Allow parent rows to be selected, not just leaves |
File format
Each line is key,displayvalue with an optional third column for the parent key. No header row:
FIN,Finance Department
HR,Human Resources
MKT,Marketing
With a single column, the same text is used as both key and display value. With three columns, the third builds a tree:
inv,Invoices,
in,Incoming,inv
out,Outgoing,inv
Here "Incoming" and "Outgoing" are children of "Invoices". Values are split on commas, so commas within a value are not supported — use JSON or XML if your data contains commas.
JSON List Parameter
Configuration
|
Field |
Description |
|---|---|
|
File Path |
Full path to the JSON file on the OptimiDoc server, e.g. |
|
Prefetch Data |
Load and cache the list ahead of time |
|
Allow selecting group items |
Allow parent items to be selected, not just leaves |
File format
An array of objects, each with a key, a value, and an optional parentKey:
[
{ "key": "inv", "value": "Invoices" },
{ "key": "in", "value": "Incoming", "parentKey": "inv" },
{ "key": "out", "value": "Outgoing", "parentKey": "inv" }
]
The property names key, value, and parentKey are recognised (the capitalised forms Key, Value, ParentKey also work). A legacy flat object of "key": "value" pairs is still accepted for simple lists.
XML List Parameter
Configuration
|
Field |
Description |
|---|---|
|
File Path |
Full path to the XML file on the OptimiDoc server, e.g. |
|
XML Element Name |
The element that represents each item, e.g. |
|
Key Element/Attribute |
The element or attribute holding the stored key, e.g. |
|
Value Element/Attribute |
The element or attribute holding the display value, e.g. |
|
Parent Element/Attribute |
(optional) The element or attribute holding the parent key, for tree lists |
|
Use Attributes |
Read Key/Value/Parent from element attributes instead of child elements |
|
Prefetch Data |
Load and cache the list ahead of time |
|
Allow selecting group items |
Allow parent items to be selected, not just leaves |
Child-element form (Use Attributes off)
<departments>
<department>
<id>FIN</id>
<name>Finance Department</name>
</department>
</departments>
Element Name = department, Key = id, Value = name.
Attribute form (Use Attributes on)
<departments>
<department id="FIN" name="Finance Department" parent="" />
<department id="FIN-AP" name="Accounts Payable" parent="FIN" />
</departments>
Element Name = department, Key = id, Value = name, Parent = parent, Use Attributes = on.
Prefetch and Automatic Refresh
|
Prefetch Data |
Behaviour |
Best for |
|---|---|---|
|
On |
The list is loaded and cached for fast display |
Larger lists that do not change constantly |
|
Off |
Items are fetched and searched on demand as the operator types |
Very large or frequently changing lists |
Either way, OptimiDoc watches the file: when the file's modification time changes, the cached list is reloaded automatically on next use — editing the file does not require a service restart.
File Location Requirements
-
The file must be reachable from the OptimiDoc server, not the device.
-
Use a local path (
C:\Data\lists\) or a UNC path (\\fileserver\share\lists\). -
The OptimiDoc service account needs read access to the file (and network access for UNC paths).
-
Save files as UTF-8 so accented and special characters display correctly.
Using the Value
The placeholder resolves to the key of the selected item. For a parameter with key department where the operator picked the item keyed FIN:
|
Location |
Example |
Result |
|---|---|---|
|
Filename |
|
|
|
Folder path |
|
Routes into the |
|
Metadata |
(automatic) |
The key is included in PDF metadata and the metadata sidecar |
Choosing the Format
|
Consideration |
CSV |
JSON |
XML |
|---|---|---|---|
|
Simplicity |
Easiest |
Moderate |
Most verbose |
|
Editing |
Text editor / spreadsheet |
Text editor / API tools |
Text / XML tools |
|
Commas in values |
Not supported |
Supported |
Supported |
|
Attribute-based data |
— |
— |
Supported |
|
Hierarchy |
3rd column |
|
Parent element/attribute |
Troubleshooting
|
Issue |
Possible cause |
Resolution |
|---|---|---|
|
Empty selection |
File not found or empty |
Verify the path and that the file contains data |
|
Permission denied |
Service account lacks read access |
Grant read access to the OptimiDoc service account |
|
Values not updating |
File modification time unchanged |
Re-save the file so its timestamp changes |
|
XML parsing error |
Element/attribute names do not match |
Check Element Name, Key, Value (and Parent) against the file, and the Use Attributes setting |
|
Broken accented characters |
Wrong encoding |
Save the file as UTF-8 |
|
No tree / flat list only |
Parent key not set or does not match |
Ensure each child's parent key equals an existing item's key |
In Summary
External list parameters keep large or system-managed option sets out of OptimiDoc and in a file that the right team can maintain. Pick the format that fits your data — CSV for simple exports, JSON for structured data, XML for attribute-rich or legacy sources — add a parent column/property/element for tree navigation, and let automatic refresh keep the panel current without a restart.
Related Articles
-
Scan Parameters Reference — Overview of all parameter types and the
[key]placeholder syntax -
List Parameter — Inline key/value list with the same tree support
-
SharePoint List Parameter — SharePoint-sourced list
-
Parameters Tab — Attaching parameters to workflows