18209 Commits

Author SHA1 Message Date
William Cheng
a28772b08f
skip website push (#14573) 2023-01-31 22:44:03 +08:00
Paul Parenko
cffe2d0259
[Kotlin-Spring] support to Spring boot3 & jakarta extension (#14369)
* [Kotlin] add spring boot 3 & jakarta extension support

* [kotlin-spring] readme update & modified imports

* use latest Spring Boot starter parent

* use same options as in [Java] generator

* new config kotlin-spring-boot-3

---------

Co-authored-by: jayandran sampath <jayandran.sampath@opencastsoftware.com>
2023-01-31 22:16:06 +08:00
julien Lengrand-Lambert
eca9ec775b
Feat/jetbrains http client (#14477)
* Dummy client generated

* Adding dummy versions, my IDE crashed

* Making my first actual requests

* Creates first version of API Generator for Jetbrains Client

* Adds generated API files

* Adds more complex API definition

* Adds basic supporting files

* Adds empty environment file for variables
* Adds basic README

* Adds minimal set of values in env file`

* Adds minimal support for API Key header

* Adds Adyen API sample

* Add null checks on code

* Simplifies the generator, cleans output

* Improves README

* Fix minor issues with README

* Removes API file and config used for local testing

* Remove leftover logging file

* Disables tests as I find how to write them

* Sets generator as experimental

* Add new generator language enum value

* Adds generator doc file

* Adds generators main file

* Removes unused method. Adds my name

* Adding Jetbrains HTTP Client to the README
2023-01-31 22:03:15 +08:00
Martin Delille
fa1cbb9322
Add action for qt client (#14566)
* Add action for qt client

* Use matrix for os too
2023-01-31 21:59:38 +08:00
William Cheng
37e8cfadc7
minor imrovemets to julia generators (#14560) 2023-01-30 20:20:45 +08:00
William Cheng
fd45b74128
[Java] better default value handling (#14130)
* add test for array default value

* update null return

* minor fixes

* move default value tests to echo api spec

* add new files

* remove unused files

* fix enum array default, add tests

* better array init

* Update modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractJavaCodegen.java

Co-authored-by: Leonard Brünings <lord_damokles@gmx.net>

* Update modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/AbstractJavaCodegen.java

Co-authored-by: Leonard Brünings <lord_damokles@gmx.net>

* revert the fix

* improve default value handling

* update native samples, add tests

* update samples

* fix tests

* use conditional test for timezone

* add tests to apache http client echo api

* add option to default container to null

* fix map default value

* minor refactoring

* update samples

* fix javadoc

* fix pom.xml

* add tests in java native echo client

* add java apache client echo tests

* fix test

* fix test

---------

Co-authored-by: Leonard Brünings <lord_damokles@gmx.net>
2023-01-30 20:19:00 +08:00
William Cheng
b3527348f3 update doc 2023-01-30 16:58:19 +08:00
Tanmay Mohapatra
4bc16ea6bb
Added a Julia client and server (#14520)
* Added a Julia client and server

This PR adds two new generators for the [Julia language](https://julialang.org/)
- `julia-client` to generate a client from specifications
- `julia-server` to generate a server with stubs that can be used to host a server conforming to the specifications

The generated code uses the Julia [OpenAPI.jl](https://github.com/JuliaComputing/OpenAPI.jl) package that includes support functions for both client and server.

* fix javadoc generation

* add changes after ensure-up-to-date run
2023-01-30 16:40:33 +08:00
Oleh Kurpiak
28493dfa95
[Spring] Spring HTTP Interface library (#14485) 2023-01-30 10:37:00 +02:00
Sebastian Cevallos
8540c82d30
Add handling for parsing optional bool params & regenerate samples (#14550) 2023-01-30 16:35:19 +08:00
devhl-labs
b538c2adf8
[csharp-netcore] Fixed serialization of nullable guids (#14556)
* fixed serialization of nullable guids

* build more csharp samples

* build all samples

* why do i have to build again?
2023-01-29 19:16:58 +08:00
devhl-labs
57546d49c2
renamed json converter variables (#14555) 2023-01-29 10:58:53 +08:00
Beppe Catanese
1c157a2847
Support examples in Response Content (#14336)
* Add examples map and overload constructor

* Create CodegenMediaType with examples

* Add test
2023-01-28 12:42:00 +08:00
Martin Delille
03299528e9
Add conan badge (#14537) 2023-01-28 12:12:20 +08:00
bgong-mdsol
47813a88a2
update imports for enum (#14546) 2023-01-28 12:10:59 +08:00
itaru2622
4ffdadfbcc
[python-nextgen] fix issue on API example doc autogeneration (#14539)
* [python-nextgen] fix template to make auto-generated example runnable when spec has no auth methods

* update samples with ./bin/generate-samples.sh

* add unit test code
2023-01-28 12:03:17 +08:00
DevFlorian
6a2d8d23da
#8792 [Java] [jaxrs-cxf] "useAbstractionForFiles" config option for jaxrs-cxf (#14316)
* [REQ] Add equals and hashcode to java-cxf pojo #12519

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* [Java] Use abstraction for files for jaxrs-cxf #8792

* fix sample

* fix sample

---------

Co-authored-by: FWermelskirchen <fwermelskirchen@eitco.de>
2023-01-28 11:37:08 +08:00
Oleh Kurpiak
ac5134acf3
[Java] fix JsonTypeName import (#14474) (fix #12524) 2023-01-25 14:39:58 +02:00
Michael Ramstein
5047273f1e
[elixir] Properly map AnyType (#14497) 2023-01-24 07:48:49 +01:00
tjbdev
82ac92aed6
[elixir] connection.ex typo fix (#14512) 2023-01-24 07:12:32 +01:00
Michael Ramstein
ccbea26390
[elixir] Fixes issue with setting Header parameters (#14511)
* Fixes issue with request not beeing struct of Tesla.Env when setting a header parameter.
2023-01-23 22:03:05 +01:00
William Cheng
90e468b9a3
[java] Fix template logic related to supportUrlQuery (#14496)
* [java] Fix template logic related to supportUrlQuery

Generated models for arrays marked with uniqueItems: true (which end up as a Set<> in java) won't
compile because the templates are in some places using .get(i) on the sets.

Also, when the supportUrlQuery property is present in the additionalProperties map the
resulting value will be read using the key SUPPORT_STREAMING instead of 'supportUrlQuery'.

* fix NPE

Co-authored-by: Björgvin <bjorgvino@gmail.com>
2023-01-21 11:10:30 +08:00
devhl-labs
d4c8c97e19
[csharp-netcore] Pipeline fix (#14495)
* trying to fix pipeline

* forcing pipeline to run

* reverting change to wrong branch

* forcing pipeline to run

* reverting change
2023-01-21 10:46:42 +08:00
William Cheng
5e7d31a83b
add a rule to keep only the first tag (#14465) 2023-01-20 15:50:31 +08:00
William Cheng
4ecb9f4186
[java][native] Fix urlQuery string method in oneOf (#14488)
* better tests, fix oneOf in urlquery string method

* update samples

* update
2023-01-20 01:57:32 +08:00
Ian Cubbon
6e780218ad
[Go] Client Models using AllOf, OneOf, or AnyOf Correctly Include time and os imports (Attempt 2) (#14459)
* Currently, if a Model is an allOf the time and os imports are not correctly added to the generated file. This was introduced recently with a fix to not include those imports when the model is a composedSchema #13833. The logic in that fix was just slightly off as an allOf should be treated the same as a standard model.

If a model is an AllOf or does not have any composed schemas at all, the sub-models are in-lined defined in the struct. In this case, the standard logic of including the time and os imports apply.

If a model is a OneOf or AnyOf, the sub-models are included as pointers to the defined model. In this case, do not include those items in the logic of including time and os imports.

* Update example to include a time in an allOf

* Add back the accidentally removed nil check
2023-01-20 01:53:19 +08:00
William Cheng
6cd7989e9e
[Java][native][apache-httpclient] Update toUrlQueryString to support form style for object (#14478)
* update toUrlQueryString

* add new files

* minor bug fixes

* support object in query parameter - java apache httpclient

* rename variable - java native

* update samples

* fix try catch
2023-01-19 16:13:51 +08:00
William Cheng
d1cde7febe
Add 2 rules to OpenAPI Normalizer (#14463)
* add REMOVE_ANYOF_ONEOF_AND_KEEP_PROPERTIIES_ONLY

* add rules to simplify anyOf

* fix rules, update docs

* remove test

* fix doc
2023-01-17 21:27:57 +08:00
Johnny Marnell
c912bae3bc
[Spring] Fix bean name collisions (#14092) (fix #14094)
* Use correct Pascal case for java enum

* Uniquely name @Bean annotations

* Use existing mustache var instead, run generate files

* rebase, re-run generators

* try to undo botched rebase/merge

* Attempt to manually undo whatever is going on w/ build, oops

* Attempt to manually undo whatever is going on w/ build, oops
2023-01-17 11:24:15 +02:00
Vikrant Balyan
9f502930ea
[Go] Adds a sha256 configuration option to hs2019 (#14467)
* enables configuration of sha256 with hs2019

* committing generated examples

Co-authored-by: Aanisha Mishra <aanisha.mishra05@gmail.com>
Co-authored-by: Sebastien Rosset <serosset@cisco.com>
2023-01-16 23:21:53 +08:00
Marvin Rensing
4cd080762a
[Java][Spring] fix RequestPart/RequestParam handling on multipart request for arrays (#14450) (fix #14449) 2023-01-16 11:39:51 +02:00
Ian Cubbon
74073df27c
[GO][Client] Use a *os.File for the API Client when uploading and downloading (#14340)
* Change the return type of a file back to a pointer

* Change the api template to handle not double pointer-ing return types of os.File

* Fix unit tests

* Couple more unit test fixes
2023-01-16 16:51:04 +08:00
Oleh Kurpiak
27137e75ce
[Java][Spring] fix ParameterObject import for Spring Boot 3 (#14454)
fix #14077
2023-01-14 08:00:32 -08:00
Paul Parenko
be87382fde
[Java][Spring] Fix #14398 springboot 3 schema required (#14402)
* fix depricated @Schema(required) since swagger 2.2.5

* use same swagger-annotations version which is used by swagger-core which is a dependency of springdoc

* generated java sampes
2023-01-14 06:59:33 -08:00
philkild
7958990254
Add CancellationToken to generated aspnetcore controller methods. (#14326) 2023-01-14 22:15:53 +08:00
Ian Cubbon
92775ceffc
[Go] [Client] Don't Explode Query Params (#14447)
* If the collection type is csv, that means 'dont explode the query params'.

* Simplify the logic just a tad

* url.Values -> Has was added in go1.17 but there are CI tests running at 1.16
2023-01-14 00:48:27 +08:00
Bruno Coelho
d348754399
[kotlin][client] add info if endpoints requires authentication or not (#14445)
* [kotlin][client] add info if endpoints requires authentication or not

* [kotlin][client] update sample projects

* [kotlin][client] add info if endpoints requires authentication or not

* [kotlin][client] update sample projects
2023-01-13 10:29:27 +00:00
Bruno Coelho
b6ad68baca
[swift5][client] - fix combine warning (#14444)
* [swift5][client] - fix combine warning

* [swift5][client] - fix combine warning

* [swift5][client] - update samples
2023-01-13 10:29:00 +00:00
William Cheng
079ad1742e
update useRuntimeException description (#14452) 2023-01-13 17:38:31 +08:00
William Cheng
cf4f2c76b2
Use inline allof instead of $ref in echo test (#14429)
* use inline allof instead of $ref in echo test

* update samples

* update samples

* fix tests
2023-01-13 17:21:28 +08:00
Sebastian Saip
ed2029f863
[Java][Microprofile] fix useRuntimeException (#14409) (#14414)
Co-authored-by: Sebastian Saip <sebastian.saip@senacor.com>
2023-01-13 15:42:07 +08:00
devhl-labs
8abc750c0e
[csharp-netcore] Added isNew property to CodegenProperty (#14412)
* added isNew property to CodegenModel

* build all samples
2023-01-13 14:43:33 +08:00
William Cheng
9fae221f1d
[Java][okhttp-gson] add echo client test (#14442)
* add echo api tests for java okhttp client

* test okhttp gson echo client in jdk8 workflow

* update samples
2023-01-13 00:15:29 +08:00
Bruno Coelho
b1f8f976c0
[swift5][client] - enable swift unit tests (#14441) 2023-01-12 15:10:15 +00:00
William Cheng
a584f32d68
Add workflow to test java apache client with jdk8 (#14437)
* add workflow to test java apache client with jdk8

* fix url encode issue with jdk8

* update samples

* minor improvements in java native client

* minor fix
2023-01-12 22:12:08 +08:00
Paul Parenko
c2c91e2d2e
[Java][Spring] Fix #14362 when useSpringBoot3=true, then useJakartaEe=true (#14373) 2023-01-12 19:54:42 +08:00
Oleh Kurpiak
076b88429e
[Java][Spring] fix param docs (#14426) 2023-01-12 19:53:01 +08:00
Chao Yang
e1e291bc12
[Crystal] Skip primitive types from ModelImportMap (#14436)
* Support requiring models in crystal lang

* Return null instead of empty string
2023-01-12 19:42:33 +08:00
Bruno Coelho
e8811ecd28
[swift5][client] - simplify async await (#14430)
* [swift5][client] - simplify async await

* [swift5][client] - update sample projects

* [swift5][client] - add more tests
2023-01-12 10:55:41 +00:00
William Cheng
cffacc8023
fix deploy in travis (#14428) 2023-01-12 01:05:52 +08:00