Version: v1.2.3
This app showcases a variety of features.
Files Uploads With 'multipart/form-data'
Name
In
Type
Description
in_query
query
Number
Simple scalar value in query.
simple
formData
String
Simple scalar value in body.
uploads1
formData
Array<String
, Format: binary>
, null
Uploads with *multipart.FileHeader.
uploads2
formData
Array<null
, String
, Format: binary>
, null
Uploads with multipart.File.
File Upload With 'multipart/form-data'
Name
In
Type
Description
in_query
query
Number
Simple scalar value in query.
simple
formData
String
Simple scalar value in body.
upload1
formData
String
, Format: binary
upload2
formData
null
, String
, Format: binary
Status
Content Type
Body Type
Description
200
application/json
AdvancedInfo
OK
direct Gzip
Name
In
Type
Description
plainStruct
query
Boolean
Output plain structure instead of gzip container.
countItems
query
Boolean
Invokes internal decoding of compressed data.
direct Gzip
Name
In
Type
Description
plainStruct
query
Boolean
Output plain structure instead of gzip container.
countItems
query
Boolean
Invokes internal decoding of compressed data.
Status
Content Type
Headers
Description
200
application/json
X-Header
: String
OK
POST /json-body-validation/{in-path}
Request With JSON Body and non-trivial validation
Request with JSON body and query/header/path params, response with JSON body and data from request.
Name
In
Type
Description
in_query
query
InQuery2
, Number
Simple scalar value in query.
in-path
path
InPath
, String
Simple scalar value in path
X-Header
header
XHeader2
, String
Simple scalar value in header.
body
body
AdvancedInputWithJSONType3
POST /json-body/{in-path}
Request With JSON Body
Request with JSON body and query/header/path params, response with JSON body and data from request.
Name
In
Type
Description
in_query
query
String
, Format: date
Simple scalar value in query.
in-path
path
String
Simple scalar value in path
X-Header
header
String
Simple scalar value in header.
body
body
AdvancedInputWithJSONType2
Request With JSON Map In Body
Request with JSON object (map) body.
Name
In
Type
Description
in_query
query
Number
Simple scalar value in query.
X-Header
header
String
Simple scalar value in header.
body
body
Map<String,Number>
, null
GET /json-param/{in-path}
Request With JSON Query Parameter
Request with JSON body and query/header/path params, response with JSON body and data from request.
Name
In
Type
Description
in_query
query
Number
Simple scalar value in query.
identity
query
AdvancedJSONPayload
JSON value in query
in-path
path
String
Simple scalar value in path
X-Header
header
String
Simple scalar value in header.
Request With JSON Array In Body
Name
In
Type
Description
in_query
query
Number
Simple scalar value in query.
X-Header
header
String
Simple scalar value in header.
body
body
Array<Number>
, null
Output With Stream Writer
Output with stream writer.
Status
Content Type
Body Type
Headers
Description
200
text/csv
X-Header
: String
OK
500
application/json
RestErrResponse
Internal Server Error
GET /output-headers
Output With Headers
Output with headers.
Status
Content Type
Body Type
Headers
Description
200
application/json
AdvancedHeaderOutput
X-Header
: String
OK
HEAD /output-headers
Output With Headers
Output with headers.
Status
Content Type
Headers
Description
200
application/json
X-Header
: String
OK
Request With Object As Query Parameter
Name
In
Type
Description
in_query
query
Map<String,Number>
Object value in query.
Request Response Mapping
This use case has transport concerns fully decoupled with external req/resp mapping.
Name
In
Type
Description
X-Header
header
String
Simple scalar value.
val2
formData
Number
Simple scalar value.
Status
Headers
Description
204
X-Value-1
: String
X-Value-2
: Number
No Content
Validation
Input/Output with validation. Custom annotation.
Name
In
Type
Description
q
query
Boolean
This parameter will bypass explicit validation as it does not have constraints.
X-Input
header
XInput
, Number
Request minimum: 10, response maximum: 20.
body
body
AdvancedInputPortType2
Property
Type
filenames
Array<String>
, null
headers
Array<Map<String,Array<String>>
, null>
, null
inQuery
Number
peeks1
Array<String>
, null
peeks2
Array<String>
, null
simple
String
sizes
Array<Number>
, null
Property
Type
filename
String
header
Map<String,Array<String>>
, null
inQuery
Number
peek1
String
peek2
String
simple
String
size
Number
AdvancedGzipPassThroughStruct
Property
Type
id
Number
text
Array<String>
, null
Simple scalar value in query.
Constraint
Value
minimum
100
Simple scalar value in path
Constraint
Value
minLength
3
XHeader2
Simple scalar value in header.
Constraint
Value
minLength
3
AdvancedInputWithJSONType3Id
Constraint
Value
minimum
100
AdvancedInputWithJSONType3Name
Constraint
Value
minLength
3
AdvancedInputWithJSONType3
AdvancedOutputWithJSONType3Id
Constraint
Value
minimum
100
AdvancedOutputWithJSONType3InHeader
Constraint
Value
minLength
3
AdvancedOutputWithJSONType3InPath
Constraint
Value
minLength
3
AdvancedOutputWithJSONType3InQuery
Constraint
Value
minimum
3
AdvancedOutputWithJSONType3Name
Constraint
Value
minLength
3
AdvancedOutputWithJSONType3
AdvancedInputWithJSONType2
Property
Type
id
Number
name
String
AdvancedOutputWithJSONType2
Property
Type
id
Number
inHeader
String
inPath
String
inQuery
String
, Format: date
name
String
Property
Type
data
Map<String,Number>
, null
inHeader
String
inQuery
Number
Property
Type
id
Number
name
String
Property
Type
id
Number
inHeader
String
inPath
String
inQuery
Number
name
String
Property
Type
data
Array<Number>
, null
inHeader
String
inQuery
Number
Property
Type
Description
code
Number
Application-specific error code.
context
Map<String,*>
Application context.
error
String
Error message.
status
String
Status text.
AdvancedHeaderOutput
Property
Type
inBody
String
AdvancedOutputQueryObject
Property
Type
inQuery
Map<String,Number>
, null
Request minimum: 10, response maximum: 20.
Constraint
Value
minimum
10
AdvancedInputPortType2DataValue
Request minLength: 3, response maxLength: 7
Constraint
Value
minLength
3
AdvancedInputPortType2Data
Constraint
Value
maximum
20
AdvancedOutputPortType2DataValue
Constraint
Value
maxLength
7
AdvancedOutputPortType2Data