Read JSON activity configuration

You can apply a sample JSON or XML message to the Read JSON input parameter. Use of a schema is optional for this step.

About this task

If you're applying a JSON or XML message to the Read JSON input parameter, do the following steps:

Note: Because not all JSON messages contain a root node, Studio, by default, adds a virtual root element to all JSON messages during a write JSON activity. (Virtual nodes facilitate handling of rootless messages in Studio). To determine if a root node is present, view the message in the Configure panel. If the message does not contain a root element, Studio will automatically generate one during the write JSON activity and display it in the root element file. To remove the root element, delete it from the Configure panel so the output message matches the required structure.

Procedure

  1. Click Configure from the Checklist. The Configure window is displayed.
  2. In the Configure window, copy the JSON or XML message into the text area and click Generate Output Map. If you're specifying an XML schema to apply to the Read JSON input parameter, do the following additional steps: (a) In the Select XML Schema pane click the Select XML Schema button to browse for the XML schema, then (b) select the XML schema to parse against during run time and click OK. (You must select a root or global element and not a schema fragment).
  3. Specify how to read the data passed into the JSONText input parameter during run time by selecting one of the appropriate options:
    1. Select the Data is text-Needs no decoding option if the incoming data is text and does not need decoding.
    2. Select the Decode data using encoding type option if incoming data is binary data that needs to be decoded using the specified encoding type. Set the encoding type by selecting a default encoding type from the Decode data using encoding type list or enter your encoding type by clicking in the Decode data using encoding type field and typing in your encoding type.
  4. Click OK.



Feedback | Notices


Timestamp icon Last updated: Wednesday, February 17, 2016


http://pic.dhe.ibm.com/infocenter/wci/v7r0m0/topic/com.ibm.wci.doc/Read_json_Activity_conf.html