About JSON Document Types
Integration Server creates the JSON document types based on the schemas present under
components in the OpenAPI document and adds them under the
docTypes folder. These document types describe the schemas and contain their properties and constraints.
Designer displays the JSON and OpenAPI document specific constraints under
JSON Schema property in the
Properties panel.
Designer displays the
Title,
Description,
Read only, and
Write only properties directly under
JSON Schema and displays other properties under
Validations. For more details on JSON document types, see
Working with JSON Document Types.
Validations
Validations
Designer displays the following JSON schema core properties under Core Properties as shown above in the Validations dialog box.
type format multipleOf maximum exclusiveMaximum minimum exclusiveMinimum maxLength minLength pattern enum maxItems minItems uniqueItems maxProperties minProperties additionalProperties allOf anyOf oneOf not Designer displays the following OpenAPI document specific properties under Extended Properties as shown above in the Validations dialog box.
default deprecated discrimator xml externalDocs extensions The value of the above core and extended properties is the same as defined in the OpenAPI document except for the following properties where the value is a reference to a schema or an inline schema.
allOf anyOf oneof not additionalProperties When the value is a reference to a schema, Designer displays the value as the namespace name of the generated document type. When the value is an inline schema, Integration Server generates a document type according to the inline schema definition. The document type name starts with the prefix name provided during import or uses the default prefix name. For example, _untitled_1. You can use this document reference to read or write data in the service implementation.
The following table shows the mapping between the OpenAPI Specification (OAS) type and Integration Server type.
OAS Type | Format | Integration Server Type |
string | date | java.util.Date |
string | date-time | java.util.Date |
string | password | string |
string | base64 , byte | byte[] |
string | binary | byte[] |
string | any other format or no format | string |
number | float | java.lang.Float |
number | double | java.lang.Double |
number | any other format or no format | java.math.BigDecimal |
integer | int32 | java.lang.Integer |
integer | int64 | java.lang.Long |
integer | any other format or no format | java.math.BigInteger |
boolean | -- | java.lang.Boolean |
Note:
If the OpenAPI Specification type is an array, Integration Server generates the variable with the type based on the item type of the array.
For composite keywords, allOf, anyOf, and oneOf, Integration Server generates a document containing the fields. The fields under that document are based on the schemas defined under these composite keywords. The document contains the composite keywords and Designer displays them along with the names of the generated variable in the Validations dialog box under Properties > JSON Schema.
For composite keyword not, the variable type is an object and the JSON schema validation property is the namespace name of the document type describing the schema.
Example for JSON document type generation
OpenAPI Snippet | Generated Document Type |
| |