The Read Binary Content Task parses file content into JSON or TXT format and stores the result in a process variable.
Use this task when a process needs to read the contents of a file and make the data available for variable mapping, decision logic, or further processing. A binary content object represents the contents of a file rather than a folder. Therefore, this task cannot be used to read the contents of a folder.
During execution the task executes the READ_BINARY_CONTENT action. The specified content object is retrieved from the repository and parsed into the requested format. The parsed content is stored in a process variable. The resulting variable can be used by subsequent workflow activities.
The input parameters of the task are:
| Parameter | Type | Required | Description |
|---|---|---|---|
| content | content | Requires one | Reference to the content object containing the content to read and parse. Example: 775a8f2d-8123-49a7-ae1f-f3f49d4eae20. |
| contentFormat | string | Requires one | Format of the returned content. Valid values are JSON and TXT. The source files must also be in JSON or TXT format. |
The output parameters of the task are:
| Parameter | Type | Required | Description |
|---|---|---|---|
| contentJSON | JSON | Optional | The resulting file content as a JSON variable. |
| contentText | string | Optional | The resulting file content as a string variable. |