2642 Commits

Author SHA1 Message Date
William Cheng
ac5478e909 update php symfony samples 2025-08-28 14:06:54 +08:00
William Cheng
e903a89ccf
Add PHP server syntax check worfklow (#21830)
* add php server syntax check worfklow

* update

* fix

* trigger build failure

* Revert "trigger build failure"

This reverts commit cd8fa3000dfb98afd57a3f25081a30ebc52fe496.

* add more folders

* comment
2025-08-28 14:04:41 +08:00
William Cheng
ffaeca3204 update 2025-08-28 13:35:52 +08:00
Linh Tran Tuan
7c4d7277b4
Separate Basic Authorization into new template file (#21828) 2025-08-28 13:00:06 +08:00
Daniel Genchev
8ce639ddae
[kotlin-client][kotlin-spring] Fix duplicate discriminator serialization with Jackson used as serialization library (#21734)
* [kotlin-client][kotlin-spring] Fix duplicate discriminator serialization with Jackson used as serialization library

* Update samples
2025-08-27 17:37:38 +08:00
Oliver Kuntze
cd7fe341d3
Fix validation constraints for parameters in request body of form request are not generated (at least with Spring Boot generator) (#21749)
* fix(Spring Boot): adds validation to body params of forms requests

* fix(Spring Boot): adds test for validation of body params of forms requests

* fix(Spring Boot): adds samples
2025-08-23 15:58:46 +08:00
William Cheng
20be2decde
Prepare v7.16.0 release (#21794)
* Revert "v7.15.0 release (#21792)"

This reverts commit 2c816f89cbd6c4670aaf6e3387c88daadae6cbad.

* prepare 7.15.0 release

* update samples
2025-08-22 19:17:23 +08:00
William Cheng
2bbb19a1d5
Update gradle jar to newer version (java micronut) (#21762)
* update gradle wrapper to newer version (java micronaut)

* update gradle setup to v4
2025-08-16 11:45:15 +08:00
Mattias Sehlstedt
8874df4702
Codegen parameter for query json serialization (#21718)
* Add endpoints with query parameters that require Json-serialization

* Add property for query json-serialization

* Update samples

* Adjust indentation for specification
2025-08-10 22:47:51 +08:00
​Andrzej Ressel
0f231d9494
Fix rust-axum homepage toml quotes (#21716) 2025-08-08 13:29:54 +08:00
​Andrzej Ressel
a7af767e34
[Rust] Replace more HeaderValue::from_str with compile time HeaderValue::from_static (#21689) 2025-08-05 11:21:21 +08:00
William Cheng
87231c3b58
[php][php-nextgen] add new github workflow to perform syntax check on php files (#21678)
* update php laravel samples

* add php-nextgen to the github workflow

* trigger build failure

* add syntax checker workflow

* Revert "trigger build failure"

This reverts commit 5be28f2e768cb22d9edca83ec897cbaa9cf296e9.
2025-08-01 17:48:04 +08:00
dsteeley
97aa4a8587
Fixup dependency on forked serde_xml (#21664) 2025-08-01 16:06:30 +08:00
dependabot[bot]
5ba0650659
Bump multer and @nestjs/platform-express (#21673)
Bumps [multer](https://github.com/expressjs/multer) to 2.0.2 and updates ancestor dependency [@nestjs/platform-express](https://github.com/nestjs/nest/tree/HEAD/packages/platform-express). These dependencies need to be updated together.


Updates `multer` from 2.0.1 to 2.0.2
- [Release notes](https://github.com/expressjs/multer/releases)
- [Changelog](https://github.com/expressjs/multer/blob/main/CHANGELOG.md)
- [Commits](https://github.com/expressjs/multer/compare/v2.0.1...v2.0.2)

Updates `@nestjs/platform-express` from 11.1.3 to 11.1.5
- [Release notes](https://github.com/nestjs/nest/releases)
- [Commits](https://github.com/nestjs/nest/commits/v11.1.5/packages/platform-express)

---
updated-dependencies:
- dependency-name: multer
  dependency-version: 2.0.2
  dependency-type: indirect
- dependency-name: "@nestjs/platform-express"
  dependency-version: 11.1.5
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-08-01 16:05:23 +08:00
Ary Obenholzner
fcc83db0f8
NestJS server codegen (#21494)
* setup basic codegen for nestjs server

* set up generated file structure

* adapted moustache files

* fixed imports

* adapted templates

* added module bootstrap

* added model generation

* fixed error with generic type

* added README

* added usage clarification to README, introduced module index.ts

* Update modules/openapi-generator/src/main/resources/typescript-nestjs-server/api.module.mustache

Co-authored-by: Esteban Gehring <esteban.gehring@gmail.com>

* cleaned up package.mustache, added parameters for versions

* cleaned up unneeded boilerplate templates

* fixed indentations from templates

* implemented useSingleRequestParameter

* fixed parameter handling

* added samples with tests

* added docs

* fixed samples

* corrected docs

* updated docs after merge of master

* fixed samples build

* fixed workflow

---------

Co-authored-by: Esteban Gehring <esteban.gehring@gmail.com>
2025-07-31 14:37:44 +02:00
Christopher Gual
a60d3d4f81
[Bug][java-spring] Use Flux only for multipart-form-data file parameters with multiple file uploads (#21561)
* Use Flux only for multipart-form-data file parameters with multiple files

* Update samples

---------

Co-authored-by: Chris Gual <cgual@omnidian.com>
2025-07-28 18:28:53 +08:00
Iurii Ignatko
f5da0ea4a1
Remove [this-escape] warnings in generated ApiClient classes (#21620) 2025-07-28 16:43:14 +08:00
Stefan Wurzinger
0e97e19bbc
kotlin-spring: fix exception thrown in enum.forValue (#21622)
* kotlin-spring: fix exception thrown in enum.forValue

* update samples
2025-07-28 16:01:03 +08:00
Linh Tran Tuan
777b7eeea0
[Rust-Axum] Basic Authorization - Basic Analytic - XSS Sanitize (#21578)
* Update

* Update

* Update

* Update

* Update

* Update
2025-07-22 17:43:46 +08:00
Christopher Gual
bfb69388aa
[Bug][kotlin-spring] add a Spring type converter for enum values #21564 (#21579)
* [kotlin-spring] add a Spring type converter for enum values #21564

* [kotlin-spring] simplify unit test for inner enum converter

* update samples

* code review feedback; move containsEnums to ModelUtils

* code review feedback; provide comment for generated EnumConverterConfiguration.kt

* update samples

---------

Co-authored-by: Chris Gual <cgual@omnidian.com>
2025-07-21 18:22:32 +08:00
Christopher Gual
31089c0e49
[Java-Spring] add comment to EnumConverterConfiguration mustache file (#21598)
* [java-spring] provide a clarifying comment for the generated EnumConverterConfiguration class

* update samples

---------

Co-authored-by: Chris Gual <cgual@omnidian.com>
2025-07-21 18:21:44 +08:00
Kraust
20ed1ee3cc
Fixes to cpp-oatpp-server generator. (#21595) 2025-07-21 18:08:44 +08:00
James Shaw
7ca3fc3115
Fix response model generation with ParseOptions.resolveResponses=true (#21568)
* set resolveResponses=true

needed by swagger-parser>=2.1.23, see https://github.com/swagger-api/swagger-parser/pull/2127

* update samples

---------

Co-authored-by: James Shaw <james.shaw@masabi.com>
2025-07-19 21:37:11 +08:00
Mikko Maunu
faf6924f63
Regular comment instead of document comment before package declaration. fix #21496 (#21572) 2025-07-17 01:29:18 +08:00
Kraust
8862b960f8
Add cpp-oatpp-server generator (alpha) (#21547)
* Oat++ Server Generator (C++)

* Fixed for support for newest OpenAPI version.

* ALPHA not STABLE.

* Fixed for support for newest OpenAPI version.

* Added github workflow & changed to OA3 Petstore.

* Good catch on adding the Workflow.

* Might help to update the samples.

* Set C++ Standard the CMake way.

* Would be easier if there was a .pc file.

* oatpp.lib.

* Add ws2.

* This probably doesn't work, need to take a time out.
2025-07-16 15:32:28 +08:00
donilg
7a6be5a3e6
[scala][http4s] fix codegen for using reserved words in openapi (#21518) 2025-07-12 22:18:55 +08:00
Lukáš Vasek
117be2ca4c
1385 Generate constants for path in spring boot @RequestMapping (#19782) 2025-07-09 16:26:52 +08:00
William Cheng
7e439fd0bd
update chi to newer version (#21528) 2025-07-08 11:00:10 +08:00
William Cheng
a809c187b4
[JavaSpring] Fix when openapi spec file has array of files (#21524)
* [JavaSpring] Fix when openapi spec file has array of files

The isArray is not checked for non-reactive isFile condition. This is remediated.

* update samples

---------

Co-authored-by: Siddharth Wagle <SidWagz@users.noreply.github.com>
2025-07-07 17:45:22 +08:00
dsteeley
2af194b014
[rust-server] Update to hyper1 in rust-server generator (#21422)
* Add rust-server-deprecated generator in preparation for hyper1 upgrade to rust-server generator

* [Rust Server] Fix spacing in `Cargo.mustache` (#17876)

* [Rust Server] Update dependency versions in `Cargo.mustache` (#17876)

* [Rust Server] Update templates so generated client and server compile (#17876)

* [Rust Server] Get `server` example to compile (#17876)

* [Rust Server] Update `client` example to compile (#17876)

* [Rust Server] Update `bin/cli.rs` to compile (#17876)

* Revert changes to use typed auth in rust-server. Run sample generation.

* Hyper1 fixup compilation errors in all examples

* Add tests to all examples, clippy, tests, cli-bin, run examples
* Use headers Auth structs
* Fixup various clippy lints
* Move more Service impl to use BoxBody
* Reduce generic restriction on some Service impl where possible

* Appease clippy lints in rust 1.88

---------

Co-authored-by: Azriel Hoh <azriel@healthpoint.co.nz>
2025-07-03 01:55:33 +08:00
Jochen Schalanda
311233d804
[Java][MicroProfile] Support additionalProperties with Jackson (#21451)
Refs #20853
Refs #20947
2025-07-02 15:52:58 +08:00
William Cheng
d0327b2683
add tests for scala http4s server: (#21507) 2025-07-02 15:45:58 +08:00
Steven Crake
03effd7d05
Replace periods with underscores in Rust model names (#21480)
Fix issue where period-delimited model names (e.g. microsoft.graph.fido2AuthenticationMethod)
were being converted to unwieldy names with "Period" substitutions. Now periods are replaced
with underscores like hyphens, resulting in cleaner and more idiomatic Rust identifiers.

Fixes #15254
2025-06-29 15:52:55 +08:00
William Cheng
046be5dba1
Prepare 7.15.0 (#21445)
* Revert "v7.14.0 release (#21443)"

This reverts commit 5eb083e5ce1dd99659fadc03d7c6e809d3077af6.

* prepare v7.15.0 snapshot

* update samples

* update readme

* update doc
2025-06-25 21:34:58 +08:00
William Cheng
0903ecf85e
update urllib3 to newer versions in python-fastpi (#21439) 2025-06-19 21:47:05 +08:00
William Cheng
dbc5d09da6
update python-fastapi requests to newer version (#21421) 2025-06-16 20:42:16 +08:00
Mostafa Aghajani
fa64c8e012
Issue: #21334 Abstract PHP support of "original" for variableNamingConvention (#21336)
* feat(php): add support for 'off' variable naming convention in AbstractPhpCodegen

* feat(php-laravel): add tests for issue 21334 with API and model definitions

* feat(php-laravel): update variableNamingConvention option in php-laravel help file to include 'off' as a valid value

* feat: enhance variableNamingConvention options to include 'off' and detailed descriptions in documentation

* feat(php): update variableNamingConvention from 'off' to 'original' in AbstractPhpCodegen

* feat: include php-laravel-issue-21334 in workflow triggers for push and pull_request events
2025-06-09 19:26:53 +08:00
Andrew Wilson
4402d836bb
Fix MiskKotlin OpenApiGenerator types (#21390)
* first pass

* fixup up Array -> List

* fixup up Array -> List

* File response type

* don't mess returnTypes.mustache
2025-06-06 20:47:39 +08:00
Ondřej Šimon
9d70de44d6
[JavaSpring][21200] improve Kotlin interopability with optional values (#21202)
nullable annotations are now added to getters, setters, parameters, for optional attributes without default value
2025-06-04 15:47:43 +08:00
Thomas Sickinger
49cadfec3a
fix(python-fastapi): remove 200 fallback code and use default (#12481) (#21333)
Co-authored-by: Thomas Sickinger <thomas.sickinger@teamviewer.com>
2025-06-03 21:02:24 +08:00
William Cheng
bce88c93ba
update swagger pareer to 2.1.28 (#21325) 2025-06-02 15:33:27 +08:00
Alexandre Cassagne
1f8787e53a
fix: update axum generated multipart requests to own the body (#21301)
* fix: update axum generated multipart requests to own the Multipart or Body

Notes: &Multipart cannot access fields, as we need mutable access.

* chore: run the updated rust-axum sample

* chore: run the updated rust-axum sample (2)
Notes: Ran
   ./mvnw clean package || exit
   ./bin/generate-samples.sh
   ./bin/configs/*.yaml || exit
   ./bin/utils/export_docs_generators.sh || exit

* chore: fix inconsistent lifetimes

Notes: Multipart should be owned; normal request remains borrowed

* chore: rerun axum samples
2025-05-31 23:32:03 +08:00
Spencer Cornish
c4dad53455
[GO] Go Server: Adds ordered routes to go-server router (#21280)
* Adds ordered routes to go-server router

* Generate and fix test

* Newline

* Readd escaping

* Fixes go router unit test

* Updates tests, one more time
2025-05-25 13:49:15 +08:00
Guillaume Turri
6e2b4f99ba
[PHP-Symfony] revamp the computation of the contentType (#21292)
recent commit 40894382fc9fe959f3beacd20cfd6421eaf840b0 already improved
that method: before that other commit it was juste impossible to query
a endpoint with a response type that was something else than
application/json or application/xml. With that commit it became possible
to query such endpoint provided that the client declare in its Accept
header that it can cope with */* (or provided that the client omitted
that header altogether).

But there were still cases badly handled. For instance if an endpoint
returns a response of type image/png and that it receives a query with
header "Accept: image/png", then it would reply with 406.

To avoid any other issue with type resolution, this commit revamps the
getOutputFormat function more thoroughly and does it by implementing
the specification available at
https://httpwg.org/specs/rfc9110.html#field.accept ), which means that
the format accepted by the client are ordered by the relative weights
specified it specified.
2025-05-19 10:09:16 +08:00
Rens Groothuijsen
45047b77f1
[python-fastapi] Upgrade dependencies to support Python 3.13 (#21291) 2025-05-18 09:56:24 +08:00
Andrew Wilson
9b39c05563
Kotlin Misk Add Extra Parameters (#21271)
* first pass

* squash

* fixing FILES
2025-05-16 14:37:49 +08:00
Guillaume Turri
6c0e7274ea
[Php-Symfony] showcase recent features in petstore.yaml (#21286)
PR #21261 added support for endpoint with response of type text/plain
or even image/png.

This commit adds such endpoint so that:
- the way those are supported is clearer (as it is now directly visible
  in the generated sample files)
- if a future commit impacts this part of the generation it will be easier
  to assess that impact
2025-05-16 10:32:52 +08:00
Peter Storch
5b885cd3db
[kotlin-spring] fix validation regression in kotlin-spring generator (#21255)
* fix #21238 regression in kotlin-spring generator

* add tests for issue #21238
2025-05-16 00:08:51 +08:00
Guillaume Turri
40894382fc
[php-symfony] fix handling of endpoints with "text/plain" or "image/png" response type (#21261)
* [php-symfony] Never return 406 when user accepts */*

When a query has header "Accept" set to "*/*" it means it accepts
everything. It is hence weird to return a 406.
This patch ensures it does not occur: when the query accepts everything
then we take any produced type.

This fixes #13334. This also partly makes the open PR #15560 obsolete
(or at least, it provides a workaround)

* [php-symfony] Don't crash at runtime on null convertFormat

$this->convertFormat may return "null". When it's the case we end up
calling

    ...->serialize($data, null);

but this crashes at runtime because that serialize method declares that
the 2nd parameter is of type "string" (so null is not accepted).

With this patch we avoid having an error 500. Instead we return something
that makes perfect sense when the OpenApi specification declares a content
of type "text/plain" and that the returned value is for instance a string,
an int, or a boolean.

* [php Symfony] fix return type for non json/xml api

This fixes the generated returned type of controller methods for
endpoint with a response declared like

    content:
      text/plain:
        schema:
          type: <boolean|string|integer|number>

or for

    content:
      image/png:
        schema:
          type: string
          format: binary

Without this commit the generated method *had to* return a value that
matched "array|object|null", which does not work in this case.
This commit makes it possible to return the proper type.
2025-05-14 21:11:39 +08:00
jglagrimas
a0b9ecd773
[php-laravel generator] update $request->bool to $request->boolean (#21273)
* Chores : update $request->bool to $request->boolean

$request->bool is not a laravel function should be $request->boolean()

* Chores : update FakeController.php $request->boolean()
2025-05-14 14:37:16 +08:00