Skip to content

Commit f1fcceb

Browse files
authored
Major Jetbrains HTTP Client upgrade. Move to BETA (#15779)
* Add notes to requests for better readability * Adds extra configs for jetbrains http client for testing * Adding new sample data * Changes * Setting up test infrastructure * Adds body to requests. * Fixing some bugs in map traversal It'd be much better to use a proper library for this though * Adding secret file to gitignore * Adds github spec, for complex example. Add null check to avoid errors in example extraction * Add support for custom variables in request body * Add support for all basic Auth headers * Not sure whaet happened with my api mustache file * Add support for custom headers * Fixes empty lines issue * Adds support for Accept header * Adding many tests, deleting experiment files * Updates generator doc * Completes README file with extra information * Runs generate-samples and export docs * Running sample generation * Adding missing files to samples * Removing forgotten stdout statements * Ignore one test making the docker image generation fail
1 parent 93d5fc6 commit f1fcceb

123 files changed

Lines changed: 395594 additions & 98 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -283,3 +283,4 @@ samples/openapi3/client/petstore/go/privatekey.pem
283283

284284
## OCaml
285285
samples/client/petstore/ocaml/_build/
286+
/samples/client/jetbrains/adyen/checkout71/http/client/Apis/http-client.private.env.json
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
generatorName: jetbrains-http-client
2+
outputDir: samples/client/jetbrains/adyen/adyen/http/client
3+
inputSpec: modules/openapi-generator/src/test/resources/3_0/jetbrains/CheckoutService-v71.yaml
4+
templateDir: modules/openapi-generator/src/main/resources/jetbrains-http-client
5+
additionalProperties:
6+
hideGenerationTimestamp: "true"
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
generatorName: jetbrains-http-client
2+
outputDir: samples/client/jetbrains/adyen/checkoutbasic/http/client
3+
inputSpec: modules/openapi-generator/src/test/resources/3_0/jetbrains/CheckoutBasic.yaml
4+
templateDir: modules/openapi-generator/src/main/resources/jetbrains-http-client
5+
additionalProperties:
6+
hideGenerationTimestamp: "true"
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
generatorName: jetbrains-http-client
2+
outputDir: samples/client/opendota/jetbrains/http/client
3+
inputSpec: modules/openapi-generator/src/test/resources/3_0/opendota.json
4+
templateDir: modules/openapi-generator/src/main/resources/jetbrains-http-client
5+
additionalProperties:
6+
hideGenerationTimestamp: "true"
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
generatorName: jetbrains-http-client
2+
outputDir: samples/client/github/jetbrains/http/client
3+
inputSpec: modules/openapi-generator/src/test/resources/3_0/jetbrains/github.json
4+
templateDir: modules/openapi-generator/src/main/resources/jetbrains-http-client
5+
additionalProperties:
6+
hideGenerationTimestamp: "true"

docs/generators/jetbrains-http-client.md

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,8 @@ These options may be applied as additional-properties (cli) or configOptions (pl
1818

1919
| Option | Description | Values | Default |
2020
| ------ | ----------- | ------ | ------- |
21-
|allowUnicodeIdentifiers|boolean, toggles whether unicode identifiers are allowed in names or not, default is false| |false|
22-
|disallowAdditionalPropertiesIfNotPresent|If false, the 'additionalProperties' implementation (set to true by default) is compliant with the OAS and JSON schema specifications. If true (default), keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.|<dl><dt>**false**</dt><dd>The 'additionalProperties' implementation is compliant with the OAS and JSON schema specifications.</dd><dt>**true**</dt><dd>Keep the old (incorrect) behaviour that 'additionalProperties' is set to false by default.</dd></dl>|true|
23-
|ensureUniqueParams|Whether to ensure parameter names are unique in an operation (rename parameters that are not).| |true|
24-
|enumUnknownDefaultCase|If the server adds new enum cases, that are unknown by an old spec/client, the client will fail to parse the network response.With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the server sends an enum case that is not known by the client/spec, they can safely fallback to this case.|<dl><dt>**false**</dt><dd>No changes to the enum's are made, this is the default option.</dd><dt>**true**</dt><dd>With this option enabled, each enum will have a new case, 'unknown_default_open_api', so that when the enum case sent by the server is not known by the client/spec, can safely be decoded to this case.</dd></dl>|false|
25-
|legacyDiscriminatorBehavior|Set to false for generators with better support for discriminators. (Python, Java, Go, PowerShell, C# have this enabled by default).|<dl><dt>**true**</dt><dd>The mapping in the discriminator includes descendent schemas that allOf inherit from self and the discriminator mapping schemas in the OAS document.</dd><dt>**false**</dt><dd>The mapping in the discriminator includes any descendent schemas that allOf inherit from self, any oneOf schemas, any anyOf schemas, any x-discriminator-values, and the discriminator mapping schemas in the OAS document AND Codegen validates that oneOf and anyOf schemas contain the required discriminator and throws an error if the discriminator is missing.</dd></dl>|true|
26-
|prependFormOrBodyParameters|Add form or body parameters to the beginning of the parameter list.| |false|
27-
|sortModelPropertiesByRequiredFlag|Sort model properties to place required parameters before optional parameters.| |true|
28-
|sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true|
21+
|bodyVariables|whether to convert body placeholders (i.e. VAR_1) into variables (i.e. {{VAR_1}})| |null|
22+
|customHeaders|custom headers that can be set for each request. Can be used for unsupported features, for example auth methods like oauth.| |null|
2923

3024
## IMPORT MAPPING
3125

0 commit comments

Comments
 (0)