Commit Graph

132 Commits

Author SHA1 Message Date
William Cheng
b88b1d656a
Add auto-generated tests and travis config to Dart clients (#3006)
* add auto-generated tests and travis config for dart

* improve tests

* fix tests

* add test, travis files to dart jaguar generator
2019-05-27 18:44:57 +08:00
William Cheng
ff1c7c87ef
update jackson joda version, samples (#3005) 2019-05-27 00:26:24 +08:00
William Cheng
2bc9592bd5
Revert "Add auto-generated tests and travis config to Dart clients (#2909)" (#3001)
This reverts commit dfda6655ec.
2019-05-26 01:50:31 +08:00
William Cheng
dfda6655ec
Add auto-generated tests and travis config to Dart clients (#2909)
* add auto-generated tests and travis config for dart

* improve tests

* fix tests
2019-05-25 22:52:30 +08:00
Vincent Devos
ef26ce68d4 [Kotlin] client improvement / remove WildCards in client/server (#2862) 2019-05-11 11:42:11 +08:00
Matthieu Berthomé
ee43cc1520 handle composed schemas in InlineModelResolver (#2112)
* handle composed schemas in InlineModelResolver

* fix unit test -> TestUtils.parseSpec

* update samples

* fix samples

* update samples

* update samples

* add new files
2019-05-08 10:19:15 +08:00
Matthieu Berthomé
f0346aeeb2 python: api_client: add the multipart files after sanitization (#2122)
* python: api_client: add the multipart files after sanitization

* simplify prepare_post_parameters

* fix case of both post params and files set

* update samples

* update samples
2019-05-07 21:27:01 +08:00
Vincent Devos
6e6926a8b8 [TypeScript] harmonize gitignore file (#2746) 2019-04-26 22:34:24 +08:00
William Cheng
9455fe7bec
Add sponsor section to the website (#2634)
* add sponsor section

* add sponsor title
2019-04-10 21:30:59 +08:00
William Cheng
e6658278ad
R client refactoring (#2215)
* [R] fix namespace, use 2-space indentation (#2105)

* fix namespace, indentation

* use 2-space indentation in model files

* update gitignore

* use PascalCase for function naming (#2106)

* [R] improve .travis.yml, .Rbuildignore (#2109)

* update travis

* enhance travis.yml

* update travis, .Rbuildignore

* [R] Add auto-generated documentations, change parameter naming (#2114)

* add auto-generated doc for r client

* remove module name

* replace nil with void

* [R] fix object serialization to JSON (#2129)

* fix object serialization

* fix array property seriziation

* fix deserializing array of string

* fix array of object deserialization

* [R] Fix return type (#2140)

* fix return type

* update r petstore sample

* add auto-generated tests (#2141)

* rename file to conform to style guide (#2142)

* add authenticaiton support to R (#2153)

[R] Add authentication support, minor ApiClient refactor

* rename test files

* [R] various improvements and bug fixes (#2162)

* fix api keys in headers

* use optional parameter in function signature

* fix property naming

* fix doc assignment operator

* [R] fix base64 encode (#2171)

* fix base64 encode

* fix basic http auth

* fix typo, update instruction (#2203)

* rename test files to conform to style guide (#2206)

* [R] improve class constructor (#2208)

* update constructor with optional parameter, default value

* update r petstore sample

* clean up files

* regenerate files

* Revert "rename test files to conform to style guide (#2206)"

This reverts commit 90a6302a6565d208a6ab298fda41a47836a63d9c.

* fix query parameter in api client (#2214)
2019-02-23 23:51:11 +08:00
William Cheng
8f561f1ef3
[C#][Refactor] Fix nullable required property in the constructor (#1819)
* add serialization test, fix nulllable reuqired

* remove vs folder
2019-01-05 18:54:29 +08:00
Akihito Nakano
05107032d1
Fix missing closing parenthesis (#1739)
* Add a script to generate kotlin client samples from OAS3

* Generate kotlin client

* Fix missing closing parenthesis

* Update samples

* Add build folder to gitignore
2018-12-23 09:54:51 +09:00
William Cheng
93c13074ff
various fixes to csharp refactor client (#1711) 2018-12-20 16:06:29 +08:00
William Cheng
98aa5f8db2
add erlang-proper to shippable CI (#1642) 2018-12-10 17:43:00 +08:00
William Cheng
774013c7e1
Better OpenAPI spec v3 support: allOf, anyOf, oneOf (#1360)
* add oneOf support to Ruby

* add anyOf support to ruby client

* add discriminator support to ruby client

* fix typo

* update samples, fix NPE

* better format in ruby generator

* fix test cases, disable mapping test

* fix update script, update samples

* add test, fix mapping

* update exit code

* reenabled discriminator test

* remove duplicated properties

* add test for duplicated properties

* update samples, add new spec

* fix ruby test cases

* fix hasMore after removing duplicates

* refactor method, comment out haskell client test

* fix hasMore and update samples

* fix parent detection

* fix discriminator check

* [haskell-http-client] need to use {{vars}}{{required}} instead of {{requiredVars}}

* remove deprecated methods in default codegen (#1031)

* regenerate samples

* remove commented code
2018-12-07 00:30:20 +08:00
Hemant Zope
df19c13347 [C] Resolve some issues from #1473 (#1497)
* change folder structure for external and added list as primitive type

* modified gitignore for C generator

* change include statement as per directory structure

* added projectname variable for using in cmakelists

* modified cmakefile:compile files irrespective of testfiles and add support for make install

* updated readme with how to compile and how to use

* CMakeLists change curl to 7.58.0

* fix indentation

* add remove as reserved word
2018-12-06 11:39:30 +08:00
Nathan Broadbent
a0f8c5e468 Ignore modules/openapi-generator-gradle-plugin/bin/ (#983) 2018-09-07 15:42:08 +08:00
Adam Drakeford
8689227b3e [KOTLIN] Spring Boot Server Generator (#820)
* Kotlin Spring initial bootstrap

* Basic configuration construction for Kotlin Spring

* Wired up with comand line client

* Initial kotlin spring boot application generated using gradle kotlin-dsl

* Added basic support for generating models

* Basic controllers generated without endpoints generated

* Basic spring boot app generated with models and controllers

* Added fix for type mapping in AbstractKotlinCodegen. Originally it was mapping list o kotlin.Array instead of kotlin.collections.List

* Fixed return type mapping

* Sorted bash springboot petstore generator script

* Implemented toVarName in AbstractKotlinCodegen to better handle some edgecases

* Checking for reserved words or numerical starting class names in AbstractKotlinCodegen

* Implemented toOperationId in AbstractKotlinCodegen

* Fixed types that were not correctly being mapped to primitives (byte / arrayOf / mapOf)

* Escaping dollar symbols in function names

* Added support for outter enum classes

* Added basic support for generating services

* Removed option for generated config package. Added option to enable/disable generated global exception handler

* Added configuration option to generate gradle. Generated maven pom.xml file as default

* Fixed up bash scripts for generating test sample code

* Added configurable option for Swagger Annotations

* Added configurable option for generating service interfaces and service implementations

* Added README generation

* Enable optional bean validation

* Added kotlin spring sample to CircleCI pom.xml

* Removed kotlin spring boot from .gitignore

* Minor fixes from PR comments for user submission (#1)

* Minor fixes from PR comments for user submission

* Puts braces around conditional block bodies with one-liner bodies.
* Modifies README.mustache to use artifact id and version supplied by
user (or default configuration)
* Targets templates under resource directory explicitly to prevent the
need to rebuild for evaluation of  template-only changes.

* [kotlin-spring] Remove comments referencing sbt in bash scripts

* List of changes based upon code review:
* Additional comments around how we set the title based off the open api spec
* Fixed missing `beanValidationCore` template
* Put the lambdas into the lambda object as other generators do (Ktor, C#, cpp)
* Bump swagger-annotations version to latest pre-2.0 version (1.5.21)
* Set kotlin version to 1.2.60
* Updated README to set port based on template
* Added more additional properties to build bash scripts
* Removed `defaultBasePath.mustache` in place of using {{contextPath}} directly
* Log warning for when `serviceImplementation` is set t o true

* Updated samples

* Generating ConstraintViolation Exception Handler, as Springboot doesnt correctly catch the error and return bad request. Handling other exceptions a litle better

* Small fix for date time mappings (plus sample re-gen)

* Minor fix in README template, where port was using wrong variable

* Fix missing jackson-dataformat-xml dependency

* Fix build - needed to re-run kotlin-server-petstore.sh

* Fixes after merge with master

* Revert "Small fix for date time mappings (plus sample re-gen)"

This reverts commit 4152dc78b4813da71c675272ca90fb31a333aea1.

* Moved type mappings to Kotlin Spring generator

* Regenerated samples

* Regenerated samples
2018-08-27 23:54:53 +08:00
Yuriy Belenko
e605882451 [PHP] Add gitignore to AbstractPhpCodegen (#765)
* [PHP] Remove PHP related rules from root gitignore

After conversation with @ackintosh we've agreed that every PHP codegen
should create it's own `.gitignore`. Client libraries(SDKs) should ignore
`composer.lock` file while server stubs better do opposite.

* [PHP] Set .gitignore as default supporting file

* [PHP] Add default gitignore to Client SDK

* [PHP] Add default gitignore to Laravel

* [PHP] Add default gitignore to Lumen

* [PHP] Add default gitignore to Silex

Seems like issue #663 and pull request #681 missed this security script,
I've changed output path in bin/security/silex-petstore-server.sh.

* [PHP] Update Slim

* [PHP] Add default gitignore to Symfony

I've copied few old rules from root gitignore to local one. These rules
should be reviewed by original SymfonyCodegen authors.

* [PHP] Add default gitignore to Zend

* [PHP] Refresh Openapi3 client samples

* [PHP] Add refs to .gitignore templates collection
2018-08-20 12:16:01 +08:00
William Cheng
6de09688ad
Add auto-generated readme for cpprestsdk client (#814)
* add auto-generated readme for cpprestsdk client

* update cpprest client sample

* remove error message from cmake
2018-08-16 00:23:48 +08:00
Christoph, René Pardon
f793ac25c7 feat (PHP LARAVEL) 8417: initial PHP-laravel codegen integration (#574)
* feat (PHP LARAVEL) 8417: initial PHP-laravel codegen integration

* feat (PHP LARAVEL) 8417: code review adjustments

* feat (PHP LARAVEL) 8417: fix typos; add missing files; adjust readme for those unfamilar with laravel to get started quickly

* feat (PHP LARAVEL) 8417: add sample petstore server

* feat (PHP LARAVEL) 8417: adjust route service provdider and model generation
2018-08-01 00:34:33 +08:00
William Cheng
d863c3e5f4
Add travis.yml to test java6 option (#568)
Add travis.yml to test java6 option, update Java (Jersey2) dependencies
2018-07-15 16:00:07 +08:00
Tomasz Prus
96e86ac03e update and fix python samples (#489)
* fix: update petstore samples for python, fix broken tests

* chore: entries for python-asyncio/tornado in gitignore
2018-07-08 15:29:55 +08:00
Jim Schubert
5a332f3c57
[gradle] Plugin release management (#201)
* [gradle] Plugin release management

This applies steps necessary for publishing to Sonatype, including
sources, javadoc, jar and signing. Also includes full POM details, per
Sonatype requirements.

* Properties placeholders in gradle plugin (should allow users without these settings to build locally)
* Update build wrapper for install task to be used with new maven plugin, not maven-publish plugin
* Add code signing for gradle and maven
2018-06-09 14:21:31 -04:00
William Cheng
7d9fb9f51e
Add CI test for Elm in travis (#40)
* test elm in travis

* install elm
2018-05-15 09:58:37 +08:00
William Cheng
1d889da4e3
Various fixes (#1)
* fix pistache c++ server in windows

* skip perl test

* comment out go tests

* Fix go test, manually fix go client

* fix rails batch file

* fix tab in java file

* install rust

* fix swift2-deprecated in windows batch file

* fix rust installation

* comment out js test

* update swift windows batch files

* update tizen batch script

* comment out ktor test
2018-05-13 01:31:13 +08:00
Jérémie Bresson
a00261d3da Change default package name value for kotlin server (#387)
* Update default package

* Regenerate samples/server/petstore/kotlin-server/ktor

* Update git ignore

* Add CI
2018-05-09 16:38:16 +08:00
Akihito Nakano
872dd546f4 Update php related samples (#375)
* Update php client (OAS3)

bin/openapi3/php-petstore.sh

* Update symfony server (OAS2)

bin/php-symfony-petstore.sh

* Lumen: remove 'swagger'

* Update lumen server (OAS2)

* Update php client (security): deleted 'SwaggerClient-php' folder

* Update TEST_DIR

* Update php client tests (OAS3)

bin/openapi3/php-petstore.sh

* Update php client (OAS2)

bin/php-petstore.sh

* Fix

* Fix lumen -> php-lumen

* Update lumen server (security)

* Delete moved files

currently it will generate into under 'lib' folder.

* Fix slim -> php-slim

* Update slim server (security)

bin/security/slim-petstore-server.sh

* Fix

* Update dot files
2018-05-09 10:34:19 +08:00
Jérémie Bresson
d35bf1a388 Change default package name value for kotlin client (#382)
* Move pom.xml to sample.ci

* Regenerate 'kotlin-threetenbp' example

* Add build to gitignore

* Change default value for Kotlin

* Regenerate kotlin-string client

* Regenerate kotlin-threetenbp client

* Regenerate 'samples/client/petstore/kotlin'
2018-05-09 10:32:37 +08:00
William Cheng
aab99bc530
Update Dart default value, re-enable Objc Tests (#328)
* update dart client default

* re-enable objc test

* restore dart flutter_petstore, update dart oas3 script
2018-05-06 01:45:52 +08:00
William Cheng
bcc7b788e0
fix erlang client compilation error (#228) 2018-04-26 13:44:05 +08:00
William Cheng
df26bcb40c
Update Erlang server samples with Petstore OAS2 (#150)
* update erlang server samples with petstore oas2

* fix compilation in erlang server
2018-04-26 13:34:02 +08:00
William Cheng
b908b734dd
Update Groovy default value, fix import error when doing "gradle test" (#203)
* update groovy default value, fix import error when doing gradle test

* remove empty lines
2018-04-23 17:31:14 +08:00
Jeremie Bresson
53597764c3 Add OpenAPI spec 3.0 support (beta)
Co-authored-by: Akihito Nakano <sora.akatsuki@gmail.com>
Co-authored-by: Jeremie Bresson <dev@jmini.fr>
Co-authored-by: Jim Schubert <james.schubert@gmail.com>
Co-authored-by: Martin Delille <martin@phonations.com>
Co-authored-by: Tomasz Prus <tomasz.prus@gmail.com>
Co-authored-by: William Cheng <wing328hk@gmail.com>
2018-04-17 09:19:10 +02:00
Martin Delille
1bb1e44d18 [qt5cpp] Remove qt5 pro.user file (#7813) 2018-03-12 23:17:39 +08:00
naelrashdeen
b034e4446a [PHP][Symfony] Enhancements (#6615)
* Removed commented code

* Input validation is now supported as strict JSON validation

* [PHP][Symfony] Improve the implementation
Closes #6614

* Generated code is tested to assure it compiles and updated README to dynamically load dependencies via composer

* Updated shell script because shippable tests were failing
2017-10-23 22:50:56 +08:00
wing328
3ac2b803f9 [Elixir] Add Elixir Petstore sample to Shippable CI (#6575)
* add elixir petstore to shippable ci

* use oracle sdk
2017-09-27 20:53:27 +08:00
Jakob Schelbert
e3ba06cabb Fix some bugs for the R client (#6535)
* * Fix bugs in api.mustache, model.mustache, mostly bracket errors or small typos
* Added section about installation in README.mustace
TODO: fix tests in testthat
TODO: fix bug in description.mustace regarding package name

* Updates to sample for R client caused by running ./bin/r-petstore.sh (or .\bin\windows\r-petstore.bat)

* Add R specific files to .gitignore

* [R] add additional files generated by the petstore sample. (see #6520)
2017-09-27 00:06:53 +08:00
Jon Schoning
c7d145a4ba add haskell-http-client-generator (#6429) 2017-09-06 00:33:48 +08:00
Yusuke Tsutsumi
d39b1ff76f [python] asyncio support (#6245)
* trying an approach with providing asyncio as a framework.

* adding example of asyncio.

* removing sample client to help PR look more manageable.

* possibly fixing a unit test

* getting unit test to pass again.

* addressing comments.
2017-08-14 16:16:55 +08:00
wing328
71123e157e [Java][JAX-RS] Add Petstore samples with "useTags" option (#6300)
* add samples for jaxrs (jersey1,2) usetags

* fix duplicated id
2017-08-12 22:05:25 +08:00
wing328
4a8d9c3509 add "Data" as reserved word in swift 2.x, 4.x 2017-07-24 00:06:11 +08:00
wing328
188e998683 add petstore samples for typescript aurelia 2017-07-23 15:52:02 +08:00
wing328
e964702550 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-07-12 21:54:23 +08:00
mobreza
5d32edd964 Java support for application/xml (#5962)
* WIP: CodegenProperty with XML

* WIP: CodegenModel XML bits

* WIP: Jackson XML

* WIP: Java templating

* WIP: Java client withXml flag

* WIP: resttemplate work

* WIP: withXml only when Jackson is used

* WIP: Tabs to spaces

* WIP: java-petstore-resttemplate-withxml sample

* WIP: language: spring

* WIP: language "spring" using library "spring-boot" should include apiPackage in @ComponentScan to detect the API

* WIP: javax.xml for non-Jackson Java and enabled payload logging for jersey2

* WIP: updated java petstore samples

* WIP: JavaSpring with non-jackson XML

* WIP: bin/spring-all-pestore.sh
2017-07-11 17:01:51 +08:00
wing328
25a46374c5 Updated Spring, Boot, Fox and Cloud dependencies (#5969)
* updated Spring, Boot, Fox and Cloud dependencies

* run scripts for java, jaxrs-cxf and spring samples (although changes are not related to my changes)

* update jersey java8 petstore samples

* update java feign samples

* update java petstore samples

* add new files for java petstore clients

* roll back spring cloud dep version

* fix jaxrs-cxf error
2017-07-03 18:44:22 +08:00
wing328
ecf924e78f [Spring] Adds feature useOptional (#5968)
* Adds Valid annotation for request body (#4847)

If useBeanValidation is active, this change will add Valid annotation to ReqeustBody

* Adds generated samples for bean vaildation in spring boot (#4847)

* Adds feature option (#3819)

When you enable the feature useOptional the JavaSpring generator will use type Optional for non required parameters.

* Adds generated sample for #3819

* Adds generated sample for #3819

* Reverts commit for bean validation

* Adds generated sample for #3819

* Reverts commit for bean validation

* Fix alignment

* update spring samples

* update pom.xml to include spring use optional samples

* update artifactId to "spring-boot-beanvalidation"

* rpelace tab with 4-space

* check mvn task result
2017-07-03 17:40:00 +08:00
wing328
49dbb51957 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-26 23:39:04 +08:00
wing328
522d704f7a [Java] Update dependencies for Java clients (#5926)
* update dep for java jersey1, jersey2

* update sbt dependency for jersey2

* update dep for java okhttp-gson, resteasy, resttemplate

* update dep for java retrofit 1.x, 2.x

* update java petstore samples
2017-06-26 23:18:45 +08:00
wing328
fee54157c0 Merge remote-tracking branch 'origin/master' into 2.3.0 2017-06-15 17:14:39 +08:00