Skip to main content

Documentation for the kotlin-wiremock Generator

METADATA

PropertyValueNotes
generator namekotlin-wiremockpass this to the generate command after -g
generator stabilityBETA
generator typeSERVER
generator languageKotlin
generator default templating enginemustache
helpTxtGenerates Kotlin WireMock stub request and response samples.

CONFIG OPTIONS

These options may be applied as additional-properties (cli) or configOptions (plugins). Refer to configuration docs for more details.

OptionDescriptionValuesDefault
additionalModelTypeAnnotationsAdditional annotations for model type(class level annotations). List separated by semicolon(;) or new line (Linux or Windows)null
apiSuffixsuffix for api classesApi
artifactIdGenerated artifact id (name of jar).null
artifactVersionGenerated artifact's package version.1.0.0
enumPropertyNamingNaming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'original
groupIdGenerated artifact package's organization (i.e. maven groupId).org.openapitools
modelMutableCreate mutable modelsfalse
packageNameGenerated artifact package name.org.openapitools
parcelizeModelstoggle "@Parcelize" for generated modelsnull
serializableModelboolean - toggle "implements Serializable" for generated modelsnull
sortModelPropertiesByRequiredFlagSort model properties to place required parameters before optional parameters.null
sortParamsByRequiredFlagSort method arguments to place required parameters before optional parameters.null
sourceFoldersource folder for generated codesrc/main/kotlin

IMPORT MAPPING

Type/AliasImports
BigDecimaljava.math.BigDecimal
Datejava.time.LocalDate
DateTimejava.time.OffsetDateTime
Filejava.io.File
LocalDatejava.time.LocalDate
LocalDateTimejava.time.LocalDateTime
LocalTimejava.time.LocalTime
Timestampjava.sql.Timestamp
URIjava.net.URI
UUIDjava.util.UUID

INSTANTIATION TYPES

Type/AliasInstantiated By
arraykotlin.collections.ArrayList
listkotlin.collections.ArrayList
mapkotlin.collections.HashMap

LANGUAGE PRIMITIVES

  • kotlin.Array
  • kotlin.Boolean
  • kotlin.Byte
  • kotlin.ByteArray
  • kotlin.Char
  • kotlin.Double
  • kotlin.Float
  • kotlin.Int
  • kotlin.Long
  • kotlin.Short
  • kotlin.String
  • kotlin.collections.List
  • kotlin.collections.Map
  • kotlin.collections.MutableList
  • kotlin.collections.MutableMap
  • kotlin.collections.MutableSet
  • kotlin.collections.Set

RESERVED WORDS

  • ApiResponse
  • abstract
  • actual
  • annotation
  • as
  • break
  • class
  • companion
  • const
  • constructor
  • continue
  • contract
  • crossinline
  • data
  • delegate
  • do
  • dynamic
  • else
  • enum
  • expect
  • external
  • false
  • field
  • final
  • finally
  • for
  • fun
  • if
  • import
  • in
  • infix
  • init
  • inline
  • inner
  • interface
  • internal
  • is
  • it
  • lateinit
  • noinline
  • null
  • object
  • open
  • operator
  • out
  • override
  • package
  • param
  • private
  • property
  • protected
  • public
  • receiver
  • reified
  • return
  • sealed
  • setparam
  • super
  • suspend
  • tailrec
  • this
  • throw
  • true
  • try
  • typealias
  • typeof
  • val
  • value
  • var
  • vararg
  • when
  • where
  • while

FEATURE SET

Client Modification Feature

NameSupportedDefined By
BasePathToolingExtension
AuthorizationsToolingExtension
UserAgentToolingExtension
MockServerToolingExtension

Data Type Feature

NameSupportedDefined By
CustomOAS2,OAS3
Int32OAS2,OAS3
Int64OAS2,OAS3
FloatOAS2,OAS3
DoubleOAS2,OAS3
DecimalToolingExtension
StringOAS2,OAS3
ByteOAS2,OAS3
BinaryOAS2,OAS3
BooleanOAS2,OAS3
DateOAS2,OAS3
DateTimeOAS2,OAS3
PasswordOAS2,OAS3
FileOAS2
Uuid
ArrayOAS2,OAS3
NullOAS3
AnyTypeOAS2,OAS3
ObjectOAS2,OAS3
MapsToolingExtension
CollectionFormatOAS2
CollectionFormatMultiOAS2
EnumOAS2,OAS3
ArrayOfEnumToolingExtension
ArrayOfModelToolingExtension
ArrayOfCollectionOfPrimitivesToolingExtension
ArrayOfCollectionOfModelToolingExtension
ArrayOfCollectionOfEnumToolingExtension
MapOfEnumToolingExtension
MapOfModelToolingExtension
MapOfCollectionOfPrimitivesToolingExtension
MapOfCollectionOfModelToolingExtension
MapOfCollectionOfEnumToolingExtension

Documentation Feature

NameSupportedDefined By
ReadmeToolingExtension
ModelToolingExtension
ApiToolingExtension

Global Feature

NameSupportedDefined By
HostOAS2,OAS3
BasePathOAS2,OAS3
InfoOAS2,OAS3
SchemesOAS2,OAS3
PartialSchemesOAS2,OAS3
ConsumesOAS2
ProducesOAS2
ExternalDocumentationOAS2,OAS3
ExamplesOAS2,OAS3
XMLStructureDefinitionsOAS2,OAS3
MultiServerOAS3
ParameterizedServerOAS3
ParameterStylingOAS3
CallbacksOAS3
LinkObjectsOAS3

Parameter Feature

NameSupportedDefined By
PathOAS2,OAS3
QueryOAS2,OAS3
HeaderOAS2,OAS3
BodyOAS2
FormUnencodedOAS2
FormMultipartOAS2
CookieOAS3

Schema Support Feature

NameSupportedDefined By
SimpleOAS2,OAS3
CompositeOAS2,OAS3
PolymorphismOAS2,OAS3
UnionOAS3
allOfOAS2,OAS3
anyOfOAS3
oneOfOAS3
notOAS3

Security Feature

NameSupportedDefined By
BasicAuthOAS2,OAS3
ApiKeyOAS2,OAS3
OpenIDConnectOAS3
BearerTokenOAS3
OAuth2_ImplicitOAS2,OAS3
OAuth2_PasswordOAS2,OAS3
OAuth2_ClientCredentialsOAS2,OAS3
OAuth2_AuthorizationCodeOAS2,OAS3
SignatureAuthOAS3
AWSV4SignatureToolingExtension

Wire Format Feature

NameSupportedDefined By
JSONOAS2,OAS3
XMLOAS2,OAS3
PROTOBUFToolingExtension
CustomOAS2,OAS3