Creating Types From JSON
- 30 Jul 2024
- 1 Minute to read
- Print
- DarkLight
Creating Types From JSON
- Updated on 30 Jul 2024
- 1 Minute to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Overview
Users can create new datatypes from JSON formatted objects. The properties of the JSON object will be used to create the fields for the new datatype.
If the inputted JSON object contains nested objects, then datatypes for the nested objects will also be generated.
The below section provides an example of creating a new datatype using a JSON object.
- Select CREATE DATATYPES/INTEGRATION in a Designer Project from the top action bar.
- In the Create DataTypes/Integration window, select XML/JSON/CSV from the right column, then select Create Types from JSON.
- From here, the Edit JSON Structure page will appear. Below is a table that covers the input fields for the new datatype.
Property Description Json Structure Name The name of the datatype NameSpace The namespace for the datatype Allow Nullable Values An optional setting that when enabled, allows fields to have null values Use JSON File An optional setting that allows a JSON file to be uploaded and used as the template for the new datatype. Json Structure A field where the datatype can be copied into Decisions. The structure being added here must be a valid JSON formatted object. - Once the structure is configured correctly, click Save Structure. A new Simple Flow structure will be created with the Json Structure Name.
Making changes to the JSON structure
Users can update the generated datatype if changes to the JSON structure need to be made.
- Right click the JSONDataStructure within the Project.
- Select Edit
- The Edit JSON Structure page should open. From here, the JSON used to generate the structure can be updated.
- Below is a list of properties available when editing a JSON structure.
Property Description Json Structure Name The name of the datatype NameSpace The namespace for the datatype Allow Nullable Values An optional setting that when enabled, allows fields to have null values Use JSON File An optional setting that allows a JSON file to be uploaded and used as the template for the new datatype. Json Structure A field where the datatype can be copied into Decisions. The structure being added here must be a valid JSON formatted object. Select DataTypes to Generate Steps For If checked, a Serialize and Deserialize JSON step specific to the datatype will be generated.
The steps can be found under USER DEFINED TYPES > JSON STRUCTURES > [DataStructureName]Generated Datatypes A list of generated datatypes that were created based on the inputted JSON.
Was this article helpful?