2022.1

Table Of Contents
A Capture OnTheGo Repository ID and password are required in order to configure the COTG
node in these flows.
Making a form available to COTG app users
The flow that creates and publishes COTG forms will usually have the following nodes.
l Typically the trigger will be an endpoint set up using the http in node, but the flow could
also be triggered by an input node like the OL Connect capture folder node, the standard
watch node or the third-party watch-directory node (see "Nodes used in OL Connect
flows" on page204).
l In order to create a personalized form or document, incoming data must be processed.
Once the data file is received, the data mapping node uploads it to the Connect Server
and subsequently extracts the data using a data mapping configuration. It outputs a data
set ID in msg.dataSetId.
l The data get node retrieves the records from the database using the data set ID. It stores
the retrieved data records in an array on msg.payload.
l Node-RED's split node can be used to iterate over the records. In each iteration the
record values of a single record are written to msg.payload.
l A change node sets any msg properties that the file node and the cotg publish node
need, such as the order ID, customer name, COTG account and the file name of the form.
l OL Connect's html content node takes the record ID in msg.payload as its input and
renders the form. It outputs the HTML to msg.payload.
l The file node writes the HTML content in msg.payload to disk.
l The cotg publish node informs the Capture OnTheGo Server that a new document is
available for download. The node returns the ID of the form on the COTG server in
msg.documentId.
Tip
Store the form ID in a text file or database along with the order ID and/or GUID. This
makes it possible to find and delete the form (using the cotg delete node) when
form data is submitted.
Page 219