diff --git a/docs/templating.md b/docs/templating.md index 6de1780d1715..d640142aa1e5 100644 --- a/docs/templating.md +++ b/docs/templating.md @@ -26,6 +26,31 @@ OpenAPI Generator supports user-defined templates. This approach is often the ea > **Note:** You cannot use this approach to create new templates, only override existing ones. If you'd like to create a new generator to contribute back to the project, see `new.sh` in the repository root. If you'd like to create a private generator for more templating control, see the [customization](./customization.md) docs. +### Raw values and source-literal helpers + +Specification text is data and must be encoded at its destination. The +`spring` and `kotlin-spring` generators expose additive Mustache helpers: + +* `javaStringLiteral` and `kotlinStringLiteral` accept raw contents and emit a + complete quoted literal. Do not add another pair of quotes. +* `javaStringContent` and `kotlinStringContent` emit escaped contents for a + template-owned literal. +* `javaDocText` and `kotlinDocText` emit literal documentation text: they + HTML-escape text, protect comment delimiters (including Java Unicode-escape + preprocessing), and preserve line breaks. + +Use triple-brace values inside these helpers so Mustache HTML escaping does not +run before source escaping: + +```mustache +description = {{#lambda.kotlinStringLiteral}}{{{unescapedNotes}}}{{/lambda.kotlinStringLiteral}} +``` + +These helpers are scoped to the Spring generators and their supported +libraries. Keep raw specification fields separate from generated expressions, +identifiers, and intentional vendor-extension code. Other generators, +including Java `okhttp-gson`, are not covered by this contract. + OpenAPI Generator not only supports local files for templating, but also templates defined on the classpath. This is a great option if you want to reuse templates across multiple projects. To load a template via classpath, you'll need to generate a little differently. For example, if you've created an artifact called `template-classpath-example` which contains extended templates for the `htmlDocs` generator with the following structure: ``` diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java index 47e09ea292d4..80f3a2c11f61 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenOperation.java @@ -32,8 +32,8 @@ public class CodegenOperation { isDeprecated, isCallbackRequest, uniqueItems, hasErrorResponseObject; // if 4xx, 5xx responses have at least one error object defined public CodegenProperty returnProperty; - public String path, operationId, returnType, returnFormat, httpMethod, returnBaseType, - returnContainer, summary, unescapedNotes, notes, baseName, defaultResponse; + public String path, unescapedPath, operationId, returnType, returnFormat, httpMethod, returnBaseType, + returnContainer, summary, unescapedSummary, unescapedNotes, notes, baseName, defaultResponse; public CodegenDiscriminator discriminator; public List> consumes, produces, prioritizedContentTypes; public List servers = new ArrayList(); diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenParameter.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenParameter.java index 90c4c66558c0..0610354c7ba5 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenParameter.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenParameter.java @@ -17,6 +17,7 @@ package org.openapitools.codegen; +import com.fasterxml.jackson.databind.JsonNode; import io.swagger.v3.oas.models.examples.Example; import lombok.Getter; import lombok.Setter; @@ -35,6 +36,10 @@ public class CodegenParameter implements IJsonSchemaValidationProperties { isFormStyle, isSpaceDelimited, isPipeDelimited; public String baseName, paramName, dataType, datatypeWithEnum, dataFormat, contentType, collectionFormat, description, unescapedDescription, baseType, defaultValue, enumDefaultValue, enumName, style; + /** Typed snapshot of the schema default captured before language conversion. */ + public JsonNode rawDefaultValue; + public String rawDefaultValueText; + public boolean hasDefaultValue; public String nameInLowerCase; // property name in lower case public String nameInCamelCase; // property name in camel case (e.g. modifiedDate) @@ -182,6 +187,9 @@ public CodegenParameter copy() { output.multipleOf = this.multipleOf; output.jsonSchema = this.jsonSchema; output.defaultValue = this.defaultValue; + output.rawDefaultValue = this.rawDefaultValue; + output.rawDefaultValueText = this.rawDefaultValueText; + output.hasDefaultValue = this.hasDefaultValue; output.enumDefaultValue = this.enumDefaultValue; output.example = this.example; output.examples = this.examples; @@ -290,7 +298,8 @@ public int hashCode() { isBodyParam, isContainer, isCollectionFormatMulti, isPrimitiveType, isModel, isExplode, baseName, paramName, dataType, datatypeWithEnum, dataFormat, collectionFormat, description, unescapedDescription, baseType, containerType, containerTypeMapped, defaultValue, - enumDefaultValue, enumName, style, isDeepObject, isMatrix, isAllowEmptyValue, example, examples, + rawDefaultValue, rawDefaultValueText, hasDefaultValue, enumDefaultValue, enumName, style, + isDeepObject, isMatrix, isAllowEmptyValue, example, examples, isFormStyle, isSpaceDelimited, isPipeDelimited, jsonSchema, isString, isNumeric, isInteger, isLong, isNumber, isFloat, isDouble, isDecimal, isByteArray, isBinary, isBoolean, isDate, isDateTime, isUuid, isUri, isEmail, isPassword, @@ -382,6 +391,9 @@ public boolean equals(Object o) { Objects.equals(containerType, that.containerType) && Objects.equals(containerTypeMapped, that.containerTypeMapped) && Objects.equals(defaultValue, that.defaultValue) && + Objects.equals(rawDefaultValue, that.rawDefaultValue) && + Objects.equals(rawDefaultValueText, that.rawDefaultValueText) && + hasDefaultValue == that.hasDefaultValue && Objects.equals(enumDefaultValue, that.enumDefaultValue) && Objects.equals(enumName, that.enumName) && Objects.equals(style, that.style) && @@ -1151,4 +1163,3 @@ public void setIsEnum(boolean isEnum) { this.isEnum = isEnum; } } - diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenProperty.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenProperty.java index c854389be7b2..9e478a8e971c 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenProperty.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenProperty.java @@ -17,6 +17,7 @@ package org.openapitools.codegen; +import com.fasterxml.jackson.databind.JsonNode; import lombok.Getter; import lombok.Setter; @@ -61,6 +62,10 @@ public class CodegenProperty implements Cloneable, IJsonSchemaValidationProperti public String max; // TODO: is this really used? @Getter @Setter public String defaultValue; + /** Typed snapshot of the schema default captured before language conversion. */ + public JsonNode rawDefaultValue; + public String rawDefaultValueText; + public boolean hasDefaultValue; @Getter @Setter public String defaultValueWithParam; @Setter public String baseType; @@ -98,6 +103,8 @@ public class CodegenProperty implements Cloneable, IJsonSchemaValidationProperti */ @Getter @Setter public String example; + /** Original schema example before language-specific escaping. */ + public String rawExample; @Getter @Setter public String jsonSchema; @@ -986,6 +993,9 @@ public String toString() { sb.append(", min='").append(min).append('\''); sb.append(", max='").append(max).append('\''); sb.append(", defaultValue='").append(defaultValue).append('\''); + sb.append(", rawDefaultValue=").append(rawDefaultValue); + sb.append(", rawDefaultValueText='").append(rawDefaultValueText).append('\''); + sb.append(", hasDefaultValue=").append(hasDefaultValue); sb.append(", defaultValueWithParam='").append(defaultValueWithParam).append('\''); sb.append(", baseType='").append(baseType).append('\''); sb.append(", containerType='").append(containerType).append('\''); @@ -996,6 +1006,7 @@ public String toString() { sb.append(", minLength=").append(minLength); sb.append(", pattern='").append(pattern).append('\''); sb.append(", example='").append(example).append('\''); + sb.append(", rawExample='").append(rawExample).append('\''); sb.append(", jsonSchema='").append(jsonSchema).append('\''); sb.append(", minimum='").append(minimum).append('\''); sb.append(", maximum='").append(maximum).append('\''); @@ -1173,6 +1184,9 @@ public boolean equals(Object o) { Objects.equals(min, that.min) && Objects.equals(max, that.max) && Objects.equals(defaultValue, that.defaultValue) && + Objects.equals(rawDefaultValue, that.rawDefaultValue) && + Objects.equals(rawDefaultValueText, that.rawDefaultValueText) && + hasDefaultValue == that.hasDefaultValue && Objects.equals(defaultValueWithParam, that.defaultValueWithParam) && Objects.equals(baseType, that.baseType) && Objects.equals(containerType, that.containerType) && @@ -1183,6 +1197,7 @@ public boolean equals(Object o) { Objects.equals(minLength, that.minLength) && Objects.equals(pattern, that.pattern) && Objects.equals(example, that.example) && + Objects.equals(rawExample, that.rawExample) && Objects.equals(jsonSchema, that.jsonSchema) && Objects.equals(minimum, that.minimum) && Objects.equals(maximum, that.maximum) && @@ -1212,8 +1227,9 @@ public int hashCode() { return Objects.hash(openApiType, baseName, complexType, getter, setter, description, dataType, datatypeWithEnum, dataFormat, name, min, max, defaultValue, - defaultValueWithParam, baseType, containerType, containerTypeMapped, title, unescapedDescription, - maxLength, minLength, pattern, example, jsonSchema, minimum, maximum, + rawDefaultValue, rawDefaultValueText, hasDefaultValue, defaultValueWithParam, baseType, + containerType, containerTypeMapped, title, unescapedDescription, + maxLength, minLength, pattern, example, rawExample, jsonSchema, minimum, maximum, exclusiveMinimum, exclusiveMaximum, required, deprecated, isPrimitiveType, isModel, isContainer, isString, isNumeric, isInteger, isLong, isNumber, isFloat, isDouble, isDecimal, isByteArray, isBinary, isFile, diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenResponse.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenResponse.java index 3298d80868f2..58163f75baf5 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenResponse.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/CodegenResponse.java @@ -33,6 +33,8 @@ public class CodegenResponse implements IJsonSchemaValidationProperties { public boolean is4xx; public boolean is5xx; public String message; + /** Original response description before generator escaping. */ + public String unescapedMessage; public List> examples; public String dataType; public String baseType; @@ -109,7 +111,7 @@ public class CodegenResponse implements IJsonSchemaValidationProperties { @Override public int hashCode() { - return Objects.hash(headers, code, message, examples, dataType, baseType, containerType, containerTypeMapped, hasHeaders, + return Objects.hash(headers, code, message, unescapedMessage, examples, dataType, baseType, containerType, containerTypeMapped, hasHeaders, isString, isNumeric, isInteger, isLong, isNumber, isFloat, isDouble, isDecimal, isByteArray, isBoolean, isDate, isDateTime, isUuid, isEmail, isPassword, isModel, isFreeFormObject, isAnyType, isDefault, simpleType, primitiveType, isMap, isOptional, isArray, isBinary, isFile, schema, jsonSchema, vendorExtensions, items, additionalProperties, @@ -182,6 +184,7 @@ public boolean equals(Object o) { Objects.equals(headers, that.headers) && Objects.equals(code, that.code) && Objects.equals(message, that.message) && + Objects.equals(unescapedMessage, that.unescapedMessage) && Objects.equals(examples, that.examples) && Objects.equals(dataType, that.dataType) && Objects.equals(baseType, that.baseType) && diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java index ddae177f7b85..5e8afd668c0c 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java @@ -17,6 +17,7 @@ package org.openapitools.codegen; +import com.fasterxml.jackson.databind.JsonNode; import com.github.benmanes.caffeine.cache.Cache; import com.github.benmanes.caffeine.cache.Caffeine; import com.github.benmanes.caffeine.cache.Ticker; @@ -4230,6 +4231,7 @@ public CodegenProperty fromProperty(String name, Schema p, boolean required, boo // unalias schema p = unaliasSchema(p); + Object referencedDefault = p.getDefault(); property.setSchemaIsFromAdditionalProperties(schemaIsFromAdditionalProperties); property.required = required; @@ -4249,6 +4251,7 @@ public CodegenProperty fromProperty(String name, Schema p, boolean required, boo property.nameInSnakeCase = CaseFormat.UPPER_CAMEL.to(CaseFormat.UPPER_UNDERSCORE, property.nameInPascalCase); property.description = escapeText(p.getDescription()); property.unescapedDescription = p.getDescription(); + property.rawExample = p.getExample() == null ? null : String.valueOf(p.getExample()); property.title = p.getTitle(); property.getter = toGetter(name); property.setter = toSetter(name); @@ -4482,9 +4485,15 @@ public CodegenProperty fromProperty(String name, Schema p, boolean required, boo // instead of falling back to the literal "null". if (original.getExample() != null) { property.example = toExampleValue(original); + property.rawExample = String.valueOf(original.getExample()); } } + Object effectiveDefault = p.getDefault() != null ? p.getDefault() : referencedDefault; + property.hasDefaultValue = effectiveDefault != null; + property.rawDefaultValue = snapshotDefaultValue(effectiveDefault); + property.rawDefaultValueText = rawDefaultValueText(effectiveDefault); + // override defaultValue if it's not set and defaultToEmptyContainer is set if (p.getDefault() == null && defaultToEmptyContainer) { updateDefaultToEmptyContainer(property, p); @@ -4926,8 +4935,10 @@ public CodegenOperation fromOperation(String path, op.path = path; } // remove backslash from path, e.g. /api/v2/GetPetById\\(\\) => /api/v2/GetPetById() + op.unescapedPath = op.path; op.path = op.path.replace("\\", ""); + op.unescapedSummary = operation.getSummary(); op.summary = escapeText(operation.getSummary()); op.unescapedNotes = operation.getDescription(); op.notes = escapeText(operation.getDescription()); @@ -5096,6 +5107,7 @@ public CodegenOperation fromOperation(String path, if (bodyParam != null) { bodyParam.description = escapeText(requestBody.getDescription()); + bodyParam.unescapedDescription = requestBody.getDescription(); postProcessParameter(bodyParam); bodyParams.add(bodyParam); if (prependFormOrBodyParameters) { @@ -5297,6 +5309,7 @@ public CodegenResponse fromResponse(String responseCode, ApiResponse response) { responseSchema = ModelUtils.getSchemaFromResponse(openAPI, response); } r.schema = responseSchema; + r.unescapedMessage = response.getDescription(); r.message = escapeText(response.getDescription()); // adding examples to API responses @@ -5762,6 +5775,12 @@ public CodegenParameter fromParameter(Parameter parameter, Set imports) if (codegenProperty.isModel) { codegenParameter.isModel = true; } + if (codegenProperty.isString && !codegenParameter.isByteArray && !codegenParameter.isBinary + && !codegenParameter.isDate && !codegenParameter.isDateTime && !codegenParameter.isDecimal + && !codegenParameter.isUuid && !codegenParameter.isUri && !codegenParameter.isEmail + && !codegenParameter.isPassword) { + codegenParameter.isString = true; + } if (parameterModelName != null) { codegenParameter.dataType = parameterModelName; @@ -5858,11 +5877,38 @@ public CodegenParameter fromParameter(Parameter parameter, Set imports) // set default value codegenParameter.defaultValue = toDefaultParameterValue(codegenProperty, parameterSchema); - + codegenParameter.hasDefaultValue = codegenProperty != null && codegenProperty.hasDefaultValue; + codegenParameter.rawDefaultValue = codegenProperty == null ? null : codegenProperty.rawDefaultValue; + codegenParameter.rawDefaultValueText = codegenProperty == null ? null : codegenProperty.rawDefaultValueText; + // swagger-parser materializes date defaults as Date, losing the lexical + // OpenAPI value. Preserve the same date form emitted for parameter binding. + if (codegenParameter.isDate && codegenParameter.rawDefaultValue != null + && codegenParameter.defaultValue != null) { + codegenParameter.rawDefaultValueText = codegenParameter.defaultValue; + } finishUpdatingParameter(codegenParameter, parameter); return codegenParameter; } + private JsonNode snapshotDefaultValue(Object value) { + if (value == null) { + return null; + } + try { + return Json.mapper().valueToTree(value); + } catch (RuntimeException e) { + return null; + } + } + + private String rawDefaultValueText(Object value) { + if (value == null) { + return null; + } + JsonNode node = snapshotDefaultValue(value); + return node != null && node.isTextual() ? node.textValue() : String.valueOf(value); + } + private Schema getReferencedSchemaWhenNotEnum(Schema parameterSchema) { Schema referencedSchema = ModelUtils.getReferencedSchema(openAPI, parameterSchema); if (referencedSchema.getEnum() != null && !referencedSchema.getEnum().isEmpty()) { @@ -7193,7 +7239,9 @@ protected List buildEnumVars(List values, String dataType) { final String finalEnumName = toEnumVarName(enumName, dataType); - enumVar.enumVar(finalEnumName, toEnumValue(String.valueOf(value), dataType), isDataTypeString(dataType)); + String rawEnumValue = String.valueOf(value); + enumVar.enumVar(finalEnumName, toEnumValue(rawEnumValue, dataType), isDataTypeString(dataType)); + enumVar.setEnumValueRaw(rawEnumValue); // TODO: add isNumeric enumVars.add(enumVar); } @@ -7227,6 +7275,7 @@ private void injectEnumUnknownDefaultCase(List enumVars, String data String.valueOf(11184809); enumVar.enumVar(toEnumVarName(enumName, dataType), toEnumValue(enumValue, dataType), isDataTypeString(dataType)); + enumVar.setEnumValueRaw(enumValue); // TODO: add isNumeric enumVars.add(enumVar); } @@ -7555,6 +7604,7 @@ private void setOauth2Info(CodegenSecurity codegenSecurity, OAuthFlow flow) { Map scope = new HashMap<>(); scope.put("scope", scopeEntry.getKey()); scope.put("description", escapeText(scopeEntry.getValue())); + scope.put("descriptionRaw", scopeEntry.getValue()); scopes.add(scope); } codegenSecurity.scopes = scopes; @@ -7831,6 +7881,9 @@ public CodegenParameter fromFormProperty(String name, Schema propertySchema, Set // set default value codegenParameter.defaultValue = toDefaultParameterValue(codegenProperty, propertySchema); + codegenParameter.hasDefaultValue = codegenProperty != null && codegenProperty.hasDefaultValue; + codegenParameter.rawDefaultValue = codegenProperty == null ? null : codegenProperty.rawDefaultValue; + codegenParameter.rawDefaultValueText = codegenProperty == null ? null : codegenProperty.rawDefaultValueText; if (ModelUtils.isFileSchema(ps) && !ModelUtils.isStringSchema(ps)) { // swagger v2 only, type file @@ -7951,7 +8004,7 @@ public CodegenParameter fromFormProperty(String name, Schema propertySchema, Set codegenParameter.isFormParam = Boolean.TRUE; codegenParameter.description = escapeText(codegenProperty.description); - codegenParameter.unescapedDescription = codegenProperty.getDescription(); + codegenParameter.unescapedDescription = codegenProperty.unescapedDescription; codegenParameter.jsonSchema = Json.pretty(propertySchema); codegenParameter.containerType = codegenProperty.containerType; codegenParameter.containerTypeMapped = codegenProperty.containerTypeMapped; @@ -7981,7 +8034,6 @@ public CodegenParameter fromFormProperty(String name, Schema propertySchema, Set // set nullable setParameterNullable(codegenParameter, codegenProperty); - return codegenParameter; } @@ -8377,6 +8429,7 @@ public CodegenParameter fromRequestBody(RequestBody body, Set imports, S codegenParameter.baseName = "UNKNOWN_BASE_NAME"; codegenParameter.paramName = "UNKNOWN_PARAM_NAME"; codegenParameter.description = escapeText(body.getDescription()); + codegenParameter.unescapedDescription = body.getDescription(); codegenParameter.required = body.getRequired() != null ? body.getRequired() : Boolean.FALSE; codegenParameter.isBodyParam = Boolean.TRUE; if (body.getExtensions() != null) { diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultGenerator.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultGenerator.java index b750ee2167bb..4d939e1ba7ee 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultGenerator.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultGenerator.java @@ -86,6 +86,7 @@ public class DefaultGenerator implements Generator { private String basePath; private String basePathWithoutHost; private String contextPath; + private String contextPathRaw; private final Map generatorPropertyDefaults = new HashMap<>(); /** * Retrieves an instance to the configured template processor, available after user-defined options are @@ -299,6 +300,7 @@ void configureGeneratorProperties() { // TODO: Allow user to define _which_ servers object in the array to target. // Configures contextPath/basePath according to api document's servers URL url = URLPathUtils.getServerURL(openAPI, config.serverVariableOverrides()); + contextPathRaw = removeTrailingSlash(url.getPath()); contextPath = removeTrailingSlash(config.escapeText(url.getPath())); // for backward compatibility basePathWithoutHost = contextPath; if (URLPathUtils.isRelativeUrl(openAPI.getServers())) { @@ -315,12 +317,15 @@ private void configureOpenAPIInfo() { } if (info.getTitle() != null) { config.additionalProperties().put("appName", config.escapeText(info.getTitle())); + config.additionalProperties().put("appNameRaw", info.getTitle()); } if (info.getVersion() != null) { config.additionalProperties().put("appVersion", config.escapeText(info.getVersion())); + config.additionalProperties().put("appVersionRaw", info.getVersion()); } else { LOGGER.error("Missing required field info version. Default appVersion set to 1.0.0"); config.additionalProperties().put("appVersion", "1.0.0"); + config.additionalProperties().put("appVersionRaw", "1.0.0"); } if (StringUtils.isEmpty(info.getDescription())) { @@ -345,12 +350,15 @@ private void configureOpenAPIInfo() { Contact contact = info.getContact(); if (contact.getEmail() != null) { config.additionalProperties().put("infoEmail", config.escapeText(contact.getEmail())); + config.additionalProperties().put("infoEmailRaw", contact.getEmail()); } if (contact.getName() != null) { config.additionalProperties().put("infoName", config.escapeText(contact.getName())); + config.additionalProperties().put("infoNameRaw", contact.getName()); } if (contact.getUrl() != null) { config.additionalProperties().put("infoUrl", config.escapeText(contact.getUrl())); + config.additionalProperties().put("infoUrlRaw", contact.getUrl()); } } @@ -358,9 +366,11 @@ private void configureOpenAPIInfo() { License license = info.getLicense(); if (license.getName() != null) { config.additionalProperties().put("licenseInfo", config.escapeText(license.getName())); + config.additionalProperties().put("licenseInfoRaw", license.getName()); } if (license.getUrl() != null) { config.additionalProperties().put("licenseUrl", config.escapeText(license.getUrl())); + config.additionalProperties().put("licenseUrlRaw", license.getUrl()); } } @@ -373,6 +383,7 @@ private void configureOpenAPIInfo() { if (info.getTermsOfService() != null) { config.additionalProperties().put("termsOfService", config.escapeText(info.getTermsOfService())); + config.additionalProperties().put("termsOfServiceRaw", info.getTermsOfService()); } } @@ -708,6 +719,7 @@ void generateApis(List files, List allOperations, List files, List allWebhooks, List buildSupportFileBundle(List allOperations, Li bundle.put("port", url.getPort()); } bundle.put("contextPath", contextPath); + bundle.put("contextPathRaw", contextPathRaw); bundle.put("apiInfo", apis); bundle.put("webhooks", allWebhooks); bundle.put("models", allModels); diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java index 12047a88e12f..e4335b91913d 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/KotlinSpringServerCodegen.java @@ -22,6 +22,7 @@ import com.samskivert.mustache.Template; import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.Operation; +import io.swagger.v3.oas.models.media.Schema; import lombok.Getter; import lombok.Setter; import org.openapitools.codegen.*; @@ -33,6 +34,7 @@ import org.openapitools.codegen.model.ModelsMap; import org.openapitools.codegen.model.OperationMap; import org.openapitools.codegen.model.OperationsMap; +import org.openapitools.codegen.templating.SourceStringEscaper; import org.openapitools.codegen.templating.mustache.SpringHttpStatusLambda; import org.openapitools.codegen.utils.JsonAnnotationPolicyUtils; import org.openapitools.codegen.utils.JsonIncludePolicy; @@ -1061,7 +1063,38 @@ public void processOpts() { @Override protected ImmutableMap.Builder addMustacheLambdas() { return super.addMustacheLambdas() - .put("escapeDoubleQuote", new EscapeLambda("\"", "\\\"")); + .put("escapeDoubleQuote", new EscapeLambda("\"", "\\\"")) + .put("kotlinStringLiteral", (fragment, writer) -> writer.write(SourceStringEscaper.kotlinStringLiteral(fragment.execute()))) + .put("kotlinStringContent", (fragment, writer) -> writer.write(SourceStringEscaper.kotlinStringContent(fragment.execute()))) + .put("kotlinDocText", (fragment, writer) -> writer.write(SourceStringEscaper.docText(fragment.execute()))); + } + + @Override + public String toDefaultValue(CodegenProperty property, Schema schema) { + String value = super.toDefaultValue(property, schema); + Schema resolved = ModelUtils.getReferencedSchema(openAPI, schema); + if (resolved != null && ModelUtils.isURISchema(resolved) + && resolved.getDefault() instanceof String) { + return "URI.create(" + SourceStringEscaper.kotlinStringLiteral((String) resolved.getDefault()) + ")"; + } + if (resolved != null && ModelUtils.isStringSchema(resolved) + && !ModelUtils.isURISchema(resolved) + && (resolved.getEnum() == null || resolved.getEnum().isEmpty()) + && resolved.getDefault() instanceof String) { + return SourceStringEscaper.kotlinStringLiteral((String) resolved.getDefault()); + } + return value; + } + + @Override + public CodegenParameter fromFormProperty(String name, Schema propertySchema, Set imports) { + CodegenParameter parameter = super.fromFormProperty(name, propertySchema, imports); + if (parameter.hasDefaultValue) { + parameter.vendorExtensions.put("x-spring-form-default-not-applied", true); + LOGGER.warn("OpenAPI default for form parameter '{}' is not applied when the field is omitted; " + + "the generated Spring binding does not apply it.", parameter.baseName); + } + return parameter; } @Override diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/SpringCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/SpringCodegen.java index 4d8b7f462fcc..957807134a9b 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/SpringCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/SpringCodegen.java @@ -17,7 +17,9 @@ package org.openapitools.codegen.languages; +import com.google.common.collect.ImmutableMap; import com.samskivert.mustache.Mustache; +import com.samskivert.mustache.Mustache.Lambda; import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.Operation; import io.swagger.v3.oas.models.PathItem; @@ -39,6 +41,7 @@ import org.openapitools.codegen.model.ModelsMap; import org.openapitools.codegen.model.OperationMap; import org.openapitools.codegen.model.OperationsMap; +import org.openapitools.codegen.templating.SourceStringEscaper; import org.openapitools.codegen.templating.mustache.SplitStringLambda; import org.openapitools.codegen.templating.mustache.SpringHttpStatusLambda; import org.openapitools.codegen.templating.mustache.TrimWhitespaceLambda; @@ -221,6 +224,8 @@ public enum RequestMappingMode { // Holds scan results for Spring Pageable features (populated during preprocessOpenAPI) private final SpringPageableScanUtils pageableUtils = new SpringPageableScanUtils(); + // Preserves all operation tags for generated annotations without mutating the parsed OpenAPI model. + private final Map>> operationTagValues = new IdentityHashMap<>(); public SpringCodegen() { super(); @@ -871,7 +876,6 @@ public void processOpts() { .write(fragment.execute().replaceAll("\"", Matcher.quoteReplacement("\\\"")))); additionalProperties.put("lambdaRemoveLineBreak", (Mustache.Lambda) (fragment, writer) -> writer.write(fragment.execute().replaceAll("\\r|\\n", ""))); - additionalProperties.put("lambdaTrimWhitespace", new TrimWhitespaceLambda()); additionalProperties.put("lambdaSplitString", new SplitStringLambda()); @@ -887,6 +891,15 @@ public void processOpts() { if (useJspecify) { applyJspecify(); } + + } + + @Override + protected ImmutableMap.Builder addMustacheLambdas() { + return super.addMustacheLambdas() + .put("javaStringLiteral", (fragment, writer) -> writer.write(SourceStringEscaper.javaStringLiteral(fragment.execute()))) + .put("javaStringContent", (fragment, writer) -> writer.write(SourceStringEscaper.javaStringContent(fragment.execute()))) + .put("javaDocText", (fragment, writer) -> writer.write(SourceStringEscaper.docText(fragment.execute()))); } protected void applyJackson2Package() { @@ -939,6 +952,7 @@ public void addOperationToGroup(String tag, String resourcePath, Operation opera @Override public void preprocessOpenAPI(OpenAPI openAPI) { + operationTagValues.clear(); super.preprocessOpenAPI(openAPI); if (SPRING_BOOT.equals(library) && ModelUtils.containsEnums(this.openAPI)) { @@ -1032,16 +1046,21 @@ public void preprocessOpenAPI(OpenAPI openAPI) { for (final Operation operation : path.readOperations()) { if (operation.getTags() != null) { final List> tags = new ArrayList<>(); + final List> publicTags = new ArrayList<>(); for (final String tag : operation.getTags()) { final Map value = new HashMap<>(); - value.put("tag", escapeText(tag)); + String escapedTag = escapeText(tag); + value.put("tag", escapedTag); + value.put("tagRaw", tag); tags.add(value); + publicTags.add(Collections.singletonMap("tag", escapedTag)); } if (!operation.getTags().isEmpty()) { final String tag = operation.getTags().get(0); operation.setTags(Collections.singletonList(tag)); } - operation.addExtension("x-tags", tags); + operation.addExtension("x-tags", publicTags); + operationTagValues.put(operation, tags); } } } @@ -1118,8 +1137,12 @@ public void setIsVoid(boolean isVoid) { final Tag firstTag = firstOperation.tags.get(0); final String firstTagName = firstTag.getName(); // But use a sensible tag name if there is none - objs.put("tagName", escapeText("default".equals(firstTagName) ? firstOperation.baseName : firstTagName)); + String effectiveTagName = "default".equals(firstTagName) ? firstOperation.baseName : firstTagName; + objs.put("tagName", escapeText(effectiveTagName)); + objs.put("tagNameRaw", effectiveTagName); objs.put("tagDescription", escapeText(firstTag.getDescription())); + objs.put("tagDescriptionRaw", firstTag.getDescription()); + objs.put("hasTagDescription", firstTag.getDescription() != null); // Add clientRegistrationId for spring-http-interface with OAuth if (SPRING_HTTP_INTERFACE.equals(library) && clientRegistrationId != null && !clientRegistrationId.isEmpty()) { @@ -1132,6 +1155,34 @@ public void setIsVoid(boolean isVoid) { return objs; } + @Override + public String toDefaultValue(CodegenProperty property, Schema schema) { + String value = super.toDefaultValue(property, schema); + Schema resolved = ModelUtils.getReferencedSchema(openAPI, schema); + if (resolved != null && ModelUtils.isStringSchema(resolved) + && !ModelUtils.isURISchema(resolved) + && !ModelUtils.isDateSchema(resolved) + && !ModelUtils.isDateTimeSchema(resolved) + && !ModelUtils.isTimeLocalSchema(resolved) + && !ModelUtils.isDateTimeLocalSchema(resolved) + && (resolved.getEnum() == null || resolved.getEnum().isEmpty()) + && resolved.getDefault() instanceof String) { + return SourceStringEscaper.javaStringLiteral((String) resolved.getDefault()); + } + return value; + } + + @Override + public CodegenParameter fromFormProperty(String name, Schema propertySchema, Set imports) { + CodegenParameter parameter = super.fromFormProperty(name, propertySchema, imports); + if (parameter.hasDefaultValue) { + parameter.vendorExtensions.put("x-spring-form-default-not-applied", true); + LOGGER.warn("OpenAPI default for form parameter '{}' is not applied when the field is omitted; " + + "the generated Spring binding does not apply it.", parameter.baseName); + } + return parameter; + } + /** * Adds a Spring Security expression that preserves the OpenAPI security requirement semantics: * entries in a {@code security} array are OR alternatives, while schemes and scopes in one @@ -1459,6 +1510,10 @@ public CodegenOperation fromOperation(String path, String httpMethod, Operation Set provideArgsClassSet = reformatProvideArgsParams(operation); CodegenOperation codegenOperation = super.fromOperation(path, httpMethod, operation, servers); + List> tags = operationTagValues.get(operation); + if (tags != null) { + codegenOperation.vendorExtensions.put("x-tags", tags); + } // add org.springframework.format.annotation.DateTimeFormat when needed codegenOperation.allParams.stream().filter(p -> p.isDate || p.isDateTime).findFirst() diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/model/EnumVarMap.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/model/EnumVarMap.java index 40726a647aec..b2ba7dbe1207 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/model/EnumVarMap.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/model/EnumVarMap.java @@ -14,6 +14,8 @@ public class EnumVarMap extends HashMap { public static final String ENUM_NAME = "name"; // The on-the-line value, i.e., the one present in the "values" public static final String ENUM_VALUE = "value"; + // The unescaped enum value from the OpenAPI specification + public static final String ENUM_VALUE_RAW = "valueRaw"; // If the enum is typed as a string public static final String ENUM_IS_STRING = "isString"; // The description that should be attached to an entry in "enumVars" @@ -49,6 +51,10 @@ public void setEnumValue(String value) { put(ENUM_VALUE, value); } + public void setEnumValueRaw(String value) { + put(ENUM_VALUE_RAW, value); + } + public Object getEnumValue() { return get(ENUM_VALUE); } diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/templating/SourceStringEscaper.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/templating/SourceStringEscaper.java new file mode 100644 index 000000000000..6dff54d3622d --- /dev/null +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/templating/SourceStringEscaper.java @@ -0,0 +1,124 @@ +/* + * Copyright 2026 OpenAPI-Generator Contributors (https://openapi-generator.tech) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.openapitools.codegen.templating; + +import java.util.Locale; + +/** + * Encoders for values inserted into generated source. These methods accept + * parsed, unescaped data and return either literal contents or a complete + * source literal. + */ +public final class SourceStringEscaper { + private SourceStringEscaper() { + } + + public static String javaStringLiteral(String input) { + return "\"" + javaStringContent(input) + "\""; + } + + public static String javaStringContent(String input) { + return escape(input, false); + } + + public static String kotlinStringLiteral(String input) { + return "\"" + kotlinStringContent(input) + "\""; + } + + public static String kotlinStringContent(String input) { + return escape(input, true); + } + + /** + * Protect a value rendered inside a Java/Kotlin block comment while + * retaining its literal displayed meaning in standard documentation renderers. + */ + public static String docText(String input) { + if (input == null) { + return ""; + } + return input.stripTrailing() + .replace("&", "&") + .replace("<", "<") + .replace(">", ">") + .replace("\"", """) + .replace("'", "'") + .replace("@", "@") + // Java processes Unicode escapes before recognizing comments. + .replace("\\", "\") + .replace("/*", "/*") + .replace("*/", "*/") + .replace("\r\n", "\n") + .replace("\r", "\n") + .replace("\n", "\n * "); + } + + private static String escape(String input, boolean kotlin) { + if (input == null) { + return ""; + } + + StringBuilder result = new StringBuilder(input.length() + 16); + for (int i = 0; i < input.length(); i++) { + char c = input.charAt(i); + switch (c) { + case '\\': + result.append("\\\\"); + break; + case '"': + result.append("\\\""); + break; + case '$': + if (kotlin) { + result.append("\\$"); + } else { + result.append(c); + } + break; + case '\b': + result.append("\\b"); + break; + case '\t': + result.append("\\t"); + break; + case '\n': + result.append("\\n"); + break; + case '\f': + result.append(kotlin ? "\\u000c" : "\\f"); + break; + case '\r': + result.append("\\r"); + break; + default: + if (c < 0x20) { + if (kotlin) { + result.append(String.format(Locale.ROOT, "\\u%04x", (int) c)); + } else { + result.append("\\0"); + result.append((char) ('0' + ((c >> 3) & 7))); + result.append((char) ('0' + (c & 7))); + } + } else { + result.append(c); + } + break; + } + } + return result.toString(); + } +} diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/utils/ExamplesUtils.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/utils/ExamplesUtils.java index 64e46987af3f..1552888bbc45 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/utils/ExamplesUtils.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/utils/ExamplesUtils.java @@ -120,8 +120,11 @@ public static List> unaliasExamples(OpenAPI openapi, Map{{summary}} Documentation + * {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} + * @see {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} {{/externalDocs}} */ {{#isDeprecated}} @@ -170,28 +170,28 @@ public interface {{classname}} { {{/virtualService}} {{#swagger2AnnotationLibrary}} @Operation( - operationId = "{{{operationId}}}", + operationId = {{#lambda.javaStringLiteral}}{{{operationId}}}{{/lambda.javaStringLiteral}}, {{#summary}} - summary = "{{{.}}}", + summary = {{#lambda.javaStringLiteral}}{{{unescapedSummary}}}{{/lambda.javaStringLiteral}}, {{/summary}} {{#notes}} - description = "{{{.}}}", + description = {{#lambda.javaStringLiteral}}{{{unescapedNotes}}}{{/lambda.javaStringLiteral}}, {{/notes}} {{#isDeprecated}} deprecated = true, {{/isDeprecated}} {{#vendorExtensions.x-tags.size}} - tags = { {{#vendorExtensions.x-tags}}"{{{tag}}}"{{^-last}}, {{/-last}}{{/vendorExtensions.x-tags}} }, + tags = { {{#vendorExtensions.x-tags}}{{#lambda.javaStringLiteral}}{{{tagRaw}}}{{/lambda.javaStringLiteral}}{{^-last}}, {{/-last}}{{/vendorExtensions.x-tags}} }, {{/vendorExtensions.x-tags.size}} responses = { {{#responses}} - @ApiResponse(responseCode = {{#isDefault}}"default"{{/isDefault}}{{^isDefault}}"{{{code}}}"{{/isDefault}}, description = "{{{message}}}"{{#baseType}}, content = { + @ApiResponse(responseCode = {{#isDefault}}{{#lambda.javaStringLiteral}}default{{/lambda.javaStringLiteral}}{{/isDefault}}{{^isDefault}}{{#lambda.javaStringLiteral}}{{{code}}}{{/lambda.javaStringLiteral}}{{/isDefault}}, description = {{#lambda.javaStringLiteral}}{{{unescapedMessage}}}{{/lambda.javaStringLiteral}}{{#baseType}}, content = { {{#produces}} @Content(mediaType = "{{{mediaType}}}", {{#isArray}}array = @ArraySchema({{/isArray}}schema = @Schema(implementation = {{{baseType}}}.class){{#isArray}}){{/isArray}}{{^isJson}}){{^-last}},{{/-last}}{{/isJson}}{{#isJson}}{{^examples.0}}){{^-last}},{{/-last}}{{/examples.0}}{{#examples.0}}, examples = { {{#examples}} @ExampleObject( - name = "{{{exampleName}}}", - value = "{{{exampleValue}}}" + name = {{#lambda.javaStringLiteral}}{{{exampleName}}}{{/lambda.javaStringLiteral}}, + value = {{#lambda.javaStringLiteral}}{{{exampleValueRaw}}}{{/lambda.javaStringLiteral}} ){{^-last}},{{/-last}} {{/examples}} {{#-last}} @@ -206,39 +206,39 @@ public interface {{classname}} { }{{#hasAuthMethods}}, security = { {{#authMethods}} - @SecurityRequirement(name = "{{name}}"{{#scopes.0}}, scopes={ {{#scopes}}"{{scope}}"{{^-last}}, {{/-last}}{{/scopes}} }{{/scopes.0}}){{^-last}},{{/-last}} + @SecurityRequirement(name = {{#lambda.javaStringLiteral}}{{{name}}}{{/lambda.javaStringLiteral}}{{#scopes.0}}, scopes={ {{#scopes}}{{#lambda.javaStringLiteral}}{{{scope}}}{{/lambda.javaStringLiteral}}{{^-last}}, {{/-last}}{{/scopes}} }{{/scopes.0}}){{^-last}},{{/-last}} {{/authMethods}} }{{/hasAuthMethods}}{{#externalDocs}}, - externalDocs = @ExternalDocumentation(description = "{{externalDocs.description}}", url = "{{externalDocs.url}}"){{/externalDocs}} + externalDocs = @ExternalDocumentation(description = {{#lambda.javaStringLiteral}}{{{description}}}{{/lambda.javaStringLiteral}}, url = {{#lambda.javaStringLiteral}}{{{url}}}{{/lambda.javaStringLiteral}}){{/externalDocs}} ) {{/swagger2AnnotationLibrary}} {{#swagger1AnnotationLibrary}} @ApiOperation( {{#vendorExtensions.x-tags.size}} - tags = { {{#vendorExtensions.x-tags}}"{{{tag}}}"{{^-last}}, {{/-last}}{{/vendorExtensions.x-tags}} }, + tags = { {{#vendorExtensions.x-tags}}{{#lambda.javaStringLiteral}}{{{tagRaw}}}{{/lambda.javaStringLiteral}}{{^-last}}, {{/-last}}{{/vendorExtensions.x-tags}} }, {{/vendorExtensions.x-tags.size}} - value = "{{{summary}}}", - nickname = "{{{operationId}}}", - notes = "{{{notes}}}"{{#returnBaseType}}, + value = {{#lambda.javaStringLiteral}}{{{unescapedSummary}}}{{/lambda.javaStringLiteral}}, + nickname = {{#lambda.javaStringLiteral}}{{{operationId}}}{{/lambda.javaStringLiteral}}, + notes = {{#lambda.javaStringLiteral}}{{{unescapedNotes}}}{{/lambda.javaStringLiteral}}{{#returnBaseType}}, response = {{{.}}}.class{{/returnBaseType}}{{#returnContainer}}, responseContainer = "{{{.}}}"{{/returnContainer}}{{#hasAuthMethods}}, authorizations = { {{#authMethods}} {{#scopes.0}} - @Authorization(value = "{{name}}", scopes = { + @Authorization(value = {{#lambda.javaStringLiteral}}{{{name}}}{{/lambda.javaStringLiteral}}, scopes = { {{#scopes}} - @AuthorizationScope(scope = "{{scope}}", description = "{{description}}"){{^-last}},{{/-last}} + @AuthorizationScope(scope = {{#lambda.javaStringLiteral}}{{{scope}}}{{/lambda.javaStringLiteral}}, description = {{#lambda.javaStringLiteral}}{{{description}}}{{/lambda.javaStringLiteral}}){{^-last}},{{/-last}} {{/scopes}} }){{^-last}},{{/-last}} {{/scopes.0}} {{^scopes.0}} - @Authorization(value = "{{name}}"){{^-last}},{{/-last}} + @Authorization(value = {{#lambda.javaStringLiteral}}{{{name}}}{{/lambda.javaStringLiteral}}){{^-last}},{{/-last}} {{/scopes.0}} {{/authMethods}} }{{/hasAuthMethods}} ) @ApiResponses({ {{#responses}} - @ApiResponse(code = {{{code}}}, message = "{{{message}}}"{{#baseType}}, response = {{{.}}}.class{{/baseType}}{{#containerType}}, responseContainer = "{{{.}}}"{{/containerType}}){{^-last}},{{/-last}} + @ApiResponse(code = {{{code}}}, message = {{#lambda.javaStringLiteral}}{{{unescapedMessage}}}{{/lambda.javaStringLiteral}}{{#baseType}}, response = {{{.}}}.class{{/baseType}}{{#containerType}}, responseContainer = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}{{/containerType}}){{^-last}},{{/-last}} {{/responses}} }) {{/swagger1AnnotationLibrary}} diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/apiController.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/apiController.mustache index 7de0ac763bcf..5c5067000888 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/apiController.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/apiController.mustache @@ -98,22 +98,22 @@ public class {{classname}}Controller implements {{classname}} { {{#_api_controller_impl_}} {{#operation}} /** - * {{httpMethod}} {{{path}}}{{#summary}} : {{.}}{{/summary}} - {{#notes}} - * {{.}} - {{/notes}} + * {{httpMethod}} {{#lambda.javaDocText}}{{{unescapedPath}}}{{/lambda.javaDocText}}{{#summary}} : {{#lambda.javaDocText}}{{{unescapedSummary}}}{{/lambda.javaDocText}}{{/summary}} + {{#unescapedNotes}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} + {{/unescapedNotes}} * {{#allParams}} - * @param {{paramName}} {{description}}{{#required}} (required){{/required}}{{^required}} (optional{{#defaultValue}}, default to {{.}}{{/defaultValue}}){{/required}} + * @param {{paramName}} {{#lambda.javaDocText}}{{{unescapedDescription}}}{{/lambda.javaDocText}}{{#required}} (required){{/required}}{{^required}} (optional{{#vendorExtensions.x-spring-form-default-not-applied}}, OpenAPI schema default to {{#lambda.javaDocText}}{{{rawDefaultValueText}}}{{/lambda.javaDocText}}{{/vendorExtensions.x-spring-form-default-not-applied}}{{^vendorExtensions.x-spring-form-default-not-applied}}{{#hasDefaultValue}}, default to {{#lambda.javaDocText}}{{{rawDefaultValueText}}}{{/lambda.javaDocText}}{{/hasDefaultValue}}{{/vendorExtensions.x-spring-form-default-not-applied}}){{/required}} {{/allParams}} - * @return {{#responses}}{{message}} (status code {{code}}){{^-last}} + * @return {{#responses}}{{#lambda.javaDocText}}{{{unescapedMessage}}}{{/lambda.javaDocText}} (status code {{code}}){{^-last}} * or {{/-last}}{{/responses}} {{#isDeprecated}} * @deprecated {{/isDeprecated}} {{#externalDocs}} - * {{description}} - * @see {{summary}} Documentation + * {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} + * @see {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} {{/externalDocs}} * @see {{classname}}#{{operationId}} */ diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/apiDelegate.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/apiDelegate.mustache index 12ed158dedb5..9e3c5288c933 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/apiDelegate.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/apiDelegate.mustache @@ -55,22 +55,22 @@ public interface {{classname}}Delegate { {{#operation}} /** - * {{httpMethod}} {{{path}}}{{#summary}} : {{.}}{{/summary}} - {{#notes}} - * {{.}} - {{/notes}} + * {{httpMethod}} {{#lambda.javaDocText}}{{{unescapedPath}}}{{/lambda.javaDocText}}{{#summary}} : {{#lambda.javaDocText}}{{{unescapedSummary}}}{{/lambda.javaDocText}}{{/summary}} + {{#unescapedNotes}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} + {{/unescapedNotes}} * {{#allParams}} - * @param {{paramName}} {{description}}{{#required}} (required){{/required}}{{^required}} (optional{{#defaultValue}}, default to {{.}}{{/defaultValue}}){{/required}} + * @param {{paramName}} {{#lambda.javaDocText}}{{{unescapedDescription}}}{{/lambda.javaDocText}}{{#required}} (required){{/required}}{{^required}} (optional{{#vendorExtensions.x-spring-form-default-not-applied}}, OpenAPI schema default to {{#lambda.javaDocText}}{{{rawDefaultValueText}}}{{/lambda.javaDocText}}{{/vendorExtensions.x-spring-form-default-not-applied}}{{^vendorExtensions.x-spring-form-default-not-applied}}{{#hasDefaultValue}}, default to {{#lambda.javaDocText}}{{{rawDefaultValueText}}}{{/lambda.javaDocText}}{{/hasDefaultValue}}{{/vendorExtensions.x-spring-form-default-not-applied}}){{/required}} {{/allParams}} - * @return {{#responses}}{{message}} (status code {{code}}){{^-last}} + * @return {{#responses}}{{#lambda.javaDocText}}{{{unescapedMessage}}}{{/lambda.javaDocText}} (status code {{code}}){{^-last}} * or {{/-last}}{{/responses}} {{#isDeprecated}} * @deprecated {{/isDeprecated}} {{#externalDocs}} - * {{description}} - * @see {{summary}} Documentation + * {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} + * @see {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} {{/externalDocs}} * @see {{classname}}#{{operationId}} */ diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/cookieParams.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/cookieParams.mustache index a255b5c7daf2..983085c27139 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/cookieParams.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/cookieParams.mustache @@ -1 +1 @@ -{{#isCookieParam}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{>paramDoc}} @CookieValue(name = "{{baseName}}"{{^required}}, required = false{{/required}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}){{>dateTimeParam}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isCookieParam}} \ No newline at end of file +{{#isCookieParam}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{>paramDoc}} @CookieValue(name = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}{{^required}}, required = false{{/required}}{{#hasDefaultValue}}{{#isString}}{{^isContainer}}, defaultValue = {{#lambda.javaStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.javaStringLiteral}}{{/isContainer}}{{/isString}}{{#isContainer}}, defaultValue = "{{{defaultValue}}}"{{/isContainer}}{{^isString}}{{^isContainer}}, defaultValue = "{{{defaultValue}}}"{{/isContainer}}{{/isString}}{{/hasDefaultValue}}{{^hasDefaultValue}}{{#defaultValue}}, defaultValue = "{{{defaultValue}}}"{{/defaultValue}}{{/hasDefaultValue}}){{>dateTimeParam}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isCookieParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/enumClass.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/enumClass.mustache index f9dab019e42a..c8f3fa2f3f84 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/enumClass.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/enumClass.mustache @@ -1,5 +1,5 @@ /** - * {{^description}}Gets or Sets {{{name}}}{{/description}}{{{description}}}{{#deprecated}} + * {{^description}}Gets or Sets {{{name}}}{{/description}}{{#lambda.javaDocText}}{{{unescapedDescription}}}{{/lambda.javaDocText}}{{#deprecated}} * @deprecated deprecated{{/deprecated}} */ {{>additionalEnumTypeAnnotations}}{{#deprecated}}@Deprecated @@ -9,11 +9,11 @@ {{#enumVars}} {{#enumDescription}} /** - * {{.}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} */ {{/enumDescription}} - @SerializedName({{#isInteger}}"{{/isInteger}}{{#isDouble}}"{{/isDouble}}{{#isLong}}"{{/isLong}}{{#isFloat}}"{{/isFloat}}{{{value}}}{{#isInteger}}"{{/isInteger}}{{#isDouble}}"{{/isDouble}}{{#isLong}}"{{/isLong}}{{#isFloat}}"{{/isFloat}}) - {{{name}}}({{{value}}}){{^-last}}, + @SerializedName({{#lambda.javaStringLiteral}}{{{valueRaw}}}{{/lambda.javaStringLiteral}}) + {{{name}}}({{#isString}}{{#lambda.javaStringLiteral}}{{{valueRaw}}}{{/lambda.javaStringLiteral}}{{/isString}}{{^isString}}{{{value}}}{{/isString}}){{^-last}}, {{/-last}}{{#-last}};{{/-last}} {{/enumVars}} {{/allowableValues}} @@ -23,10 +23,10 @@ {{#enumVars}} {{#enumDescription}} /** - * {{.}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} */ {{/enumDescription}} - {{{name}}}({{{value}}}){{^-last}}, + {{{name}}}({{#isString}}{{#lambda.javaStringLiteral}}{{{valueRaw}}}{{/lambda.javaStringLiteral}}{{/isString}}{{^isString}}{{{value}}}{{/isString}}){{^-last}}, {{/-last}}{{#-last}};{{/-last}} {{/enumVars}} {{/allowableValues}} diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/enumOuterClass.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/enumOuterClass.mustache index 74912b9e0d0f..350cf7c6e25d 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/enumOuterClass.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/enumOuterClass.mustache @@ -4,7 +4,7 @@ import com.fasterxml.jackson.annotation.JsonValue; {{/jackson}} /** - * {{^description}}Gets or Sets {{{name}}}{{/description}}{{{description}}}{{#isDeprecated}} + * {{^description}}Gets or Sets {{{name}}}{{/description}}{{#lambda.javaDocText}}{{{unescapedDescription}}}{{/lambda.javaDocText}}{{#isDeprecated}} * @deprecated deprecated{{/isDeprecated}} */ {{>additionalEnumTypeAnnotations}} @@ -19,21 +19,21 @@ public enum {{{datatypeWithEnum}}}{{^datatypeWithEnum}}{{{classname}}}{{/datatyp {{#allowableValues}}{{#enumVars}} {{#enumDescription}} /** - * {{.}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} */ {{/enumDescription}} - @SerializedName({{#isInteger}}"{{/isInteger}}{{#isDouble}}"{{/isDouble}}{{#isLong}}"{{/isLong}}{{#isFloat}}"{{/isFloat}}{{{value}}}{{#isInteger}}"{{/isInteger}}{{#isDouble}}"{{/isDouble}}{{#isLong}}"{{/isLong}}{{#isFloat}}"{{/isFloat}}) - {{{name}}}({{{value}}}){{^-last}}, + @SerializedName({{#lambda.javaStringLiteral}}{{{valueRaw}}}{{/lambda.javaStringLiteral}}) + {{{name}}}({{#isString}}{{#lambda.javaStringLiteral}}{{{valueRaw}}}{{/lambda.javaStringLiteral}}{{/isString}}{{^isString}}{{{value}}}{{/isString}}){{^-last}}, {{/-last}}{{#-last}};{{/-last}}{{/enumVars}}{{/allowableValues}} {{/gson}} {{^gson}} {{#allowableValues}}{{#enumVars}} {{#enumDescription}} /** - * {{.}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} */ {{/enumDescription}} - {{{name}}}({{{value}}}){{^-last}}, + {{{name}}}({{#isString}}{{#lambda.javaStringLiteral}}{{{valueRaw}}}{{/lambda.javaStringLiteral}}{{/isString}}{{^isString}}{{{value}}}{{/isString}}){{^-last}}, {{/-last}}{{#-last}};{{/-last}}{{/enumVars}}{{/allowableValues}} {{/gson}} diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/formParams.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/formParams.mustache index e71ccf22e28d..9123d316f17f 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/formParams.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/formParams.mustache @@ -1 +1 @@ -{{#isFormParam}}{{^isFile}}{{>paramDoc}}{{#useBeanValidation}} {{>beanValidationBodyParams}}@Valid{{/useBeanValidation}} {{#isModel}}@RequestPart{{/isModel}}{{^isModel}}{{#isArray}}@RequestPart{{/isArray}}{{^isArray}}{{#reactive}}@RequestPart{{/reactive}}{{^reactive}}@RequestParam{{/reactive}}{{/isArray}}{{/isModel}}(value = "{{baseName}}"{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}){{>dateTimeParam}} {{^required}}{{#useOptional}}Optional<{{/useOptional}}{{/required}}{{{dataType}}}{{^required}}{{#useOptional}}>{{/useOptional}}{{/required}} {{paramName}}{{/isFile}}{{#isFile}}{{>paramDoc}} {{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}@RequestPart(value = "{{baseName}}"{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}) {{#reactive}}{{#isArray}}Flux<{{/isArray}}Part{{#isArray}}>{{/isArray}}{{/reactive}}{{^reactive}}{{#isArray}}List<{{/isArray}}MultipartFile{{#isArray}}>{{/isArray}}{{/reactive}} {{paramName}}{{/isFile}}{{/isFormParam}} \ No newline at end of file +{{#isFormParam}}{{^isFile}}{{>paramDoc}}{{#useBeanValidation}} {{>beanValidationBodyParams}}@Valid{{/useBeanValidation}} {{#isModel}}@RequestPart{{/isModel}}{{^isModel}}{{#isArray}}@RequestPart{{/isArray}}{{^isArray}}{{#reactive}}@RequestPart{{/reactive}}{{^reactive}}@RequestParam{{/reactive}}{{/isArray}}{{/isModel}}(value = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}){{>dateTimeParam}} {{^required}}{{#useOptional}}Optional<{{/useOptional}}{{/required}}{{{dataType}}}{{^required}}{{#useOptional}}>{{/useOptional}}{{/required}} {{paramName}}{{/isFile}}{{#isFile}}{{>paramDoc}} {{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}@RequestPart(value = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}) {{#reactive}}{{#isArray}}Flux<{{/isArray}}Part{{#isArray}}>{{/isArray}}{{/reactive}}{{^reactive}}{{#isArray}}List<{{/isArray}}MultipartFile{{#isArray}}>{{/isArray}}{{/reactive}} {{paramName}}{{/isFile}}{{/isFormParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/headerParams.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/headerParams.mustache index 80b1d0a82341..1fddbf90aefb 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/headerParams.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/headerParams.mustache @@ -1 +1 @@ -{{#isHeaderParam}}{{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{>paramDoc}} @RequestHeader(value = "{{baseName}}", required = {{#required}}true{{/required}}{{^required}}false{{/required}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}){{>dateTimeParam}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isHeaderParam}} \ No newline at end of file +{{#isHeaderParam}}{{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{>paramDoc}} @RequestHeader(value = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}, required = {{#required}}true{{/required}}{{^required}}false{{/required}}{{#hasDefaultValue}}{{#isString}}{{^isContainer}}, defaultValue = {{#lambda.javaStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.javaStringLiteral}}{{/isContainer}}{{/isString}}{{#isContainer}}, defaultValue = "{{{defaultValue}}}"{{/isContainer}}{{^isString}}{{^isContainer}}, defaultValue = "{{{defaultValue}}}"{{/isContainer}}{{/isString}}{{/hasDefaultValue}}{{^hasDefaultValue}}{{#defaultValue}}, defaultValue = "{{{defaultValue}}}"{{/defaultValue}}{{/hasDefaultValue}}){{>dateTimeParam}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isHeaderParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/implicitHeader.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/implicitHeader.mustache index 0453940ce574..95841664678e 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/implicitHeader.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/implicitHeader.mustache @@ -1 +1 @@ -{{#isHeaderParam}}@ApiImplicitParam(name = "{{{baseName}}}", value = "{{{description}}}", {{#required}}required = true,{{/required}} dataType = "{{{dataType}}}", paramType = "header"){{/isHeaderParam}} \ No newline at end of file +{{#isHeaderParam}}@ApiImplicitParam(name = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}, value = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}, {{#required}}required = true,{{/required}} dataType = {{#lambda.javaStringLiteral}}{{{dataType}}}{{/lambda.javaStringLiteral}}, paramType = "header"){{/isHeaderParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/jackson_annotations.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/jackson_annotations.mustache index 0668f40785ce..9d183e1e782e 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/jackson_annotations.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/jackson_annotations.mustache @@ -1,7 +1,7 @@ - @JsonProperty("{{baseName}}") + @JsonProperty({{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}) {{#withXml}} - @JacksonXmlProperty(localName = "{{items.xmlName}}{{^items.xmlName}}{{xmlName}}{{^xmlName}}{{baseName}}{{/xmlName}}{{/items.xmlName}}"{{#isXmlAttribute}}, isAttribute = true{{/isXmlAttribute}}{{#xmlNamespace}}, namespace = "{{.}}"{{/xmlNamespace}}) + @JacksonXmlProperty(localName = {{#lambda.javaStringLiteral}}{{#items.xmlName}}{{{items.xmlName}}}{{/items.xmlName}}{{^items.xmlName}}{{#xmlName}}{{{xmlName}}}{{/xmlName}}{{^xmlName}}{{{baseName}}}{{/xmlName}}{{/items.xmlName}}{{/lambda.javaStringLiteral}}{{#isXmlAttribute}}, isAttribute = true{{/isXmlAttribute}}{{#xmlNamespace}}, namespace = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}{{/xmlNamespace}}) {{#isContainer}} - @JacksonXmlElementWrapper({{#isXmlWrapped}}localName = "{{xmlName}}{{^xmlName}}{{baseName}}{{/xmlName}}", {{#xmlNamespace}}namespace = "{{.}}", {{/xmlNamespace}}{{/isXmlWrapped}}useWrapping = {{isXmlWrapped}}) + @JacksonXmlElementWrapper({{#isXmlWrapped}}localName = {{#lambda.javaStringLiteral}}{{#xmlName}}{{{xmlName}}}{{/xmlName}}{{^xmlName}}{{{baseName}}}{{/xmlName}}{{/lambda.javaStringLiteral}}, {{#xmlNamespace}}namespace = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}, {{/xmlNamespace}}{{/isXmlWrapped}}useWrapping = {{isXmlWrapped}}) {{/isContainer}} {{/withXml}} diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/libraries/spring-http-interface/api.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/libraries/spring-http-interface/api.mustache index 48249db662eb..7533b2cda038 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/libraries/spring-http-interface/api.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/libraries/spring-http-interface/api.mustache @@ -48,22 +48,22 @@ public interface {{classname}} { {{#operation}} /** - * {{httpMethod}} {{{path}}}{{#summary}} : {{.}}{{/summary}} - {{#notes}} - * {{.}} - {{/notes}} + * {{httpMethod}} {{#lambda.javaDocText}}{{{unescapedPath}}}{{/lambda.javaDocText}}{{#summary}} : {{#lambda.javaDocText}}{{{unescapedSummary}}}{{/lambda.javaDocText}}{{/summary}} + {{#unescapedNotes}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} + {{/unescapedNotes}} * {{#allParams}} - * @param {{paramName}} {{description}}{{#required}} (required){{/required}}{{^required}} (optional{{#defaultValue}}, default to {{.}}{{/defaultValue}}){{/required}} + * @param {{paramName}} {{#lambda.javaDocText}}{{{unescapedDescription}}}{{/lambda.javaDocText}}{{#required}} (required){{/required}}{{^required}} (optional{{#vendorExtensions.x-spring-form-default-not-applied}}, OpenAPI schema default to {{#lambda.javaDocText}}{{{rawDefaultValueText}}}{{/lambda.javaDocText}}{{/vendorExtensions.x-spring-form-default-not-applied}}{{^vendorExtensions.x-spring-form-default-not-applied}}{{#hasDefaultValue}}, default to {{#lambda.javaDocText}}{{{rawDefaultValueText}}}{{/lambda.javaDocText}}{{/hasDefaultValue}}{{/vendorExtensions.x-spring-form-default-not-applied}}){{/required}} {{/allParams}} - * @return {{#responses}}{{message}} (status code {{code}}){{^-last}} + * @return {{#responses}}{{#lambda.javaDocText}}{{{unescapedMessage}}}{{/lambda.javaDocText}} (status code {{code}}){{^-last}} * or {{/-last}}{{/responses}} {{#isDeprecated}} * @deprecated {{/isDeprecated}} {{#externalDocs}} - * {{description}} - * @see {{summary}} Documentation + * {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} + * @see {{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}} {{/externalDocs}} */ {{#isDeprecated}} @@ -74,7 +74,7 @@ public interface {{classname}} { {{/useResponseEntity}} @HttpExchange( method = "{{{httpMethod}}}", - value = "{{{path}}}", + value = {{#lambda.javaStringLiteral}}{{{path}}}{{/lambda.javaStringLiteral}}, accept = { {{#vendorExtensions.x-accepts}}"{{{.}}}"{{^-last}}, {{/-last}}{{/vendorExtensions.x-accepts}} }{{#vendorExtensions.x-content-type}}, contentType = "{{{vendorExtensions.x-content-type}}}"{{/vendorExtensions.x-content-type}} ) diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/lombokAnnotation.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/lombokAnnotation.mustache index 6b09b602fe2a..f1e68bec02dd 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/lombokAnnotation.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/lombokAnnotation.mustache @@ -21,7 +21,7 @@ {{/required}} {{/useBeanValidation}} {{#swagger2AnnotationLibrary}} - @Schema(name = "{{{baseName}}}"{{#isReadOnly}}, accessMode = Schema.AccessMode.READ_ONLY{{/isReadOnly}}{{#example}}, example = "{{{.}}}"{{/example}}{{#description}}, description = "{{{.}}}"{{/description}}{{#deprecated}}, deprecated = true{{/deprecated}}, requiredMode = {{#required}}Schema.RequiredMode.REQUIRED{{/required}}{{^required}}Schema.RequiredMode.NOT_REQUIRED{{/required}}) + @Schema(name = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}{{#isReadOnly}}, accessMode = Schema.AccessMode.READ_ONLY{{/isReadOnly}}{{#rawExample}}, example = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}{{/rawExample}}{{#description}}, description = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}{{/description}}{{#deprecated}}, deprecated = true{{/deprecated}}, requiredMode = {{#required}}Schema.RequiredMode.REQUIRED{{/required}}{{^required}}Schema.RequiredMode.NOT_REQUIRED{{/required}}) {{/swagger2AnnotationLibrary}} {{#jackson}}{{>jackson_annotations}}{{/jackson}} {{/lombok.Data}} diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/paramDoc.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/paramDoc.mustache index c546f9c4e904..75dcf5b51297 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/paramDoc.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/paramDoc.mustache @@ -1 +1 @@ -{{#swagger2AnnotationLibrary}}@Parameter(name = "{{{baseName}}}"{{#isDeprecated}}, deprecated = true{{/isDeprecated}}, description = "{{{description}}}"{{#required}}, required = true{{/required}}{{#isPathParam}}, in = ParameterIn.PATH{{/isPathParam}}{{#isQueryParam}}, in = ParameterIn.QUERY{{/isQueryParam}}{{#isCookieParam}}, in = ParameterIn.COOKIE{{/isCookieParam}}{{#isHeaderParam}}, in = ParameterIn.HEADER{{/isHeaderParam}}){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}, {{> allowableValues }}{{/allowableValues}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}){{/swagger1AnnotationLibrary}} \ No newline at end of file +{{#swagger2AnnotationLibrary}}@Parameter(name = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}{{#isDeprecated}}, deprecated = true{{/isDeprecated}}, description = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}{{#required}}, required = true{{/required}}{{#isPathParam}}, in = ParameterIn.PATH{{/isPathParam}}{{#isQueryParam}}, in = ParameterIn.QUERY{{/isQueryParam}}{{#isCookieParam}}, in = ParameterIn.COOKIE{{/isCookieParam}}{{#isHeaderParam}}, in = ParameterIn.HEADER{{/isHeaderParam}}){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}, {{> allowableValues }}{{/allowableValues}}{{#hasDefaultValue}}{{#isString}}{{^isEnum}}, defaultValue = {{#lambda.javaStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.javaStringLiteral}}{{/isEnum}}{{/isString}}{{^isString}}{{^isEnum}}, defaultValue = "{{{defaultValue}}}"{{/isEnum}}{{/isString}}{{#isEnum}}, defaultValue = "{{{defaultValue}}}"{{/isEnum}}{{/hasDefaultValue}}){{/swagger1AnnotationLibrary}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/pathParams.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/pathParams.mustache index 5a351829131d..2c023a61ed96 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/pathParams.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/pathParams.mustache @@ -1 +1 @@ -{{#isPathParam}}{{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}{{#useBeanValidation}}{{>beanValidationPathParams}}{{/useBeanValidation}}{{>paramDoc}} @PathVariable("{{baseName}}"){{>dateTimeParam}}{{#isDeprecated}} @Deprecated{{/isDeprecated}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isPathParam}} \ No newline at end of file +{{#isPathParam}}{{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}{{#useBeanValidation}}{{>beanValidationPathParams}}{{/useBeanValidation}}{{>paramDoc}} @PathVariable({{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}){{>dateTimeParam}}{{#isDeprecated}} @Deprecated{{/isDeprecated}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isPathParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/pojo.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/pojo.mustache index 99dc720a635d..df4805a93035 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/pojo.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/pojo.mustache @@ -1,5 +1,5 @@ /** - * {{description}}{{^description}}{{classname}}{{/description}}{{#isDeprecated}} + * {{#lambda.javaDocText}}{{{unescapedDescription}}}{{/lambda.javaDocText}}{{^description}}{{classname}}{{/description}}{{#isDeprecated}} * @deprecated{{/isDeprecated}} */ {{>additionalModelTypeAnnotations}} @@ -9,10 +9,10 @@ {{/isDeprecated}} {{#description}} {{#swagger1AnnotationLibrary}} -@ApiModel(description = "{{{description}}}") +@ApiModel(description = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}) {{/swagger1AnnotationLibrary}} {{#swagger2AnnotationLibrary}} -@Schema({{#name}}name = "{{name}}", {{/name}}description = "{{{description}}}"{{#deprecated}}, deprecated = true{{/deprecated}}) +@Schema({{#name}}name = {{#lambda.javaStringLiteral}}{{{name}}}{{/lambda.javaStringLiteral}}, {{/name}}description = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}{{#deprecated}}, deprecated = true{{/deprecated}}) {{/swagger2AnnotationLibrary}} {{/description}} {{#discriminator}} @@ -204,12 +204,12 @@ public {{>sealed}}class {{classname}}{{#parent}} extends {{{parent}}}{{/parent}} {{^lombok.Getter}} /** - {{#description}} - * {{{.}}} - {{/description}} - {{^description}} + {{#unescapedDescription}} + * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}} + {{/unescapedDescription}} + {{^unescapedDescription}} * Get {{name}} - {{/description}} + {{/unescapedDescription}} {{#minimum}} * minimum: {{.}} {{/minimum}} @@ -231,10 +231,10 @@ public {{>sealed}}class {{classname}}{{#parent}} extends {{{parent}}}{{/parent}} {{#lambda.trim}}{{>notNull}}{{/lambda.trim}} {{/useBeanValidation}} {{#swagger2AnnotationLibrary}} - @Schema(name = "{{{baseName}}}"{{#isReadOnly}}, accessMode = Schema.AccessMode.READ_ONLY{{/isReadOnly}}{{#example}}, example = "{{{.}}}"{{/example}}{{#description}}, description = "{{{.}}}"{{/description}}{{#deprecated}}, deprecated = true{{/deprecated}}, requiredMode = {{#required}}Schema.RequiredMode.REQUIRED{{/required}}{{^required}}Schema.RequiredMode.NOT_REQUIRED{{/required}}{{#isNullable}}, nullable = true{{/isNullable}}) + @Schema(name = {{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}{{#isReadOnly}}, accessMode = Schema.AccessMode.READ_ONLY{{/isReadOnly}}{{#rawExample}}, example = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}{{/rawExample}}{{#description}}, description = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}{{/description}}{{#deprecated}}, deprecated = true{{/deprecated}}, requiredMode = {{#required}}Schema.RequiredMode.REQUIRED{{/required}}{{^required}}Schema.RequiredMode.NOT_REQUIRED{{/required}}{{#isNullable}}, nullable = true{{/isNullable}}) {{/swagger2AnnotationLibrary}} {{#swagger1AnnotationLibrary}} - @ApiModelProperty({{#example}}example = "{{{.}}}", {{/example}}{{#required}}required = {{required}}, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = "{{{description}}}") + @ApiModelProperty({{#rawExample}}example = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}, {{/rawExample}}{{#required}}required = {{required}}, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = {{#lambda.javaStringLiteral}}{{{unescapedDescription}}}{{/lambda.javaStringLiteral}}) {{/swagger1AnnotationLibrary}} {{#deprecated}} @Deprecated diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/queryParams.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/queryParams.mustache index 56f7527eb92a..d3c99c893ba8 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/queryParams.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/queryParams.mustache @@ -1 +1 @@ -{{#isQueryParam}}{{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{>paramDoc}}{{#useBeanValidation}} @Valid{{/useBeanValidation}}{{^isModel}} @RequestParam(value = {{#isMap}}""{{/isMap}}{{^isMap}}"{{baseName}}"{{/isMap}}{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}){{/isModel}}{{>dateTimeParam}}{{#isDeprecated}} @Deprecated{{/isDeprecated}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isQueryParam}} \ No newline at end of file +{{#isQueryParam}}{{#vendorExtensions.x-field-extra-annotation}}{{{.}}} {{/vendorExtensions.x-field-extra-annotation}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{>paramDoc}}{{#useBeanValidation}} @Valid{{/useBeanValidation}}{{^isModel}} @RequestParam(value = {{#isMap}}""{{/isMap}}{{^isMap}}{{#lambda.javaStringLiteral}}{{{baseName}}}{{/lambda.javaStringLiteral}}{{/isMap}}{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}{{#hasDefaultValue}}{{#isString}}{{^isContainer}}, defaultValue = {{#lambda.javaStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.javaStringLiteral}}{{/isContainer}}{{/isString}}{{#isContainer}}, defaultValue = "{{{defaultValue}}}"{{/isContainer}}{{^isString}}{{^isContainer}}, defaultValue = "{{{defaultValue}}}"{{/isContainer}}{{/isString}}{{/hasDefaultValue}}{{^hasDefaultValue}}{{#defaultValue}}, defaultValue = "{{{defaultValue}}}"{{/defaultValue}}{{/hasDefaultValue}}){{/isModel}}{{>dateTimeParam}}{{#isDeprecated}} @Deprecated{{/isDeprecated}} {{>nullableAnnotation}}{{>optionalDataType}} {{paramName}}{{/isQueryParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/xmlAccessorAnnotation.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/xmlAccessorAnnotation.mustache index ee5195c0eb5c..853751620d78 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/xmlAccessorAnnotation.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/xmlAccessorAnnotation.mustache @@ -1,4 +1,4 @@ - @Xml{{#isXmlAttribute}}Attribute{{/isXmlAttribute}}{{^isXmlAttribute}}Element{{/isXmlAttribute}}(name = "{{items.xmlName}}{{^items.xmlName}}{{xmlName}}{{^xmlName}}{{baseName}}{{/xmlName}}{{/items.xmlName}}"{{#xmlNamespace}}, namespace = "{{.}}"{{/xmlNamespace}}) + @Xml{{#isXmlAttribute}}Attribute{{/isXmlAttribute}}{{^isXmlAttribute}}Element{{/isXmlAttribute}}(name = {{#lambda.javaStringLiteral}}{{#items.xmlName}}{{{items.xmlName}}}{{/items.xmlName}}{{^items.xmlName}}{{#xmlName}}{{{xmlName}}}{{/xmlName}}{{^xmlName}}{{{baseName}}}{{/xmlName}}{{/items.xmlName}}{{/lambda.javaStringLiteral}}{{#xmlNamespace}}, namespace = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}{{/xmlNamespace}}) {{#isXmlWrapped}} - @XmlElementWrapper(name = "{{xmlName}}{{^xmlName}}{{baseName}}{{/xmlName}}"{{#xmlNamespace}}, namespace = "{{.}}"{{/xmlNamespace}}) + @XmlElementWrapper(name = {{#lambda.javaStringLiteral}}{{#xmlName}}{{{xmlName}}}{{/xmlName}}{{^xmlName}}{{{baseName}}}{{/xmlName}}{{/lambda.javaStringLiteral}}{{#xmlNamespace}}, namespace = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}{{/xmlNamespace}}) {{/isXmlWrapped}} diff --git a/modules/openapi-generator/src/main/resources/JavaSpring/xmlAnnotation.mustache b/modules/openapi-generator/src/main/resources/JavaSpring/xmlAnnotation.mustache index b3a89fa362fd..338119dac3ea 100644 --- a/modules/openapi-generator/src/main/resources/JavaSpring/xmlAnnotation.mustache +++ b/modules/openapi-generator/src/main/resources/JavaSpring/xmlAnnotation.mustache @@ -1,6 +1,6 @@ {{#withXml}} {{#jackson}} -@JacksonXmlRootElement({{#xmlNamespace}}namespace = "{{.}}", {{/xmlNamespace}}localName = "{{xmlName}}{{^xmlName}}{{classname}}{{/xmlName}}") +@JacksonXmlRootElement({{#xmlNamespace}}namespace = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}, {{/xmlNamespace}}localName = {{#lambda.javaStringLiteral}}{{#xmlName}}{{{xmlName}}}{{/xmlName}}{{^xmlName}}{{{classname}}}{{/xmlName}}{{/lambda.javaStringLiteral}}) {{/jackson}} -@XmlRootElement({{#xmlNamespace}}namespace = "{{.}}", {{/xmlNamespace}}name = "{{xmlName}}{{^xmlName}}{{classname}}{{/xmlName}}") +@XmlRootElement({{#xmlNamespace}}namespace = {{#lambda.javaStringLiteral}}{{{.}}}{{/lambda.javaStringLiteral}}, {{/xmlNamespace}}name = {{#lambda.javaStringLiteral}}{{#xmlName}}{{{xmlName}}}{{/xmlName}}{{^xmlName}}{{{classname}}}{{/xmlName}}{{/lambda.javaStringLiteral}}) @XmlAccessorType(XmlAccessType.FIELD){{/withXml}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/api.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/api.mustache index 9ff4eb9308dc..1c00e5fe9fe7 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/api.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/api.mustache @@ -67,10 +67,10 @@ import kotlin.collections.Map {{/useSpringBuiltInValidation}} {{/useBeanValidation}} {{#swagger1AnnotationLibrary}} -@Api(value = "{{{baseName}}}", description = "The {{{baseName}}} API") +@Api(value = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}, description = {{#lambda.kotlinStringLiteral}}The {{{baseName}}} API{{/lambda.kotlinStringLiteral}}) {{/swagger1AnnotationLibrary}} {{#useRequestMappingOnController}} -@RequestMapping("\${api.base-path:{{contextPath}}}") +@RequestMapping("\${api.base-path:{{#lambda.kotlinStringContent}}{{{contextPathRaw}}}{{/lambda.kotlinStringContent}}}") {{/useRequestMappingOnController}} {{#operations}} class {{classname}}Controller({{#serviceInterface}}@Autowired(required = true) val service: {{classname}}Service{{/serviceInterface}}) { @@ -81,22 +81,22 @@ class {{classname}}Controller({{#serviceInterface}}@Autowired(required = true) v }}{{/useResponseEntity}}{{! }}{{#swagger2AnnotationLibrary}}{{! }} @Operation( - summary = "{{{summary}}}", - operationId = "{{{operationId}}}", - description = """{{{unescapedNotes}}}""", + summary = {{#lambda.kotlinStringLiteral}}{{{unescapedSummary}}}{{/lambda.kotlinStringLiteral}}, + operationId = {{#lambda.kotlinStringLiteral}}{{{operationId}}}{{/lambda.kotlinStringLiteral}}, + description = {{#lambda.kotlinStringLiteral}}{{{unescapedNotes}}}{{/lambda.kotlinStringLiteral}}, responses = [{{#responses}} - ApiResponse(responseCode = "{{#isDefault}}default{{/isDefault}}{{^isDefault}}{{{code}}}{{/isDefault}}", description = "{{{message}}}"{{#baseType}}, content = [Content({{#isArray}}array = ArraySchema({{/isArray}}schema = Schema(implementation = {{{baseType}}}::class)){{#isArray}}){{/isArray}}]{{/baseType}}){{^-last}},{{/-last}}{{/responses}} ]{{#hasAuthMethods}}, - security = [ {{#authMethods}}SecurityRequirement(name = "{{name}}"{{#isOAuth}}, scopes = [ {{#scopes}}"{{scope}}"{{^-last}}, {{/-last}}{{/scopes}} ]{{/isOAuth}}){{^-last}},{{/-last}}{{/authMethods}} ]{{/hasAuthMethods}} + ApiResponse(responseCode = {{#lambda.kotlinStringLiteral}}{{#isDefault}}default{{/isDefault}}{{^isDefault}}{{{code}}}{{/isDefault}}{{/lambda.kotlinStringLiteral}}, description = {{#lambda.kotlinStringLiteral}}{{{unescapedMessage}}}{{/lambda.kotlinStringLiteral}}{{#baseType}}, content = [Content({{#isArray}}array = ArraySchema({{/isArray}}schema = Schema(implementation = {{{baseType}}}::class)){{#isArray}}){{/isArray}}]{{/baseType}}){{^-last}},{{/-last}}{{/responses}} ]{{#hasAuthMethods}}, + security = [ {{#authMethods}}SecurityRequirement(name = {{#lambda.kotlinStringLiteral}}{{{name}}}{{/lambda.kotlinStringLiteral}}{{#isOAuth}}, scopes = [ {{#scopes}}{{#lambda.kotlinStringLiteral}}{{{scope}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/scopes}} ]{{/isOAuth}}){{^-last}},{{/-last}}{{/authMethods}} ]{{/hasAuthMethods}} ){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} @ApiOperation( - value = "{{{summary}}}", - nickname = "{{{operationId}}}", - notes = "{{{notes}}}"{{#returnBaseType}}, + value = {{#lambda.kotlinStringLiteral}}{{{unescapedSummary}}}{{/lambda.kotlinStringLiteral}}, + nickname = {{#lambda.kotlinStringLiteral}}{{{operationId}}}{{/lambda.kotlinStringLiteral}}, + notes = {{#lambda.kotlinStringLiteral}}{{{unescapedNotes}}}{{/lambda.kotlinStringLiteral}}{{#returnBaseType}}, response = {{{.}}}::class{{/returnBaseType}}{{#returnContainer}}, responseContainer = "{{{.}}}"{{/returnContainer}}{{#hasAuthMethods}}, - authorizations = [{{#authMethods}}Authorization(value = "{{name}}"{{#isOAuth}}, scopes = [{{#scopes}}AuthorizationScope(scope = "{{scope}}", description = "{{description}}"){{^-last}}, {{/-last}}{{/scopes}}]{{/isOAuth}}){{^-last}}, {{/-last}}{{/authMethods}}]{{/hasAuthMethods}}) + authorizations = [{{#authMethods}}Authorization(value = {{#lambda.kotlinStringLiteral}}{{{name}}}{{/lambda.kotlinStringLiteral}}{{#isOAuth}}, scopes = [{{#scopes}}AuthorizationScope(scope = {{#lambda.kotlinStringLiteral}}{{{scope}}}{{/lambda.kotlinStringLiteral}}, description = {{#lambda.kotlinStringLiteral}}{{{descriptionRaw}}}{{/lambda.kotlinStringLiteral}}){{^-last}}, {{/-last}}{{/scopes}}]{{/isOAuth}}){{^-last}}, {{/-last}}{{/authMethods}}]{{/hasAuthMethods}}) @ApiResponses( - value = [{{#responses}}ApiResponse(code = {{{code}}}, message = "{{{message}}}"{{#baseType}}, response = {{{.}}}::class{{/baseType}}{{#containerType}}, responseContainer = "{{{.}}}"{{/containerType}}){{^-last}},{{/-last}}{{/responses}}]){{/swagger1AnnotationLibrary}} + value = [{{#responses}}ApiResponse(code = {{{code}}}, message = {{#lambda.kotlinStringLiteral}}{{{unescapedMessage}}}{{/lambda.kotlinStringLiteral}}{{#baseType}}, response = {{{.}}}::class{{/baseType}}{{#containerType}}, responseContainer = {{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{/containerType}}){{^-last}},{{/-last}}{{/responses}}]){{/swagger1AnnotationLibrary}} {{#implicitHeadersParams.0}} {{>implicitHeaders}} {{/implicitHeadersParams.0}} @@ -128,10 +128,10 @@ class {{classname}}Controller({{#serviceInterface}}@Autowired(required = true) v companion object { //for your own safety never directly reuse these path definitions in tests {{#useRequestMappingOnController}} - const val BASE_PATH: String = "{{=<% %>=}}<%contextPath%><%={{ }}=%>" + const val BASE_PATH: String = {{#lambda.kotlinStringLiteral}}{{{contextPathRaw}}}{{/lambda.kotlinStringLiteral}} {{/useRequestMappingOnController}} {{#operation}} - const val PATH_{{#lambda.uppercase}}{{#lambda.snakecase}}{{{operationId}}}{{/lambda.snakecase}}{{/lambda.uppercase}}: String = "{{{path}}}" + const val PATH_{{#lambda.uppercase}}{{#lambda.snakecase}}{{{operationId}}}{{/lambda.snakecase}}{{/lambda.uppercase}}: String = {{#lambda.kotlinStringLiteral}}{{{path}}}{{/lambda.kotlinStringLiteral}} {{/operation}} } } diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/apiController.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/apiController.mustache index 9288062c6270..920b258593f3 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/apiController.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/apiController.mustache @@ -8,7 +8,7 @@ import java.util.Optional @Controller{{#beanQualifiers}}("{{package}}.{{classname}}Controller"){{/beanQualifiers}} {{#useRequestMappingOnController}} -@RequestMapping("\${api.base-path:{{contextPath}}}") +@RequestMapping("\${api.base-path:{{#lambda.kotlinStringContent}}{{{contextPathRaw}}}{{/lambda.kotlinStringContent}}}") {{/useRequestMappingOnController}} {{#operations}} class {{classname}}Controller( @@ -32,7 +32,7 @@ class {{classname}}Controller( companion object { //for your own safety never directly reuse these path definitions in tests - const val BASE_PATH: String = "{{=<% %>=}}<%>defaultBasePath%><%={{ }}=%>" + const val BASE_PATH: String = {{#lambda.kotlinStringLiteral}}{{{contextPathRaw}}}{{/lambda.kotlinStringLiteral}} } {{/useRequestMappingOnController}} diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/apiInterface.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/apiInterface.mustache index 8059e27f83b6..09c43e631b57 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/apiInterface.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/apiInterface.mustache @@ -74,10 +74,10 @@ import kotlin.collections.Map {{/useSpringBuiltInValidation}} {{/useBeanValidation}} {{#swagger1AnnotationLibrary}} -@Api(value = "{{{baseName}}}", description = "The {{{baseName}}} API") +@Api(value = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}, description = {{#lambda.kotlinStringLiteral}}The {{{baseName}}} API{{/lambda.kotlinStringLiteral}}) {{/swagger1AnnotationLibrary}} {{#useRequestMappingOnInterface}} -@RequestMapping("\${api.base-path:{{contextPath}}}") +@RequestMapping("\${api.base-path:{{#lambda.kotlinStringContent}}{{{contextPathRaw}}}{{/lambda.kotlinStringContent}}}") {{/useRequestMappingOnInterface}} {{#operations}} interface {{classname}} { @@ -92,25 +92,25 @@ interface {{classname}} { }}{{/useResponseEntity}}{{! }}{{#swagger2AnnotationLibrary}}{{! }} @Operation( - tags = [{{#tags}}"{{{name}}}",{{/tags}}], - summary = "{{{summary}}}", - operationId = "{{{operationId}}}", - description = """{{{unescapedNotes}}}""", + tags = [{{#tags}}{{#lambda.kotlinStringLiteral}}{{{name}}}{{/lambda.kotlinStringLiteral}},{{/tags}}], + summary = {{#lambda.kotlinStringLiteral}}{{{unescapedSummary}}}{{/lambda.kotlinStringLiteral}}, + operationId = {{#lambda.kotlinStringLiteral}}{{{operationId}}}{{/lambda.kotlinStringLiteral}}, + description = {{#lambda.kotlinStringLiteral}}{{{unescapedNotes}}}{{/lambda.kotlinStringLiteral}}, responses = [{{#responses}} - ApiResponse(responseCode = "{{#isDefault}}default{{/isDefault}}{{^isDefault}}{{{code}}}{{/isDefault}}", description = "{{{message}}}"{{#baseType}}, content = [Content({{#isArray}}array = ArraySchema({{/isArray}}schema = Schema(implementation = {{{baseType}}}::class)){{#isArray}}){{/isArray}}]{{/baseType}}){{^-last}},{{/-last}}{{/responses}} + ApiResponse(responseCode = {{#lambda.kotlinStringLiteral}}{{#isDefault}}default{{/isDefault}}{{^isDefault}}{{{code}}}{{/isDefault}}{{/lambda.kotlinStringLiteral}}, description = {{#lambda.kotlinStringLiteral}}{{{unescapedMessage}}}{{/lambda.kotlinStringLiteral}}{{#baseType}}, content = [Content({{#isArray}}array = ArraySchema({{/isArray}}schema = Schema(implementation = {{{baseType}}}::class)){{#isArray}}){{/isArray}}]{{/baseType}}){{^-last}},{{/-last}}{{/responses}} ]{{#hasAuthMethods}}, - security = [ {{#authMethods}}SecurityRequirement(name = "{{name}}"{{#isOAuth}}, scopes = [ {{#scopes}}"{{scope}}"{{^-last}}, {{/-last}}{{/scopes}} ]{{/isOAuth}}){{^-last}},{{/-last}}{{/authMethods}} ]{{/hasAuthMethods}} + security = [ {{#authMethods}}SecurityRequirement(name = {{#lambda.kotlinStringLiteral}}{{{name}}}{{/lambda.kotlinStringLiteral}}{{#isOAuth}}, scopes = [ {{#scopes}}{{#lambda.kotlinStringLiteral}}{{{scope}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/scopes}} ]{{/isOAuth}}){{^-last}},{{/-last}}{{/authMethods}} ]{{/hasAuthMethods}} ){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} @ApiOperation( - value = "{{{summary}}}", - nickname = "{{{operationId}}}", - notes = "{{{notes}}}"{{#returnBaseType}}, + value = {{#lambda.kotlinStringLiteral}}{{{unescapedSummary}}}{{/lambda.kotlinStringLiteral}}, + nickname = {{#lambda.kotlinStringLiteral}}{{{operationId}}}{{/lambda.kotlinStringLiteral}}, + notes = {{#lambda.kotlinStringLiteral}}{{{unescapedNotes}}}{{/lambda.kotlinStringLiteral}}{{#returnBaseType}}, response = {{{.}}}::class{{/returnBaseType}}{{#returnContainer}}, responseContainer = "{{{.}}}"{{/returnContainer}}{{#hasAuthMethods}}, - authorizations = [{{#authMethods}}Authorization(value = "{{name}}"{{#isOAuth}}, scopes = [{{#scopes}}AuthorizationScope(scope = "{{scope}}", description = "{{description}}"){{^-last}}, {{/-last}}{{/scopes}}]{{/isOAuth}}){{^-last}}, {{/-last}}{{/authMethods}}]{{/hasAuthMethods}} + authorizations = [{{#authMethods}}Authorization(value = {{#lambda.kotlinStringLiteral}}{{{name}}}{{/lambda.kotlinStringLiteral}}{{#isOAuth}}, scopes = [{{#scopes}}AuthorizationScope(scope = {{#lambda.kotlinStringLiteral}}{{{scope}}}{{/lambda.kotlinStringLiteral}}, description = {{#lambda.kotlinStringLiteral}}{{{descriptionRaw}}}{{/lambda.kotlinStringLiteral}}){{^-last}}, {{/-last}}{{/scopes}}]{{/isOAuth}}){{^-last}}, {{/-last}}{{/authMethods}}]{{/hasAuthMethods}} ) @ApiResponses( - value = [{{#responses}}ApiResponse(code = {{{code}}}, message = "{{{message}}}"{{#baseType}}, response = {{{.}}}::class{{/baseType}}{{#containerType}}, responseContainer = "{{{.}}}"{{/containerType}}){{^-last}}, {{/-last}}{{/responses}}] + value = [{{#responses}}ApiResponse(code = {{{code}}}, message = {{#lambda.kotlinStringLiteral}}{{{unescapedMessage}}}{{/lambda.kotlinStringLiteral}}{{#baseType}}, response = {{{.}}}::class{{/baseType}}{{#containerType}}, responseContainer = {{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{/containerType}}){{^-last}}, {{/-last}}{{/responses}}] ){{/swagger1AnnotationLibrary}} {{#implicitHeadersParams.0}} {{>implicitHeaders}} @@ -148,10 +148,10 @@ interface {{classname}} { companion object { //for your own safety never directly reuse these path definitions in tests {{#useRequestMappingOnInterface}} - const val BASE_PATH: String = "{{=<% %>=}}<%contextPath%><%={{ }}=%>" + const val BASE_PATH: String = {{#lambda.kotlinStringLiteral}}{{{contextPathRaw}}}{{/lambda.kotlinStringLiteral}} {{/useRequestMappingOnInterface}} {{#operation}} - const val PATH_{{#lambda.uppercase}}{{#lambda.snakecase}}{{{operationId}}}{{/lambda.snakecase}}{{/lambda.uppercase}}: String = "{{{path}}}" + const val PATH_{{#lambda.uppercase}}{{#lambda.snakecase}}{{{operationId}}}{{/lambda.snakecase}}{{/lambda.uppercase}}: String = {{#lambda.kotlinStringLiteral}}{{{path}}}{{/lambda.kotlinStringLiteral}} {{/operation}} } } diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/bodyParams.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/bodyParams.mustache index b4f03475cd0b..8858e7e9d479 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/bodyParams.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/bodyParams.mustache @@ -1 +1 @@ -{{#isBodyParam}}{{#swagger2AnnotationLibrary}}@Parameter(description = "{{{description}}}"{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}{{#defaultValue}}, schema = Schema(allowableValues = ["{{{allowableValues}}}"], defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/defaultValue}}{{/allowableValues}}{{^allowableValues}}{{#defaultValue}}, schema = Schema(defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/defaultValue}}{{/allowableValues}}{{#allowableValues}}{{^defaultValue}}, schema = Schema(allowableValues = ["{{{allowableValues}}}"]){{/defaultValue}}{{/allowableValues}}{{/isContainer}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "{{{description}}}"{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}, allowableValues = "{{{.}}}"{{/allowableValues}}{{/isContainer}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{>beanValidationBodyParams}}{{/useBeanValidation}} @RequestBody{{^required}}(required = false){{/required}} {{{paramName}}}: {{^reactive}}{{>optionalDataType}}{{/reactive}}{{#reactive}}{{^isArray}}{{>optionalDataType}}{{/isArray}}{{#isArray}}Flow<{{{baseType}}}>{{/isArray}}{{/reactive}}{{/isBodyParam}} \ No newline at end of file +{{#isBodyParam}}{{#swagger2AnnotationLibrary}}@Parameter(description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}{{#hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}], defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/hasDefaultValue}}{{/allowableValues}}{{^allowableValues}}{{#hasDefaultValue}}, schema = Schema(defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/hasDefaultValue}}{{/allowableValues}}{{#allowableValues}}{{^hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]){{/hasDefaultValue}}{{/allowableValues}}{{/isContainer}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}, allowableValues = "{{#values}}{{#lambda.kotlinStringContent}}{{{.}}}{{/lambda.kotlinStringContent}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{/isContainer}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{>beanValidationBodyParams}}{{/useBeanValidation}} @RequestBody{{^required}}(required = false){{/required}} {{{paramName}}}: {{^reactive}}{{>optionalDataType}}{{/reactive}}{{#reactive}}{{^isArray}}{{>optionalDataType}}{{/isArray}}{{#isArray}}Flow<{{{baseType}}}>{{/isArray}}{{/reactive}}{{/isBodyParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/cookieParams.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/cookieParams.mustache index 028264a18bcf..7545f51a95a5 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/cookieParams.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/cookieParams.mustache @@ -1 +1 @@ -{{#isCookieParam}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}@CookieValue(name = "{{baseName}}"{{^required}}, required = false{{/required}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}) {{{paramName}}}: {{>optionalDataType}}{{/isCookieParam}} \ No newline at end of file +{{#isCookieParam}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}@CookieValue(name = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}{{^required}}, required = false{{/required}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}{{^hasDefaultValue}}{{#defaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{defaultValue}}}{{/lambda.kotlinStringLiteral}}{{/defaultValue}}{{/hasDefaultValue}}) {{{paramName}}}: {{>optionalDataType}}{{/isCookieParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/dataClass.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/dataClass.mustache index 3eeb19e70bcd..9f5cd8caab8b 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/dataClass.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/dataClass.mustache @@ -1,10 +1,10 @@ /** - * {{{description}}} + * {{#lambda.kotlinDocText}}{{{unescapedDescription}}}{{/lambda.kotlinDocText}} {{#requiredVars}} - * @param {{name}} {{{description}}} + * @param {{name}} {{#lambda.kotlinDocText}}{{{unescapedDescription}}}{{/lambda.kotlinDocText}} {{/requiredVars}} {{#optionalVars}} - * @param {{name}} {{{description}}} + * @param {{name}} {{#lambda.kotlinDocText}}{{{unescapedDescription}}}{{/lambda.kotlinDocText}} {{/optionalVars}} */{{#discriminator}} {{>typeInfoAnnotation}}{{/discriminator}} @@ -45,12 +45,12 @@ {{/discriminator}} {{#hasEnums}}{{#vars}}{{#isEnum}} /** - * {{{description}}} + * {{#lambda.kotlinDocText}}{{{unescapedDescription}}}{{/lambda.kotlinDocText}} * Values: {{#allowableValues}}{{#enumVars}}{{&name}}{{^-last}},{{/-last}}{{/enumVars}}{{/allowableValues}} */ enum class {{{nameInPascalCase}}}(@get:JsonValue {{#useEnumValueInterface}}{{^isContainer}}override {{/isContainer}}{{/useEnumValueInterface}}val value: {{#isContainer}}{{#items}}{{{dataType}}}{{/items}}{{/isContainer}}{{^isContainer}}{{{dataType}}}{{/isContainer}}) {{#vendorExtensions.x-kotlin-implements}}{{#-first}}: {{{.}}}{{/-first}}{{^-first}}, {{{.}}}{{/-first}} {{/vendorExtensions.x-kotlin-implements}}{ {{#allowableValues}}{{#enumVars}} - {{{name}}}({{{value}}}){{^-last}},{{/-last}}{{/enumVars}}{{/allowableValues}}; + {{{name}}}({{#isString}}{{#lambda.kotlinStringLiteral}}{{{valueRaw}}}{{/lambda.kotlinStringLiteral}}{{/isString}}{{^isString}}{{{value}}}{{/isString}}){{^-last}},{{/-last}}{{/enumVars}}{{/allowableValues}}; companion object { @JvmStatic diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassOptVar.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassOptVar.mustache index 78380ea41ac9..45cde0140bda 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassOptVar.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassOptVar.mustache @@ -1,10 +1,10 @@ {{#useBeanValidation}}{{>beanValidation}}{{>beanValidationModel}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}} - @Schema({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = "{{{description}}}"){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} - @ApiModelProperty({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = "{{{description}}}"){{/swagger1AnnotationLibrary}}{{#deprecated}} + @Schema({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} + @ApiModelProperty({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger1AnnotationLibrary}}{{#deprecated}} @Deprecated(message = ""){{/deprecated}}{{#vendorExtensions.x-field-extra-annotation}} {{{.}}}{{/vendorExtensions.x-field-extra-annotation}}{{#vendorExtensions.x-jackson-json-include-policy}} @field:JsonInclude(JsonInclude.Include.{{{vendorExtensions.x-jackson-json-include-policy}}}){{/vendorExtensions.x-jackson-json-include-policy}}{{#vendorExtensions.x-has-json-setter-nulls-skip}} @field:JsonSetter(nulls = Nulls.SKIP){{/vendorExtensions.x-has-json-setter-nulls-skip}}{{#vendorExtensions.x-has-json-setter-nulls-fail}} @field:JsonSetter(nulls = Nulls.FAIL){{/vendorExtensions.x-has-json-setter-nulls-fail}} - @param:JsonProperty("{{{baseName}}}") - @get:JsonProperty("{{{baseName}}}"){{#isInherited}} override{{/isInherited}} {{>modelMutable}} {{{name}}}: {{#vendorExtensions.x-is-jackson-optional-nullable}}JsonNullable<{{#isEnum}}{{#isArray}}{{baseType}}<{{/isArray}}{{classname}}.{{{nameInPascalCase}}}{{#isArray}}>{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}>{{/vendorExtensions.x-is-jackson-optional-nullable}}{{^vendorExtensions.x-is-jackson-optional-nullable}}{{#isEnum}}{{#isArray}}{{baseType}}<{{/isArray}}{{classname}}.{{{nameInPascalCase}}}{{#isArray}}>{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}?{{/vendorExtensions.x-is-jackson-optional-nullable}} = {{#vendorExtensions.x-is-jackson-optional-nullable}}JsonNullable.undefined(){{/vendorExtensions.x-is-jackson-optional-nullable}}{{^vendorExtensions.x-is-jackson-optional-nullable}}{{^defaultValue}}null{{/defaultValue}}{{#defaultValue}}{{^isNumber}}{{{defaultValue}}}{{/isNumber}}{{#isNumber}}{{{dataType}}}("{{{defaultValue}}}"){{/isNumber}}{{/defaultValue}}{{/vendorExtensions.x-is-jackson-optional-nullable}} \ No newline at end of file + @param:JsonProperty({{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}) + @get:JsonProperty({{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}){{#isInherited}} override{{/isInherited}} {{>modelMutable}} {{{name}}}: {{#vendorExtensions.x-is-jackson-optional-nullable}}JsonNullable<{{#isEnum}}{{#isArray}}{{baseType}}<{{/isArray}}{{classname}}.{{{nameInPascalCase}}}{{#isArray}}>{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}>{{/vendorExtensions.x-is-jackson-optional-nullable}}{{^vendorExtensions.x-is-jackson-optional-nullable}}{{#isEnum}}{{#isArray}}{{baseType}}<{{/isArray}}{{classname}}.{{{nameInPascalCase}}}{{#isArray}}>{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}?{{/vendorExtensions.x-is-jackson-optional-nullable}} = {{#vendorExtensions.x-is-jackson-optional-nullable}}JsonNullable.undefined(){{/vendorExtensions.x-is-jackson-optional-nullable}}{{^vendorExtensions.x-is-jackson-optional-nullable}}{{^defaultValue}}null{{/defaultValue}}{{#defaultValue}}{{^isNumber}}{{{defaultValue}}}{{/isNumber}}{{#isNumber}}{{{dataType}}}("{{{defaultValue}}}"){{/isNumber}}{{/defaultValue}}{{/vendorExtensions.x-is-jackson-optional-nullable}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassReqVar.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassReqVar.mustache index 9adc56998e1a..71b4f8c63800 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassReqVar.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/dataClassReqVar.mustache @@ -1,9 +1,9 @@ {{#useBeanValidation}}{{>beanValidation}}{{>beanValidationModel}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}} - @Schema({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}required = true, {{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = "{{{description}}}"){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} - @ApiModelProperty({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}required = true, {{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = "{{{description}}}"){{/swagger1AnnotationLibrary}}{{#vendorExtensions.x-field-extra-annotation}} + @Schema({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}required = true, {{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} + @ApiModelProperty({{#example}}example = "{{#lambdaRemoveLineBreak}}{{#lambdaEscapeInNormalString}}{{{.}}}{{/lambdaEscapeInNormalString}}{{/lambdaRemoveLineBreak}}", {{/example}}required = true, {{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger1AnnotationLibrary}}{{#vendorExtensions.x-field-extra-annotation}} {{{.}}}{{/vendorExtensions.x-field-extra-annotation}}{{#vendorExtensions.x-jackson-json-include-policy}} @field:JsonInclude(JsonInclude.Include.{{{vendorExtensions.x-jackson-json-include-policy}}}){{/vendorExtensions.x-jackson-json-include-policy}}{{#vendorExtensions.x-has-json-setter-nulls-skip}} @field:JsonSetter(nulls = Nulls.SKIP){{/vendorExtensions.x-has-json-setter-nulls-skip}}{{#vendorExtensions.x-has-json-setter-nulls-fail}} @field:JsonSetter(nulls = Nulls.FAIL){{/vendorExtensions.x-has-json-setter-nulls-fail}} - @param:JsonProperty("{{{baseName}}}", required = true) - @get:JsonProperty("{{{baseName}}}", required = true){{#isInherited}} override{{/isInherited}} {{>modelMutable}} {{{name}}}: {{#isEnum}}{{#isArray}}{{baseType}}<{{/isArray}}{{classname}}.{{{nameInPascalCase}}}{{#isArray}}>{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{#isNullable}}?{{/isNullable}}{{#defaultValue}} = {{^isNumber}}{{{defaultValue}}}{{/isNumber}}{{#isNumber}}{{{dataType}}}("{{{defaultValue}}}"){{/isNumber}}{{/defaultValue}} \ No newline at end of file + @param:JsonProperty({{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}, required = true) + @get:JsonProperty({{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}, required = true){{#isInherited}} override{{/isInherited}} {{>modelMutable}} {{{name}}}: {{#isEnum}}{{#isArray}}{{baseType}}<{{/isArray}}{{classname}}.{{{nameInPascalCase}}}{{#isArray}}>{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{#isNullable}}?{{/isNullable}}{{#defaultValue}} = {{^isNumber}}{{{defaultValue}}}{{/isNumber}}{{#isNumber}}{{{dataType}}}("{{{defaultValue}}}"){{/isNumber}}{{/defaultValue}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/enumClass.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/enumClass.mustache index d22051e2367a..064b99b8c5f4 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/enumClass.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/enumClass.mustache @@ -1,10 +1,10 @@ /** -* {{{description}}} +* {{#lambda.kotlinDocText}}{{{unescapedDescription}}}{{/lambda.kotlinDocText}} * Values: {{#allowableValues}}{{#enumVars}}{{&name}}{{^-last}},{{/-last}}{{/enumVars}}{{/allowableValues}} */ enum class {{classname}}(@get:JsonValue {{#useEnumValueInterface}}override {{/useEnumValueInterface}}val value: {{dataType}}) {{#vendorExtensions.x-kotlin-implements}}{{#-first}}: {{{.}}}{{/-first}}{{^-first}}, {{{.}}}{{/-first}} {{/vendorExtensions.x-kotlin-implements}}{ {{#allowableValues}}{{#enumVars}} - {{&name}}({{{value}}}){{^-last}},{{/-last}}{{/enumVars}}{{/allowableValues}}; + {{&name}}({{#isString}}{{#lambda.kotlinStringLiteral}}{{{valueRaw}}}{{/lambda.kotlinStringLiteral}}{{/isString}}{{^isString}}{{{value}}}{{/isString}}){{^-last}},{{/-last}}{{/enumVars}}{{/allowableValues}}; companion object { @JvmStatic diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/formParams.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/formParams.mustache index 456af893718f..d6d7166ae325 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/formParams.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/formParams.mustache @@ -1 +1 @@ -{{#isFormParam}}{{^isFile}}{{#swagger2AnnotationLibrary}}@Parameter(description = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}{{#defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{/isContainer}}){{/defaultValue}}{{/allowableValues}}{{#allowableValues}}{{^defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]){{/defaultValue}}{{/allowableValues}}{{^allowableValues}}{{#defaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/isContainer}}{{/defaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{{.}}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid {{/useBeanValidation}}{{#isModel}}@RequestPart{{/isModel}}{{^isModel}}@RequestParam{{/isModel}}(value = "{{baseName}}"{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}) {{{paramName}}}: {{>optionalDataType}}{{/isFile}}{{#isFile}}{{#swagger2AnnotationLibrary}}@Parameter(description = "{{{description}}}") {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "file detail") {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{/useBeanValidation}} @RequestPart("{{baseName}}"{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}) {{{paramName}}}: {{>optionalDataType}}{{/isFile}}{{/isFormParam}} \ No newline at end of file +{{#isFormParam}}{{^isFile}}{{#swagger2AnnotationLibrary}}@Parameter(description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}{{#hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/isContainer}}){{/hasDefaultValue}}{{/allowableValues}}{{#allowableValues}}{{^hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]){{/hasDefaultValue}}{{/allowableValues}}{{^allowableValues}}{{#hasDefaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/isContainer}}{{/hasDefaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{#lambda.kotlinStringContent}}{{{.}}}{{/lambda.kotlinStringContent}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid {{/useBeanValidation}}{{#isModel}}@RequestPart{{/isModel}}{{^isModel}}@RequestParam{{/isModel}}(value = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}) {{{paramName}}}: {{>optionalDataType}}{{/isFile}}{{#isFile}}{{#swagger2AnnotationLibrary}}@Parameter(description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "file detail") {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{/useBeanValidation}} @RequestPart({{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}) {{{paramName}}}: {{>optionalDataType}}{{/isFile}}{{/isFormParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/headerParams.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/headerParams.mustache index 0c2678f1bf67..756236812d7c 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/headerParams.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/headerParams.mustache @@ -1 +1 @@ -{{#isHeaderParam}}{{#useBeanValidation}}{{>beanValidationCore}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}}@Parameter(description = "{{{description}}}", `in` = ParameterIn.HEADER{{#required}}, required = true{{/required}}{{#allowableValues}}{{#defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{/isContainer}}){{/defaultValue}}{{/allowableValues}}{{#allowableValues}}{{^defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]){{/defaultValue}}{{/allowableValues}}{{^allowableValues}}{{#defaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/isContainer}}{{/defaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{{.}}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}) {{/swagger1AnnotationLibrary}}@RequestHeader(value = "{{baseName}}", required = {{#required}}true{{/required}}{{^required}}false{{/required}}{{#defaultValue}}, defaultValue = {{^isString}}"{{{.}}}"{{/isString}}{{#isString}}{{#isEnum}}"{{{.}}}"{{/isEnum}}{{^isEnum}}{{{.}}}{{/isEnum}}{{/isString}}{{/defaultValue}}) {{{paramName}}}: {{>optionalDataType}}{{/isHeaderParam}} \ No newline at end of file +{{#isHeaderParam}}{{#useBeanValidation}}{{>beanValidationCore}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}}@Parameter(description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}, `in` = ParameterIn.HEADER{{#required}}, required = true{{/required}}{{#allowableValues}}{{#hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/isContainer}}){{/hasDefaultValue}}{{/allowableValues}}{{#allowableValues}}{{^hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]){{/hasDefaultValue}}{{/allowableValues}}{{^allowableValues}}{{#hasDefaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/isContainer}}{{/hasDefaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{#lambda.kotlinStringContent}}{{{.}}}{{/lambda.kotlinStringContent}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}) {{/swagger1AnnotationLibrary}}@RequestHeader(value = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}, required = {{#required}}true{{/required}}{{^required}}false{{/required}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}) {{{paramName}}}: {{>optionalDataType}}{{/isHeaderParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/implicitHeaders.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/implicitHeaders.mustache index c7b37059e2d9..8507198c07e6 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/implicitHeaders.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/implicitHeaders.mustache @@ -1,14 +1,14 @@ {{#swagger2AnnotationLibrary}} @Parameters(value = [ {{#implicitHeadersParams}} - Parameter(name = "{{{baseName}}}"{{#isDeprecated}}, deprecated = true{{/isDeprecated}}, description = "{{{description}}}"{{#required}}, required = true{{/required}}, `in` = ParameterIn.HEADER){{^-last}},{{/-last}} + Parameter(name = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}{{#isDeprecated}}, deprecated = true{{/isDeprecated}}, description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}, `in` = ParameterIn.HEADER){{^-last}},{{/-last}} {{/implicitHeadersParams}} ]) {{/swagger2AnnotationLibrary}} {{#swagger1AnnotationLibrary}} @ApiImplicitParams(value = [ {{#implicitHeadersParams}} - ApiImplicitParam(name = "{{{baseName}}}", value = "{{{description}}}", {{#required}}required = true,{{/required}} dataType = "{{{dataType}}}", paramType = "header"){{^-last}},{{/-last}} + ApiImplicitParam(name = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}, value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}, {{#required}}required = true,{{/required}} dataType = {{#lambda.kotlinStringLiteral}}{{{dataType}}}{{/lambda.kotlinStringLiteral}}, paramType = "header"){{^-last}},{{/-last}} {{/implicitHeadersParams}} ]) {{/swagger1AnnotationLibrary}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceOptVar.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceOptVar.mustache index 3fa63ad64876..ad2d9ac6aaca 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceOptVar.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceOptVar.mustache @@ -1,5 +1,5 @@ {{#swagger2AnnotationLibrary}} - @get:Schema({{#example}}example = "{{{.}}}", {{/example}}{{#required}}requiredMode = Schema.RequiredMode.REQUIRED, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = "{{{description}}}"){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} - @get:ApiModelProperty({{#example}}example = "{{{.}}}", {{/example}}{{#required}}required = {{required}}, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = "{{{description}}}"){{/swagger1AnnotationLibrary}}{{#vendorExtensions.x-field-extra-annotation}} + @get:Schema({{#example}}example = {{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}, {{/example}}{{#required}}requiredMode = Schema.RequiredMode.REQUIRED, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} + @get:ApiModelProperty({{#example}}example = {{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}, {{/example}}{{#required}}required = {{required}}, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger1AnnotationLibrary}}{{#vendorExtensions.x-field-extra-annotation}} {{{.}}}{{/vendorExtensions.x-field-extra-annotation}} {{#isInherited}}override {{/isInherited}}{{>modelMutable}} {{{name}}}: {{#isEnum}}{{classname}}.{{nameInPascalCase}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}? {{^discriminator}}= {{{defaultValue}}}{{^defaultValue}}null{{/defaultValue}}{{/discriminator}} diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceReqVar.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceReqVar.mustache index 8f0fb71ba319..33b2caa81e3f 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceReqVar.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/interfaceReqVar.mustache @@ -1,5 +1,5 @@ {{#swagger2AnnotationLibrary}} - @get:Schema({{#example}}example = "{{{.}}}", {{/example}}{{#required}}requiredMode = Schema.RequiredMode.REQUIRED, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = "{{{description}}}"){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} - @get:ApiModelProperty({{#example}}example = "{{{.}}}", {{/example}}{{#required}}required = {{required}}, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = "{{{description}}}"){{/swagger1AnnotationLibrary}}{{#vendorExtensions.x-field-extra-annotation}} + @get:Schema({{#example}}example = {{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}, {{/example}}{{#required}}requiredMode = Schema.RequiredMode.REQUIRED, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}} + @get:ApiModelProperty({{#example}}example = {{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}, {{/example}}{{#required}}required = {{required}}, {{/required}}{{#isReadOnly}}readOnly = {{{isReadOnly}}}, {{/isReadOnly}}value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}){{/swagger1AnnotationLibrary}}{{#vendorExtensions.x-field-extra-annotation}} {{{.}}}{{/vendorExtensions.x-field-extra-annotation}} {{#isInherited}}override {{/isInherited}}{{>modelMutable}} {{{name}}}: {{#isEnum}}{{classname}}.{{nameInPascalCase}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}} diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/apiInterface.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/apiInterface.mustache index 10c6a9b5c8b4..dee52de8ec48 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/apiInterface.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/apiInterface.mustache @@ -80,9 +80,9 @@ interface {{classname}} { {{/operation}} companion object { //for your own safety never directly reuse these path definitions in tests - const val BASE_PATH: String = "{{=<% %>=}}<%contextPath%><%={{ }}=%>" + const val BASE_PATH: String = {{#lambda.kotlinStringLiteral}}{{{contextPathRaw}}}{{/lambda.kotlinStringLiteral}} {{#operation}} - const val PATH_{{#lambda.uppercase}}{{#lambda.snakecase}}{{{operationId}}}{{/lambda.snakecase}}{{/lambda.uppercase}}: String = "{{{path}}}" + const val PATH_{{#lambda.uppercase}}{{#lambda.snakecase}}{{{operationId}}}{{/lambda.snakecase}}{{/lambda.uppercase}}: String = {{#lambda.kotlinStringLiteral}}{{{path}}}{{/lambda.kotlinStringLiteral}} {{/operation}} } } diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/httpInterfaceBodyParams.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/httpInterfaceBodyParams.mustache index e884046f7d6d..b28e545052aa 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/httpInterfaceBodyParams.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/libraries/spring-declarative-http-interface/httpInterfaceBodyParams.mustache @@ -1 +1 @@ -{{#isBodyParam}}{{#swagger2AnnotationLibrary}}@Parameter(description = "{{{description}}}"{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}{{#defaultValue}}, schema = Schema(allowableValues = ["{{{allowableValues}}}"], defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/defaultValue}}{{/allowableValues}}{{^allowableValues}}{{#defaultValue}}, schema = Schema(defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/defaultValue}}{{/allowableValues}}{{#allowableValues}}{{^defaultValue}}, schema = Schema(allowableValues = ["{{{allowableValues}}}"]){{/defaultValue}}{{/allowableValues}}{{/isContainer}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "{{{description}}}"{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}, allowableValues = "{{{.}}}"{{/allowableValues}}{{/isContainer}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{>beanValidationBodyParams}}{{/useBeanValidation}} @RequestBody{{^required}}(required = false){{/required}} {{{paramName}}}: {{>optionalDataType}}{{/isBodyParam}} \ No newline at end of file +{{#isBodyParam}}{{#swagger2AnnotationLibrary}}@Parameter(description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}{{#hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}], defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/hasDefaultValue}}{{/allowableValues}}{{^allowableValues}}{{#hasDefaultValue}}, schema = Schema(defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/hasDefaultValue}}{{/allowableValues}}{{#allowableValues}}{{^hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]){{/hasDefaultValue}}{{/allowableValues}}{{/isContainer}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{^isContainer}}{{#allowableValues}}, allowableValues = "{{#values}}{{#lambda.kotlinStringContent}}{{{.}}}{{/lambda.kotlinStringContent}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{/isContainer}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{>beanValidationBodyParams}}{{/useBeanValidation}} @RequestBody{{^required}}(required = false){{/required}} {{{paramName}}}: {{>optionalDataType}}{{/isBodyParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/oneof_interface.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/oneof_interface.mustache index 06e5c7943fe7..0d3873159a51 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/oneof_interface.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/oneof_interface.mustache @@ -1,5 +1,5 @@ /** - * {{{description}}} + * {{#lambda.kotlinDocText}}{{{unescapedDescription}}}{{/lambda.kotlinDocText}} */ {{#discriminator}} {{>typeInfoAnnotation}} diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/pathParams.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/pathParams.mustache index 2e28d18c78fa..abde5bcd15de 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/pathParams.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/pathParams.mustache @@ -1 +1 @@ -{{#isPathParam}}{{#useBeanValidation}}{{>beanValidationPathParams}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}}@Parameter(description = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}{{#defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{/isContainer}}){{/defaultValue}}{{/allowableValues}}{{#allowableValues}}{{^defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]){{/defaultValue}}{{/allowableValues}}{{^allowableValues}}{{#defaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/isContainer}}{{/defaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{{.}}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{#defaultValue}}, defaultValue = "{{{.}}}"{{/defaultValue}}) {{/swagger1AnnotationLibrary}}@PathVariable("{{baseName}}") {{{paramName}}}: {{>optionalDataType}}{{/isPathParam}} \ No newline at end of file +{{#isPathParam}}{{#useBeanValidation}}{{>beanValidationPathParams}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}}@Parameter(description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}{{#hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/isContainer}}){{/hasDefaultValue}}{{/allowableValues}}{{#allowableValues}}{{^hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]){{/hasDefaultValue}}{{/allowableValues}}{{^allowableValues}}{{#hasDefaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/isContainer}}{{/hasDefaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{#lambda.kotlinStringContent}}{{{.}}}{{/lambda.kotlinStringContent}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}) {{/swagger1AnnotationLibrary}}@PathVariable({{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}) {{{paramName}}}: {{>optionalDataType}}{{/isPathParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/queryParams.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/queryParams.mustache index 27d7e286bb33..f17b14ab0e24 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/queryParams.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/queryParams.mustache @@ -1 +1 @@ -{{#isQueryParam}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}}@Parameter(description = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}{{#defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{/isContainer}}){{/defaultValue}}{{/allowableValues}}{{#allowableValues}}{{^defaultValue}}, schema = Schema(allowableValues = [{{#values}}"{{{.}}}"{{^-last}}, {{/-last}}{{/values}}]){{/defaultValue}}{{/allowableValues}}{{^allowableValues}}{{#defaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}){{/isContainer}}{{/defaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = "{{{description}}}"{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{{.}}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{^isContainer}}{{#defaultValue}}, defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{/defaultValue}}{{/isContainer}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{/useBeanValidation}}{{^isModel}} @RequestParam(value = "{{baseName}}"{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}{{^isContainer}}{{#defaultValue}}, defaultValue = {{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{{defaultValue}}}{{^isString}}"{{/isString}}{{#isString}}{{#isEnum}}"{{/isEnum}}{{/isString}}{{/defaultValue}}{{/isContainer}}){{/isModel}}{{#isDate}} @org.springframework.format.annotation.DateTimeFormat(iso = org.springframework.format.annotation.DateTimeFormat.ISO.DATE){{/isDate}}{{#isDateTime}} @org.springframework.format.annotation.DateTimeFormat(iso = org.springframework.format.annotation.DateTimeFormat.ISO.DATE_TIME){{/isDateTime}} {{{paramName}}}: {{>optionalDataType}}{{/isQueryParam}} \ No newline at end of file +{{#isQueryParam}}{{#useBeanValidation}}{{>beanValidationQueryParams}}{{/useBeanValidation}}{{#swagger2AnnotationLibrary}}@Parameter(description = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}{{#hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]{{^isContainer}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/isContainer}}){{/hasDefaultValue}}{{/allowableValues}}{{#allowableValues}}{{^hasDefaultValue}}, schema = Schema(allowableValues = [{{#values}}{{#lambda.kotlinStringLiteral}}{{{.}}}{{/lambda.kotlinStringLiteral}}{{^-last}}, {{/-last}}{{/values}}]){{/hasDefaultValue}}{{/allowableValues}}{{^allowableValues}}{{#hasDefaultValue}}{{^isContainer}}, schema = Schema(defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}){{/isContainer}}{{/hasDefaultValue}}{{/allowableValues}}) {{/swagger2AnnotationLibrary}}{{#swagger1AnnotationLibrary}}@ApiParam(value = {{#lambda.kotlinStringLiteral}}{{{unescapedDescription}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{#allowableValues}}, allowableValues = "{{#values}}{{#lambda.kotlinStringContent}}{{{.}}}{{/lambda.kotlinStringContent}}{{^-last}}, {{/-last}}{{/values}}"{{/allowableValues}}{{^isContainer}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}{{/isContainer}}) {{/swagger1AnnotationLibrary}}{{#useBeanValidation}}@Valid{{/useBeanValidation}}{{^isModel}} @RequestParam(value = {{#lambda.kotlinStringLiteral}}{{{baseName}}}{{/lambda.kotlinStringLiteral}}{{#required}}, required = true{{/required}}{{^required}}, required = false{{/required}}{{^isContainer}}{{#hasDefaultValue}}, defaultValue = {{#lambda.kotlinStringLiteral}}{{{rawDefaultValueText}}}{{/lambda.kotlinStringLiteral}}{{/hasDefaultValue}}{{/isContainer}}){{/isModel}}{{#isDate}} @org.springframework.format.annotation.DateTimeFormat(iso = org.springframework.format.annotation.DateTimeFormat.ISO.DATE){{/isDate}}{{#isDateTime}} @org.springframework.format.annotation.DateTimeFormat(iso = org.springframework.format.annotation.DateTimeFormat.ISO.DATE_TIME){{/isDateTime}} {{{paramName}}}: {{>optionalDataType}}{{/isQueryParam}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/service.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/service.mustache index e8972a7afd51..856f93cc4413 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/service.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/service.mustache @@ -11,22 +11,22 @@ interface {{classname}}Service { {{#operation}} /** - * {{httpMethod}} {{{path}}}{{#summary}} : {{.}}{{/summary}} - {{#notes}} - * {{.}} - {{/notes}} + * {{httpMethod}} {{#lambda.kotlinDocText}}{{{unescapedPath}}}{{/lambda.kotlinDocText}}{{#unescapedSummary}} : {{#lambda.kotlinDocText}}{{{unescapedSummary}}}{{/lambda.kotlinDocText}}{{/unescapedSummary}} + {{#unescapedNotes}} + * {{#lambda.kotlinDocText}}{{{unescapedNotes}}}{{/lambda.kotlinDocText}} + {{/unescapedNotes}} * {{#allParams}} - * @param {{{paramName}}} {{description}}{{#required}} (required){{/required}}{{^required}} (optional{{#defaultValue}}, default to {{.}}{{/defaultValue}}){{/required}} + * @param {{{paramName}}} {{#lambda.kotlinDocText}}{{{unescapedDescription}}}{{/lambda.kotlinDocText}}{{#required}} (required){{/required}}{{^required}} (optional{{#vendorExtensions.x-spring-form-default-not-applied}}, OpenAPI schema default to {{#lambda.kotlinDocText}}{{{rawDefaultValueText}}}{{/lambda.kotlinDocText}}{{/vendorExtensions.x-spring-form-default-not-applied}}{{^vendorExtensions.x-spring-form-default-not-applied}}{{#hasDefaultValue}}, default to {{#lambda.kotlinDocText}}{{{rawDefaultValueText}}}{{/lambda.kotlinDocText}}{{/hasDefaultValue}}{{/vendorExtensions.x-spring-form-default-not-applied}}){{/required}} {{/allParams}} - * @return {{#responses}}{{message}} (status code {{code}}){{^-last}} + * @return {{#responses}}{{#lambda.kotlinDocText}}{{{unescapedMessage}}}{{/lambda.kotlinDocText}} (status code {{code}}){{^-last}} * or {{/-last}}{{/responses}} {{#isDeprecated}} * @deprecated {{/isDeprecated}} {{#externalDocs}} - * {{description}} - * @see {{summary}} Documentation + * {{#lambda.kotlinDocText}}{{{description}}}{{/lambda.kotlinDocText}} + * @see {{#lambda.kotlinDocText}}{{{summary}}}{{/lambda.kotlinDocText}} Documentation {{/externalDocs}} * @see {{classname}}#{{operationId}} */ diff --git a/modules/openapi-generator/src/main/resources/kotlin-spring/springdocDocumentationConfig.mustache b/modules/openapi-generator/src/main/resources/kotlin-spring/springdocDocumentationConfig.mustache index 91b4cd7fc595..f004c797bb0a 100644 --- a/modules/openapi-generator/src/main/resources/kotlin-spring/springdocDocumentationConfig.mustache +++ b/modules/openapi-generator/src/main/resources/kotlin-spring/springdocDocumentationConfig.mustache @@ -18,34 +18,34 @@ class SpringDocConfiguration { return OpenAPI() .info( Info(){{#appName}} - .title("{{appName}}"){{/appName}} - .description("{{{appDescription}}}"){{#termsOfService}} - .termsOfService("{{termsOfService}}"){{/termsOfService}}{{#openAPI}}{{#info}}{{#contact}} + .title({{#lambda.kotlinStringLiteral}}{{{appNameRaw}}}{{/lambda.kotlinStringLiteral}}){{/appName}} + .description({{#lambda.kotlinStringLiteral}}{{{unescapedAppDescription}}}{{/lambda.kotlinStringLiteral}}){{#termsOfService}} + .termsOfService({{#lambda.kotlinStringLiteral}}{{{termsOfServiceRaw}}}{{/lambda.kotlinStringLiteral}}){{/termsOfService}}{{#openAPI}}{{#info}}{{#contact}} .contact( Contact(){{#infoName}} - .name("{{infoName}}"){{/infoName}}{{#infoUrl}} - .url("{{infoUrl}}"){{/infoUrl}}{{#infoEmail}} - .email("{{infoEmail}}"){{/infoEmail}} + .name({{#lambda.kotlinStringLiteral}}{{{infoNameRaw}}}{{/lambda.kotlinStringLiteral}}){{/infoName}}{{#infoUrl}} + .url({{#lambda.kotlinStringLiteral}}{{{infoUrlRaw}}}{{/lambda.kotlinStringLiteral}}){{/infoUrl}}{{#infoEmail}} + .email({{#lambda.kotlinStringLiteral}}{{{infoEmailRaw}}}{{/lambda.kotlinStringLiteral}}){{/infoEmail}} ){{/contact}}{{#license}} .license( License() - {{#licenseInfo}}.name("{{licenseInfo}}") - {{/licenseInfo}}{{#licenseUrl}}.url("{{licenseUrl}}") + {{#licenseInfo}}.name({{#lambda.kotlinStringLiteral}}{{{licenseInfoRaw}}}{{/lambda.kotlinStringLiteral}}) + {{/licenseInfo}}{{#licenseUrl}}.url({{#lambda.kotlinStringLiteral}}{{{licenseUrlRaw}}}{{/lambda.kotlinStringLiteral}}) {{/licenseUrl}} ){{/license}}{{/info}}{{/openAPI}} - .version("{{appVersion}}") + .version({{#lambda.kotlinStringLiteral}}{{{appVersionRaw}}}{{/lambda.kotlinStringLiteral}}) ){{#hasAuthMethods}} .components( Components(){{#authMethods}} - .addSecuritySchemes("{{name}}", SecurityScheme(){{#isBasic}} + .addSecuritySchemes({{#lambda.kotlinStringLiteral}}{{{name}}}{{/lambda.kotlinStringLiteral}}, SecurityScheme(){{#isBasic}} .type(SecurityScheme.Type.HTTP) - .scheme("{{scheme}}"){{#bearerFormat}} - .bearerFormat("{{bearerFormat}}"){{/bearerFormat}}{{/isBasic}}{{#isApiKey}} + .scheme({{#lambda.kotlinStringLiteral}}{{{scheme}}}{{/lambda.kotlinStringLiteral}}){{#bearerFormat}} + .bearerFormat({{#lambda.kotlinStringLiteral}}{{{bearerFormat}}}{{/lambda.kotlinStringLiteral}}){{/bearerFormat}}{{/isBasic}}{{#isApiKey}} .type(SecurityScheme.Type.APIKEY){{#isKeyInHeader}} .`in`(SecurityScheme.In.HEADER){{/isKeyInHeader}}{{#isKeyInQuery}} .`in`(SecurityScheme.In.QUERY){{/isKeyInQuery}}{{#isKeyInCookie}} .`in`(SecurityScheme.In.COOKIE){{/isKeyInCookie}} - .name("{{keyParamName}}"){{/isApiKey}}{{#isOAuth}} + .name({{#lambda.kotlinStringLiteral}}{{{keyParamName}}}{{/lambda.kotlinStringLiteral}}){{/isApiKey}}{{#isOAuth}} .type(SecurityScheme.Type.OAUTH2){{/isOAuth}} ){{/authMethods}} ){{/hasAuthMethods}} diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/spring/SpringCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/spring/SpringCodegenTest.java index 0bd582e30076..1dddac81b9af 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/spring/SpringCodegenTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/java/spring/SpringCodegenTest.java @@ -2320,6 +2320,11 @@ public void shouldGenerateOneTagAttributeForMultipleTags_Regression11464(String generator.opts(input).generate(); + Operation multipleTagsOperation = openAPI.getPaths().get("/multiple").getGet(); + assertEquals(multipleTagsOperation.getExtensions().get("x-tags"), List.of( + Map.of("tag", "tag1"), + Map.of("tag", "tag2"))); + assertFunction.accept(outputPath); } @@ -3326,6 +3331,22 @@ public void contractWithUuidEnumShouldGenerateValidEnum() throws IOException { .fileContains("private final UUID value"); } + @Test + public void arrayParameterDefaultsUseOneItemArraySchemaDefault() throws IOException { + Map output = generateFromContract( + "src/test/resources/3_0/spring/petstore-with-fake-endpoints-models-for-testing.yaml", + SPRING_BOOT); + + JavaFileAssert.assertThat(output.get("FakeApi.java")) + .fileContains( + "@param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"])", + "@param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"])", + "@param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"])", + "@RequestHeader(value = \"enum_header_string_array\", required = false, defaultValue = \"$\")", + "@RequestParam(value = \"enum_query_string_array\", required = false, defaultValue = \"$\")", + "@RequestPart(value = \"enum_form_string_array\", required = false)"); + } + @Test public void shouldUseTheSameTagNameForTheInterfaceAndTheMethod_issue11570() throws IOException { final Map output = generateFromContract( @@ -3372,6 +3393,155 @@ private Map generateFromContract(String url, String library, Map generatedFiles = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", SPRING_BOOT); + final String apiSource = Files.readString(generatedFiles.get("EscapedApi.java").toPath()); + final String formApiSource = Files.readString(generatedFiles.get("FormApi.java").toPath()); + + assertTrue(apiSource.contains("External docs &amp; <literal> */ \u002a/")); + assertFalse(apiSource.contains("Operation docs */ \\u002a/\n * @see")); + assertTrue(apiSource.contains("default to raw &amp; <tag> */ \u002a/")); + assertTrue(apiSource.contains( + "defaultValue = \"raw & */ \\\\u002a/\"")); + assertTrue(apiSource.contains("value = \"{\\\"message\\\"")); + assertTrue(formApiSource.contains("description = \"Form & \\\"quote\\\" \\\\u002a/\"")); + + final String temporalDefaults = Files.readString(generatedFiles.get("TemporalDefaults.java").toPath()); + assertTrue(temporalDefaults.contains("LocalDate.parse(\"2026-01-02\")")); + assertTrue(temporalDefaults.contains("private OffsetDateTime dateTime = OffsetDateTime.parse(\"")); + assertFalse(temporalDefaults.contains("private OffsetDateTime dateTime = \"")); + assertTrue(temporalDefaults.contains("LocalTime.parse(\"10:15:30\")")); + assertTrue(temporalDefaults.contains("LocalDateTime.parse(\"2026-01-02T03:04:05\")")); + } + + @Test + public void externalDocumentationUsesItsOwnDescriptionInEveryJavaTemplate() throws IOException { + for (String library : new String[]{SPRING_BOOT, SPRING_CLOUD_LIBRARY, SPRING_HTTP_INTERFACE}) { + Map files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", library); + assertExternalDocumentation(files.get("EscapedApi.java")); + assertJavaDocumentationEscaped(files.get("EscapedApi.java"), "Operation docs"); + } + + Map delegateProperties = new HashMap<>(); + delegateProperties.put(DELEGATE_PATTERN, true); + Map delegateFiles = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", SPRING_BOOT, delegateProperties); + assertExternalDocumentation(delegateFiles.get("EscapedApiDelegate.java")); + assertExternalDocumentationTemplate("JavaSpring/apiController.mustache"); + } + + @Test + public void javaDocumentationAndPropertyExamplesUseRawValuesInGeneratedSources() throws IOException { + Map files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", SPRING_BOOT); + assertJavaDocumentationEscaped(files.get("EscapedApi.java"), "Operation docs"); + assertJavaDocumentationEscaped(files.get("EscapedDocumentation.java"), + "Model docs", "Property docs", "Inline enum docs"); + assertJavaDocumentationEscaped(files.get("EscapedEnum.java"), + "Enum docs", "Enum value docs"); + assertTrue(Files.readString(files.get("EscapedEnum.java").toPath()) + .contains("(\"quote\\\" slash\\\\ $value\")")); + assertTrue(Files.readString(files.get("EscapedDocumentation.java").toPath()) + .contains("example = \"Property example \\\" $ \\\\u002a/\"")); + + Map delegateFiles = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", + SPRING_BOOT, + Map.of(DELEGATE_PATTERN, true)); + assertJavaDocumentationEscaped(delegateFiles.get("EscapedApiDelegate.java"), "Operation docs"); + + Map swagger1Files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", + SPRING_BOOT, + Map.of( + ANNOTATION_LIBRARY, DocumentationProviderFeatures.AnnotationLibrary.SWAGGER1.toCliOptValue(), + DOCUMENTATION_PROVIDER, DocumentationProviderFeatures.DocumentationProvider.NONE.toCliOptValue(), + USE_SPRING_BOOT3, false)); + assertTrue(Files.readString(swagger1Files.get("EscapedDocumentation.java").toPath()) + .contains("example = \"Property example \\\" $ \\\\u002a/\"")); + assertTrue(Files.readString(swagger1Files.get("EscapedApi.java").toPath()) + .contains("allowableValues = \"quote\\\" slash\\\\ $value\"")); + + Map lombokFiles = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", + SPRING_BOOT, + Map.of(AbstractJavaCodegen.ADDITIONAL_MODEL_TYPE_ANNOTATIONS, "@lombok.Data")); + assertTrue(Files.readString(lombokFiles.get("EscapedDocumentation.java").toPath()) + .contains("example = \"Property example \\\" $ \\\\u002a/\"")); + } + + private void assertJavaDocumentationEscaped(File source, String... descriptions) throws IOException { + String content = Files.readString(source.toPath()); + for (String description : descriptions) { + assertTrue(content.contains("* " + description + " */ \u002a/")); + assertFalse(content.contains("* " + description + " */ \\u002a/")); + } + } + + @Test + public void swagger1NumericEnumParameterHasOneDefaultValueAttribute() throws IOException { + Map properties = new HashMap<>(); + properties.put(ANNOTATION_LIBRARY, DocumentationProviderFeatures.AnnotationLibrary.SWAGGER1.toCliOptValue()); + properties.put(DOCUMENTATION_PROVIDER, DocumentationProviderFeatures.DocumentationProvider.NONE.toCliOptValue()); + properties.put(USE_SPRING_BOOT3, false); + + Map files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", SPRING_BOOT, properties); + String apiSource = Files.readString(files.get("EscapedApi.java").toPath()); + int parameterStart = apiSource.indexOf("@ApiParam(value = \"Numeric enum default\""); + int parameterEnd = apiSource.indexOf("@RequestParam", parameterStart); + assertTrue(parameterStart >= 0 && parameterEnd > parameterStart); + assertEquals(apiSource.substring(parameterStart, parameterEnd).split("defaultValue = \"1\"", -1).length - 1, 1); + assertTrue(Files.readString(files.get("FormApi.java").toPath()).contains("defaultValue = \"form default\"")); + } + + @Test + public void jacksonWireNamesUseJavaSourceLiteralsIncludingXmlAnnotations() throws IOException { + Map files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", + SPRING_BOOT, + Map.of(CodegenConstants.WITH_XML, true)); + String source = Files.readString(files.get("WireNames.java").toPath()); + + assertTrue(source.contains("@JsonProperty(\"wire&\\\"\\\\name\")")); + assertTrue(source.contains( + "@JacksonXmlProperty(localName = \"element&\\\"\\\\name\", namespace = \"urn:wire&\\\"\\\\namespace\")")); + assertTrue(source.contains( + "@JacksonXmlProperty(localName = \"item&\\\"\\\\name\", namespace = \"urn:wrapper&\\\"\\\\namespace\")")); + assertTrue(source.contains( + "@JacksonXmlElementWrapper(localName = \"wrapper&\\\"\\\\name\", namespace = \"urn:wrapper&\\\"\\\\namespace\", useWrapping = true)")); + assertTrue(source.contains( + "@XmlElement(name = \"element&\\\"\\\\name\", namespace = \"urn:wire&\\\"\\\\namespace\")")); + assertTrue(source.contains( + "@XmlElementWrapper(name = \"wrapper&\\\"\\\\name\", namespace = \"urn:wrapper&\\\"\\\\namespace\")")); + } + + @Test + public void swagger2SecurityRequirementUsesJavaSourceLiterals() throws IOException { + Map files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", SPRING_BOOT); + String source = Files.readString(files.get("EscapedApi.java").toPath()); + + assertTrue(source.contains( + "@SecurityRequirement(name = \"oauth&\\\"\\\\name\", scopes={ \"scope&\\\"\\\\name\" })")); + } + + private void assertExternalDocumentation(File source) throws IOException { + String content = Files.readString(source.toPath()); + assertTrue(content.contains("External docs &amp; <literal> */ \u002a/")); + assertTrue(content.contains("External docs &amp; <literal> */ \u002a/")); + assertFalse(content.contains("Operation docs */ \u002a/\n * @see")); + } + + private void assertExternalDocumentationTemplate(String template) throws IOException { + String content = Files.readString(Paths.get("src/main/resources", template)); + assertTrue(content.contains("{{#lambda.javaDocText}}{{{description}}}{{/lambda.javaDocText}}")); + assertTrue(content.contains("{{#unescapedNotes}}\n * {{#lambda.javaDocText}}{{{.}}}{{/lambda.javaDocText}}")); + } + /** * Generate the contract with additional configuration. *

@@ -5226,7 +5396,7 @@ public void multiLineOperationDescription() throws IOException { Map files = generateFromContract("src/test/resources/3_0/spring/issue12474-multiline-description.yaml", SPRING_BOOT, additionalProperties); - String expectedDescription = "# Multi-line descriptions This is an example of a multi-line description. It: - has multiple lines - uses Markdown (CommonMark) for rich text representation"; + String expectedDescription = "description = \"# Multi-line descriptions\\n\\nThis is an example of a multi-line description.\\n\\nIt:\\n- has multiple lines\\n- uses Markdown (CommonMark) for rich text representation\""; JavaFileAssert.assertThat(files.get("PingTagApi.java")) .fileContains(expectedDescription); } @@ -5241,7 +5411,7 @@ public void multiLineTagDescription() throws IOException { Map files = generateFromContract("src/test/resources/3_0/spring/issue12474-multiline-description.yaml", SPRING_BOOT, additionalProperties); JavaFileAssert.assertThat(files.get("PingTagApi.java")) - .fileContains("This is a multine tag : * tag item 1 * tag item 2 "); + .fileContains("This is a multine tag :\\n* tag item 1\\n* tag item 2\\n"); } @Test @@ -9173,12 +9343,12 @@ void testStringQuotesInTags_Issue22629() throws IOException { // 1. Verify the @Tag annotations have escaped double quotes, backslashes, and newlines assertFileContains(endpoint1ApiFile.toPath(), "name = \"My \\\"quoted\\\" api\""); assertFileContains(endpoint2ApiFile.toPath(), "name = \"My\\\\backslash\\\\api\""); - assertFileContains(endpoint3ApiFile.toPath(), "name = \"My newline api\""); + assertFileContains(endpoint3ApiFile.toPath(), "name = \"My\\nnewline\\napi\""); // 2. Verify the @Operation tags attributes have escaped double quotes, backslashes, and newlines assertFileContains(endpoint1ApiFile.toPath(), "tags = { \"My \\\"quoted\\\" api\" }"); assertFileContains(endpoint2ApiFile.toPath(), "tags = { \"My\\\\backslash\\\\api\" }"); - assertFileContains(endpoint3ApiFile.toPath(), "tags = { \"My newline api\" }"); + assertFileContains(endpoint3ApiFile.toPath(), "tags = { \"My\\nnewline\\napi\" }"); } @Test diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/kotlin/spring/KotlinSpringServerCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/kotlin/spring/KotlinSpringServerCodegenTest.java index 7671d2683121..25c907dcebf2 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/kotlin/spring/KotlinSpringServerCodegenTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/kotlin/spring/KotlinSpringServerCodegenTest.java @@ -817,13 +817,13 @@ private static void testMultiLineOperationDescription(final boolean isInterfaceO assertFileContains( Paths.get( outputPath + "/src/main/kotlin/org/openapitools/api/" + pingApiFileName), - "description = \"\"\"# Multi-line descriptions\n" - + "\n" - + "This is an example of a multi-line description.\n" - + "\n" - + "It:\n" - + "- has multiple lines\n" - + "- uses Markdown (CommonMark) for rich text representation\"\"\"" + "description = \"# Multi-line descriptions\\n" + + "\\n" + + "This is an example of a multi-line description.\\n" + + "\\n" + + "It:\\n" + + "- has multiple lines\\n" + + "- uses Markdown (CommonMark) for rich text representation\"" ); } @@ -4482,6 +4482,103 @@ public void declarativeReactorArrayOfStringReturnsMonoResponseEntity() throws Ex "kotlin.collections.Set<", "Mono files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml"); + + assertFileContains(files.get("RequiredDecimal.kt").toPath(), "BigDecimal(\"12.34\")"); + assertFileContains(files.get("OptionalDecimal.kt").toPath(), "BigDecimal(\"56.78\")"); + assertFileContains(files.get("FormFeed.kt").toPath(), "description = \"form feed \\u000c\""); + assertFileContains(files.get("EscapedApiController.kt").toPath(), + "defaultValue = \"raw & */ \\\\u002a/\""); + assertFileContains(files.get("FormApiController.kt").toPath(), + "description = \"Form & \\\"quote\\\" \\\\u002a/\""); + assertFileContains(files.get("EscapedEnum.kt").toPath(), + "(\"quote\\\" slash\\\\ \\$value\")"); + assertFileContains(files.get("EscapedApiController.kt").toPath(), + "allowableValues = [\"quote\\\" slash\\\\ \\$value\"]"); + + Map serviceFiles = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", + Map.of(SERVICE_INTERFACE, true)); + assertFileContains(serviceFiles.get("FormApiService.kt").toPath(), + "@param defaulted Form default (optional, OpenAPI schema default to form default)"); + } + + @Test + public void serviceExternalDocumentationUsesItsOwnDescription() throws IOException { + Map files = generateFromContract( + "src/test/resources/3_0/spring/escaping-regressions.yaml", + Map.of(SERVICE_INTERFACE, true)); + String serviceSource = Files.readString(files.get("EscapedApiService.kt").toPath()); + + Assert.assertTrue(serviceSource.contains("External docs &amp; <literal> */ \u002a/")); + Assert.assertFalse(serviceSource.contains("Operation docs */ \u002a/\n * @see")); + + Map rawPathFiles = generateFromContract( + "src/test/resources/3_0/spring/kotlin-escaping-regressions.yaml", + Map.of(SERVICE_INTERFACE, true)); + assertFileContains(rawPathFiles.get("KdocU002aApiService.kt").toPath(), + "* GET /kdoc-\u002a/"); + } + + @Test + public void kotlinSourceLiteralsEscapePathsContextPathsAndOAuthAnnotations() throws IOException { + final String input = "src/test/resources/3_0/spring/kotlin-escaping-regressions.yaml"; + + Map controllerFiles = generateFromContract(input); + assertKotlinEscapedPaths(controllerFiles.get("EscapingApiController.kt")); + assertFileContains(controllerFiles.get("EscapingApiController.kt").toPath(), + "SecurityRequirement(name = \"oauth\\$\\\"name\", scopes = [ \"scope\\$\\\"name\" ])"); + assertFileContains(controllerFiles.get("UriDefault.kt").toPath(), + "URI.create(\"https://example.test/\\$uri\")"); + assertFileContains(controllerFiles.get("SpringDocConfiguration.kt").toPath(), + ".title(\"Kotlin \\$ & \\\" \\\\ title\")", + ".description(\"Description \\$ & \\\" \\\\ details\")", + ".termsOfService(\"https://example.test/\\$terms?value=one&two\")", + ".name(\"Contact \\$ & \\\" \\\\ name\")", + ".url(\"https://example.test/\\$contact\")", + ".email(\"contact\\$@example.test\")", + ".name(\"License \\$ & \\\" \\\\ name\")", + ".url(\"https://example.test/\\$license\")", + ".version(\"1.0.\\$version\")", + ".addSecuritySchemes(\"oauth\\$\\\"name\", SecurityScheme()"); + + Map interfaceFiles = generateFromContract(input, Map.of( + INTERFACE_ONLY, true, + REQUEST_MAPPING_OPTION, KotlinSpringServerCodegen.RequestMappingMode.api_interface)); + assertKotlinEscapedPaths(interfaceFiles.get("EscapingApi.kt")); + + Map controllerWrapperFiles = generateFromContract(input, Map.of( + DELEGATE_PATTERN, true, + REQUEST_MAPPING_OPTION, KotlinSpringServerCodegen.RequestMappingMode.controller)); + assertFileContains(controllerWrapperFiles.get("EscapingApiController.kt").toPath(), + "@RequestMapping(\"\\${api.base-path:/server-\\$context}\")", + "const val BASE_PATH: String = \"/server-\\$context\""); + + Map swagger1Files = generateFromContract(input, Map.of( + INTERFACE_ONLY, true, + ANNOTATION_LIBRARY, AnnotationLibrary.SWAGGER1.toCliOptValue(), + DOCUMENTATION_PROVIDER, DocumentationProvider.NONE.toCliOptValue())); + assertFileContains(swagger1Files.get("EscapingApi.kt").toPath(), + "Authorization(value = \"oauth\\$\\\"name\", scopes = [AuthorizationScope(scope = \"scope\\$\\\"name\", description = \"Scope description \\$ \\\" \\\\u002a/\")])"); + + Map declarativeFiles = generateFromContract(input, new HashMap<>(), new HashMap<>(), + configurator -> configurator.setLibrary(SPRING_DECLARATIVE_HTTP_INTERFACE_LIBRARY)); + Path declarativeApi = declarativeFiles.get("EscapingApi.kt").toPath(); + assertFileContains(declarativeApi, + "const val BASE_PATH: String = \"/server-\\$context\"", + "const val PATH_ESCAPED: String = \"/escaping/operations-\\$path\""); + } + + private void assertKotlinEscapedPaths(File source) throws IOException { + assertFileContains(source.toPath(), + "@RequestMapping(\"\\${api.base-path:/server-\\$context}\")", + "const val BASE_PATH: String = \"/server-\\$context\"", + "const val PATH_ESCAPED: String = \"/escaping/operations-\\$path\""); + } + private Map generateFromContract(String url) throws IOException { return generateFromContract(url, new HashMap<>(), new HashMap<>()); } diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/php/PhpModelTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/php/PhpModelTest.java index 4328e2037312..bce9a2707d7a 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/php/PhpModelTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/php/PhpModelTest.java @@ -314,10 +314,12 @@ public void enumArrayModelTest() { HashMap fish = new HashMap(); fish.put("name", "FISH"); fish.put("value", "\'fish\'"); + fish.put("valueRaw", "fish"); fish.put("isString", true); HashMap crab = new HashMap(); crab.put("name", "CRAB"); crab.put("value", "\'crab\'"); + crab.put("valueRaw", "crab"); crab.put("isString", true); Assert.assertEquals(prope.allowableValues.get("enumVars"), Arrays.asList(fish, crab)); @@ -350,10 +352,12 @@ public void enumModelValueTest() { HashMap one = new HashMap(); one.put("name", "NUMBER_1"); one.put("value", "1"); + one.put("valueRaw", "1"); one.put("isString", false); HashMap minusOne = new HashMap(); minusOne.put("name", "MINUS_1"); minusOne.put("value", "-1"); + minusOne.put("valueRaw", "-1"); minusOne.put("isString", false); Assert.assertEquals(prope.allowableValues.get("enumVars"), Arrays.asList(one, minusOne)); } diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/rust/RustServerCodegenTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/rust/RustServerCodegenTest.java index ff3bf2c9b829..73a63541e1e0 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/rust/RustServerCodegenTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/rust/RustServerCodegenTest.java @@ -110,6 +110,10 @@ public void testRequiredQueryParamWithoutExampleDisablesClientExample() throws I TestUtils.assertFileContains(exampleClientMain, "Disabled because there's no example."); TestUtils.assertFileContains(exampleClientMain, "Some(\"QueryExampleGet\")"); + Path clientModPath = Path.of(target.toString(), "/src/client/mod.rs"); + TestUtils.assertFileExists(clientModPath); + TestUtils.assertFileContains(clientModPath, "¶m_uuid.to_string()"); + // Clean up target.toFile().deleteOnExit(); } diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/templating/SourceStringEscaperTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/templating/SourceStringEscaperTest.java new file mode 100644 index 000000000000..fc09d456d7f6 --- /dev/null +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/templating/SourceStringEscaperTest.java @@ -0,0 +1,36 @@ +package org.openapitools.codegen.templating; + +import org.testng.annotations.Test; + +import static org.testng.Assert.assertEquals; + +public class SourceStringEscaperTest { + @Test + public void javaLiteralPreservesControlCharactersAndBackslashes() { + assertEquals(SourceStringEscaper.javaStringLiteral("quote \" slash \\ line\nliteral\\n"), + "\"quote \\\" slash \\\\ line\\nliteral\\\\n\""); + } + + @Test + public void kotlinLiteralEscapesInterpolationCharacters() { + assertEquals(SourceStringEscaper.kotlinStringLiteral("$name ${value} \" \\ \t"), + "\"\\$name \\${value} \\\" \\\\ \\t\""); + } + + @Test + public void kotlinLiteralUsesUnicodeEscapeForFormFeed() { + assertEquals(SourceStringEscaper.kotlinStringLiteral("form\ffeed"), + "\"form\\u000cfeed\""); + } + + @Test + public void documentationProtectsCommentDelimitersUnicodeEscapesAndLiteralHtml() { + assertEquals(SourceStringEscaper.docText("first\n/* data */ \\u002a/ & {@code text}\n@return last"), + "first\n * /* data */ \u002a/ &amp; <tag> {@code text}\n * @return last"); + } + + @Test + public void documentationTrimsTrailingWhitespace() { + assertEquals(SourceStringEscaper.docText("description\n \t\r\n"), "description"); + } +} diff --git a/modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/fetch/TypeScriptFetchModelTest.java b/modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/fetch/TypeScriptFetchModelTest.java index 1795a90ef938..97568222b83b 100644 --- a/modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/fetch/TypeScriptFetchModelTest.java +++ b/modules/openapi-generator/src/test/java/org/openapitools/codegen/typescript/fetch/TypeScriptFetchModelTest.java @@ -383,10 +383,12 @@ public void enumArrayModelTest() { HashMap fish = new HashMap(); fish.put("name", "Fish"); fish.put("value", "'fish'"); + fish.put("valueRaw", "fish"); fish.put("isString", false); HashMap crab = new HashMap(); crab.put("name", "Crab"); crab.put("value", "'crab'"); + crab.put("valueRaw", "crab"); crab.put("isString", false); Assert.assertEquals(prope.allowableValues.get("enumVars"), Arrays.asList(fish, crab)); @@ -423,10 +425,12 @@ public void enumModelValueTest() { HashMap one = new HashMap(); one.put("name", "NUMBER_1"); one.put("value", "1"); + one.put("valueRaw", "1"); one.put("isString", false); HashMap minusOne = new HashMap(); minusOne.put("name", "NUMBER_MINUS_1"); minusOne.put("value", "-1"); + minusOne.put("valueRaw", "-1"); minusOne.put("isString", false); Assert.assertEquals(prope.allowableValues.get("enumVars"), Arrays.asList(one, minusOne)); diff --git a/modules/openapi-generator/src/test/resources/3_0/spring/escaping-regressions.yaml b/modules/openapi-generator/src/test/resources/3_0/spring/escaping-regressions.yaml new file mode 100644 index 000000000000..85a9a7de5863 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/3_0/spring/escaping-regressions.yaml @@ -0,0 +1,170 @@ +openapi: 3.0.3 +info: + title: Escaping regressions + version: 1.0.0 +security: + - 'oauth&"\name': + - 'scope&"\name' +paths: + /escaped: + get: + tags: + - escaped + summary: Operation summary + description: 'Operation docs */ \u002a/' + operationId: escaped + externalDocs: + description: 'External docs & */ \u002a/' + url: 'https://example.test/docs?value=\u002a/' + parameters: + - name: cookie + in: cookie + required: false + description: Cookie description + schema: + allOf: + - $ref: '#/components/schemas/CookieText' + default: 'raw & */ \u002a/' + - name: numericEnum + in: query + required: false + description: Numeric enum default + schema: + type: number + enum: + - 1 + - 2 + default: 1 + - name: stringEnum + in: query + required: false + description: String enum + schema: + type: string + enum: + - 'quote" slash\ $value' + responses: + '200': + description: Response description + content: + application/json: + schema: + type: object + examples: + escapedExample: + value: + message: 'quote " and slash \' + /form: + post: + tags: + - escaped + operationId: escapedForm + requestBody: + required: true + content: + application/x-www-form-urlencoded: + schema: + type: object + required: + - text + properties: + text: + type: string + description: 'Form & "quote" \u002a/' + defaulted: + type: string + description: Form default + default: form default + responses: + '204': + description: Form accepted +components: + securitySchemes: + 'oauth&"\name': + type: oauth2 + flows: + clientCredentials: + tokenUrl: https://example.test/token + scopes: + 'scope&"\name': Security scope + schemas: + CookieText: + type: string + RequiredDecimal: + type: object + required: + - amount + properties: + amount: + type: number + default: 12.34 + OptionalDecimal: + type: object + properties: + amount: + type: number + default: 56.78 + FormFeed: + type: object + properties: + value: + type: string + description: "form feed \f" + WireNames: + type: object + properties: + 'wire&"\name': + type: string + xml: + name: 'element&"\name' + namespace: 'urn:wire&"\namespace' + 'wrapped&"\name': + type: array + xml: + name: 'wrapper&"\name' + namespace: 'urn:wrapper&"\namespace' + wrapped: true + items: + type: string + xml: + name: 'item&"\name' + EscapedDocumentation: + type: object + description: 'Model docs */ \u002a/' + properties: + text: + type: string + description: 'Property docs */ \u002a/' + example: 'Property example " $ \u002a/' + inline: + type: string + enum: + - inline + x-enum-descriptions: + - 'Inline enum docs */ \u002a/' + EscapedEnum: + type: string + description: 'Enum docs */ \u002a/' + enum: + - 'quote" slash\ $value' + x-enum-descriptions: + - 'Enum value docs */ \u002a/' + TemporalDefaults: + type: object + properties: + date: + type: string + format: date + default: '2026-01-02' + dateTime: + type: string + format: date-time + default: '2026-01-02T03:04:05Z' + localTime: + type: string + format: time-local + default: '10:15:30' + localDateTime: + type: string + format: date-time-local + default: '2026-01-02T03:04:05' diff --git a/modules/openapi-generator/src/test/resources/3_0/spring/kotlin-escaping-regressions.yaml b/modules/openapi-generator/src/test/resources/3_0/spring/kotlin-escaping-regressions.yaml new file mode 100644 index 000000000000..3e3d53a2eb88 --- /dev/null +++ b/modules/openapi-generator/src/test/resources/3_0/spring/kotlin-escaping-regressions.yaml @@ -0,0 +1,52 @@ +openapi: 3.0.3 +info: + title: 'Kotlin $ & " \ title' + description: 'Description $ & " \ details' + termsOfService: 'https://example.test/$terms?value=one&two' + contact: + name: 'Contact $ & " \ name' + url: 'https://example.test/$contact' + email: 'contact$@example.test' + license: + name: 'License $ & " \ name' + url: 'https://example.test/$license' + version: '1.0.$version' +servers: + - url: /server-$context +security: + - 'oauth$"name': + - 'scope$"name' +paths: + /escaping/operations-$path: + get: + tags: + - escaping + operationId: escaped + responses: + '204': + description: No content + '/kdoc-\u002a/': + get: + tags: + - escaping + operationId: escapedKdoc + responses: + '204': + description: No content +components: + securitySchemes: + 'oauth$"name': + type: oauth2 + flows: + clientCredentials: + tokenUrl: https://example.test/token + scopes: + 'scope$"name': 'Scope description $ " \u002a/' + schemas: + UriDefault: + type: object + properties: + value: + type: string + format: uri + default: 'https://example.test/$uri' diff --git a/modules/openapi-generator/src/test/resources/3_0/spring/petstore-with-fake-endpoints-models-for-testing.yaml b/modules/openapi-generator/src/test/resources/3_0/spring/petstore-with-fake-endpoints-models-for-testing.yaml index 29aa9b9a1056..d0674ede90aa 100644 --- a/modules/openapi-generator/src/test/resources/3_0/spring/petstore-with-fake-endpoints-models-for-testing.yaml +++ b/modules/openapi-generator/src/test/resources/3_0/spring/petstore-with-fake-endpoints-models-for-testing.yaml @@ -579,9 +579,10 @@ paths: description: Header parameter enum test (string array) schema: type: array + default: + - $ items: type: string - default: $ enum: - ">" - $ @@ -600,9 +601,10 @@ paths: description: Query parameter enum test (string array) schema: type: array + default: + - $ items: type: string - default: $ enum: - ">" - $ @@ -643,9 +645,10 @@ paths: enum_form_string_array: description: Form parameter enum test (string array) type: array + default: + - $ items: type: string - default: $ enum: - ">" - $ @@ -1013,7 +1016,7 @@ paths: put: tags: - fake - description: For this test, the body for this request much reference a schema named + description: For this test, the body for this request must reference a schema named `File`. operationId: testBodyWithFileSchema requestBody: diff --git a/samples/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java b/samples/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java index 8c1998ebd3b1..b33fea452788 100644 --- a/samples/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java +++ b/samples/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java @@ -72,7 +72,7 @@ ResponseEntity get( * update with form data * * @param date A date path parameter (required) - * @param visitDate Updated last visit timestamp (optional, default to 1971-12-19T03:39:57-08:00) + * @param visitDate Updated last visit timestamp (optional, OpenAPI schema default to 1971-12-19T03:39:57-08:00) * @return Invalid input (status code 405) */ @Operation( diff --git a/samples/client/petstore/spring-cloud-deprecated/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-cloud-deprecated/src/main/java/org/openapitools/api/StoreApi.java index 0ff000a1ac60..4cc780b08f57 100644 --- a/samples/client/petstore/spring-cloud-deprecated/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-cloud-deprecated/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/PetApi.java b/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/PetApi.java index 0930fd851726..93da5b2f23b7 100644 --- a/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/PetApi.java @@ -225,7 +225,7 @@ ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/StoreApi.java index 0ff000a1ac60..4cc780b08f57 100644 --- a/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-cloud-feign-without-url/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-cloud-tags/src/main/java/org/openapitools/api/StoreController.java b/samples/client/petstore/spring-cloud-tags/src/main/java/org/openapitools/api/StoreController.java index 7dfa47a6898a..ccdae0f18fdd 100644 --- a/samples/client/petstore/spring-cloud-tags/src/main/java/org/openapitools/api/StoreController.java +++ b/samples/client/petstore/spring-cloud-tags/src/main/java/org/openapitools/api/StoreController.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java b/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java index 0930fd851726..93da5b2f23b7 100644 --- a/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java @@ -225,7 +225,7 @@ ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java index 0ff000a1ac60..4cc780b08f57 100644 --- a/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/FakeApi.java index a089293ed3f8..b4906efeb06c 100644 --- a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/FakeApi.java @@ -127,7 +127,7 @@ ResponseEntity fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClassDto (required) * @return Success (status code 200) @@ -163,8 +163,8 @@ ResponseEntity testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param clientDto client model (required) * @return successful operation (status code 200) @@ -181,8 +181,14 @@ ResponseEntity testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -229,14 +235,14 @@ ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -247,9 +253,9 @@ ResponseEntity testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) ResponseEntity testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/StoreApi.java index 3cc149bde388..ff29654dcd74 100644 --- a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/api/StoreApi.java @@ -61,7 +61,7 @@ ResponseEntity> getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/CapitalizationDto.java b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/CapitalizationDto.java index 9b32e4d6cb2a..53a0745ae428 100644 --- a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/CapitalizationDto.java +++ b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/CapitalizationDto.java @@ -148,7 +148,7 @@ public CapitalizationDto ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/ClassModelDto.java b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/ClassModelDto.java index c3e1017cbb97..11c940fb1ada 100644 --- a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/ClassModelDto.java +++ b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/ClassModelDto.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @JsonTypeName("ClassModel") diff --git a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/FileDto.java b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/FileDto.java index 651fd4f66507..c2cec4b9e7a0 100644 --- a/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/FileDto.java +++ b/samples/client/petstore/spring-http-interface-bean-validation/src/main/java/org/openapitools/model/FileDto.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @JsonTypeName("File") diff --git a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java index debb7ecc8f66..f48c538e782a 100644 --- a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java @@ -129,7 +129,7 @@ String fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClassDto (required) * @return Success (status code 200) @@ -167,8 +167,8 @@ void testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param clientDto client model (required) * @return successful operation (status code 200) @@ -186,8 +186,14 @@ ClientDto testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -235,14 +241,14 @@ void testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -254,9 +260,9 @@ void testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) void testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java index 3aa621eff85d..4b66592ba663 100644 --- a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java @@ -60,7 +60,7 @@ Map getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/CapitalizationDto.java b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/CapitalizationDto.java index f9a81f870652..23d0f828ca3b 100644 --- a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/CapitalizationDto.java +++ b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/CapitalizationDto.java @@ -147,7 +147,7 @@ public CapitalizationDto ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/ClassModelDto.java b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/ClassModelDto.java index 7110ac2123bc..77272617d274 100644 --- a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/ClassModelDto.java +++ b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/ClassModelDto.java @@ -16,7 +16,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @JsonTypeName("ClassModel") diff --git a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/FileDto.java b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/FileDto.java index 9d65f9b55d10..48f726ceedf1 100644 --- a/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/FileDto.java +++ b/samples/client/petstore/spring-http-interface-noResponseEntity/src/main/java/org/openapitools/model/FileDto.java @@ -16,7 +16,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @JsonTypeName("File") diff --git a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/FakeApi.java index 066620ff21e3..995845c6036c 100644 --- a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/FakeApi.java @@ -131,7 +131,7 @@ Mono> fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -167,8 +167,8 @@ Mono> testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -185,8 +185,14 @@ Mono> testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -233,14 +239,14 @@ Mono> testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -251,9 +257,9 @@ Mono> testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) Mono> testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/StoreApi.java index 4d8d5cee2118..ec0fbb307a37 100644 --- a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/api/StoreApi.java @@ -65,7 +65,7 @@ Mono>> getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/Capitalization.java b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/Capitalization.java index f314f7cb0b33..803bc9a51983 100644 --- a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/Capitalization.java @@ -146,7 +146,7 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/ClassModel.java b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/ClassModel.java index 872f68d89b0c..3e503a43553c 100644 --- a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/ClassModel.java @@ -16,7 +16,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/File.java b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/File.java index dcf444fe1993..609e56f2c7e7 100644 --- a/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/File.java +++ b/samples/client/petstore/spring-http-interface-reactive-bean-validation/src/main/java/org/openapitools/model/File.java @@ -16,7 +16,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java index d0056903871a..abda5f8cb83d 100644 --- a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java @@ -133,7 +133,7 @@ Mono fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -171,8 +171,8 @@ Mono testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -190,8 +190,14 @@ Mono testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -239,14 +245,14 @@ Mono testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -258,9 +264,9 @@ Mono testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) Mono testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java index 397e809ee6b3..73f37b7bc793 100644 --- a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java @@ -64,7 +64,7 @@ Mono> getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java index 5edb0c2d356b..6c7e0d92e83c 100644 --- a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java @@ -145,7 +145,7 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java index cfb8efd12d05..93f56b58e018 100644 --- a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java @@ -15,7 +15,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java index 5030119322bd..c6893d582e0b 100644 --- a/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java +++ b/samples/client/petstore/spring-http-interface-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java @@ -15,7 +15,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/FakeApi.java index af75ee77bd9c..1670a44c5ffa 100644 --- a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/FakeApi.java @@ -128,7 +128,7 @@ Mono> fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -164,8 +164,8 @@ Mono> testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -182,8 +182,14 @@ Mono> testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -230,14 +236,14 @@ Mono> testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -248,9 +254,9 @@ Mono> testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) Mono> testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/StoreApi.java index 764c066b6a51..fd42983b8d6c 100644 --- a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/api/StoreApi.java @@ -62,7 +62,7 @@ Mono>> getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/Capitalization.java b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/Capitalization.java index 5edb0c2d356b..6c7e0d92e83c 100644 --- a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/Capitalization.java @@ -145,7 +145,7 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/ClassModel.java b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/ClassModel.java index cfb8efd12d05..93f56b58e018 100644 --- a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/ClassModel.java @@ -15,7 +15,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/File.java b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/File.java index 5030119322bd..c6893d582e0b 100644 --- a/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/File.java +++ b/samples/client/petstore/spring-http-interface-reactive/src/main/java/org/openapitools/model/File.java @@ -15,7 +15,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/FakeApi.java index a089293ed3f8..b4906efeb06c 100644 --- a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/FakeApi.java @@ -127,7 +127,7 @@ ResponseEntity fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClassDto (required) * @return Success (status code 200) @@ -163,8 +163,8 @@ ResponseEntity testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param clientDto client model (required) * @return successful operation (status code 200) @@ -181,8 +181,14 @@ ResponseEntity testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -229,14 +235,14 @@ ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -247,9 +253,9 @@ ResponseEntity testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) ResponseEntity testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/StoreApi.java index 3cc149bde388..ff29654dcd74 100644 --- a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/api/StoreApi.java @@ -61,7 +61,7 @@ ResponseEntity> getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/CapitalizationDto.java b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/CapitalizationDto.java index ddb7d6381884..5eeb4afaefde 100644 --- a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/CapitalizationDto.java +++ b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/CapitalizationDto.java @@ -156,7 +156,7 @@ public CapitalizationDto ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/ClassModelDto.java b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/ClassModelDto.java index cfa0c871563d..47a188d4dcde 100644 --- a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/ClassModelDto.java +++ b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/ClassModelDto.java @@ -19,7 +19,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @JsonTypeName("ClassModel") diff --git a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/FileDto.java b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/FileDto.java index 016252a262c7..9c6664ecf332 100644 --- a/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/FileDto.java +++ b/samples/client/petstore/spring-http-interface-springboot-4/src/main/java/org/openapitools/model/FileDto.java @@ -19,7 +19,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @JsonTypeName("File") diff --git a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/FakeApi.java index d8898d654c99..cd560be933ef 100644 --- a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/FakeApi.java @@ -127,7 +127,7 @@ ResponseEntity fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -163,8 +163,8 @@ ResponseEntity testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -181,8 +181,14 @@ ResponseEntity testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -229,14 +235,14 @@ ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -247,9 +253,9 @@ ResponseEntity testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) ResponseEntity testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/StoreApi.java index a9f9812fcc4b..add62449b13a 100644 --- a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/api/StoreApi.java @@ -61,7 +61,7 @@ ResponseEntity> getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/Capitalization.java b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/Capitalization.java index a61b4ba33db2..ca3f22a6daf9 100644 --- a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/Capitalization.java @@ -147,7 +147,7 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/ClassModel.java b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/ClassModel.java index 57bf5d121e95..811ce57b28af 100644 --- a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/File.java b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/File.java index 09504641c88d..c1599c58e6b9 100644 --- a/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/File.java +++ b/samples/client/petstore/spring-http-interface-useHttpServiceProxyFactoryInterfacesConfigurator/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Generated(value = "org.openapitools.codegen.languages.SpringCodegen", comments = "Generator version: 7.26.0-SNAPSHOT") diff --git a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/FakeApi.java b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/FakeApi.java index a617a642bae4..976ee81c9d23 100644 --- a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/FakeApi.java @@ -124,7 +124,7 @@ ResponseEntity fakeOuterStringSerialize( /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClassDto (required) * @return Success (status code 200) @@ -160,8 +160,8 @@ ResponseEntity testBodyWithQueryParams( /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param clientDto client model (required) * @return successful operation (status code 200) @@ -178,8 +178,14 @@ ResponseEntity testClientModel( /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -226,14 +232,14 @@ ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -244,9 +250,9 @@ ResponseEntity testEndpointParameters( contentType = "application/x-www-form-urlencoded" ) ResponseEntity testEnumParameters( - @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/StoreApi.java b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/StoreApi.java index e246b9a10964..6824fd543a3f 100644 --- a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/api/StoreApi.java @@ -58,7 +58,7 @@ ResponseEntity> getInventory( /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/CapitalizationDto.java b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/CapitalizationDto.java index f9a81f870652..23d0f828ca3b 100644 --- a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/CapitalizationDto.java +++ b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/CapitalizationDto.java @@ -147,7 +147,7 @@ public CapitalizationDto ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ diff --git a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/ClassModelDto.java b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/ClassModelDto.java index 7110ac2123bc..77272617d274 100644 --- a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/ClassModelDto.java +++ b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/ClassModelDto.java @@ -16,7 +16,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @JsonTypeName("ClassModel") diff --git a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/FileDto.java b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/FileDto.java index 9d65f9b55d10..48f726ceedf1 100644 --- a/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/FileDto.java +++ b/samples/client/petstore/spring-http-interface/src/main/java/org/openapitools/model/FileDto.java @@ -16,7 +16,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @JsonTypeName("File") diff --git a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/AnotherFakeApi.ts b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/AnotherFakeApi.ts index cb6f1f2ad35d..005709d4eb97 100644 --- a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/AnotherFakeApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/AnotherFakeApi.ts @@ -21,7 +21,7 @@ import { export interface 123testSpecialTagsRequest { /** - * + * client model */ client: Client; } diff --git a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeApi.ts b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeApi.ts index f64fcdc89bf5..7d632ca34190 100644 --- a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeApi.ts @@ -71,7 +71,7 @@ import { export interface FakeHttpSignatureTestRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; /** @@ -86,49 +86,49 @@ export interface FakeHttpSignatureTestRequest { export interface FakeOuterBooleanSerializeRequest { /** - * + * Input boolean as post body */ body?: boolean; } export interface FakeOuterCompositeSerializeRequest { /** - * + * Input composite as post body */ outerComposite?: OuterComposite; } export interface FakeOuterNumberSerializeRequest { /** - * + * Input number as post body */ body?: number; } export interface FakeOuterStringSerializeRequest { /** - * + * Input string as post body */ body?: string; } export interface FakePropertyEnumIntegerSerializeRequest { /** - * + * Input enum (int) as post body */ outerObjectWithEnumProperty: OuterObjectWithEnumProperty; } export interface TestAdditionalPropertiesReferenceRequest { /** - * + * request body */ requestBody: { [key: string]: any; }; } export interface TestBodyWithBinaryRequest { /** - * + * image to upload */ body: Blob | null; } @@ -153,7 +153,7 @@ export interface TestBodyWithQueryParamsRequest { export interface TestClientModelRequest { /** - * + * client model */ client: Client; } @@ -285,14 +285,14 @@ export interface TestGroupParametersRequest { export interface TestInlineAdditionalPropertiesRequest { /** - * + * request body */ requestBody: { [key: string]: string; }; } export interface TestInlineFreeformAdditionalPropertiesOperationRequest { /** - * + * request body */ testInlineFreeformAdditionalPropertiesRequest: TestInlineFreeformAdditionalPropertiesRequest; } @@ -310,7 +310,7 @@ export interface TestJsonFormDataRequest { export interface TestNullableRequest { /** - * + * request body */ childWithNullable: ChildWithNullable; } @@ -348,7 +348,7 @@ export interface TestQueryParameterCollectionFormatRequest { export interface TestStringMapReferenceRequest { /** - * + * request body */ requestBody: { [key: string]: string; }; } diff --git a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeClassnameTags123Api.ts b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeClassnameTags123Api.ts index 73ea32dd8b15..839c847f84e7 100644 --- a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeClassnameTags123Api.ts +++ b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/FakeClassnameTags123Api.ts @@ -21,7 +21,7 @@ import { export interface TestClassnameRequest { /** - * + * client model */ client: Client; } diff --git a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/PetApi.ts index 022abaa2616d..6b267517ebb9 100644 --- a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } @@ -66,7 +66,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/StoreApi.ts index 97fc9123716c..1020841c1752 100644 --- a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ order: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/UserApi.ts index 9ccdec2d6745..65b80a5dc9c7 100644 --- a/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default-v3.0/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ user: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ user: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ user: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ user: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts index 08701d5f9df8..1aad04de5e05 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } @@ -65,7 +65,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts index 6ca4b778ee7b..dfd72a728d04 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts index 973e383f071b..e692ff74d2f4 100644 --- a/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/default/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ body: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/enum/docs/DefaultApi.md b/samples/client/petstore/typescript-fetch/builds/enum/docs/DefaultApi.md index 9650fa77bd97..fdde536855d1 100644 --- a/samples/client/petstore/typescript-fetch/builds/enum/docs/DefaultApi.md +++ b/samples/client/petstore/typescript-fetch/builds/enum/docs/DefaultApi.md @@ -34,7 +34,7 @@ async function example() { // 'one' | 'two' | 'three' (optional) stringEnum: stringEnum_example, // string (optional) - nullableStringEnum: ..., + nullableStringEnum: nullableStringEnum_example, // 1 | 2 | 3 (optional) numberEnum: 8.14, // number (optional) diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts index 08701d5f9df8..1aad04de5e05 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } @@ -65,7 +65,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts index 6ca4b778ee7b..dfd72a728d04 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts index 973e383f071b..e692ff74d2f4 100644 --- a/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/es6-target/src/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ body: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/another-fake-api.ts b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/another-fake-api.ts index 81593279cf15..0d33d3ac2d44 100644 --- a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/another-fake-api.ts +++ b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/another-fake-api.ts @@ -21,7 +21,7 @@ import { export interface 123testSpecialTagsRequest { /** - * + * client model */ client: Client; } diff --git a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-api.ts b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-api.ts index 290f6b63a71d..ae8b099a88ae 100644 --- a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-api.ts +++ b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-api.ts @@ -71,7 +71,7 @@ import { export interface FakeHttpSignatureTestRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; /** @@ -86,49 +86,49 @@ export interface FakeHttpSignatureTestRequest { export interface FakeOuterBooleanSerializeRequest { /** - * + * Input boolean as post body */ body?: boolean; } export interface FakeOuterCompositeSerializeRequest { /** - * + * Input composite as post body */ outerComposite?: OuterComposite; } export interface FakeOuterNumberSerializeRequest { /** - * + * Input number as post body */ body?: number; } export interface FakeOuterStringSerializeRequest { /** - * + * Input string as post body */ body?: string; } export interface FakePropertyEnumIntegerSerializeRequest { /** - * + * Input enum (int) as post body */ outerObjectWithEnumProperty: OuterObjectWithEnumProperty; } export interface TestAdditionalPropertiesReferenceRequest { /** - * + * request body */ requestBody: { [key: string]: any; }; } export interface TestBodyWithBinaryRequest { /** - * + * image to upload */ body: Blob | null; } @@ -153,7 +153,7 @@ export interface TestBodyWithQueryParamsRequest { export interface TestClientModelRequest { /** - * + * client model */ client: Client; } @@ -285,14 +285,14 @@ export interface TestGroupParametersRequest { export interface TestInlineAdditionalPropertiesRequest { /** - * + * request body */ requestBody: { [key: string]: string; }; } export interface TestInlineFreeformAdditionalPropertiesOperationRequest { /** - * + * request body */ testInlineFreeformAdditionalPropertiesRequest: TestInlineFreeformAdditionalPropertiesRequest; } @@ -310,7 +310,7 @@ export interface TestJsonFormDataRequest { export interface TestNullableRequest { /** - * + * request body */ childWithNullable: ChildWithNullable; } @@ -348,7 +348,7 @@ export interface TestQueryParameterCollectionFormatRequest { export interface TestStringMapReferenceRequest { /** - * + * request body */ requestBody: { [key: string]: string; }; } diff --git a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-classname-tags123-api.ts b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-classname-tags123-api.ts index ba644a53139b..9e628a1c3d9f 100644 --- a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-classname-tags123-api.ts +++ b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/fake-classname-tags123-api.ts @@ -21,7 +21,7 @@ import { export interface TestClassnameRequest { /** - * + * client model */ client: Client; } diff --git a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/pet-api.ts b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/pet-api.ts index 51e199a31980..921db5998165 100644 --- a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/pet-api.ts +++ b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/pet-api.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } @@ -66,7 +66,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/store-api.ts b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/store-api.ts index 18861ba50f3a..4c169647f18c 100644 --- a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/store-api.ts +++ b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/store-api.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ order: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/user-api.ts b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/user-api.ts index 133845c9e970..5fa2f46186c8 100644 --- a/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/user-api.ts +++ b/samples/client/petstore/typescript-fetch/builds/kebab-case/apis/user-api.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ user: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ user: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ user: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ user: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts index 90a3ddba16f6..7b6017832711 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } @@ -65,7 +65,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts index 7ad41c7209c4..c48f15d6f704 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts index e16cdb11331f..a50fab92f435 100644 --- a/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/multiple-parameters/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ body: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts index f959d1785b55..41f55cd8528f 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface PetApiAddPetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } @@ -65,7 +65,7 @@ export interface PetApiGetPetByIdRequest { export interface PetApiUpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts index e11aaccd0617..3db9acab68b0 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface StoreApiGetOrderByIdRequest { export interface StoreApiPlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts index dd7c0a9b9138..68dd8a425d5b 100644 --- a/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/prefix-parameter-interfaces/src/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface UserApiCreateUserRequest { /** - * + * Created user object */ body: User; } export interface UserApiCreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface UserApiCreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -71,7 +71,7 @@ export interface UserApiUpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/PetApi.ts index 05b3a0ff97ac..4715093ee4d2 100644 --- a/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/PetApi.ts @@ -46,7 +46,7 @@ import { export interface AddPetRequest { /** - * + * dummy category for testing */ dummyCat: Category; } @@ -106,7 +106,7 @@ export interface GetPetRegionsRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be updated in the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/StoreApi.ts index 7ad41c7209c4..c48f15d6f704 100644 --- a/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/UserApi.ts index 8f11d7ea40c5..3254e29ffbb3 100644 --- a/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/sagas-and-records/src/apis/UserApi.ts @@ -26,21 +26,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ body: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -76,7 +76,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/AnotherFakeApi.ts b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/AnotherFakeApi.ts index cb6f1f2ad35d..005709d4eb97 100644 --- a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/AnotherFakeApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/AnotherFakeApi.ts @@ -21,7 +21,7 @@ import { export interface 123testSpecialTagsRequest { /** - * + * client model */ client: Client; } diff --git a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeApi.ts b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeApi.ts index 992042979312..1bfca1422275 100644 --- a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeApi.ts @@ -61,7 +61,7 @@ import { export interface FakeHttpSignatureTestRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; /** @@ -76,42 +76,42 @@ export interface FakeHttpSignatureTestRequest { export interface FakeOuterBooleanSerializeRequest { /** - * + * Input boolean as post body */ body?: boolean; } export interface FakeOuterCompositeSerializeRequest { /** - * + * Input composite as post body */ outerComposite?: OuterComposite; } export interface FakeOuterNumberSerializeRequest { /** - * + * Input number as post body */ body?: number; } export interface FakeOuterStringSerializeRequest { /** - * + * Input string as post body */ body?: string; } export interface FakePropertyEnumIntegerSerializeRequest { /** - * + * Input enum (int) as post body */ outerObjectWithEnumProperty: OuterObjectWithEnumProperty; } export interface TestBodyWithBinaryRequest { /** - * + * image to upload */ body: Blob | null; } @@ -136,7 +136,7 @@ export interface TestBodyWithQueryParamsRequest { export interface TestClientModelRequest { /** - * + * client model */ client: Client; } @@ -268,7 +268,7 @@ export interface TestGroupParametersRequest { export interface TestInlineAdditionalPropertiesRequest { /** - * + * request body */ requestBody: { [key: string]: string; }; } diff --git a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeClassnameTags123Api.ts b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeClassnameTags123Api.ts index 73ea32dd8b15..839c847f84e7 100644 --- a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeClassnameTags123Api.ts +++ b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/FakeClassnameTags123Api.ts @@ -21,7 +21,7 @@ import { export interface TestClassnameRequest { /** - * + * client model */ client: Client; } diff --git a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/PetApi.ts index 022abaa2616d..6b267517ebb9 100644 --- a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } @@ -66,7 +66,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/StoreApi.ts index 97fc9123716c..1020841c1752 100644 --- a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ order: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/UserApi.ts index 9ccdec2d6745..65b80a5dc9c7 100644 --- a/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/snakecase-discriminator/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ user: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ user: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ user: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ user: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/PetApi.ts index 1f5737779542..570e55abc27c 100644 --- a/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } @@ -66,7 +66,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ pet: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/StoreApi.ts index 43ea23daf8d7..ff6f054af4d8 100644 --- a/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ order: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/UserApi.ts index 4dc95623fc17..877388cc99e0 100644 --- a/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/validation-attributes/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ user: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ user: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ user: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ user: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts index d1d35722ba27..5d65fe1d1337 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } @@ -65,7 +65,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts index c38e5f11bb74..98f0ce8339e1 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts index ed89e6b4ec62..6f21c3776e51 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-interfaces/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ body: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts index 08701d5f9df8..1aad04de5e05 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/PetApi.ts @@ -26,7 +26,7 @@ import { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } @@ -65,7 +65,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts index 6ca4b778ee7b..dfd72a728d04 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/StoreApi.ts @@ -35,7 +35,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts index 973e383f071b..e692ff74d2f4 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/with-npm-version/src/apis/UserApi.ts @@ -21,21 +21,21 @@ import { export interface CreateUserRequest { /** - * + * Created user object */ body: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -71,7 +71,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/client/petstore/typescript-fetch/builds/with-string-enums/docs/DefaultApi.md b/samples/client/petstore/typescript-fetch/builds/with-string-enums/docs/DefaultApi.md index 9650fa77bd97..fdde536855d1 100644 --- a/samples/client/petstore/typescript-fetch/builds/with-string-enums/docs/DefaultApi.md +++ b/samples/client/petstore/typescript-fetch/builds/with-string-enums/docs/DefaultApi.md @@ -34,7 +34,7 @@ async function example() { // 'one' | 'two' | 'three' (optional) stringEnum: stringEnum_example, // string (optional) - nullableStringEnum: ..., + nullableStringEnum: nullableStringEnum_example, // 1 | 2 | 3 (optional) numberEnum: 8.14, // number (optional) diff --git a/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/PetApi.ts b/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/PetApi.ts index 8abd817792e8..89914ac26f02 100644 --- a/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/PetApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/PetApi.ts @@ -20,7 +20,7 @@ import type { export interface AddPetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } @@ -59,7 +59,7 @@ export interface GetPetByIdRequest { export interface UpdatePetRequest { /** - * + * Pet object that needs to be added to the store */ body: Pet; } diff --git a/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/StoreApi.ts b/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/StoreApi.ts index 957a127aaff8..0bee6231bc65 100644 --- a/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/StoreApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/StoreApi.ts @@ -33,7 +33,7 @@ export interface GetOrderByIdRequest { export interface PlaceOrderRequest { /** - * + * order placed for purchasing the pet */ body: Order; } diff --git a/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/UserApi.ts b/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/UserApi.ts index 8b482792e462..6a4ad73d9129 100644 --- a/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/UserApi.ts +++ b/samples/client/petstore/typescript-fetch/builds/without-runtime-checks/src/apis/UserApi.ts @@ -19,21 +19,21 @@ import type { export interface CreateUserRequest { /** - * + * Created user object */ body: User; } export interface CreateUsersWithArrayInputRequest { /** - * + * List of user object */ body: Array; } export interface CreateUsersWithListInputRequest { /** - * + * List of user object */ body: Array; } @@ -69,7 +69,7 @@ export interface UpdateUserRequest { */ username: string; /** - * + * Updated user object */ body: User; } diff --git a/samples/documentation/html/index.html b/samples/documentation/html/index.html index d2cf9d683377..b11d380ce73b 100644 --- a/samples/documentation/html/index.html +++ b/samples/documentation/html/index.html @@ -248,7 +248,7 @@

Request body

Pet Pet (required)
-
Body Parameter
+
Body Parameter — Pet object that needs to be added to the store
@@ -663,7 +663,7 @@

Request body

Pet Pet (required)
-
Body Parameter
+
Body Parameter — Pet object that needs to be added to the store
@@ -992,7 +992,7 @@

Request body

Order Order (required)
-
Body Parameter
+
Body Parameter — order placed for purchasing the pet
@@ -1064,7 +1064,7 @@

Request body

User User (required)
-
Body Parameter
+
Body Parameter — Created user object
@@ -1100,7 +1100,7 @@

Request body

User array[User] (required)
-
Body Parameter
+
Body Parameter — List of user object
@@ -1136,7 +1136,7 @@

Request body

User array[User] (required)
-
Body Parameter
+
Body Parameter — List of user object
@@ -1354,7 +1354,7 @@

Request body

User User (required)
-
Body Parameter
+
Body Parameter — Updated user object
diff --git a/samples/documentation/html2/index.html b/samples/documentation/html2/index.html index f5c2487a959a..da9530891670 100644 --- a/samples/documentation/html2/index.html +++ b/samples/documentation/html2/index.html @@ -1216,7 +1216,7 @@

Usage and SDK Samples

// Create an instance of the API class PetApi apiInstance = new PetApi(); - Pet pet = ; // Pet | + Pet pet = ; // Pet | Pet object that needs to be added to the store try { Pet result = apiInstance.addPet(pet); @@ -1235,7 +1235,7 @@

Usage and SDK Samples

final api_instance = DefaultApi(); -final Pet pet = new Pet(); // Pet | +final Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store try { final result = await api_instance.addPet(pet); @@ -1253,7 +1253,7 @@

Usage and SDK Samples

public class PetApiExample { public static void main(String[] args) { PetApi apiInstance = new PetApi(); - Pet pet = ; // Pet | + Pet pet = ; // Pet | Pet object that needs to be added to the store try { Pet result = apiInstance.addPet(pet); @@ -1278,7 +1278,7 @@

Usage and SDK Samples

// Create an instance of the API class PetApi *apiInstance = [[PetApi alloc] init]; -Pet *pet = ; // +Pet *pet = ; // Pet object that needs to be added to the store // Add a new pet to the store [apiInstance addPetWith:pet @@ -1303,7 +1303,7 @@

Usage and SDK Samples

// Create an instance of the API class var api = new OpenApiPetstore.PetApi() -var pet = ; // {Pet} +var pet = ; // {Pet} Pet object that needs to be added to the store var callback = function(error, data, response) { if (error) { @@ -1337,7 +1337,7 @@

Usage and SDK Samples

// Create an instance of the API class var apiInstance = new PetApi(); - var pet = new Pet(); // Pet | + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Add a new pet to the store @@ -1361,7 +1361,7 @@

Usage and SDK Samples

// Create an instance of the API class $api_instance = new OpenAPITools\Client\Api\PetApi(); -$pet = ; // Pet | +$pet = ; // Pet | Pet object that needs to be added to the store try { $result = $api_instance->addPet($pet); @@ -1382,7 +1382,7 @@

Usage and SDK Samples

# Create an instance of the API class my $api_instance = WWW::OPenAPIClient::PetApi->new(); -my $pet = WWW::OPenAPIClient::Object::Pet->new(); # Pet | +my $pet = WWW::OPenAPIClient::Object::Pet->new(); # Pet | Pet object that needs to be added to the store eval { my $result = $api_instance->addPet(pet => $pet); @@ -1405,7 +1405,7 @@

Usage and SDK Samples

# Create an instance of the API class api_instance = openapi_client.PetApi() -pet = # Pet | +pet = # Pet | Pet object that needs to be added to the store try: # Add a new pet to the store @@ -3668,7 +3668,7 @@

Usage and SDK Samples

// Create an instance of the API class PetApi apiInstance = new PetApi(); - Pet pet = ; // Pet | + Pet pet = ; // Pet | Pet object that needs to be added to the store try { Pet result = apiInstance.updatePet(pet); @@ -3687,7 +3687,7 @@

Usage and SDK Samples

final api_instance = DefaultApi(); -final Pet pet = new Pet(); // Pet | +final Pet pet = new Pet(); // Pet | Pet object that needs to be added to the store try { final result = await api_instance.updatePet(pet); @@ -3705,7 +3705,7 @@

Usage and SDK Samples

public class PetApiExample { public static void main(String[] args) { PetApi apiInstance = new PetApi(); - Pet pet = ; // Pet | + Pet pet = ; // Pet | Pet object that needs to be added to the store try { Pet result = apiInstance.updatePet(pet); @@ -3730,7 +3730,7 @@

Usage and SDK Samples

// Create an instance of the API class PetApi *apiInstance = [[PetApi alloc] init]; -Pet *pet = ; // +Pet *pet = ; // Pet object that needs to be added to the store // Update an existing pet [apiInstance updatePetWith:pet @@ -3755,7 +3755,7 @@

Usage and SDK Samples

// Create an instance of the API class var api = new OpenApiPetstore.PetApi() -var pet = ; // {Pet} +var pet = ; // {Pet} Pet object that needs to be added to the store var callback = function(error, data, response) { if (error) { @@ -3789,7 +3789,7 @@

Usage and SDK Samples

// Create an instance of the API class var apiInstance = new PetApi(); - var pet = new Pet(); // Pet | + var pet = new Pet(); // Pet | Pet object that needs to be added to the store try { // Update an existing pet @@ -3813,7 +3813,7 @@

Usage and SDK Samples

// Create an instance of the API class $api_instance = new OpenAPITools\Client\Api\PetApi(); -$pet = ; // Pet | +$pet = ; // Pet | Pet object that needs to be added to the store try { $result = $api_instance->updatePet($pet); @@ -3834,7 +3834,7 @@

Usage and SDK Samples

# Create an instance of the API class my $api_instance = WWW::OPenAPIClient::PetApi->new(); -my $pet = WWW::OPenAPIClient::Object::Pet->new(); # Pet | +my $pet = WWW::OPenAPIClient::Object::Pet->new(); # Pet | Pet object that needs to be added to the store eval { my $result = $api_instance->updatePet(pet => $pet); @@ -3857,7 +3857,7 @@

Usage and SDK Samples

# Create an instance of the API class api_instance = openapi_client.PetApi() -pet = # Pet | +pet = # Pet | Pet object that needs to be added to the store try: # Update an existing pet @@ -6529,7 +6529,7 @@

Usage and SDK Samples

// Create an instance of the API class StoreApi apiInstance = new StoreApi(); - Order order = ; // Order | + Order order = ; // Order | order placed for purchasing the pet try { Order result = apiInstance.placeOrder(order); @@ -6548,7 +6548,7 @@

Usage and SDK Samples

final api_instance = DefaultApi(); -final Order order = new Order(); // Order | +final Order order = new Order(); // Order | order placed for purchasing the pet try { final result = await api_instance.placeOrder(order); @@ -6566,7 +6566,7 @@

Usage and SDK Samples

public class StoreApiExample { public static void main(String[] args) { StoreApi apiInstance = new StoreApi(); - Order order = ; // Order | + Order order = ; // Order | order placed for purchasing the pet try { Order result = apiInstance.placeOrder(order); @@ -6587,7 +6587,7 @@

Usage and SDK Samples

// Create an instance of the API class StoreApi *apiInstance = [[StoreApi alloc] init]; -Order *order = ; // +Order *order = ; // order placed for purchasing the pet // Place an order for a pet [apiInstance placeOrderWith:order @@ -6607,7 +6607,7 @@

Usage and SDK Samples

// Create an instance of the API class var api = new OpenApiPetstore.StoreApi() -var order = ; // {Order} +var order = ; // {Order} order placed for purchasing the pet var callback = function(error, data, response) { if (error) { @@ -6639,7 +6639,7 @@

Usage and SDK Samples

// Create an instance of the API class var apiInstance = new StoreApi(); - var order = new Order(); // Order | + var order = new Order(); // Order | order placed for purchasing the pet try { // Place an order for a pet @@ -6660,7 +6660,7 @@

Usage and SDK Samples

// Create an instance of the API class $api_instance = new OpenAPITools\Client\Api\StoreApi(); -$order = ; // Order | +$order = ; // Order | order placed for purchasing the pet try { $result = $api_instance->placeOrder($order); @@ -6678,7 +6678,7 @@

Usage and SDK Samples

# Create an instance of the API class my $api_instance = WWW::OPenAPIClient::StoreApi->new(); -my $order = WWW::OPenAPIClient::Object::Order->new(); # Order | +my $order = WWW::OPenAPIClient::Object::Order->new(); # Order | order placed for purchasing the pet eval { my $result = $api_instance->placeOrder(order => $order); @@ -6698,7 +6698,7 @@

Usage and SDK Samples

# Create an instance of the API class api_instance = openapi_client.StoreApi() -order = # Order | +order = # Order | order placed for purchasing the pet try: # Place an order for a pet @@ -7007,7 +7007,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi apiInstance = new UserApi(); - User user = ; // User | + User user = ; // User | Created user object try { apiInstance.createUser(user); @@ -7025,7 +7025,7 @@

Usage and SDK Samples

final api_instance = DefaultApi(); -final User user = new User(); // User | +final User user = new User(); // User | Created user object try { final result = await api_instance.createUser(user); @@ -7043,7 +7043,7 @@

Usage and SDK Samples

public class UserApiExample { public static void main(String[] args) { UserApi apiInstance = new UserApi(); - User user = ; // User | + User user = ; // User | Created user object try { apiInstance.createUser(user); @@ -7069,7 +7069,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi *apiInstance = [[UserApi alloc] init]; -User *user = ; // +User *user = ; // Created user object // Create user [apiInstance createUserWith:user @@ -7093,7 +7093,7 @@

Usage and SDK Samples

// Create an instance of the API class var api = new OpenApiPetstore.UserApi() -var user = ; // {User} +var user = ; // {User} Created user object var callback = function(error, data, response) { if (error) { @@ -7129,7 +7129,7 @@

Usage and SDK Samples

// Create an instance of the API class var apiInstance = new UserApi(); - var user = new User(); // User | + var user = new User(); // User | Created user object try { // Create user @@ -7154,7 +7154,7 @@

Usage and SDK Samples

// Create an instance of the API class $api_instance = new OpenAPITools\Client\Api\UserApi(); -$user = ; // User | +$user = ; // User | Created user object try { $api_instance->createUser($user); @@ -7176,7 +7176,7 @@

Usage and SDK Samples

# Create an instance of the API class my $api_instance = WWW::OPenAPIClient::UserApi->new(); -my $user = WWW::OPenAPIClient::Object::User->new(); # User | +my $user = WWW::OPenAPIClient::Object::User->new(); # User | Created user object eval { $api_instance->createUser(user => $user); @@ -7200,7 +7200,7 @@

Usage and SDK Samples

# Create an instance of the API class api_instance = openapi_client.UserApi() -user = # User | +user = # User | Created user object try: # Create user @@ -7424,7 +7424,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi apiInstance = new UserApi(); - array[User] user = ; // array[User] | + array[User] user = ; // array[User] | List of user object try { apiInstance.createUsersWithArrayInput(user); @@ -7442,7 +7442,7 @@

Usage and SDK Samples

final api_instance = DefaultApi(); -final array[User] user = new array[User](); // array[User] | +final array[User] user = new array[User](); // array[User] | List of user object try { final result = await api_instance.createUsersWithArrayInput(user); @@ -7460,7 +7460,7 @@

Usage and SDK Samples

public class UserApiExample { public static void main(String[] args) { UserApi apiInstance = new UserApi(); - array[User] user = ; // array[User] | + array[User] user = ; // array[User] | List of user object try { apiInstance.createUsersWithArrayInput(user); @@ -7486,7 +7486,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi *apiInstance = [[UserApi alloc] init]; -array[User] *user = ; // +array[User] *user = ; // List of user object // Creates list of users with given input array [apiInstance createUsersWithArrayInputWith:user @@ -7510,7 +7510,7 @@

Usage and SDK Samples

// Create an instance of the API class var api = new OpenApiPetstore.UserApi() -var user = ; // {array[User]} +var user = ; // {array[User]} List of user object var callback = function(error, data, response) { if (error) { @@ -7546,7 +7546,7 @@

Usage and SDK Samples

// Create an instance of the API class var apiInstance = new UserApi(); - var user = new array[User](); // array[User] | + var user = new array[User](); // array[User] | List of user object try { // Creates list of users with given input array @@ -7571,7 +7571,7 @@

Usage and SDK Samples

// Create an instance of the API class $api_instance = new OpenAPITools\Client\Api\UserApi(); -$user = ; // array[User] | +$user = ; // array[User] | List of user object try { $api_instance->createUsersWithArrayInput($user); @@ -7593,7 +7593,7 @@

Usage and SDK Samples

# Create an instance of the API class my $api_instance = WWW::OPenAPIClient::UserApi->new(); -my $user = [WWW::OPenAPIClient::Object::array[User]->new()]; # array[User] | +my $user = [WWW::OPenAPIClient::Object::array[User]->new()]; # array[User] | List of user object eval { $api_instance->createUsersWithArrayInput(user => $user); @@ -7617,7 +7617,7 @@

Usage and SDK Samples

# Create an instance of the API class api_instance = openapi_client.UserApi() -user = # array[User] | +user = # array[User] | List of user object try: # Creates list of users with given input array @@ -7844,7 +7844,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi apiInstance = new UserApi(); - array[User] user = ; // array[User] | + array[User] user = ; // array[User] | List of user object try { apiInstance.createUsersWithListInput(user); @@ -7862,7 +7862,7 @@

Usage and SDK Samples

final api_instance = DefaultApi(); -final array[User] user = new array[User](); // array[User] | +final array[User] user = new array[User](); // array[User] | List of user object try { final result = await api_instance.createUsersWithListInput(user); @@ -7880,7 +7880,7 @@

Usage and SDK Samples

public class UserApiExample { public static void main(String[] args) { UserApi apiInstance = new UserApi(); - array[User] user = ; // array[User] | + array[User] user = ; // array[User] | List of user object try { apiInstance.createUsersWithListInput(user); @@ -7906,7 +7906,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi *apiInstance = [[UserApi alloc] init]; -array[User] *user = ; // +array[User] *user = ; // List of user object // Creates list of users with given input array [apiInstance createUsersWithListInputWith:user @@ -7930,7 +7930,7 @@

Usage and SDK Samples

// Create an instance of the API class var api = new OpenApiPetstore.UserApi() -var user = ; // {array[User]} +var user = ; // {array[User]} List of user object var callback = function(error, data, response) { if (error) { @@ -7966,7 +7966,7 @@

Usage and SDK Samples

// Create an instance of the API class var apiInstance = new UserApi(); - var user = new array[User](); // array[User] | + var user = new array[User](); // array[User] | List of user object try { // Creates list of users with given input array @@ -7991,7 +7991,7 @@

Usage and SDK Samples

// Create an instance of the API class $api_instance = new OpenAPITools\Client\Api\UserApi(); -$user = ; // array[User] | +$user = ; // array[User] | List of user object try { $api_instance->createUsersWithListInput($user); @@ -8013,7 +8013,7 @@

Usage and SDK Samples

# Create an instance of the API class my $api_instance = WWW::OPenAPIClient::UserApi->new(); -my $user = [WWW::OPenAPIClient::Object::array[User]->new()]; # array[User] | +my $user = [WWW::OPenAPIClient::Object::array[User]->new()]; # array[User] | List of user object eval { $api_instance->createUsersWithListInput(user => $user); @@ -8037,7 +8037,7 @@

Usage and SDK Samples

# Create an instance of the API class api_instance = openapi_client.UserApi() -user = # array[User] | +user = # array[User] | List of user object try: # Creates list of users with given input array @@ -10096,7 +10096,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi apiInstance = new UserApi(); String username = username_example; // String | name that need to be deleted - User user = ; // User | + User user = ; // User | Updated user object try { apiInstance.updateUser(username, user); @@ -10115,7 +10115,7 @@

Usage and SDK Samples

final api_instance = DefaultApi(); final String username = new String(); // String | name that need to be deleted -final User user = new User(); // User | +final User user = new User(); // User | Updated user object try { final result = await api_instance.updateUser(username, user); @@ -10134,7 +10134,7 @@

Usage and SDK Samples

public static void main(String[] args) { UserApi apiInstance = new UserApi(); String username = username_example; // String | name that need to be deleted - User user = ; // User | + User user = ; // User | Updated user object try { apiInstance.updateUser(username, user); @@ -10161,7 +10161,7 @@

Usage and SDK Samples

// Create an instance of the API class UserApi *apiInstance = [[UserApi alloc] init]; String *username = username_example; // name that need to be deleted (default to null) -User *user = ; // +User *user = ; // Updated user object // Updated user [apiInstance updateUserWith:username @@ -10187,7 +10187,7 @@

Usage and SDK Samples

// Create an instance of the API class var api = new OpenApiPetstore.UserApi() var username = username_example; // {String} name that need to be deleted -var user = ; // {User} +var user = ; // {User} Updated user object var callback = function(error, data, response) { if (error) { @@ -10224,7 +10224,7 @@

Usage and SDK Samples

// Create an instance of the API class var apiInstance = new UserApi(); var username = username_example; // String | name that need to be deleted (default to null) - var user = new User(); // User | + var user = new User(); // User | Updated user object try { // Updated user @@ -10250,7 +10250,7 @@

Usage and SDK Samples

// Create an instance of the API class $api_instance = new OpenAPITools\Client\Api\UserApi(); $username = username_example; // String | name that need to be deleted -$user = ; // User | +$user = ; // User | Updated user object try { $api_instance->updateUser($username, $user); @@ -10273,7 +10273,7 @@

Usage and SDK Samples

# Create an instance of the API class my $api_instance = WWW::OPenAPIClient::UserApi->new(); my $username = username_example; # String | name that need to be deleted -my $user = WWW::OPenAPIClient::Object::User->new(); # User | +my $user = WWW::OPenAPIClient::Object::User->new(); # User | Updated user object eval { $api_instance->updateUser(username => $username, user => $user); @@ -10298,7 +10298,7 @@

Usage and SDK Samples

# Create an instance of the API class api_instance = openapi_client.UserApi() username = username_example # String | name that need to be deleted (default to null) -user = # User | +user = # User | Updated user object try: # Updated user diff --git a/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/PetApi.java index 470f0fe2de6a..c06d1e7be7d4 100644 --- a/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/PetApi.java @@ -134,7 +134,7 @@ ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @RequestMapping( method = RequestMethod.PUT, diff --git a/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/StoreApi.java index 107bfbf06337..8be8bb614286 100644 --- a/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-3-with-optional/src/main/java/org/openapitools/api/StoreApi.java @@ -61,7 +61,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/PetApi.java index 0930fd851726..93da5b2f23b7 100644 --- a/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/PetApi.java @@ -225,7 +225,7 @@ ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/StoreApi.java index 0ff000a1ac60..4cc780b08f57 100644 --- a/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-3/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/PetApi.java index 470f0fe2de6a..c06d1e7be7d4 100644 --- a/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/PetApi.java @@ -134,7 +134,7 @@ ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @RequestMapping( method = RequestMethod.PUT, diff --git a/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/StoreApi.java index 107bfbf06337..8be8bb614286 100644 --- a/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-4-with-optional/src/main/java/org/openapitools/api/StoreApi.java @@ -61,7 +61,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/PetApi.java index 5b5249a40338..3f6fda75387b 100644 --- a/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/PetApi.java @@ -226,7 +226,7 @@ CompletableFuture> getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/StoreApi.java index 8cdd7c8340d0..1c761603c9ea 100644 --- a/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-async/src/main/java/org/openapitools/api/StoreApi.java @@ -99,7 +99,7 @@ CompletableFuture>> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java b/samples/openapi3/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java index 8c1998ebd3b1..b33fea452788 100644 --- a/samples/openapi3/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-date-time/src/main/java/org/openapitools/api/DefaultApi.java @@ -72,7 +72,7 @@ ResponseEntity get( * update with form data * * @param date A date path parameter (required) - * @param visitDate Updated last visit timestamp (optional, default to 1971-12-19T03:39:57-08:00) + * @param visitDate Updated last visit timestamp (optional, OpenAPI schema default to 1971-12-19T03:39:57-08:00) * @return Invalid input (status code 405) */ @Operation( diff --git a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/FakeApi.java b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/FakeApi.java index e3edb782f9b8..99f2d8e4a552 100644 --- a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/FakeApi.java @@ -192,14 +192,14 @@ ResponseEntity fakeOuterStringSerialize( String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -243,8 +243,8 @@ ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -273,8 +273,14 @@ ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -295,8 +301,8 @@ ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -334,14 +340,14 @@ ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -361,9 +367,9 @@ ResponseEntity testEndpointParameters( consumes = "application/x-www-form-urlencoded" ) ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/StoreApi.java index 99d5abd32a85..f99f35a42a8d 100644 --- a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/Capitalization.java b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/ClassModel.java b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/File.java b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/File.java +++ b/samples/openapi3/client/petstore/spring-cloud-oas3-fakeapi/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/openapi3/client/petstore/spring-cloud-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-cloud-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java index 7335084c9a2b..4b456d246d21 100644 --- a/samples/openapi3/client/petstore/spring-cloud-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-cloud-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java index 0930fd851726..93da5b2f23b7 100644 --- a/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/PetApi.java @@ -225,7 +225,7 @@ ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java index 0ff000a1ac60..4cc780b08f57 100644 --- a/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-cloud/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/PetApi.java index 5905f0fa5900..d15f584e8e86 100644 --- a/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/PetApi.java @@ -225,7 +225,7 @@ ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/StoreApi.java index e706451b695e..53db9145e975 100644 --- a/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-stubs-skip-default-interface/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/PetApi.java index 4145e8bbfe62..71fa58942b83 100644 --- a/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/PetApi.java @@ -303,7 +303,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/StoreApi.java index 6ad955b8a608..cc1a034f8a26 100644 --- a/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/client/petstore/spring-stubs/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/PetApi.java index 7f0b47028028..e19c9a888e77 100644 --- a/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/PetApi.java @@ -303,7 +303,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/StoreApi.java index 8425ab0970d4..c5e8bc211d61 100644 --- a/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/spring-boot-springdoc/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApi.java index 7cceae5de330..4aa6889b10fa 100644 --- a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApi.java @@ -244,7 +244,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApiDelegate.java b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApiDelegate.java index 99ef4e827454..3e78b4d97749 100644 --- a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApiDelegate.java +++ b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/PetApiDelegate.java @@ -173,7 +173,7 @@ default ResponseEntity getPetById(Long petId, * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation * @see PetApi#updatePet */ default ResponseEntity updatePet(Pet pet, diff --git a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java index e48b36f7ff7c..ed2d386d59a7 100644 --- a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java @@ -107,7 +107,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApiDelegate.java index 2787db7be905..a87e2f8792d8 100644 --- a/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/openapi3/server/petstore/springboot-3-include-http-request-context/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -56,7 +56,7 @@ default ResponseEntity> getInventory(HttpServletRequest ser /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/PetApi.java index 7f0b47028028..e19c9a888e77 100644 --- a/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/PetApi.java @@ -303,7 +303,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/StoreApi.java index 8425ab0970d4..c5e8bc211d61 100644 --- a/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/springboot-3/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/PetApi.java index 7f0b47028028..e19c9a888e77 100644 --- a/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/PetApi.java @@ -303,7 +303,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/StoreApi.java index 8425ab0970d4..c5e8bc211d61 100644 --- a/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/springboot-4/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java index f8c2da3c98e8..5d4a344239ca 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java @@ -235,14 +235,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -290,8 +290,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -322,8 +322,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -344,8 +350,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -385,14 +391,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -412,9 +418,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java index 5b6cdd7f828f..cb16f6879bbc 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java @@ -135,7 +135,7 @@ default ResponseEntity responseObjectDiff /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -161,8 +161,8 @@ default ResponseEntity testBodyWithQueryParams(String query, } /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -183,8 +183,14 @@ default ResponseEntity testClientModel(Client client) { } /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -226,14 +232,14 @@ default ResponseEntity testEndpointParameters(BigDecimal number, * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) * @see FakeApi#testEnumParameters diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java index e942c0ba6398..395285bbf2ea 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java @@ -105,7 +105,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java index 7e90b451b58e..7cdb6f136f89 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -54,7 +54,7 @@ default ResponseEntity> getInventory() { /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/openapi3/server/petstore/springboot-delegate/src/main/resources/openapi.yaml b/samples/openapi3/server/petstore/springboot-delegate/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/openapi3/server/petstore/springboot-delegate/src/main/resources/openapi.yaml +++ b/samples/openapi3/server/petstore/springboot-delegate/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java index df27ef76840a..b93f701a9406 100644 --- a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java @@ -263,14 +263,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -320,8 +320,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -362,8 +362,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -384,8 +390,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -426,12 +432,12 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -455,7 +461,7 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java index 0813a3064040..cfdef0b90498 100644 --- a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java +++ b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml +++ b/samples/openapi3/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/PetApi.java index 6aee93b8c797..328e1fc6c19a 100644 --- a/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/PetApi.java @@ -212,7 +212,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @RequestMapping( method = RequestMethod.PUT, diff --git a/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/StoreApi.java index eca12efebb7b..92b645aa4b4b 100644 --- a/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/springboot-source/src/main/java/org/openapitools/api/StoreApi.java @@ -74,7 +74,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/PetApi.java b/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/PetApi.java index c5be670cc67e..777039aa0605 100644 --- a/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/PetApi.java @@ -304,7 +304,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java b/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java index a9027934286d..9a09eb56db22 100644 --- a/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/openapi3/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java @@ -112,7 +112,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/java-undertow/src/main/java/org/openapitools/handler/PathHandlerInterface.java b/samples/server/petstore/java-undertow/src/main/java/org/openapitools/handler/PathHandlerInterface.java index d5faaeaaa5fe..b1fc52116b9a 100644 --- a/samples/server/petstore/java-undertow/src/main/java/org/openapitools/handler/PathHandlerInterface.java +++ b/samples/server/petstore/java-undertow/src/main/java/org/openapitools/handler/PathHandlerInterface.java @@ -574,13 +574,13 @@ public interface PathHandlerInterface { *

* * - *

Response headers: [CodegenProperty{openApiType='string', baseName='Set-Cookie', complexType='null', getter='getSetCookie', setter='setSetCookie', description='Cookie authentication key for use with the `api_key` apiKey authentication.', dataType='String', datatypeWithEnum='String', dataFormat='null', name='setCookie', min='null', max='null', defaultValue='null', defaultValueWithParam=' = data.Set-Cookie;', baseType='String', containerType='null', containerTypeMapped='null', title='null', unescapedDescription='Cookie authentication key for use with the `api_key` apiKey authentication.', maxLength=null, minLength=null, pattern='null', example='AUTH_KEY=abcde12345; Path=/; HttpOnly', jsonSchema='{ + *

Response headers: [CodegenProperty{openApiType='string', baseName='Set-Cookie', complexType='null', getter='getSetCookie', setter='setSetCookie', description='Cookie authentication key for use with the `api_key` apiKey authentication.', dataType='String', datatypeWithEnum='String', dataFormat='null', name='setCookie', min='null', max='null', defaultValue='null', rawDefaultValue=null, rawDefaultValueText='null', hasDefaultValue=false, defaultValueWithParam=' = data.Set-Cookie;', baseType='String', containerType='null', containerTypeMapped='null', title='null', unescapedDescription='Cookie authentication key for use with the `api_key` apiKey authentication.', maxLength=null, minLength=null, pattern='null', example='AUTH_KEY=abcde12345; Path=/; HttpOnly', rawExample='AUTH_KEY=abcde12345; Path=/; HttpOnly', jsonSchema='{ "example" : "AUTH_KEY=abcde12345; Path=/; HttpOnly", "type" : "string" -}', minimum='null', maximum='null', exclusiveMinimum=false, exclusiveMaximum=false, required=false, deprecated=false, isPrimitiveType=true, isModel=false, isContainer=false, isString=true, isNumeric=false, isInteger=false, isShort=false, isLong=false, isUnboundedInteger=false, isNumber=false, isFloat=false, isDouble=false, isDecimal=false, isByteArray=false, isBinary=false, isFile=false, isBoolean=false, isDate=false, isDateTime=false, isUuid=false, isUri=false, isEmail=false, isPassword=false, isFreeFormObject=false, isArray=false, isMap=false, isOptional=false, isEnum=false, isInnerEnum=false, isEnumRef=false, isAnyType=false, isReadOnly=false, isWriteOnly=false, isNullable=false, isSelfReference=false, isCircularReference=false, isDiscriminator=false, isNew=false, isOverridden=null, _enum=null, allowableValues=null, items=null, additionalProperties=null, vars=[], requiredVars=[], mostInnerItems=null, vendorExtensions={}, hasValidation=false, isInherited=false, discriminatorValue='null', nameInCamelCase='setCookie', nameInPascalCase='SetCookie', nameInSnakeCase='SET_COOKIE', enumName='null', maxItems=null, minItems=null, maxProperties=null, minProperties=null, uniqueItems=false, uniqueItemsBoolean=null, multipleOf=null, isXmlAttribute=false, xmlPrefix='null', xmlName='null', xmlNamespace='null', isXmlWrapped=false, isNull=false, isVoid=false, getAdditionalPropertiesIsAnyType=false, getHasVars=false, getHasRequired=false, getHasDiscriminatorWithNonEmptyMapping=false, composedSchemas=null, hasMultipleTypes=false, hasSanitizedName=true, requiredVarsMap=null, ref=null, schemaIsFromAdditionalProperties=false, isBooleanSchemaTrue=false, isBooleanSchemaFalse=false, format=null, dependentRequired=null, contains=null}, CodegenProperty{openApiType='integer', baseName='X-Rate-Limit', complexType='null', getter='getxRateLimit', setter='setxRateLimit', description='calls per hour allowed by the user', dataType='Integer', datatypeWithEnum='Integer', dataFormat='int32', name='xRateLimit', min='null', max='null', defaultValue='null', defaultValueWithParam=' = data.X-Rate-Limit;', baseType='Integer', containerType='null', containerTypeMapped='null', title='null', unescapedDescription='calls per hour allowed by the user', maxLength=null, minLength=null, pattern='null', example='null', jsonSchema='{ +}', minimum='null', maximum='null', exclusiveMinimum=false, exclusiveMaximum=false, required=false, deprecated=false, isPrimitiveType=true, isModel=false, isContainer=false, isString=true, isNumeric=false, isInteger=false, isShort=false, isLong=false, isUnboundedInteger=false, isNumber=false, isFloat=false, isDouble=false, isDecimal=false, isByteArray=false, isBinary=false, isFile=false, isBoolean=false, isDate=false, isDateTime=false, isUuid=false, isUri=false, isEmail=false, isPassword=false, isFreeFormObject=false, isArray=false, isMap=false, isOptional=false, isEnum=false, isInnerEnum=false, isEnumRef=false, isAnyType=false, isReadOnly=false, isWriteOnly=false, isNullable=false, isSelfReference=false, isCircularReference=false, isDiscriminator=false, isNew=false, isOverridden=null, _enum=null, allowableValues=null, items=null, additionalProperties=null, vars=[], requiredVars=[], mostInnerItems=null, vendorExtensions={}, hasValidation=false, isInherited=false, discriminatorValue='null', nameInCamelCase='setCookie', nameInPascalCase='SetCookie', nameInSnakeCase='SET_COOKIE', enumName='null', maxItems=null, minItems=null, maxProperties=null, minProperties=null, uniqueItems=false, uniqueItemsBoolean=null, multipleOf=null, isXmlAttribute=false, xmlPrefix='null', xmlName='null', xmlNamespace='null', isXmlWrapped=false, isNull=false, isVoid=false, getAdditionalPropertiesIsAnyType=false, getHasVars=false, getHasRequired=false, getHasDiscriminatorWithNonEmptyMapping=false, composedSchemas=null, hasMultipleTypes=false, hasSanitizedName=true, requiredVarsMap=null, ref=null, schemaIsFromAdditionalProperties=false, isBooleanSchemaTrue=false, isBooleanSchemaFalse=false, format=null, dependentRequired=null, contains=null}, CodegenProperty{openApiType='integer', baseName='X-Rate-Limit', complexType='null', getter='getxRateLimit', setter='setxRateLimit', description='calls per hour allowed by the user', dataType='Integer', datatypeWithEnum='Integer', dataFormat='int32', name='xRateLimit', min='null', max='null', defaultValue='null', rawDefaultValue=null, rawDefaultValueText='null', hasDefaultValue=false, defaultValueWithParam=' = data.X-Rate-Limit;', baseType='Integer', containerType='null', containerTypeMapped='null', title='null', unescapedDescription='calls per hour allowed by the user', maxLength=null, minLength=null, pattern='null', example='null', rawExample='null', jsonSchema='{ "format" : "int32", "type" : "integer" -}', minimum='null', maximum='null', exclusiveMinimum=false, exclusiveMaximum=false, required=false, deprecated=false, isPrimitiveType=true, isModel=false, isContainer=false, isString=false, isNumeric=true, isInteger=true, isShort=true, isLong=false, isUnboundedInteger=false, isNumber=false, isFloat=false, isDouble=false, isDecimal=false, isByteArray=false, isBinary=false, isFile=false, isBoolean=false, isDate=false, isDateTime=false, isUuid=false, isUri=false, isEmail=false, isPassword=false, isFreeFormObject=false, isArray=false, isMap=false, isOptional=false, isEnum=false, isInnerEnum=false, isEnumRef=false, isAnyType=false, isReadOnly=false, isWriteOnly=false, isNullable=false, isSelfReference=false, isCircularReference=false, isDiscriminator=false, isNew=false, isOverridden=null, _enum=null, allowableValues=null, items=null, additionalProperties=null, vars=[], requiredVars=[], mostInnerItems=null, vendorExtensions={}, hasValidation=false, isInherited=false, discriminatorValue='null', nameInCamelCase='xRateLimit', nameInPascalCase='XRateLimit', nameInSnakeCase='X_RATE_LIMIT', enumName='null', maxItems=null, minItems=null, maxProperties=null, minProperties=null, uniqueItems=false, uniqueItemsBoolean=null, multipleOf=null, isXmlAttribute=false, xmlPrefix='null', xmlName='null', xmlNamespace='null', isXmlWrapped=false, isNull=false, isVoid=false, getAdditionalPropertiesIsAnyType=false, getHasVars=false, getHasRequired=false, getHasDiscriminatorWithNonEmptyMapping=false, composedSchemas=null, hasMultipleTypes=false, hasSanitizedName=true, requiredVarsMap=null, ref=null, schemaIsFromAdditionalProperties=false, isBooleanSchemaTrue=false, isBooleanSchemaFalse=false, format=int32, dependentRequired=null, contains=null}, CodegenProperty{openApiType='string', baseName='X-Expires-After', complexType='Date', getter='getxExpiresAfter', setter='setxExpiresAfter', description='date in UTC when token expires', dataType='Date', datatypeWithEnum='Date', dataFormat='date-time', name='xExpiresAfter', min='null', max='null', defaultValue='null', defaultValueWithParam=' = data.X-Expires-After;', baseType='Date', containerType='null', containerTypeMapped='null', title='null', unescapedDescription='date in UTC when token expires', maxLength=null, minLength=null, pattern='null', example='null', jsonSchema='{ +}', minimum='null', maximum='null', exclusiveMinimum=false, exclusiveMaximum=false, required=false, deprecated=false, isPrimitiveType=true, isModel=false, isContainer=false, isString=false, isNumeric=true, isInteger=true, isShort=true, isLong=false, isUnboundedInteger=false, isNumber=false, isFloat=false, isDouble=false, isDecimal=false, isByteArray=false, isBinary=false, isFile=false, isBoolean=false, isDate=false, isDateTime=false, isUuid=false, isUri=false, isEmail=false, isPassword=false, isFreeFormObject=false, isArray=false, isMap=false, isOptional=false, isEnum=false, isInnerEnum=false, isEnumRef=false, isAnyType=false, isReadOnly=false, isWriteOnly=false, isNullable=false, isSelfReference=false, isCircularReference=false, isDiscriminator=false, isNew=false, isOverridden=null, _enum=null, allowableValues=null, items=null, additionalProperties=null, vars=[], requiredVars=[], mostInnerItems=null, vendorExtensions={}, hasValidation=false, isInherited=false, discriminatorValue='null', nameInCamelCase='xRateLimit', nameInPascalCase='XRateLimit', nameInSnakeCase='X_RATE_LIMIT', enumName='null', maxItems=null, minItems=null, maxProperties=null, minProperties=null, uniqueItems=false, uniqueItemsBoolean=null, multipleOf=null, isXmlAttribute=false, xmlPrefix='null', xmlName='null', xmlNamespace='null', isXmlWrapped=false, isNull=false, isVoid=false, getAdditionalPropertiesIsAnyType=false, getHasVars=false, getHasRequired=false, getHasDiscriminatorWithNonEmptyMapping=false, composedSchemas=null, hasMultipleTypes=false, hasSanitizedName=true, requiredVarsMap=null, ref=null, schemaIsFromAdditionalProperties=false, isBooleanSchemaTrue=false, isBooleanSchemaFalse=false, format=int32, dependentRequired=null, contains=null}, CodegenProperty{openApiType='string', baseName='X-Expires-After', complexType='Date', getter='getxExpiresAfter', setter='setxExpiresAfter', description='date in UTC when token expires', dataType='Date', datatypeWithEnum='Date', dataFormat='date-time', name='xExpiresAfter', min='null', max='null', defaultValue='null', rawDefaultValue=null, rawDefaultValueText='null', hasDefaultValue=false, defaultValueWithParam=' = data.X-Expires-After;', baseType='Date', containerType='null', containerTypeMapped='null', title='null', unescapedDescription='date in UTC when token expires', maxLength=null, minLength=null, pattern='null', example='null', rawExample='null', jsonSchema='{ "format" : "date-time", "type" : "string" }', minimum='null', maximum='null', exclusiveMinimum=false, exclusiveMaximum=false, required=false, deprecated=false, isPrimitiveType=false, isModel=false, isContainer=false, isString=false, isNumeric=false, isInteger=false, isShort=false, isLong=false, isUnboundedInteger=false, isNumber=false, isFloat=false, isDouble=false, isDecimal=false, isByteArray=false, isBinary=false, isFile=false, isBoolean=false, isDate=false, isDateTime=true, isUuid=false, isUri=false, isEmail=false, isPassword=false, isFreeFormObject=false, isArray=false, isMap=false, isOptional=false, isEnum=false, isInnerEnum=false, isEnumRef=false, isAnyType=false, isReadOnly=false, isWriteOnly=false, isNullable=false, isSelfReference=false, isCircularReference=false, isDiscriminator=false, isNew=false, isOverridden=null, _enum=null, allowableValues=null, items=null, additionalProperties=null, vars=[], requiredVars=[], mostInnerItems=null, vendorExtensions={}, hasValidation=false, isInherited=false, discriminatorValue='null', nameInCamelCase='xExpiresAfter', nameInPascalCase='XExpiresAfter', nameInSnakeCase='X_EXPIRES_AFTER', enumName='null', maxItems=null, minItems=null, maxProperties=null, minProperties=null, uniqueItems=false, uniqueItemsBoolean=null, multipleOf=null, isXmlAttribute=false, xmlPrefix='null', xmlName='null', xmlNamespace='null', isXmlWrapped=false, isNull=false, isVoid=false, getAdditionalPropertiesIsAnyType=false, getHasVars=false, getHasRequired=false, getHasDiscriminatorWithNonEmptyMapping=false, composedSchemas=null, hasMultipleTypes=false, hasSanitizedName=true, requiredVarsMap=null, ref=null, schemaIsFromAdditionalProperties=false, isBooleanSchemaTrue=false, isBooleanSchemaFalse=false, format=date-time, dependentRequired=null, contains=null}]

diff --git a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/FakeApiController.kt b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/FakeApiController.kt index b1d3383a2feb..09b69a1f46c5 100644 --- a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/FakeApiController.kt +++ b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/FakeApiController.kt @@ -36,7 +36,7 @@ class FakeApiController() { @Operation( summary = "annotate", operationId = "annotations", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "OK") ] ) @@ -55,7 +55,7 @@ class FakeApiController() { @Operation( summary = "Updates a pet in the store with form data (number)", operationId = "updatePetWithFormNumber", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] diff --git a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/PetApiController.kt b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/PetApiController.kt index add6ff045ac4..da6a77c9b5d8 100644 --- a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/PetApiController.kt +++ b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/PetApiController.kt @@ -37,7 +37,7 @@ class PetApiController() { @Operation( summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "405", description = "Invalid input") ], @@ -59,7 +59,7 @@ class PetApiController() { @Operation( summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid pet value") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -79,7 +79,7 @@ class PetApiController() { @Operation( summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") ], @@ -100,7 +100,7 @@ class PetApiController() { @Operation( summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") ], @@ -122,7 +122,7 @@ class PetApiController() { @Operation( summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -144,7 +144,7 @@ class PetApiController() { @Operation( summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -168,7 +168,7 @@ class PetApiController() { @Operation( summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -190,7 +190,7 @@ class PetApiController() { @Operation( summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] diff --git a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/StoreApiController.kt b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/StoreApiController.kt index e9e3620a9e75..a2db31980e75 100644 --- a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/StoreApiController.kt +++ b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/StoreApiController.kt @@ -36,7 +36,7 @@ class StoreApiController() { @Operation( summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") ] @@ -55,7 +55,7 @@ class StoreApiController() { @Operation( summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], security = [ SecurityRequirement(name = "api_key") ] @@ -73,7 +73,7 @@ class StoreApiController() { @Operation( summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -94,7 +94,7 @@ class StoreApiController() { @Operation( summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") ] diff --git a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/UserApiController.kt b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/UserApiController.kt index 779ab20356e1..5425a830b171 100644 --- a/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/UserApiController.kt +++ b/samples/server/petstore/kotlin-spring-default/src/main/kotlin/org/openapitools/api/UserApiController.kt @@ -36,7 +36,7 @@ class UserApiController() { @Operation( summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -56,7 +56,7 @@ class UserApiController() { @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -76,7 +76,7 @@ class UserApiController() { @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -96,7 +96,7 @@ class UserApiController() { @Operation( summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") ], @@ -116,7 +116,7 @@ class UserApiController() { @Operation( summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -137,7 +137,7 @@ class UserApiController() { @Operation( summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") ] @@ -158,7 +158,7 @@ class UserApiController() { @Operation( summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -175,7 +175,7 @@ class UserApiController() { @Operation( summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") ], diff --git a/samples/server/petstore/kotlin-springboot-3-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-3-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 474b51456b27..617988354093 100644 --- a/samples/server/petstore/kotlin-springboot-3-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-3-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-3/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-3/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 474b51456b27..617988354093 100644 --- a/samples/server/petstore/kotlin-springboot-3/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-3/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-4/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-4/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 474b51456b27..617988354093 100644 --- a/samples/server/petstore/kotlin-springboot-4/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-4/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-additionalproperties/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-additionalproperties/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 474b51456b27..617988354093 100644 --- a/samples/server/petstore/kotlin-springboot-additionalproperties/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-additionalproperties/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-bigdecimal-default/src/main/kotlin/org/openapitools/api/TestApiController.kt b/samples/server/petstore/kotlin-springboot-bigdecimal-default/src/main/kotlin/org/openapitools/api/TestApiController.kt index 64844ce66fb6..7242518f7925 100644 --- a/samples/server/petstore/kotlin-springboot-bigdecimal-default/src/main/kotlin/org/openapitools/api/TestApiController.kt +++ b/samples/server/petstore/kotlin-springboot-bigdecimal-default/src/main/kotlin/org/openapitools/api/TestApiController.kt @@ -36,7 +36,7 @@ class TestApiController() { @Operation( summary = "", operationId = "testPost", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "Successful operation") ] ) diff --git a/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/PetApi.kt b/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/PetApi.kt index fe3816cc06ef..5c90b65ff275 100644 --- a/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/PetApi.kt +++ b/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/PetApi.kt @@ -45,7 +45,7 @@ interface PetApi { tags = ["pet",], summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "405", description = "Invalid input") @@ -69,7 +69,7 @@ interface PetApi { tags = ["pet",], summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid pet value") ], @@ -91,7 +91,7 @@ interface PetApi { tags = ["pet",], summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") @@ -114,7 +114,7 @@ interface PetApi { tags = ["pet",], summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") @@ -138,7 +138,7 @@ interface PetApi { tags = ["pet",], summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -162,7 +162,7 @@ interface PetApi { tags = ["pet",], summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -188,7 +188,7 @@ interface PetApi { tags = ["pet",], summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], @@ -212,7 +212,7 @@ interface PetApi { tags = ["pet",], summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], diff --git a/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/StoreApi.kt b/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/StoreApi.kt index 2a58596bfa90..eb744025390f 100644 --- a/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/StoreApi.kt +++ b/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/StoreApi.kt @@ -44,7 +44,7 @@ interface StoreApi { tags = ["store",], summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") @@ -65,7 +65,7 @@ interface StoreApi { tags = ["store",], summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], @@ -85,7 +85,7 @@ interface StoreApi { tags = ["store",], summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -108,7 +108,7 @@ interface StoreApi { tags = ["store",], summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") diff --git a/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/UserApi.kt b/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/UserApi.kt index e57c0241ff2c..d34d01d3cae4 100644 --- a/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/UserApi.kt +++ b/samples/server/petstore/kotlin-springboot-delegate-nodefaults/src/main/kotlin/org/openapitools/api/UserApi.kt @@ -44,7 +44,7 @@ interface UserApi { tags = ["user",], summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -66,7 +66,7 @@ interface UserApi { tags = ["user",], summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -88,7 +88,7 @@ interface UserApi { tags = ["user",], summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -110,7 +110,7 @@ interface UserApi { tags = ["user",], summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") @@ -132,7 +132,7 @@ interface UserApi { tags = ["user",], summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -155,7 +155,7 @@ interface UserApi { tags = ["user",], summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") @@ -178,7 +178,7 @@ interface UserApi { tags = ["user",], summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -197,7 +197,7 @@ interface UserApi { tags = ["user",], summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") diff --git a/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/PetApi.kt b/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/PetApi.kt index 8acb5303e965..ecb321d259cc 100644 --- a/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/PetApi.kt +++ b/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/PetApi.kt @@ -44,7 +44,7 @@ interface PetApi { tags = ["pet",], summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "405", description = "Invalid input") @@ -68,7 +68,7 @@ interface PetApi { tags = ["pet",], summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid pet value") ], @@ -90,7 +90,7 @@ interface PetApi { tags = ["pet",], summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") @@ -113,7 +113,7 @@ interface PetApi { tags = ["pet",], summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") @@ -137,7 +137,7 @@ interface PetApi { tags = ["pet",], summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -161,7 +161,7 @@ interface PetApi { tags = ["pet",], summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -187,7 +187,7 @@ interface PetApi { tags = ["pet",], summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], @@ -211,7 +211,7 @@ interface PetApi { tags = ["pet",], summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], diff --git a/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/StoreApi.kt b/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/StoreApi.kt index 485509730aff..3a6ff04def03 100644 --- a/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/StoreApi.kt +++ b/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/StoreApi.kt @@ -43,7 +43,7 @@ interface StoreApi { tags = ["store",], summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") @@ -64,7 +64,7 @@ interface StoreApi { tags = ["store",], summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], @@ -84,7 +84,7 @@ interface StoreApi { tags = ["store",], summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -107,7 +107,7 @@ interface StoreApi { tags = ["store",], summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") diff --git a/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/UserApi.kt b/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/UserApi.kt index 153217650b86..a0c362c783b0 100644 --- a/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/UserApi.kt +++ b/samples/server/petstore/kotlin-springboot-delegate/src/main/kotlin/org/openapitools/api/UserApi.kt @@ -43,7 +43,7 @@ interface UserApi { tags = ["user",], summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -65,7 +65,7 @@ interface UserApi { tags = ["user",], summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -87,7 +87,7 @@ interface UserApi { tags = ["user",], summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -109,7 +109,7 @@ interface UserApi { tags = ["user",], summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") @@ -131,7 +131,7 @@ interface UserApi { tags = ["user",], summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -154,7 +154,7 @@ interface UserApi { tags = ["user",], summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") @@ -177,7 +177,7 @@ interface UserApi { tags = ["user",], summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], @@ -196,7 +196,7 @@ interface UserApi { tags = ["user",], summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") diff --git a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/PetApiController.kt b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/PetApiController.kt index e18012463efb..ad60def2e455 100644 --- a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/PetApiController.kt +++ b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/PetApiController.kt @@ -37,7 +37,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -57,7 +57,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid pet value") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -77,7 +77,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") ], @@ -98,7 +98,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") ], @@ -120,7 +120,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -142,7 +142,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Pet not found"), @@ -164,7 +164,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -186,7 +186,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] diff --git a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiController.kt b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiController.kt index 1884db667f9c..ad4105a5eb68 100644 --- a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiController.kt +++ b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiController.kt @@ -36,7 +36,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") ] @@ -55,7 +55,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], security = [ SecurityRequirement(name = "api_key") ] @@ -73,7 +73,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -94,7 +94,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") ] diff --git a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 60e754529448..c6e46319e7ce 100644 --- a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/UserApiController.kt b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/UserApiController.kt index 166e2764f7c2..66719f93d3ce 100644 --- a/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/UserApiController.kt +++ b/samples/server/petstore/kotlin-springboot-modelMutable/src/main/kotlin/org/openapitools/api/UserApiController.kt @@ -36,7 +36,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -54,7 +54,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -72,7 +72,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -90,7 +90,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") ] @@ -109,7 +109,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -130,7 +130,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") ] @@ -151,7 +151,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -167,7 +167,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") ] diff --git a/samples/server/petstore/kotlin-springboot-multipart-request-model/src/main/kotlin/org/openapitools/api/MultipartMixedApiController.kt b/samples/server/petstore/kotlin-springboot-multipart-request-model/src/main/kotlin/org/openapitools/api/MultipartMixedApiController.kt index dd50dc75d4d9..632484c3586f 100644 --- a/samples/server/petstore/kotlin-springboot-multipart-request-model/src/main/kotlin/org/openapitools/api/MultipartMixedApiController.kt +++ b/samples/server/petstore/kotlin-springboot-multipart-request-model/src/main/kotlin/org/openapitools/api/MultipartMixedApiController.kt @@ -37,7 +37,7 @@ class MultipartMixedApiController() { @Operation( summary = "", operationId = "multipartMixed", - description = """Mixed MultipartFile test""", + description = "Mixed MultipartFile test", responses = [ ApiResponse(responseCode = "204", description = "Successful operation") ] ) diff --git a/samples/server/petstore/kotlin-springboot-no-response-entity-delegate/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-no-response-entity-delegate/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 60e754529448..c6e46319e7ce 100644 --- a/samples/server/petstore/kotlin-springboot-no-response-entity-delegate/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-no-response-entity-delegate/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 60e754529448..c6e46319e7ce 100644 --- a/samples/server/petstore/kotlin-springboot-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-no-response-entity/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-paged-model/src/main/kotlin/org/openapitools/model/SearchResult.kt b/samples/server/petstore/kotlin-springboot-paged-model/src/main/kotlin/org/openapitools/model/SearchResult.kt index 808117dbd28f..d8b2abeafdd3 100644 --- a/samples/server/petstore/kotlin-springboot-paged-model/src/main/kotlin/org/openapitools/model/SearchResult.kt +++ b/samples/server/petstore/kotlin-springboot-paged-model/src/main/kotlin/org/openapitools/model/SearchResult.kt @@ -17,7 +17,7 @@ import jakarta.validation.constraints.Size import jakarta.validation.Valid /** - * Search result with metadata — no 'content' array at all + * Search result with metadata — no 'content' array at all * @param query * @param totalHits * @param page diff --git a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/PetApiController.kt b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/PetApiController.kt index 4d9a71a3d4e6..0d2e6a54e2de 100644 --- a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/PetApiController.kt +++ b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/PetApiController.kt @@ -38,7 +38,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "405", description = "Invalid input") ], @@ -60,7 +60,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid pet value") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -80,7 +80,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") ], @@ -101,7 +101,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") ], @@ -123,7 +123,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -145,7 +145,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -169,7 +169,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -191,7 +191,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] diff --git a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiController.kt b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiController.kt index 03750f1b7577..0c596fed2cce 100644 --- a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiController.kt +++ b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiController.kt @@ -37,7 +37,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") ] @@ -56,7 +56,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], security = [ SecurityRequirement(name = "api_key") ] @@ -74,7 +74,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -95,7 +95,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") ] diff --git a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiService.kt index ca81edd9f2b0..bfa7b22979b9 100644 --- a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -27,7 +27,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/UserApiController.kt b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/UserApiController.kt index e81a31b5697d..a7ce37324af7 100644 --- a/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/UserApiController.kt +++ b/samples/server/petstore/kotlin-springboot-reactive-without-flow/src/main/kotlin/org/openapitools/api/UserApiController.kt @@ -37,7 +37,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -57,7 +57,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -77,7 +77,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -97,7 +97,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") ], @@ -117,7 +117,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -138,7 +138,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") ] @@ -159,7 +159,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -176,7 +176,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") ], diff --git a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/PetApiController.kt b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/PetApiController.kt index 9e04cc7c297a..bd5b1d334916 100644 --- a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/PetApiController.kt +++ b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/PetApiController.kt @@ -38,7 +38,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "405", description = "Invalid input") ], @@ -60,7 +60,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid pet value") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -80,7 +80,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") ], @@ -101,7 +101,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") ], @@ -123,7 +123,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -145,7 +145,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -169,7 +169,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -191,7 +191,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] diff --git a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiController.kt b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiController.kt index 03750f1b7577..0c596fed2cce 100644 --- a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiController.kt +++ b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiController.kt @@ -37,7 +37,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") ] @@ -56,7 +56,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], security = [ SecurityRequirement(name = "api_key") ] @@ -74,7 +74,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -95,7 +95,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") ] diff --git a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiService.kt index ca81edd9f2b0..bfa7b22979b9 100644 --- a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -27,7 +27,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/UserApiController.kt b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/UserApiController.kt index e81a31b5697d..a7ce37324af7 100644 --- a/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/UserApiController.kt +++ b/samples/server/petstore/kotlin-springboot-reactive/src/main/kotlin/org/openapitools/api/UserApiController.kt @@ -37,7 +37,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -57,7 +57,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -77,7 +77,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -97,7 +97,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") ], @@ -117,7 +117,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -138,7 +138,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") ] @@ -159,7 +159,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ], security = [ SecurityRequirement(name = "api_key") ] @@ -176,7 +176,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") ], diff --git a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeApi.kt b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeApi.kt index f7ba7d39a58f..21cdb9ba4e26 100644 --- a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeApi.kt +++ b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeApi.kt @@ -41,7 +41,7 @@ interface FakeApi { tags = ["fake",], summary = "", operationId = "fakeCookieSuggestion", - description = """Test list of objects with additional values matching data from cookie""", + description = "Test list of objects with additional values matching data from cookie", responses = [ ApiResponse(responseCode = "200", description = "List of pets resolved from suggestion", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]) ] diff --git a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeClassnameTestApi.kt b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeClassnameTestApi.kt index 84493df08899..e40e2eab6940 100644 --- a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeClassnameTestApi.kt +++ b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FakeClassnameTestApi.kt @@ -38,10 +38,10 @@ import kotlin.collections.Map interface FakeClassnameTestApi { @Operation( - tags = ["fake_classname_tags 123#$%^",], + tags = ["fake_classname_tags 123#\$%^",], summary = "To test class name in snake case", operationId = "testClassname", - description = """To test class name in snake case""", + description = "To test class name in snake case", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Client::class))]) ], diff --git a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FooApi.kt b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FooApi.kt index 86e2e10d40b3..64490ddec4e7 100644 --- a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FooApi.kt +++ b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/FooApi.kt @@ -41,7 +41,7 @@ interface FooApi { tags = ["default",], summary = "", operationId = "fooGet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "response", content = [Content(schema = Schema(implementation = FooGetDefaultResponse::class))]) ] diff --git a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/PetApi.kt b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/PetApi.kt index 0501ab4c8978..d20525515c4b 100644 --- a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/PetApi.kt +++ b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/PetApi.kt @@ -42,7 +42,7 @@ interface PetApi { tags = ["pet",], summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "Successful operation"), ApiResponse(responseCode = "405", description = "Invalid input") @@ -65,7 +65,7 @@ interface PetApi { tags = ["pet",], summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "Successful operation"), ApiResponse(responseCode = "400", description = "Invalid pet value") @@ -88,7 +88,7 @@ interface PetApi { tags = ["pet",], summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") @@ -111,7 +111,7 @@ interface PetApi { tags = ["pet",], summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") @@ -135,7 +135,7 @@ interface PetApi { tags = ["pet",], summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -159,7 +159,7 @@ interface PetApi { tags = ["pet",], summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "Successful operation"), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -184,7 +184,7 @@ interface PetApi { tags = ["pet",], summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "Successful operation"), ApiResponse(responseCode = "405", description = "Invalid input") @@ -209,7 +209,7 @@ interface PetApi { tags = ["pet",], summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], diff --git a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/StoreApi.kt b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/StoreApi.kt index e3097b10ff77..49c8033f4cf0 100644 --- a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/StoreApi.kt +++ b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/StoreApi.kt @@ -41,7 +41,7 @@ interface StoreApi { tags = ["store",], summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") @@ -62,7 +62,7 @@ interface StoreApi { tags = ["store",], summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], @@ -82,7 +82,7 @@ interface StoreApi { tags = ["store",], summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -105,7 +105,7 @@ interface StoreApi { tags = ["store",], summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") diff --git a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/UserApi.kt b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/UserApi.kt index 8a9f41273db9..ea7710542c9d 100644 --- a/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/UserApi.kt +++ b/samples/server/petstore/kotlin-springboot-request-cookie/src/main/kotlin/org/openapitools/api/UserApi.kt @@ -41,7 +41,7 @@ interface UserApi { tags = ["user",], summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] @@ -62,7 +62,7 @@ interface UserApi { tags = ["user",], summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] @@ -83,7 +83,7 @@ interface UserApi { tags = ["user",], summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] @@ -104,7 +104,7 @@ interface UserApi { tags = ["user",], summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") @@ -125,7 +125,7 @@ interface UserApi { tags = ["user",], summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -148,7 +148,7 @@ interface UserApi { tags = ["user",], summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") @@ -171,7 +171,7 @@ interface UserApi { tags = ["user",], summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] @@ -189,7 +189,7 @@ interface UserApi { tags = ["user",], summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") diff --git a/samples/server/petstore/kotlin-springboot-source-swagger1/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-source-swagger1/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 60e754529448..c6e46319e7ce 100644 --- a/samples/server/petstore/kotlin-springboot-source-swagger1/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-source-swagger1/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/PetApiController.kt b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/PetApiController.kt index 98c84939c6dd..2def93621468 100644 --- a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/PetApiController.kt +++ b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/PetApiController.kt @@ -37,7 +37,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Add a new pet to the store", operationId = "addPet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -57,7 +57,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Deletes a pet", operationId = "deletePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid pet value") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -79,7 +79,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by status", operationId = "findPetsByStatus", - description = """Multiple status values can be provided with comma separated strings""", + description = "Multiple status values can be provided with comma separated strings", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid status value") ], @@ -100,7 +100,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Finds Pets by tags", operationId = "findPetsByTags", - description = """Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.""", + description = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(array = ArraySchema(schema = Schema(implementation = Pet::class)))]), ApiResponse(responseCode = "400", description = "Invalid tag value") ], @@ -122,7 +122,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Find pet by ID", operationId = "getPetById", - description = """Returns a single pet""", + description = "Returns a single pet", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Pet::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -144,7 +144,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Update an existing pet", operationId = "updatePet", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Pet not found"), @@ -166,7 +166,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "Updates a pet in the store with form data", operationId = "updatePetWithForm", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "405", description = "Invalid input") ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] @@ -188,7 +188,7 @@ class PetApiController(@Autowired(required = true) val service: PetApiService) { @Operation( summary = "uploads an image", operationId = "uploadFile", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = ModelApiResponse::class))]) ], security = [ SecurityRequirement(name = "petstore_auth", scopes = [ "write:pets", "read:pets" ]) ] diff --git a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiController.kt b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiController.kt index 1884db667f9c..ad4105a5eb68 100644 --- a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiController.kt +++ b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiController.kt @@ -36,7 +36,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Delete purchase order by ID", operationId = "deleteOrder", - description = """For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors""", + description = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", responses = [ ApiResponse(responseCode = "400", description = "Invalid ID supplied"), ApiResponse(responseCode = "404", description = "Order not found") ] @@ -55,7 +55,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Returns pet inventories by status", operationId = "getInventory", - description = """Returns a map of status codes to quantities""", + description = "Returns a map of status codes to quantities", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.collections.Map::class))]) ], security = [ SecurityRequirement(name = "api_key") ] @@ -73,7 +73,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Find purchase order by ID", operationId = "getOrderById", - description = """For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions""", + description = "For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid ID supplied"), @@ -94,7 +94,7 @@ class StoreApiController(@Autowired(required = true) val service: StoreApiServic @Operation( summary = "Place an order for a pet", operationId = "placeOrder", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = Order::class))]), ApiResponse(responseCode = "400", description = "Invalid Order") ] diff --git a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 60e754529448..c6e46319e7ce 100644 --- a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/UserApiController.kt b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/UserApiController.kt index 166e2764f7c2..66719f93d3ce 100644 --- a/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/UserApiController.kt +++ b/samples/server/petstore/kotlin-springboot-source-swagger2/src/main/kotlin/org/openapitools/api/UserApiController.kt @@ -36,7 +36,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Create user", operationId = "createUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -54,7 +54,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithArrayInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -72,7 +72,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Creates list of users with given input array", operationId = "createUsersWithListInput", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -90,7 +90,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Delete user", operationId = "deleteUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid username supplied"), ApiResponse(responseCode = "404", description = "User not found") ] @@ -109,7 +109,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Get user by user name", operationId = "getUserByName", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = User::class))]), ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -130,7 +130,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs user into the system", operationId = "loginUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "200", description = "successful operation", content = [Content(schema = Schema(implementation = kotlin.String::class))]), ApiResponse(responseCode = "400", description = "Invalid username/password supplied") ] @@ -151,7 +151,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Logs out current logged in user session", operationId = "logoutUser", - description = """""", + description = "", responses = [ ApiResponse(responseCode = "default", description = "successful operation") ] ) @@ -167,7 +167,7 @@ class UserApiController(@Autowired(required = true) val service: UserApiService) @Operation( summary = "Updated user", operationId = "updateUser", - description = """This can only be done by the logged in user.""", + description = "This can only be done by the logged in user.", responses = [ ApiResponse(responseCode = "400", description = "Invalid user supplied"), ApiResponse(responseCode = "404", description = "User not found") ] diff --git a/samples/server/petstore/kotlin-springboot/src/main/kotlin/org/openapitools/api/StoreApiService.kt b/samples/server/petstore/kotlin-springboot/src/main/kotlin/org/openapitools/api/StoreApiService.kt index 60e754529448..c6e46319e7ce 100644 --- a/samples/server/petstore/kotlin-springboot/src/main/kotlin/org/openapitools/api/StoreApiService.kt +++ b/samples/server/petstore/kotlin-springboot/src/main/kotlin/org/openapitools/api/StoreApiService.kt @@ -26,7 +26,7 @@ interface StoreApiService { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/FakeApi.java index 9af1536f7766..a969729984a5 100644 --- a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/FakeApi.java @@ -220,14 +220,14 @@ ResponseEntity responseObjectDifferentNam String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -271,8 +271,8 @@ ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -301,8 +301,14 @@ ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -323,8 +329,8 @@ ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -362,14 +368,14 @@ ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -389,9 +395,9 @@ ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/StoreApi.java index fef0d5f25373..bb1995fae86a 100644 --- a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/api/StoreApi.java @@ -98,7 +98,7 @@ ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/spring-boot-defaultInterface-unhandledExcp/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/FakeApi.java index 52954ed868ca..a7674edd7162 100644 --- a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/FakeApi.java @@ -263,14 +263,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -320,8 +320,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -362,8 +362,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -384,8 +390,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -426,14 +432,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -453,9 +459,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/StoreApi.java index 0813a3064040..cfdef0b90498 100644 --- a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/Capitalization.java index f5586fc124e3..5e797c5ec303 100644 --- a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/Capitalization.java @@ -159,11 +159,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/ClassModel.java index 95616cfc6ca5..fa50269e0bae 100644 --- a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/ClassModel.java @@ -18,7 +18,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/File.java index 71bf200ab801..29e013f6f8e1 100644 --- a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/java/org/openapitools/model/File.java @@ -18,7 +18,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-beanvalidation-no-nullable/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/FakeApi.java index 52954ed868ca..a7674edd7162 100644 --- a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/FakeApi.java @@ -263,14 +263,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -320,8 +320,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -362,8 +362,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -384,8 +390,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -426,14 +432,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -453,9 +459,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/StoreApi.java index 0813a3064040..cfdef0b90498 100644 --- a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-beanvalidation/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-beanvalidation/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-beanvalidation/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-beanvalidation/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-beanvalidation/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/FakeApi.java index 454c94bfb6e0..7b7ead7798d9 100644 --- a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/FakeApi.java @@ -263,14 +263,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -320,8 +320,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -362,8 +362,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -384,8 +390,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -426,14 +432,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -453,9 +459,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/StoreApi.java index 22ad10d8e5b4..f845db009efe 100644 --- a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-builtin-validation/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-builtin-validation/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-builtin-validation/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-builtin-validation/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-builtin-validation/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApi.java index f8c2da3c98e8..5d4a344239ca 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApi.java @@ -235,14 +235,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -290,8 +290,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -322,8 +322,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -344,8 +350,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -385,14 +391,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -412,9 +418,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java index 5b6cdd7f828f..cb16f6879bbc 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java +++ b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java @@ -135,7 +135,7 @@ default ResponseEntity responseObjectDiff /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -161,8 +161,8 @@ default ResponseEntity testBodyWithQueryParams(String query, } /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -183,8 +183,14 @@ default ResponseEntity testClientModel(Client client) { } /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -226,14 +232,14 @@ default ResponseEntity testEndpointParameters(BigDecimal number, * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) * @see FakeApi#testEnumParameters diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApi.java index e942c0ba6398..395285bbf2ea 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApi.java @@ -105,7 +105,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java index 7e90b451b58e..7cdb6f136f89 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -54,7 +54,7 @@ default ResponseEntity> getInventory() { /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-delegate-j8/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-delegate-j8/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-delegate-j8/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-delegate-j8/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-delegate-j8/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApi.java b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApi.java index c1bff9f0662c..643e97f3ce28 100644 --- a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApi.java @@ -243,7 +243,7 @@ default Pet getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApiDelegate.java b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApiDelegate.java index ae977f8f1bb5..6704ffddff4e 100644 --- a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApiDelegate.java +++ b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/PetApiDelegate.java @@ -166,7 +166,7 @@ default Pet getPetById(Long petId) { * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation * @see PetApi#updatePet */ default Pet updatePet(Pet pet) { diff --git a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApi.java index 0b5fedec1da6..f2ad309012bf 100644 --- a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApi.java @@ -107,7 +107,7 @@ default Map getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApiDelegate.java index 3b63b91bd905..3326f7951ac8 100644 --- a/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-delegate-no-response-entity/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -53,7 +53,7 @@ default Map getInventory() { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java index f8c2da3c98e8..5d4a344239ca 100644 --- a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApi.java @@ -235,14 +235,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -290,8 +290,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -322,8 +322,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -344,8 +350,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -385,14 +391,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -412,9 +418,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java index 5b6cdd7f828f..cb16f6879bbc 100644 --- a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java +++ b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/FakeApiDelegate.java @@ -135,7 +135,7 @@ default ResponseEntity responseObjectDiff /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -161,8 +161,8 @@ default ResponseEntity testBodyWithQueryParams(String query, } /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -183,8 +183,14 @@ default ResponseEntity testClientModel(Client client) { } /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -226,14 +232,14 @@ default ResponseEntity testEndpointParameters(BigDecimal number, * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) * @see FakeApi#testEnumParameters diff --git a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java index e942c0ba6398..395285bbf2ea 100644 --- a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApi.java @@ -105,7 +105,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java index 7e90b451b58e..7cdb6f136f89 100644 --- a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -54,7 +54,7 @@ default ResponseEntity> getInventory() { /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java index a67ffd0d03f3..18ded4a63f77 100644 --- a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/Capitalization.java @@ -168,11 +168,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java index c75bf73efcfa..b8e5b9dfef6f 100644 --- a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java index d417a7081fab..99f0a3059bfa 100644 --- a/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-delegate/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-delegate/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-delegate/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-delegate/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-delegate/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/PetApi.java b/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/PetApi.java index b18987505442..ce7e7e004db3 100644 --- a/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/PetApi.java @@ -210,7 +210,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @RequestMapping( method = RequestMethod.PUT, diff --git a/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/StoreApi.java index f24ccfc33eb1..7719b1a7ca9c 100644 --- a/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-implicitHeaders-annotationLibrary/src/main/java/org/openapitools/api/StoreApi.java @@ -74,7 +74,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java index 5315a2a9b78a..38d2b4cba78d 100644 --- a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/FakeApi.java @@ -263,14 +263,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -320,8 +320,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -362,8 +362,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -384,8 +390,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -426,12 +432,12 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -455,7 +461,7 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java index db15a801607e..8a479398c4a4 100644 --- a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java index 556f27bc412a..9f9db994dc1c 100644 --- a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java index 1a1b8e9665da..543a0ccff553 100644 --- a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import javax.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java index f5e090c32ca2..bf6b96d84526 100644 --- a/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-implicitHeaders/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import javax.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-implicitHeaders/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/FakeApi.java index 8699c08ae736..638d5178fb92 100644 --- a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/FakeApi.java @@ -270,14 +270,14 @@ default ResponseEntity responseObjectD String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClassDto (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -329,8 +329,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param clientDto client model (required) * @return successful operation (status code 200) @@ -372,8 +372,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -394,8 +400,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -437,14 +443,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -464,9 +470,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java index 25d0ec7d461e..407cd2b3fffc 100644 --- a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/api/StoreApi.java @@ -113,7 +113,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/CapitalizationDto.java b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/CapitalizationDto.java index 634f79ee7bde..8cb2170b594f 100644 --- a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/CapitalizationDto.java +++ b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/CapitalizationDto.java @@ -154,11 +154,11 @@ public CapitalizationDto ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/ClassModelDto.java b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/ClassModelDto.java index 7ffddc733751..8c3652cc2872 100644 --- a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/ClassModelDto.java +++ b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/ClassModelDto.java @@ -18,7 +18,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/FileDto.java b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/FileDto.java index b02fa80ed592..e8a2cf2706f4 100644 --- a/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/FileDto.java +++ b/samples/server/petstore/springboot-include-http-request-context/src/main/java/org/openapitools/model/FileDto.java @@ -18,7 +18,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-include-http-request-context/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-include-http-request-context/src/main/resources/openapi.yaml index c93e954114f0..a630f048a0ad 100644 --- a/samples/server/petstore/springboot-include-http-request-context/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-include-http-request-context/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2296,9 +2298,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/PetApi.java b/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/PetApi.java index 7f0b47028028..e19c9a888e77 100644 --- a/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/PetApi.java @@ -303,7 +303,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/StoreApi.java index 8425ab0970d4..c5e8bc211d61 100644 --- a/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-lombok-data/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/PetApi.java b/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/PetApi.java index 7f0b47028028..e19c9a888e77 100644 --- a/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/PetApi.java @@ -303,7 +303,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/StoreApi.java index 8425ab0970d4..c5e8bc211d61 100644 --- a/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-lombok-tostring/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApi.java b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApi.java index 26ac8b4e0645..dc50054e38c2 100644 --- a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApi.java +++ b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApi.java @@ -254,7 +254,7 @@ default ResponseEntity getPetById( * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation */ @Operation( operationId = "updatePet", diff --git a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApiDelegate.java b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApiDelegate.java index 9ee4cb85f6a8..ec11be3b8545 100644 --- a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApiDelegate.java +++ b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/PetApiDelegate.java @@ -167,7 +167,7 @@ default ResponseEntity getPetById(Long petId) { * or Pet not found (status code 404) * or Validation exception (status code 405) * API documentation for the updatePet operation - * @see Update an existing pet Documentation + * @see API documentation for the updatePet operation * @see PetApi#updatePet */ default ResponseEntity updatePet(Pet pet) { diff --git a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApi.java index 8e37bfe64c8b..e2c5e9ebcf6b 100644 --- a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApi.java @@ -105,7 +105,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{orderId}"; /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApiDelegate.java index 7dcf713d2bd0..a548287a3f02 100644 --- a/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-petstore-with-api-response-examples/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -54,7 +54,7 @@ default ResponseEntity> getInventory() { /** * GET /store/order/{orderId} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java index b83280bb0482..9326e387b238 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApi.java @@ -244,14 +244,14 @@ default Mono responseObjectDifferentNames String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -301,8 +301,8 @@ default Mono testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -334,8 +334,14 @@ default Mono testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -356,8 +362,8 @@ default Mono testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -398,14 +404,14 @@ default Mono testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -426,9 +432,9 @@ default Mono testEndpointParameters( ) @ResponseStatus(HttpStatus.BAD_REQUEST) default Mono testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApiDelegate.java b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApiDelegate.java index 6e86c59c7b1f..21f932e174d6 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApiDelegate.java +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/FakeApiDelegate.java @@ -137,7 +137,7 @@ default Mono responseObjectDifferentNames /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -169,8 +169,8 @@ default Mono testBodyWithQueryParams(String query, } /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -185,8 +185,14 @@ default Mono testClientModel(Mono client) { } /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -231,14 +237,14 @@ default Mono testEndpointParameters(BigDecimal number, * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) * @see FakeApi#testEnumParameters diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java index 639ff2a22074..810550abf4bd 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApi.java @@ -110,7 +110,7 @@ default Mono> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApiDelegate.java index 23aaf3b2ffef..5dcd88eaaba8 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -62,7 +62,7 @@ default Mono> getInventory() { /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-reactive-noResponseEntity/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApi.java index b638df522667..e79de7df99e4 100644 --- a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApi.java @@ -245,14 +245,14 @@ default Mono> responseObje String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -302,8 +302,8 @@ default Mono> testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -335,8 +335,14 @@ default Mono> testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -357,8 +363,8 @@ default Mono> testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -399,14 +405,14 @@ default Mono> testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -426,9 +432,9 @@ default Mono> testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default Mono> testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApiDelegate.java b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApiDelegate.java index 030b302bfc28..33b88baceb7f 100644 --- a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApiDelegate.java +++ b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/FakeApiDelegate.java @@ -171,7 +171,7 @@ default Mono> responseObje /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -209,8 +209,8 @@ default Mono> testBodyWithQueryParams(String query, } /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -235,8 +235,14 @@ default Mono> testClientModel(Mono client, } /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -284,14 +290,14 @@ default Mono> testEndpointParameters(BigDecimal number, * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) * @see FakeApi#testEnumParameters diff --git a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApi.java index 2c52ce3dddf3..a508f0a1a18e 100644 --- a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApi.java @@ -110,7 +110,7 @@ default Mono>> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApiDelegate.java index 625431966e02..25e7deda9188 100644 --- a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -69,7 +69,7 @@ default Mono>> getInventory(ServerWebExchang /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-reactive/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-reactive/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-reactive/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-reactive/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-reactive/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApi.java index 5c7f0b24309a..706df3369d5e 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApi.java @@ -201,7 +201,7 @@ default ResponseEntity fakeOuterStringSerialize( String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request much reference a schema named `File`. * * @param body (required) * @return Success (status code 200) @@ -256,8 +256,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param body client model (required) * @return successful operation (status code 200) @@ -288,8 +288,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -310,8 +316,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", + summary = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", + description = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -357,8 +363,8 @@ default ResponseEntity testEndpointParameters( * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java index fea3cd713cc0..3e8824b04661 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/FakeApiDelegate.java @@ -112,7 +112,7 @@ default ResponseEntity fakeOuterStringSerialize(String body) { /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request much reference a schema named `File`. * * @param body (required) * @return Success (status code 200) @@ -138,8 +138,8 @@ default ResponseEntity testBodyWithQueryParams(String query, } /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param body client model (required) * @return successful operation (status code 200) @@ -160,8 +160,14 @@ default ResponseEntity testClientModel(Client body) { } /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -209,8 +215,8 @@ default ResponseEntity testEndpointParameters(BigDecimal number, * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) * @see FakeApi#testEnumParameters diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApi.java index 084437a4ff25..8e45f2a355bc 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApi.java @@ -105,7 +105,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java index eef8b116d596..86166a18d2f7 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -54,7 +54,7 @@ default ResponseEntity> getInventory() { /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern-without-j8/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApi.java index 5c7f0b24309a..706df3369d5e 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApi.java @@ -201,7 +201,7 @@ default ResponseEntity fakeOuterStringSerialize( String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request much reference a schema named `File`. * * @param body (required) * @return Success (status code 200) @@ -256,8 +256,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param body client model (required) * @return successful operation (status code 200) @@ -288,8 +288,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -310,8 +316,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", + summary = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", + description = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -357,8 +363,8 @@ default ResponseEntity testEndpointParameters( * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApiDelegate.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApiDelegate.java index fea3cd713cc0..3e8824b04661 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApiDelegate.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/FakeApiDelegate.java @@ -112,7 +112,7 @@ default ResponseEntity fakeOuterStringSerialize(String body) { /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request much reference a schema named `File`. * * @param body (required) * @return Success (status code 200) @@ -138,8 +138,8 @@ default ResponseEntity testBodyWithQueryParams(String query, } /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param body client model (required) * @return successful operation (status code 200) @@ -160,8 +160,14 @@ default ResponseEntity testClientModel(Client body) { } /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -209,8 +215,8 @@ default ResponseEntity testEndpointParameters(BigDecimal number, * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) * @see FakeApi#testEnumParameters diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApi.java index 084437a4ff25..8e45f2a355bc 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApi.java @@ -105,7 +105,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApiDelegate.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApiDelegate.java index eef8b116d596..86166a18d2f7 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApiDelegate.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/api/StoreApiDelegate.java @@ -54,7 +54,7 @@ default ResponseEntity> getInventory() { /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-spring-pageable-delegatePattern/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/FakeApi.java index 4319a7b8bef8..99ce86bb74b3 100644 --- a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/FakeApi.java @@ -219,7 +219,7 @@ default ResponseEntity fakeOuterStringSerialize( String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request much reference a schema named `File`. * * @param body (required) * @return Success (status code 200) @@ -276,8 +276,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param body client model (required) * @return successful operation (status code 200) @@ -318,8 +318,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -340,8 +346,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", + summary = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", + description = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -388,8 +394,8 @@ default ResponseEntity testEndpointParameters( * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ diff --git a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/StoreApi.java index 6b5e046cb344..6db36c06bd3f 100644 --- a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-spring-pageable-without-j8/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/FakeApi.java index 4319a7b8bef8..99ce86bb74b3 100644 --- a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/FakeApi.java @@ -219,7 +219,7 @@ default ResponseEntity fakeOuterStringSerialize( String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request much reference a schema named `File`. * * @param body (required) * @return Success (status code 200) @@ -276,8 +276,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param body client model (required) * @return successful operation (status code 200) @@ -318,8 +318,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -340,8 +346,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", + summary = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", + description = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -388,8 +394,8 @@ default ResponseEntity testEndpointParameters( * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ diff --git a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java index 6b5e046cb344..6db36c06bd3f 100644 --- a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/Capitalization.java index 6ad9a3fe434d..0463faac73fb 100644 --- a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/ClassModel.java index 8fdd6c0cff41..91717f14036b 100644 --- a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/File.java index e89b97aea7b3..51fd7983e1e4 100644 --- a/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-spring-pageable/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/FakeApi.java index 12a720bbe5fd..4f1d0a54c56a 100644 --- a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/FakeApi.java @@ -263,14 +263,14 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -320,8 +320,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -362,8 +362,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -384,8 +390,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -426,14 +432,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -453,9 +459,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) Optional> enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") Optional> enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") Optional enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) Optional> enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") Optional> enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") Optional enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) Optional enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) Optional enumQueryDouble, diff --git a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/StoreApi.java index 0813a3064040..cfdef0b90498 100644 --- a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/Capitalization.java b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/Capitalization.java index 0e533bc56b52..f89a7933f230 100644 --- a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/Capitalization.java +++ b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public Optional getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/ClassModel.java b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/ClassModel.java index 5c9563fca970..8755563e6d45 100644 --- a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/ClassModel.java +++ b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/File.java b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/File.java index a3ee7e38503c..22d213ca883a 100644 --- a/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/File.java +++ b/samples/server/petstore/springboot-useoptional/src/main/java/org/openapitools/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-useoptional/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-useoptional/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-useoptional/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-useoptional/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/FakeApi.java b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/FakeApi.java index bd3c0ef20206..f4d7fd0258b1 100644 --- a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/FakeApi.java +++ b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/FakeApi.java @@ -272,7 +272,7 @@ default ResponseEntity responseObjectDiff String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClass (required) * @return Success (status code 200) @@ -280,7 +280,7 @@ default ResponseEntity responseObjectDiff @ApiVirtual @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -331,8 +331,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param client client model (required) * @return successful operation (status code 200) @@ -374,8 +374,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -397,8 +403,8 @@ default ResponseEntity testClientModel( @ApiVirtual @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -439,14 +445,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -467,9 +473,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/StoreApi.java b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/StoreApi.java index e59e31d371a7..0e2beee1d47f 100644 --- a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/StoreApi.java +++ b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/api/StoreApi.java @@ -116,7 +116,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/Capitalization.java b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/Capitalization.java index 81a737c1b230..6c8e0878a7d2 100644 --- a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/Capitalization.java +++ b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/Capitalization.java @@ -152,11 +152,11 @@ public Capitalization ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/ClassModel.java b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/ClassModel.java index 05b40ea43678..4a0ddd289df4 100644 --- a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/ClassModel.java +++ b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/ClassModel.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/File.java b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/File.java index 0b9c9edcbaa8..13f93f9cfe8f 100644 --- a/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/File.java +++ b/samples/server/petstore/springboot-virtualan/src/main/java/org/openapitools/virtualan/model/File.java @@ -17,7 +17,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-virtualan/src/main/resources/openapi.yaml b/samples/server/petstore/springboot-virtualan/src/main/resources/openapi.yaml index 53ec8083c77d..0bc1c7d1c354 100644 --- a/samples/server/petstore/springboot-virtualan/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot-virtualan/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2308,9 +2310,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $ diff --git a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/FakeApi.java index 36501d5532c1..84e5c1051516 100644 --- a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/FakeApi.java @@ -411,7 +411,7 @@ default ResponseEntity testBodyWithBinary( String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request must reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClassDto (required) * @return Success (status code 200) @@ -468,8 +468,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param clientDto client model (required) * @return successful operation (status code 200) @@ -510,8 +510,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -532,8 +538,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", + summary = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", + description = "Fake endpoint for testing various parameters\n假端點\n偽のエンドポイント\n가짜 엔드 포인트\n", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -581,8 +587,8 @@ default ResponseEntity testEndpointParameters( * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) * @param enumQueryModelArray (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ diff --git a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/StoreApi.java index 621fff1557c7..94a889fc0324 100644 --- a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/CapitalizationDto.java b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/CapitalizationDto.java index 634f79ee7bde..8cb2170b594f 100644 --- a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/CapitalizationDto.java +++ b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/CapitalizationDto.java @@ -154,11 +154,11 @@ public CapitalizationDto ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/ClassModelDto.java b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/ClassModelDto.java index 7ffddc733751..8c3652cc2872 100644 --- a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/ClassModelDto.java +++ b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/ClassModelDto.java @@ -18,7 +18,7 @@ import jakarta.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FileDto.java b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FileDto.java index b02fa80ed592..e8a2cf2706f4 100644 --- a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FileDto.java +++ b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FileDto.java @@ -18,7 +18,7 @@ import jakarta.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FormatTestDto.java b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FormatTestDto.java index d61b7a9556d0..2292640c3497 100644 --- a/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FormatTestDto.java +++ b/samples/server/petstore/springboot-x-implements-skip/src/main/java/org/openapitools/model/FormatTestDto.java @@ -426,7 +426,7 @@ public FormatTestDto patternWithDigitsAndDelimiter(@Nullable String patternWithD } /** - * A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. + * A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. * @return patternWithDigitsAndDelimiter */ @Pattern(regexp = "/^image_\\d{1,3}$/i") diff --git a/samples/server/petstore/springboot/src/main/java/org/openapitools/api/FakeApi.java b/samples/server/petstore/springboot/src/main/java/org/openapitools/api/FakeApi.java index e3ff85fda171..25d17f75607d 100644 --- a/samples/server/petstore/springboot/src/main/java/org/openapitools/api/FakeApi.java +++ b/samples/server/petstore/springboot/src/main/java/org/openapitools/api/FakeApi.java @@ -263,14 +263,14 @@ default ResponseEntity responseObjectD String PATH_TEST_BODY_WITH_FILE_SCHEMA = "/fake/body-with-file-schema"; /** * PUT /fake/body-with-file-schema - * For this test, the body for this request much reference a schema named `File`. + * For this test, the body for this request must reference a schema named `File`. * * @param fileSchemaTestClassDto (required) * @return Success (status code 200) */ @Operation( operationId = "testBodyWithFileSchema", - description = "For this test, the body for this request much reference a schema named `File`.", + description = "For this test, the body for this request must reference a schema named `File`.", tags = { "fake" }, responses = { @ApiResponse(responseCode = "200", description = "Success") @@ -320,8 +320,8 @@ default ResponseEntity testBodyWithQueryParams( String PATH_TEST_CLIENT_MODEL = "/fake"; /** - * PATCH /fake : To test \"client\" model - * To test \"client\" model + * PATCH /fake : To test "client" model + * To test "client" model * * @param clientDto client model (required) * @return successful operation (status code 200) @@ -362,8 +362,14 @@ default ResponseEntity testClientModel( String PATH_TEST_ENDPOINT_PARAMETERS = "/fake"; /** - * POST /fake : Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - * Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 + * POST /fake : Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 + * Fake endpoint for testing various parameters + * 假端點 + * 偽のエンドポイント + * 가짜 엔드 포인트 * * @param number None (required) * @param _double None (required) @@ -384,8 +390,8 @@ default ResponseEntity testClientModel( */ @Operation( operationId = "testEndpointParameters", - summary = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", - description = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트", + summary = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", + description = "Fake endpoint for testing various parameters\n 假端點\n 偽のエンドポイント\n 가짜 엔드 포인트", tags = { "fake" }, responses = { @ApiResponse(responseCode = "400", description = "Invalid username supplied"), @@ -426,14 +432,14 @@ default ResponseEntity testEndpointParameters( * GET /fake : To test enum parameters * To test enum parameters * - * @param enumHeaderStringArray Header parameter enum test (string array) (optional) + * @param enumHeaderStringArray Header parameter enum test (string array) (optional, default to ["$"]) * @param enumHeaderString Header parameter enum test (string) (optional, default to -efg) - * @param enumQueryStringArray Query parameter enum test (string array) (optional) + * @param enumQueryStringArray Query parameter enum test (string array) (optional, default to ["$"]) * @param enumQueryString Query parameter enum test (string) (optional, default to -efg) * @param enumQueryInteger Query parameter enum test (double) (optional) * @param enumQueryDouble Query parameter enum test (double) (optional) - * @param enumFormStringArray Form parameter enum test (string array) (optional, default to $) - * @param enumFormString Form parameter enum test (string) (optional, default to -efg) + * @param enumFormStringArray Form parameter enum test (string array) (optional, OpenAPI schema default to ["$"]) + * @param enumFormString Form parameter enum test (string) (optional, OpenAPI schema default to -efg) * @return Invalid request (status code 400) * or Not found (status code 404) */ @@ -453,9 +459,9 @@ default ResponseEntity testEndpointParameters( consumes = { "application/x-www-form-urlencoded" } ) default ResponseEntity testEnumParameters( - @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false) @Nullable List enumHeaderStringArray, + @Parameter(name = "enum_header_string_array", description = "Header parameter enum test (string array)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string_array", required = false, defaultValue = "$") List enumHeaderStringArray, @Parameter(name = "enum_header_string", description = "Header parameter enum test (string)", in = ParameterIn.HEADER) @RequestHeader(value = "enum_header_string", required = false, defaultValue = "-efg") String enumHeaderString, - @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false) @Nullable List enumQueryStringArray, + @Parameter(name = "enum_query_string_array", description = "Query parameter enum test (string array)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string_array", required = false, defaultValue = "$") List enumQueryStringArray, @Parameter(name = "enum_query_string", description = "Query parameter enum test (string)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_string", required = false, defaultValue = "-efg") String enumQueryString, @Parameter(name = "enum_query_integer", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_integer", required = false) @Nullable Integer enumQueryInteger, @Parameter(name = "enum_query_double", description = "Query parameter enum test (double)", in = ParameterIn.QUERY) @Valid @RequestParam(value = "enum_query_double", required = false) @Nullable Double enumQueryDouble, diff --git a/samples/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java b/samples/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java index ad0a5f2f352c..fb3df66a1567 100644 --- a/samples/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java +++ b/samples/server/petstore/springboot/src/main/java/org/openapitools/api/StoreApi.java @@ -111,7 +111,7 @@ default ResponseEntity> getInventory( String PATH_GET_ORDER_BY_ID = "/store/order/{order_id}"; /** * GET /store/order/{order_id} : Find purchase order by ID - * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions + * For valid response try integer IDs with value <= 5 or > 10. Other values will generate exceptions * * @param orderId ID of pet that needs to be fetched (required) * @return successful operation (status code 200) diff --git a/samples/server/petstore/springboot/src/main/java/org/openapitools/model/CapitalizationDto.java b/samples/server/petstore/springboot/src/main/java/org/openapitools/model/CapitalizationDto.java index 35bee3406bd3..4848abbd8219 100644 --- a/samples/server/petstore/springboot/src/main/java/org/openapitools/model/CapitalizationDto.java +++ b/samples/server/petstore/springboot/src/main/java/org/openapitools/model/CapitalizationDto.java @@ -154,11 +154,11 @@ public CapitalizationDto ATT_NAME(@Nullable String ATT_NAME) { } /** - * Name of the pet + * Name of the pet * @return ATT_NAME */ - @Schema(name = "ATT_NAME", description = "Name of the pet ", requiredMode = Schema.RequiredMode.NOT_REQUIRED) + @Schema(name = "ATT_NAME", description = "Name of the pet\n", requiredMode = Schema.RequiredMode.NOT_REQUIRED) @JsonProperty("ATT_NAME") public @Nullable String getATTNAME() { return ATT_NAME; diff --git a/samples/server/petstore/springboot/src/main/java/org/openapitools/model/ClassModelDto.java b/samples/server/petstore/springboot/src/main/java/org/openapitools/model/ClassModelDto.java index ce44207d095a..f9dbef18104f 100644 --- a/samples/server/petstore/springboot/src/main/java/org/openapitools/model/ClassModelDto.java +++ b/samples/server/petstore/springboot/src/main/java/org/openapitools/model/ClassModelDto.java @@ -18,7 +18,7 @@ import javax.annotation.Generated; /** - * Model for testing model with \"_class\" property + * Model for testing model with "_class" property */ @Schema(name = "ClassModel", description = "Model for testing model with \"_class\" property") diff --git a/samples/server/petstore/springboot/src/main/java/org/openapitools/model/FileDto.java b/samples/server/petstore/springboot/src/main/java/org/openapitools/model/FileDto.java index 91b758e98395..e421d3b78251 100644 --- a/samples/server/petstore/springboot/src/main/java/org/openapitools/model/FileDto.java +++ b/samples/server/petstore/springboot/src/main/java/org/openapitools/model/FileDto.java @@ -18,7 +18,7 @@ import javax.annotation.Generated; /** - * Must be named `File` for test. + * Must be named `File` for test. */ @Schema(name = "File", description = "Must be named `File` for test.") diff --git a/samples/server/petstore/springboot/src/main/resources/openapi.yaml b/samples/server/petstore/springboot/src/main/resources/openapi.yaml index c93e954114f0..a630f048a0ad 100644 --- a/samples/server/petstore/springboot/src/main/resources/openapi.yaml +++ b/samples/server/petstore/springboot/src/main/resources/openapi.yaml @@ -743,8 +743,9 @@ paths: name: enum_header_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -770,8 +771,9 @@ paths: name: enum_query_string_array required: false schema: + default: + - $ items: - default: $ enum: - '>' - $ @@ -1133,7 +1135,7 @@ paths: - tag: $another-fake? /fake/body-with-file-schema: put: - description: "For this test, the body for this request much reference a schema\ + description: "For this test, the body for this request must reference a schema\ \ named `File`." operationId: testBodyWithFileSchema requestBody: @@ -2296,9 +2298,10 @@ components: testEnumParameters_request: properties: enum_form_string_array: + default: + - $ description: Form parameter enum test (string array) items: - default: $ enum: - '>' - $