Read JSON Data Activity
The Read JSON Data activity enables parsing of JSON content from either a specified file path or a direct JSON-formatted string. It then stores the parsed data into a designated JSON type variable, making it available for subsequent automation steps.
| Field | Description | Requirement |
|---|---|---|
| File Name | Specifies the full path to the JSON file to be read. | Required |
| JSON string | Provides the JSON-formatted string content to be parsed. | Required |
| Result variable name | Defines the name of the variable where the parsed JSON data will be stored. | Required |
Action Types & Examples
JSON Output Variable
- Format:
JSON objectorJSON array - Example Result:
resultJson
Implementation Examples
Field Setup - File Name: C:RobustaXml-JsonreadJsontest.json - JSON string: [{ "id": 1 }] - JSON string: { "id": 1, "firstname": "Katerina", "job": { "site": "www.javacodegeeks.com", "name": "Java Code Geeks" } } - Result variable name: resultJson
Execution Parameters - Example 1 (Reading from File): - File Name: C:RobustaXml-JsonreadJsontest.json - Result variable name: resultJson - Example 2 (Reading from String): - JSON string: [{ "id": 1 }] - Result variable name: resultJson
Technical Notes
The Read JSON Data activity requires either the
File Nameor theJSON stringparameter to be provided, but not necessarily both simultaneously for a single execution. The activity processes well-formed JSON data, whether provided as a file path or a direct string. Ensure the input JSON adheres to standard JSON syntax for successful parsing. The output variable will hold the parsed JSON structure, accessible for subsequent operations.