Skip to content

Commit 945ed35

Browse files
committed
Regenerate samples
1 parent 92af81d commit 945ed35

File tree

11 files changed

+68
-68
lines changed

11 files changed

+68
-68
lines changed

bin/configs/kotlin-server-jaxrs-spec-array-response.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ templateDir: modules/openapi-generator/src/main/resources/kotlin-server
66
additionalProperties:
77
interfaceOnly: "true"
88
useJakartaEe: true
9+
useTags: "true"

bin/configs/kotlin-server-jaxrs-spec-parameter-tests.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ inputSpec: modules/openapi-generator/src/test/resources/3_0/parameter-test-spec.
55
templateDir: modules/openapi-generator/src/main/resources/kotlin-server
66
additionalProperties:
77
useCoroutines: "true"
8+
useTags: "true"

bin/configs/kotlin-server-jaxrs-spec.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,4 @@ inputSpec: modules/openapi-generator/src/test/resources/2_0/petstore.yaml
55
templateDir: modules/openapi-generator/src/main/resources/kotlin-server
66
additionalProperties:
77
useCoroutines: "true"
8-
useTags: "true"
98
implicitHeaders: "true"

modules/openapi-generator/src/main/resources/kotlin-server/README.mustache

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ All URIs are relative to *{{{basePath}}}*
3535

3636
Class | Method | HTTP request | Description
3737
------------ | ------------- | ------------- | -------------
38-
{{#apiInfo}}{{#apis}}{{#operations}}{{#operation}}*{{classname}}* | [**{{operationId}}**]({{apiDocPath}}{{classname}}.md#{{operationIdLowerCase}}) | **{{httpMethod}}** {{#useTags}}{{commonPath}}{{/useTags}}{{path}} | {{{summary}}}
38+
{{#apiInfo}}{{#apis}}{{#operations}}{{#operation}}*{{classname}}* | [**{{operationId}}**]({{apiDocPath}}{{classname}}.md#{{operationIdLowerCase}}) | **{{httpMethod}}** {{commonPath}}{{path}} | {{{summary}}}
3939
{{/operation}}{{/operations}}{{/apis}}{{/apiInfo}}
4040
{{/generateApiDocs}}
4141

samples/server/others/kotlin-server/jaxrs-spec-array-response/src/main/kotlin/org/openapitools/server/apis/StuffApi.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import java.io.InputStream
1010

1111

1212

13-
@Path("/")
13+
@Path("")
1414
@jakarta.annotation.Generated(value = arrayOf("org.openapitools.codegen.languages.KotlinServerCodegen"), comments = "Generator version: 7.22.0-SNAPSHOT")
1515
interface StuffApi {
1616

samples/server/others/kotlin-server/jaxrs-spec/src/main/kotlin/org/openapitools/server/apis/DefaultApi.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,11 @@ import java.io.InputStream
99

1010

1111

12-
@Path("/")
12+
@Path("/test/parameters/{path_default}/{path_nullable}")
1313
@javax.annotation.Generated(value = arrayOf("org.openapitools.codegen.languages.KotlinServerCodegen"), comments = "Generator version: 7.22.0-SNAPSHOT")
1414
class DefaultApi {
1515

1616
@GET
17-
@Path("/test/parameters/{path_default}/{path_nullable}")
1817
suspend fun findPetsByStatus(@PathParam("path_default") pathDefault: kotlin.String,@PathParam("path_nullable") pathNullable: kotlin.String,@QueryParam("query_default") @DefaultValue("available") queryDefault: kotlin.String,@QueryParam("query_default_enum") @DefaultValue("B") queryDefaultEnum: kotlin.String,@QueryParam("query_default_int") @DefaultValue("3") queryDefaultInt: java.math.BigDecimal,@HeaderParam("header_default") @DefaultValue("available") headerDefault: kotlin.String,@HeaderParam("header_default_enum") @DefaultValue("B") headerDefaultEnum: kotlin.String,@HeaderParam("header_default_int") @DefaultValue("3") headerDefaultInt: java.math.BigDecimal,@CookieParam("cookie_default") @DefaultValue("available") cookieDefault: kotlin.String,@CookieParam("cookie_default_enum") @DefaultValue("B") cookieDefaultEnum: kotlin.String,@CookieParam("cookie_default_int") @DefaultValue("3") cookieDefaultInt: java.math.BigDecimal,@QueryParam("query_nullable") queryNullable: kotlin.String?,@HeaderParam("header_nullable") headerNullable: kotlin.String?,@CookieParam("cookie_nullable") cookieNullable: kotlin.String?,@QueryParam("\$query-\$dollar-sign") dollarQueryDollarDollarSign: kotlin.String?): Response {
1918
return Response.ok().entity("magic!").build();
2019
}

samples/server/petstore/kotlin-server/jaxrs-spec-mutiny/README.md

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -34,26 +34,26 @@ All URIs are relative to *http://petstore.swagger.io/v2*
3434

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

5858

5959
<a id="documentation-for-models"></a>

samples/server/petstore/kotlin-server/jaxrs-spec-mutiny/src/main/kotlin/org/openapitools/server/apis/PetApi.kt

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -11,46 +11,46 @@ import java.io.InputStream
1111

1212

1313

14-
@Path("/")
14+
@Path("/pet")
1515
@javax.annotation.Generated(value = arrayOf("org.openapitools.codegen.languages.KotlinServerCodegen"), comments = "Generator version: 7.22.0-SNAPSHOT")
1616
interface PetApi {
1717

1818
@POST
19-
@Path("/pet")
19+
@Path("")
2020
@Consumes("application/json", "application/xml")
2121
fun addPet( body: Pet): io.smallrye.mutiny.Uni<Response>
2222

2323
@DELETE
24-
@Path("/pet/{petId}")
24+
@Path("/{petId}")
2525
fun deletePet(@PathParam("petId") petId: kotlin.Long,@HeaderParam("api_key") apiKey: kotlin.String?): io.smallrye.mutiny.Uni<Response>
2626

2727
@GET
28-
@Path("/pet/findByStatus")
28+
@Path("/findByStatus")
2929
@Produces("application/xml", "application/json")
3030
fun findPetsByStatus(@QueryParam("status") status: kotlin.collections.List<kotlin.String>): io.smallrye.mutiny.Uni<Response>
3131

3232
@GET
33-
@Path("/pet/findByTags")
33+
@Path("/findByTags")
3434
@Produces("application/xml", "application/json")
3535
fun findPetsByTags(@QueryParam("tags") tags: kotlin.collections.List<kotlin.String>): io.smallrye.mutiny.Uni<Response>
3636

3737
@GET
38-
@Path("/pet/{petId}")
38+
@Path("/{petId}")
3939
@Produces("application/xml", "application/json")
4040
fun getPetById(@PathParam("petId") petId: kotlin.Long): io.smallrye.mutiny.Uni<Response>
4141

4242
@PUT
43-
@Path("/pet")
43+
@Path("")
4444
@Consumes("application/json", "application/xml")
4545
fun updatePet( body: Pet): io.smallrye.mutiny.Uni<Response>
4646

4747
@POST
48-
@Path("/pet/{petId}")
48+
@Path("/{petId}")
4949
@Consumes("application/x-www-form-urlencoded")
5050
fun updatePetWithForm(@PathParam("petId") petId: kotlin.Long,@FormParam(value = "name") name: kotlin.String?,@FormParam(value = "status") status: kotlin.String?): io.smallrye.mutiny.Uni<Response>
5151

5252
@POST
53-
@Path("/pet/{petId}/uploadImage")
53+
@Path("/{petId}/uploadImage")
5454
@Consumes("multipart/form-data")
5555
@Produces("application/json")
5656
fun uploadFile(@PathParam("petId") petId: kotlin.Long,@FormParam(value = "additionalMetadata") additionalMetadata: kotlin.String?, @FormParam(value = "file") fileInputStream: InputStream?): io.smallrye.mutiny.Uni<Response>

samples/server/petstore/kotlin-server/jaxrs-spec-mutiny/src/main/kotlin/org/openapitools/server/apis/StoreApi.kt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,26 +10,26 @@ import java.io.InputStream
1010

1111

1212

13-
@Path("/")
13+
@Path("/store")
1414
@javax.annotation.Generated(value = arrayOf("org.openapitools.codegen.languages.KotlinServerCodegen"), comments = "Generator version: 7.22.0-SNAPSHOT")
1515
interface StoreApi {
1616

1717
@DELETE
18-
@Path("/store/order/{orderId}")
18+
@Path("/order/{orderId}")
1919
fun deleteOrder(@PathParam("orderId") orderId: kotlin.String): io.smallrye.mutiny.Uni<Response>
2020

2121
@GET
22-
@Path("/store/inventory")
22+
@Path("/inventory")
2323
@Produces("application/json")
2424
fun getInventory(): io.smallrye.mutiny.Uni<Response>
2525

2626
@GET
27-
@Path("/store/order/{orderId}")
27+
@Path("/order/{orderId}")
2828
@Produces("application/xml", "application/json")
2929
fun getOrderById(@PathParam("orderId") orderId: kotlin.Long): io.smallrye.mutiny.Uni<Response>
3030

3131
@POST
32-
@Path("/store/order")
32+
@Path("/order")
3333
@Produces("application/xml", "application/json")
3434
fun placeOrder( body: Order): io.smallrye.mutiny.Uni<Response>
3535
}

samples/server/petstore/kotlin-server/jaxrs-spec-mutiny/src/main/kotlin/org/openapitools/server/apis/UserApi.kt

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,41 +10,41 @@ import java.io.InputStream
1010

1111

1212

13-
@Path("/")
13+
@Path("/user")
1414
@javax.annotation.Generated(value = arrayOf("org.openapitools.codegen.languages.KotlinServerCodegen"), comments = "Generator version: 7.22.0-SNAPSHOT")
1515
interface UserApi {
1616

1717
@POST
18-
@Path("/user")
18+
@Path("")
1919
fun createUser( body: User): io.smallrye.mutiny.Uni<Response>
2020

2121
@POST
22-
@Path("/user/createWithArray")
22+
@Path("/createWithArray")
2323
fun createUsersWithArrayInput( body: kotlin.collections.List<User>): io.smallrye.mutiny.Uni<Response>
2424

2525
@POST
26-
@Path("/user/createWithList")
26+
@Path("/createWithList")
2727
fun createUsersWithListInput( body: kotlin.collections.List<User>): io.smallrye.mutiny.Uni<Response>
2828

2929
@DELETE
30-
@Path("/user/{username}")
30+
@Path("/{username}")
3131
fun deleteUser(@PathParam("username") username: kotlin.String): io.smallrye.mutiny.Uni<Response>
3232

3333
@GET
34-
@Path("/user/{username}")
34+
@Path("/{username}")
3535
@Produces("application/xml", "application/json")
3636
fun getUserByName(@PathParam("username") username: kotlin.String): io.smallrye.mutiny.Uni<Response>
3737

3838
@GET
39-
@Path("/user/login")
39+
@Path("/login")
4040
@Produces("application/xml", "application/json")
4141
fun loginUser(@QueryParam("username") username: kotlin.String,@QueryParam("password") password: kotlin.String): io.smallrye.mutiny.Uni<Response>
4242

4343
@GET
44-
@Path("/user/logout")
44+
@Path("/logout")
4545
fun logoutUser(): io.smallrye.mutiny.Uni<Response>
4646

4747
@PUT
48-
@Path("/user/{username}")
48+
@Path("/{username}")
4949
fun updateUser(@PathParam("username") username: kotlin.String, body: User): io.smallrye.mutiny.Uni<Response>
5050
}

0 commit comments

Comments
 (0)