OMF 1โ.2 Writer module
- Last UpdatedNov 20, 2026
- 6 minute read
This module receives messages from upstream modules and processes them by writing OMF 1.2 messages to an OMF endpoint.
Module settings
The following table provides a detailed list of module settings.
|
Name |
Requirements |
Purpose |
Default |
|---|---|---|---|
|
Source Property |
Length: 0-64 |
Optional property that contains the input data the module will use. If not provided, the entire incoming flow message will be used as the source. |
|
|
Target Property |
Length: 1-64 |
The property to write the results into. |
data |
|
Data Selection (Resource) |
Selection |
The Omf12Streams type resource file that contains mappings between data in the incoming messages. |
|
|
Timestamp Mode |
Dropdown |
Where to read the timestamp from. Options: Current Time (use current time), From Data Item (read from each data item), and From Message (read one timestamp from the Timestamp Property). |
CurrentTime |
|
Timestamp Property |
Length: 0-64 |
The property that contains the timestamp to use for the OMF data. Used when Timestamp Mode is From Message. If this property is specified in any other Timestamp Mode, the module will fail to start. This is to avoid accidental misconfiguration. |
|
|
Keep Properties |
true/false |
If true all properties not renamed or removed will be included in the output. False will only include properties renamed or added. |
|
|
Credentials |
Must be one of the following credential types: AVEVA OMF OAuth Client Credential, AVEVA OMF Basic, or AVEVA OMF EDS No Auth |
The credentials to use for authentication. |
Data Selection (Resource) item settings
Incoming flow messages are parsed according to the Data Selection (Resource) file, which contains an array of data selection items. Each selection item specifies how to extract a value from the incoming message and send it to a specific OMF stream.
The referenceProperty and referenceValue fields are used to identify which items in the data selection items list should be used to process each data item in the message. The module looks for objects in the incoming data where the property named by referenceProperty has a value that matches referenceValue. If a match is found, the module extracts the value from the property specified by valueProperty and sends it to the OMF stream identified by streamId.
|
Name |
Requirements |
Purpose |
Default |
|---|---|---|---|
|
name |
Optional |
Friendly name for the selection item. |
|
|
streamId |
Required |
OMF stream identifier to write data values to. |
|
|
indexProperty |
Optional |
Property in the input data that provides the timestamp when Timestamp Mode uses data-item timestamps. |
|
|
referenceProperty |
Required |
Property name used to find the input item to match. |
|
|
referenceValue |
Required |
Expected value at referenceProperty to match an input item. Use "*" as a wildcard to match any value. |
|
|
dataType |
Required |
OMF data type for the value. Valid data types: BOOLEAN, INT64, INT32, INT16, UINT64, UINT32, UINT16, STRING, DATETIME, FLOAT64, FLOAT32. |
|
|
valueProperty |
Required |
Property containing the value to send to the OMF stream. |
|
|
streamName |
Optional |
Name to be given to the newly created stream. |
|
|
streamDescription |
Optional |
Description to be given to the newly created stream. |
|
|
streamTags |
Optional |
List of strings to be added as tags on the newly created stream. |
|
|
streamMetadata |
Optional |
Key-value pairs to be added as metadata on the newly created stream. |
Code examples
This section provides the following code examples:
-
Code example 1: Send a simple, incoming flow message to an OMF endpoint
-
Code example 2: Wildcard reference
-
Code example 3: Timestamp Mode - Current Time
-
Code example 4: Timestamp Mode - From Data Item
-
Code example 5: Timestamp Mode - From Message
Note: Download the .zip file to get JSON files for each code example. Copying and pasting the JSON examples does not preserve formatting.
Code 1 example: Send a simple, incoming flow message to OMF endpoint
This example shows how the module processes an incoming flow message by transforming and then sending the flow message to an OMF endpoint.
Code 1 example: Link to ZIP file download
Configuration
-
Source Property = data
-
Target Property = data
-
Data Selection (Resource) = "Existing data selection file of type Resource"
-
Credentials = "Existing credentials object of type Credentials"
-
OMF Endpoint = "Valid OMF Endpoint"
-
Incoming message
{
"data": {
"id": "tag1",
"name": "temp1",
"value": 25.853235
}
}
Data Selection Array
[
{
"name": "temp1",
"streamId": "AutoCreatedStream",
"indexProperty": null,
"referenceProperty": "name",
"referenceValue": "temp1",
"dataType": "Float64",
"valueProperty": "value"
}
]
Module output
The module output includes an object that contains the status of the write call for the incoming message. The resulting OMF data message is sent to a predefined OMF endpoint and is not visible in Flow Studio.
{
"crosser": {
"success": true
},
"data": {
"statusCode": "Accepted"
}
}
Code 2 Example: Wildcard reference value
When the referenceValue is set to "*" (wildcard), the module matches any value found at the referenceProperty key, effectively treating the property name itself as the identifier rather than requiring a specific value to match against.
This approach is useful when the incoming data is a flat set of key-value pairs -- for example, temperature: 25.8 -- rather than objects with a shared identifier field, such as name: temp1.
Code 2 example: Link to ZIP file download
Configuration
-
Source Property = data
-
Target Property = data
-
Data Selection (Resource) = "Existing data selection file of type Resource"
-
Credentials = "Existing credentials object of type Credentials"
-
OMF Endpoint = "Valid OMF Endpoint"
Incoming message
{
"data": {
"temperature": 25.853235,
"pressure": 1.01325
}
}
Data Selection Array
[
{
"name": "temperature",
"streamId": "TemperatureStream",
"indexProperty": null,
"referenceProperty": "temperature",
"referenceValue": "\*",
"dataType": "Float64",
"valueProperty": "temperature"
},
{
"name": "pressure",
"streamId": "PressureStream",
"indexProperty": null,
"referenceProperty": "pressure",
"referenceValue": "*",
"dataType": "Float64",
"valueProperty": "pressure"
}
]
How it works
|
Field |
Meaning in this example |
|---|---|
|
referenceProperty |
The key in the incoming data to look for ("temperature", "pressure"). |
|
referenceValue |
"*" = "match regardless of the value found at that key." |
|
valueProperty |
The key whose value is sent to OMF (same key here, since the value is the reading). |
|
streamId |
The OMF stream the value is written to. |
Contrast with a non-wildcard selection
In the non-wildcard examples, data items contain an identifier field -- for example, "name": "temp1" -- and referenceValue is set to "temp1" to match only items where name == "temp1". The wildcard removes that requirement and is useful when each property in the object already represents a distinct measurement.
Code 3 example: Timestamp Mode - Current Time
The module uses the current system time as the timestamp for all OMF data values. The indexProperty in the Data Selection must be null.
Code 3 example: Link to ZIP file download
Configuration
-
Source Property = data
-
Target Property = data
-
Timestamp Mode = Current Time
-
Data Selection (Resource) = "Existing data selection file of type Resource"
-
Credentials = "Existing credentials object of type Credentials"
-
OMF Endpoint = "Valid OMF Endpoint"
Incoming message
{
"data": {
"name": "temp1",
"value": 25.853235
}
}
Data Selection Array
[
{
"name": "temp1",
"streamId": "AutoCreatedStream",
"indexProperty": null,
"referenceProperty": "name",
"referenceValue": "temp1",
"dataType": "Float64",
"valueProperty": "value"
}
]
The OMF data message will be sent with the current UTC system time as the timestamp.
Code 4 example: Timestamp Mode - From Data Item
The module reads the timestamp from each individual data item using the indexProperty specified in the Data Selection.
Code 4 example: Link to ZIP file download
Configuration
-
Source Property = data
-
Target Property = data
-
Timestamp Mode = From Data Item
-
Data Selection (Resource) = "Existing data selection file of type Resource"
-
Credentials = "Existing credentials object of type Credentials"
-
OMF Endpoint = "Valid OMF Endpoint"
Incoming message
{
"data": {
"name": "temp1",
"value": 25.853235,
"timestamp": "2024-01-15T12:30:00Z"
}
}
Data Selection Array
[
{
"name": "temp1",
"streamId": "AutoCreatedStream",
"indexProperty": "timestamp",
"referenceProperty": "name",
"referenceValue": "temp1",
"dataType": "Float64",
"valueProperty": "value"
}
]
The OMF data message will use the timestamp value from each data item (2024-01-15T12:30:00Z in this case).
Code 5 example: Timestamp Mode - From Message
The module reads a single timestamp from a top-level property on the incoming flow message specified by the Timestamp Property setting. The indexProperty in the Data Selection must be null.
Code 5 example: Link to ZIP file download
Configuration
-
Source Property = data
-
Target Property = data
-
Timestamp Mode = From Message
-
Timestamp Property = timestamp
-
Data Selection (Resource) = "Existing data selection file of type Resource"
-
Credentials = "Existing credentials object of type Credentials"
-
OMF Endpoint = "Valid OMF Endpoint"
Incoming message
{
"timestamp": "2024-01-15T12:30:00Z",
"data": {
"name": "temp1",
"value": 25.853235
}
}
Data Selection Array
[
{
"name": "temp1",
"streamId": "AutoCreatedStream",
"indexProperty": null,
"referenceProperty": "name",
"referenceValue": "temp1",
"dataType": "Float64",
"valueProperty": "value"
}
]
The OMF data message uses the timestamp property from the message (2024-01-15T12:30:00Z) as the timestamp for all data values.