Restrictions on JSON

JSON files used to create REST services and references have some restrictions.

  • Arrays must have homogeneous content.
  • Arrays cannot directly contain arrays ( [ [ ... ], [ ... ] ] )
  • Null type properties throw the XSD schema conversion error in TIBCO Business Studio for BusinessWorks. To create a REST Service or REST Binding edit the input JSON file and change the data type from null to string.
  • If a Swagger 3.0 JSON file contains multiple servers URL, then on creating the REST service or a reference from it, the first URL is picked up to configure the shared resource's host and port. You can re-configure the host and port based on the server URL you want to invoke. Change the configurations accordingly in the shared resource.
  • If an operation in Swagger 2.0 JSON file has parameters or responses with embedded anonymous schema, by default a validation error occurs. In TIBCO Business Studio for BusinessWorks to turn off the validation error navigate to Preferences > BusinessWorks > Validation > Swagger with Anonymous schema and select the Warning or Ignore option.
  • If a Swagger JSON file has optional array property with minItems keyword, then it is treated as a required array property because it gets converted to an array element which has minOccurs attribute value set as per the minItems value.

Not currently supported

  • Binary content in JSON as a special case.
  • The Swagger 3.0 JSON file containing Open API 3.0 specific features which are not in parity with Swagger 2.0 JSON file.