Skip to content

Improve Kotlin Misk OpenApi Generator #21165

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 32 commits into from
Apr 29, 2025
Merged
Show file tree
Hide file tree
Changes from 26 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
54645dd
first pass
andrewwilsonnew Mar 26, 2025
cff7dbd
fixing types
andrewwilsonnew Mar 26, 2025
03e9b47
fixing action
andrewwilsonnew Mar 26, 2025
787304a
updating samples
andrewwilsonnew Mar 26, 2025
8888fbe
updating files
andrewwilsonnew Mar 26, 2025
2e66982
adding guido
andrewwilsonnew Mar 26, 2025
1f56a8f
fixing misk
andrewwilsonnew Apr 3, 2025
42aaaef
removing old files
andrewwilsonnew Apr 3, 2025
981d81c
cleaning generated files
andrewwilsonnew Apr 3, 2025
53514b9
cleaning generated files
andrewwilsonnew Apr 3, 2025
3e0077a
adding back in license
andrewwilsonnew Apr 3, 2025
cc6d9d5
first pass
andrewwilsonnew Apr 28, 2025
de78670
second pass
andrewwilsonnew Apr 28, 2025
b0f96c0
third pass
andrewwilsonnew Apr 28, 2025
93a5550
typo
andrewwilsonnew Apr 28, 2025
f5d4d40
fixup
andrewwilsonnew Apr 28, 2025
fe76a63
fixup 2
andrewwilsonnew Apr 28, 2025
281d61f
Merge remote-tracking branch 'origin/master' into cashapp/misk5
andrewwilsonnew Apr 28, 2025
8cc1d45
fixup 3
andrewwilsonnew Apr 28, 2025
0f6e76c
fixup 4
andrewwilsonnew Apr 28, 2025
128a926
fixup 5
andrewwilsonnew Apr 28, 2025
b059a74
fixup 6
andrewwilsonnew Apr 28, 2025
af99d11
fixing api override
andrewwilsonnew Apr 28, 2025
e932986
fixing docs
andrewwilsonnew Apr 28, 2025
17124ee
fixing docs json
andrewwilsonnew Apr 28, 2025
e5ef191
fix misk version
andrewwilsonnew Apr 29, 2025
6605164
add action prefix
andrewwilsonnew Apr 29, 2025
ad0fd7a
fixup
andrewwilsonnew Apr 29, 2025
90ea506
fixup 2
andrewwilsonnew Apr 29, 2025
cc80a38
fixup 3
andrewwilsonnew Apr 29, 2025
a6d9e51
fixup 4
andrewwilsonnew Apr 29, 2025
460c807
fixup 5
andrewwilsonnew Apr 29, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions bin/configs/kotlin-misk-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
generatorName: kotlin-misk
outputDir: samples/server/petstore/kotlin-misk-config
inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore.yaml
templateDir: modules/openapi-generator/src/main/resources/kotlin-misk
validateSpec: false
additionalProperties:
hideGenerationTimestamp: "true"
moduleClassName: "PetStoreModule"
generateStubImplClasses: true
addModelMoshiJsonAnnotation: true
1 change: 0 additions & 1 deletion bin/configs/kotlin-misk.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ generatorName: kotlin-misk
outputDir: samples/server/petstore/kotlin-misk
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe we can delete this one if its not required?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore.yaml
templateDir: modules/openapi-generator/src/main/resources/kotlin-misk
validateSpec: false
additionalProperties:
hideGenerationTimestamp: "true"
moduleClassName: "PetStoreModule"
4 changes: 3 additions & 1 deletion docs/generators/kotlin-misk.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,13 @@ These options may be applied as additional-properties (cli) or configOptions (pl

| Option | Description | Values | Default |
| ------ | ----------- | ------ | ------- |
|addModelMoshiJsonAnnotation|Add a Moshi JSON adapter annotation to all model classes| |true|
|additionalModelTypeAnnotations|Additional annotations for model type(class level annotations). List separated by semicolon(;) or new line (Linux or Windows)| |null|
|apiSuffix|suffix for api classes| |Api|
|artifactId|Generated artifact id (name of jar).| |null|
|artifactVersion|Generated artifact's package version.| |1.0.0|
|enumPropertyNaming|Naming convention for enum properties: 'camelCase', 'PascalCase', 'snake_case', 'UPPERCASE', and 'original'| |original|
|generateStubImplClasses|Generate Stub Impl Classes| |false|
|groupId|Generated artifact package's organization (i.e. maven groupId).| |org.openapitools|
|modelMutable|Create mutable models| |false|
|moduleClassName|Name of the generated module class| |OpenApiModule|
Expand Down Expand Up @@ -273,7 +275,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl
### Wire Format Feature
| Name | Supported | Defined By |
| ---- | --------- | ---------- |
|JSON||OAS2,OAS3
|JSON||OAS2,OAS3
|XML|✗|OAS2,OAS3
|PROTOBUF|✓|ToolingExtension
|Custom|✗|OAS2,OAS3
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,22 @@

public class KotlinMiskServerCodegen extends AbstractKotlinCodegen implements BeanValidationFeatures {

private final Logger LOGGER = LoggerFactory.getLogger(KotlinMiskServerCodegen.class);

public static final String MODULE_CLASS_NAME = "moduleClassName";

private final Logger LOGGER = LoggerFactory.getLogger(KotlinMiskServerCodegen.class);
private static final String ROOT_PACKAGE = "rootPackage";
public static final String GENERATE_STUB_IMPL_CLASSES = "generateStubImplClasses";
public static final String ADD_MODEL_MOSHI_JSON_ANNOTATION = "addModelMoshiJsonAnnotation";

private boolean useBeanValidation = true;

@Setter
private boolean generateStubImplClasses = false;

@Setter
private boolean addModelMoshiJsonAnnotation = true;

protected String rootPackage = "org.openapitools.server.api";
protected String apiVersion = "1.0.0-SNAPSHOT";

Expand All @@ -78,10 +87,12 @@ public KotlinMiskServerCodegen() {
super();

addSwitch(USE_BEANVALIDATION, "Use BeanValidation API annotations to validate data types", useBeanValidation);
addSwitch(GENERATE_STUB_IMPL_CLASSES, "Generate Stub Impl Classes", generateStubImplClasses);
addSwitch(ADD_MODEL_MOSHI_JSON_ANNOTATION, "Add a Moshi JSON adapter annotation to all model classes", addModelMoshiJsonAnnotation);

modifyFeatureSet(features -> features
.includeDocumentationFeatures(DocumentationFeature.Readme)
.wireFormatFeatures(EnumSet.of(WireFormatFeature.PROTOBUF))
.wireFormatFeatures(EnumSet.of(WireFormatFeature.JSON, WireFormatFeature.PROTOBUF))
.securityFeatures(EnumSet.noneOf(
SecurityFeature.class
))
Expand Down Expand Up @@ -122,8 +133,12 @@ public KotlinMiskServerCodegen() {

apiTemplateFiles.clear();
apiTemplateFiles.put("apiAction.mustache", "Action.kt");
apiTemplateFiles.put("apiImpl.mustache", "Impl.kt");
apiTemplateFiles.put("apiInterface.mustache", ".kt");

if (generateStubImplClasses) {
apiTemplateFiles.put("apiImpl.mustache", "Impl.kt");
apiTemplateFiles.put("apiInterface.mustache", ".kt");
}

modelTemplateFiles.put("model.mustache", ".kt");

apiPackage = rootPackage + ".api";
Expand Down Expand Up @@ -155,6 +170,15 @@ public void processOpts() {
}
writePropertyBack(USE_BEANVALIDATION, useBeanValidation);

if (additionalProperties.containsKey(GENERATE_STUB_IMPL_CLASSES)) {
setGenerateStubImplClasses(convertPropertyToBoolean(GENERATE_STUB_IMPL_CLASSES));
}
writePropertyBack(GENERATE_STUB_IMPL_CLASSES, generateStubImplClasses);

if (additionalProperties.containsKey(ADD_MODEL_MOSHI_JSON_ANNOTATION)) {
setAddModelMoshiJsonAnnotation(convertPropertyToBoolean(ADD_MODEL_MOSHI_JSON_ANNOTATION));
}
writePropertyBack(ADD_MODEL_MOSHI_JSON_ANNOTATION, addModelMoshiJsonAnnotation);
applyJakartaPackage();

String apiModuleFolder = (sourceFolder + File.separator + apiPackage).replace(".", File.separator);
Expand Down Expand Up @@ -211,6 +235,7 @@ private static Map<String, String> getMappings() {
result.put("application/grpc", "MediaTypes.APPLICATION_GRPC");
result.put("application/javascript", "MediaTypes.APPLICATION_JAVASCRIPT");
result.put("application/json", "MediaTypes.APPLICATION_JSON");
result.put("application/jwt", "MediaTypes.APPLICATION_JWT");
result.put("application/octetstream", "MediaTypes.APPLICATION_OCTETSTREAM");
result.put("application/pdf", "MediaTypes.APPLICATION_OCTETSTREAM");
result.put("application/x-protobuf", "MediaTypes.APPLICATION_PROTOBUF");
Expand All @@ -219,10 +244,11 @@ private static Map<String, String> getMappings() {
result.put("application/zip", "MediaTypes.APPLICATION_ZIP");

result.put("image/gif", "MediaTypes.IMAGE_GIF");
result.put("image/x-icon", "MediaTypes.IMAGE_ICO");
result.put("image/jpeg", "MediaTypes.IMAGE_JPEG");
result.put("image/png", "MediaTypes.IMAGE_PNG");
result.put("image/svg+xml", "MediaTypes.IMAGE_SVG");
result.put("image/x-icon", "MediaTypes.IMAGE_ICO");
result.put("image/tiff", "MediaTypes.IMAGE_TIFF");

result.put("multipart/form-data", "MediaTypes.FORM_DATA");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,22 +32,22 @@ import misk.web.mediatype.MediaTypes
{{#imports}}import {{import}}
{{/imports}}

{{#operations}}
/**
* Generated file, please change {{classname}}Impl.
*/
* @TODO("Fill out implementation")
*/
{{#operations}}
@Singleton
class {{classname}}Action @Inject constructor(
private val {{#lambda.camelcase}}{{classname}}{{/lambda.camelcase}}: {{classname}}
) : WebAction, {{classname}} {
) : WebAction {
{{#operation}}

@{{httpMethod}}("{{path}}")
@Description("{{{summary}}}"){{#hasConsumes}}
@RequestContentType({{#consumes}}{{{mediaType}}}{{^-last}}, {{/-last}}{{/consumes}}){{/hasConsumes}}{{#hasProduces}}
@ResponseContentType({{#produces}}{{{mediaType}}}{{^-last}}, {{/-last}}{{/produces}}){{/hasProduces}}
@LogRequestResponse(bodySampling = 1.0, errorBodySampling = 1.0)
override fun {{operationId}}({{#allParams}}{{>queryParams}}{{>pathParams}}{{>headerParams}}{{>cookieParams}}{{>bodyParams}}{{>formParams}}{{^-last}}, {{/-last}}{{/allParams}}){{#returnType}}: {{{returnType}}}{{/returnType}} {
fun {{operationId}}({{#allParams}}
{{>queryParams}}{{>pathParams}}{{>headerParams}}{{>cookieParams}}{{>bodyParams}}{{>formParams}}{{^-last}}, {{/-last}}{{/allParams}}){{#returnType}}: {{{returnType}}}{{/returnType}} {
TODO()
}
{{/operation}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ class {{classname}}Impl @Inject constructor(
): {{classname}} {
{{#operation}}

override fun {{operationId}}({{#allParams}}{{>queryParams}}{{>pathParams}}{{>headerParams}}{{>cookieParams}}{{>bodyParams}}{{>formParams}}{{^-last}}, {{/-last}}{{/allParams}}){{#returnType}}: {{{returnType}}}{{/returnType}} {
override fun {{operationId}}({{#allParams}}
{{>queryParams}}{{>pathParams}}{{>headerParams}}{{>cookieParams}}{{>bodyParams}}{{>formParams}}{{^-last}}, {{/-last}}{{/allParams}}){{#returnType}}: {{{returnType}}}{{/returnType}} {
TODO()
}
{{/operation}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ import misk.web.RequestHeader
interface {{classname}} {
{{#operation}}

fun {{operationId}}({{#allParams}}{{>queryParams}}{{>pathParams}}{{>headerParams}}{{>cookieParams}}{{>bodyParams}}{{>formParams}}{{^-last}}, {{/-last}}{{/allParams}}){{#returnType}}: {{{returnType}}}{{/returnType}}
fun {{operationId}}({{#allParams}}
{{>queryParams}}{{>pathParams}}{{>headerParams}}{{>cookieParams}}{{>bodyParams}}{{>formParams}}{{^-last}}, {{/-last}}{{/allParams}}){{#returnType}}: {{{returnType}}}{{/returnType}} {
{{/operation}}
}
{{/operations}}
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import misk.web.RequestHeader
@MiskTest(startService = true)
internal class {{classname}}Test {

@Inject private lateinit var {{#lambda.camelcase}}{{classname}}{{/lambda.camelcase}}: {{classname}}
@Inject private lateinit var {{#lambda.camelcase}}{{classname}}{{/lambda.camelcase}}: {{classname}}Action

{{#operations}}
{{#operation}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ version = "{{artifactVersion}}"

dependencies {
implementation("jakarta.validation:jakarta.validation-api:3.1.1")
implementation("com.squareup.misk:misk:2025.04.02.195630-a61d550")
//implementation("com.squareup.wire:wire-runtime:5.2.1")
implementation("com.squareup.misk:misk:2025.04.27.230742-6035cb3")
implementation("com.squareup.moshi:moshi:1.15.2")

testImplementation("com.squareup.misk:misk-testing:2025.02.11.123913-8a41324")
testImplementation("org.junit.jupiter:junit-jupiter:5.9.2")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package {{modelPackage}}
{{#imports}}
import {{import}}
{{/imports}}

{{#models}}
{{#model}}
{{#isEnum}}
Expand All @@ -16,6 +15,9 @@ enum class {{classname}} {
}
{{/isEnum}}
{{^isEnum}}
{{#addModelMoshiJsonAnnotation}}import com.squareup.moshi.JsonClass

@JsonClass(generateAdapter = true){{/addModelMoshiJsonAnnotation}}
data class {{classname}}(
{{#vars}}
{{#description}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,7 @@ protected void verifyOptions() {
verify(codegen).setAdditionalModelTypeAnnotations(List.of(KotlinMiskServerCodegenOptionsProvider.ADDITIONAL_MODEL_TYPE_ANNOTATIONS_VALUE));
verify(codegen).setUseBeanValidation(Boolean.valueOf(KotlinMiskServerCodegenOptionsProvider.USE_BEAN_VALIDATION));
verify(codegen).setModuleClassName(KotlinMiskServerCodegenOptionsProvider.MODULE_CLASS_NAME);
verify(codegen).setGenerateStubImplClasses(Boolean.valueOf(KotlinMiskServerCodegenOptionsProvider.GENERATE_STUB_IMPL_CLASSES));
verify(codegen).setAddModelMoshiJsonAnnotation(Boolean.valueOf(KotlinMiskServerCodegenOptionsProvider.ADD_MODEL_MOSHI_JSON_ANNOTATION));
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ public void testDefaultConfiguration() {
Assert.assertEquals(codegen.apiPackage(), "org.openapitools.server.api.api");
Assert.assertEquals(codegen.modelPackage(), "org.openapitools.server.api.model");

// Test PROTOBUF wire format
// Test wire formats
Assert.assertTrue(codegen.getFeatureSet().getWireFormatFeatures().contains(WireFormatFeature.JSON));
Assert.assertTrue(codegen.getFeatureSet().getWireFormatFeatures().contains(WireFormatFeature.PROTOBUF));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ public class KotlinMiskServerCodegenOptionsProvider implements OptionsProvider {
public static final String API_SUFFIX_VALUE = "Api";
public static final String ADDITIONAL_MODEL_TYPE_ANNOTATIONS_VALUE = "";
public static final String USE_BEAN_VALIDATION = "false";
public static final String GENERATE_STUB_IMPL_CLASSES = "false";
public static final String ADD_MODEL_MOSHI_JSON_ANNOTATION = "true";
public static final String MODULE_CLASS_NAME = "OpenApiModule";

@Override
Expand Down Expand Up @@ -51,6 +53,8 @@ public Map<String, String> createOptions() {
ADDITIONAL_MODEL_TYPE_ANNOTATIONS_VALUE)
.put(KotlinMiskServerCodegen.MODULE_CLASS_NAME, MODULE_CLASS_NAME)
.put(BeanValidationFeatures.USE_BEANVALIDATION, USE_BEAN_VALIDATION)
.put(KotlinMiskServerCodegen.GENERATE_STUB_IMPL_CLASSES, GENERATE_STUB_IMPL_CLASSES)
.put(KotlinMiskServerCodegen.ADD_MODEL_MOSHI_JSON_ANNOTATION, ADD_MODEL_MOSHI_JSON_ANNOTATION)
.build();
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# OpenAPI Generator Ignore
# Generated by openapi-generator https://github.com/openapitools/openapi-generator

# Use this file to prevent files from being overwritten by the generator.
# The patterns follow closely to .gitignore or .dockerignore.

# As an example, the C# client generator defines ApiClient.cs.
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
#ApiClient.cs

# You can match any string of characters against a directory, file or extension with a single asterisk (*):
#foo/*/qux
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux

# You can recursively match patterns against a directory, file or extension with a double asterisk (**):
#foo/**/qux
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux

# You can also negate patterns with an exclamation (!).
# For example, you can ignore all files in a docs folder with the file extension .md:
#docs/*.md
# Then explicitly reverse the ignore rule for a single file:
#!docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
README.md
build.gradle.kts
docs/ApiResponse.md
docs/Category.md
docs/Order.md
docs/Pet.md
docs/PetApi.md
docs/StoreApi.md
docs/Tag.md
docs/User.md
docs/UserApi.md
settings.gradle.kts
src/main/kotlin/org/openapitools/server/api/api/PetApiAction.kt
src/main/kotlin/org/openapitools/server/api/api/PetStoreModule.kt
src/main/kotlin/org/openapitools/server/api/api/StoreApiAction.kt
src/main/kotlin/org/openapitools/server/api/api/UserApiAction.kt
src/main/kotlin/org/openapitools/server/api/model/Category.kt
src/main/kotlin/org/openapitools/server/api/model/ModelApiResponse.kt
src/main/kotlin/org/openapitools/server/api/model/Order.kt
src/main/kotlin/org/openapitools/server/api/model/Pet.kt
src/main/kotlin/org/openapitools/server/api/model/Tag.kt
src/main/kotlin/org/openapitools/server/api/model/User.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
7.14.0-SNAPSHOT
64 changes: 64 additions & 0 deletions samples/server/petstore/kotlin-misk-config/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Documentation for OpenAPI Petstore

<a id="documentation-for-api-endpoints"></a>
## Documentation for API Endpoints

All URIs are relative to *http://petstore.swagger.io/v2*

Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*PetApi* | [**addPet**](Apis/docs/PetApi.md#addpet) | **Post** /pet | Add a new pet to the store
*PetApi* | [**deletePet**](Apis/docs/PetApi.md#deletepet) | **Delete** /pet/{petId} | Deletes a pet
*PetApi* | [**findPetsByStatus**](Apis/docs/PetApi.md#findpetsbystatus) | **Get** /pet/findByStatus | Finds Pets by status
*PetApi* | [**findPetsByTags**](Apis/docs/PetApi.md#findpetsbytags) | **Get** /pet/findByTags | Finds Pets by tags
*PetApi* | [**getPetById**](Apis/docs/PetApi.md#getpetbyid) | **Get** /pet/{petId} | Find pet by ID
*PetApi* | [**updatePet**](Apis/docs/PetApi.md#updatepet) | **Put** /pet | Update an existing pet
*PetApi* | [**updatePetWithForm**](Apis/docs/PetApi.md#updatepetwithform) | **Post** /pet/{petId} | Updates a pet in the store with form data
*PetApi* | [**uploadFile**](Apis/docs/PetApi.md#uploadfile) | **Post** /pet/{petId}/uploadImage | uploads an image
*StoreApi* | [**deleteOrder**](Apis/docs/StoreApi.md#deleteorder) | **Delete** /store/order/{orderId} | Delete purchase order by ID
*StoreApi* | [**getInventory**](Apis/docs/StoreApi.md#getinventory) | **Get** /store/inventory | Returns pet inventories by status
*StoreApi* | [**getOrderById**](Apis/docs/StoreApi.md#getorderbyid) | **Get** /store/order/{orderId} | Find purchase order by ID
*StoreApi* | [**placeOrder**](Apis/docs/StoreApi.md#placeorder) | **Post** /store/order | Place an order for a pet
*UserApi* | [**createUser**](Apis/docs/UserApi.md#createuser) | **Post** /user | Create user
*UserApi* | [**createUsersWithArrayInput**](Apis/docs/UserApi.md#createuserswitharrayinput) | **Post** /user/createWithArray | Creates list of users with given input array
*UserApi* | [**createUsersWithListInput**](Apis/docs/UserApi.md#createuserswithlistinput) | **Post** /user/createWithList | Creates list of users with given input array
*UserApi* | [**deleteUser**](Apis/docs/UserApi.md#deleteuser) | **Delete** /user/{username} | Delete user
*UserApi* | [**getUserByName**](Apis/docs/UserApi.md#getuserbyname) | **Get** /user/{username} | Get user by user name
*UserApi* | [**loginUser**](Apis/docs/UserApi.md#loginuser) | **Get** /user/login | Logs user into the system
*UserApi* | [**logoutUser**](Apis/docs/UserApi.md#logoutuser) | **Get** /user/logout | Logs out current logged in user session
*UserApi* | [**updateUser**](Apis/docs/UserApi.md#updateuser) | **Put** /user/{username} | Updated user


<a id="documentation-for-models"></a>
## Documentation for Models

- [org.openapitools.server.api.model.Category](Models/docs/Category.md)
- [org.openapitools.server.api.model.ModelApiResponse](Models/docs/ModelApiResponse.md)
- [org.openapitools.server.api.model.Order](Models/docs/Order.md)
- [org.openapitools.server.api.model.Pet](Models/docs/Pet.md)
- [org.openapitools.server.api.model.Tag](Models/docs/Tag.md)
- [org.openapitools.server.api.model.User](Models/docs/User.md)


<a id="documentation-for-authorization"></a>
## Documentation for Authorization


Authentication schemes defined for the API:
<a id="petstore_auth"></a>
### petstore_auth

- **Type**: OAuth
- **Flow**: implicit
- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog
- **Scopes**:
- write:pets: modify pets in your account
- read:pets: read your pets

<a id="api_key"></a>
### api_key

- **Type**: API key
- **API key parameter name**: api_key
- **Location**: HTTP header

Loading
Loading