Supports:
All OpenAPI 3.x data types: primitives, arrays, enums, nullable/optional fields, nested objects
All parameter types: path, query, header, cookie, and combinations
Schema composition: allOf (inheritance), oneOf (discriminated unions), anyOf (flexible unions)
Security schemes: API key and bearer token authentication
Discriminator-based polymorphic deserialization and error handling
Provides:
Error handling for invalid JSON, type mismatches, missing/unknown discriminator, and parameter validation
Build system integration (CMake) for easy compilation and linking with required dependencies
Clear build and run instructions for local development and testing
Enables comprehensive, real-world validation of generated C++ server code against OpenAPI specifications
* fix(java/feign): handle binary response types in ApiResponseDecoder
The Feign library's ApiResponseDecoder routes all responses through
JacksonDecoder, including binary ones (File, byte[], InputStream).
This causes JsonParseException when an endpoint returns non-JSON
content (e.g. PDF, ZIP, images).
Add binary type detection and handling before delegating to
JacksonDecoder. This applies to both direct return types and
ApiResponse<T> wrappers.
Consistent with the native library fix in #21346.
Closes#2486
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: address code review feedback
- Sanitize Content-Disposition filename to prevent path traversal
(Paths.get(filename).getFileName() strips directory components)
- Add null check for response.body() to handle 204/205 empty responses
- Fix regex to support quoted filenames with spaces
(e.g. filename="my invoice.pdf")
* fix: regenerate feign-hc5 sample with updated ApiResponseDecoder
The feign-hc5 sample was missed during the second commit's regeneration
because setTemplateDir("feign") overrides the filesystem templateDir
from the config, causing the generator to use embedded JAR resources.
After rebuilding the JAR with the updated mustache template, the
feign-hc5 sample now matches feign and feign-no-nullable.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
* [php-symfony] do not interpret sequential escape
* chore: update samples
* refactor: add missing return type
* [php-symfony] make template compatible with Symfony 8
* feat(python): enhance retry configuration in REST client
Updated the retry parameter in the Configuration class to support different types based on the library used (urllib3 or asyncio). Adjusted the RESTClientObject to handle the new retry configuration, allowing for more flexible retry options. This change improves the handling of retries in API requests, ensuring compatibility with various retry strategies.
* add samples
* use async context for retry doc string
* [Java] add missing nullable judgement when required property is true
* [Java] add okhttp template test and regenerate sample
* [Java] add tests when field is nullable and required
* [Java] regenerate samples to fix pipeline error
* [Java] add JSONTest fro RequiredNullableBody class
* run generate-samples after rebase
* review feedback
* review feedback
* fix test
* update hash of test file
---------
Co-authored-by: weirdo0314 <2019215183@stu.cqupt.edu.cn>
* BUG:21187 put back hardcoded client without the issue created in 8484
* BUG:21187 put back hardcoded client without the issue created in 8484
---------
Co-authored-by: Sri Sushma Karra <srisushmakarra@Sris-MacBook-Air.local>
* [kotlin][jvm-okhttp4] Fix multipart/form-data with JSON content-type
Fixes#16457
Fixes two critical bugs in multipart/form-data handling when parts
have Content-Type application/json:
1. IllegalArgumentException: OkHttp throws "Unexpected header: Content-Type"
because Content-Type was passed in headers map instead of via
asRequestBody(mediaType)/toRequestBody(mediaType) parameter.
2. Invalid JSON serialization: Non-file parts with application/json
Content-Type were serialized using toString() instead of proper
JSON serialization, producing invalid output like:
"MyObject(field1=value, field2=123)" instead of
'{"field1":"value","field2":123}'
Changes:
- Filter Content-Type from headers before passing to OkHttp
- Check part Content-Type and use appropriate serializer (JSON vs toString)
- Add integration tests with echo server to verify fix
- Support all serialization libraries (gson, moshi, jackson, kotlinx)
Fixes issues with multipart endpoints that mix file uploads with
JSON metadata, common in REST APIs for document/image uploads.
* Run mvn clean/package, and regenerate samples
* Add fix for kotlinx serialisation issue
* Refactor multipart helpers for reified type parameter support
* Fix kotlinx.serialization multipart by adding serializer lambda to PartConfig
* Fix internal Ktor API usage in multipart forms
We already have logic in postProcessModelProperty to fit integer
parameters into the correct Rust primitives. However, this doesn't apply
to other kinds of parameters so integer-typed parameters which end up in
function calls for Api traits in lib.rs are always i32, even when this
is improper.
This commit refactors integer type fitting so that we can run it on both
processParam and model post-processing.
* feat: Support selective ssl/tls backend in rust-server to avoid always requiring openssl
* feat: Switch default features so a user must select SSL backend
* Further tweaks to rust-server HTTPS feature flagging