diff --git a/modules/openapi-generator/src/main/resources/ruby-client/api_client.mustache b/modules/openapi-generator/src/main/resources/ruby-client/api_client.mustache index 3400b97da4ec..6723bb756c66 100644 --- a/modules/openapi-generator/src/main/resources/ruby-client/api_client.mustache +++ b/modules/openapi-generator/src/main/resources/ruby-client/api_client.mustache @@ -149,8 +149,9 @@ module {{moduleName}} data.each { |k, v| hash[k] = convert_to_type(v, sub_type) } end else - # models, e.g. Pet - {{moduleName}}.const_get(return_type).build_from_hash(data) + # models (e.g. Pet) or oneOf + klass = {{moduleName}}.const_get(return_type) + klass.respond_to?(:openapi_one_of) ? klass.build(data) : klass.build_from_hash(data) end end diff --git a/modules/openapi-generator/src/main/resources/ruby-client/api_doc.mustache b/modules/openapi-generator/src/main/resources/ruby-client/api_doc.mustache index 0e5d35513e32..3505c475adff 100644 --- a/modules/openapi-generator/src/main/resources/ruby-client/api_doc.mustache +++ b/modules/openapi-generator/src/main/resources/ruby-client/api_doc.mustache @@ -4,10 +4,13 @@ All URIs are relative to *{{basePath}}* -Method | HTTP request | Description -------------- | ------------- | ------------- -{{#operations}}{{#operation}}[**{{operationId}}**]({{classname}}.md#{{operationId}}) | **{{httpMethod}}** {{path}} | {{#summary}}{{summary}}{{/summary}} -{{/operation}}{{/operations}} +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +{{#operations}} +{{#operation}} +| [**{{operationId}}**]({{classname}}.md#{{operationId}}) | **{{httpMethod}}** {{path}} | {{#summary}}{{summary}}{{/summary}} | +{{/operation}} +{{/operations}} {{#operations}} {{#operation}} @@ -67,10 +70,15 @@ end ### Parameters -{{^allParams}}This endpoint does not need any parameter.{{/allParams}}{{#allParams}}{{#-last}} -Name | Type | Description | Notes -------------- | ------------- | ------------- | -------------{{/-last}}{{/allParams}} -{{#allParams}} **{{paramName}}** | {{#isPrimitiveType}}**{{dataType}}**{{/isPrimitiveType}}{{^isPrimitiveType}}{{#isFile}}**{{dataType}}**{{/isFile}}{{^isFile}}[**{{dataType}}**]({{baseType}}.md){{/isFile}}{{/isPrimitiveType}}| {{description}} | {{^required}}[optional] {{/required}}{{#defaultValue}}[default to {{defaultValue}}]{{/defaultValue}} +{{^allParams}} +This endpoint does not need any parameter. +{{/allParams}} +{{#allParams}} +{{#-first}} +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +{{/-first}} +| **{{paramName}}** | {{#isPrimitiveType}}**{{dataType}}**{{/isPrimitiveType}}{{^isPrimitiveType}}{{#isFile}}**{{dataType}}**{{/isFile}}{{^isFile}}[**{{dataType}}**]({{baseType}}.md){{/isFile}}{{/isPrimitiveType}} | {{description}} | {{^required}}[optional]{{/required}}{{#defaultValue}}[default to {{defaultValue}}]{{/defaultValue}} | {{/allParams}} ### Return type diff --git a/modules/openapi-generator/src/main/resources/ruby-client/base_object.mustache b/modules/openapi-generator/src/main/resources/ruby-client/base_object.mustache index abda94a7eb1d..00a8e35b88f7 100644 --- a/modules/openapi-generator/src/main/resources/ruby-client/base_object.mustache +++ b/modules/openapi-generator/src/main/resources/ruby-client/base_object.mustache @@ -67,7 +67,9 @@ end end else # model - {{moduleName}}.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = {{moduleName}}.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -93,7 +95,7 @@ is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash diff --git a/modules/openapi-generator/src/main/resources/ruby-client/model.mustache b/modules/openapi-generator/src/main/resources/ruby-client/model.mustache index 345d502b1d49..fa8f8c5bbb17 100644 --- a/modules/openapi-generator/src/main/resources/ruby-client/model.mustache +++ b/modules/openapi-generator/src/main/resources/ruby-client/model.mustache @@ -12,7 +12,14 @@ module {{moduleName}} {{>partial_model_enum_class}} {{/isEnum}} {{^isEnum}} +{{#oneOf}} +{{#-first}} +{{>partial_oneof_module}} +{{/-first}} +{{/oneOf}} +{{^oneOf}} {{>partial_model_generic}} +{{/oneOf}} {{/isEnum}} {{/model}} {{/models}} diff --git a/modules/openapi-generator/src/main/resources/ruby-client/model_doc.mustache b/modules/openapi-generator/src/main/resources/ruby-client/model_doc.mustache index c2a790d9dace..37809685d1c0 100644 --- a/modules/openapi-generator/src/main/resources/ruby-client/model_doc.mustache +++ b/modules/openapi-generator/src/main/resources/ruby-client/model_doc.mustache @@ -1,19 +1,12 @@ -{{#models}}{{#model}}# {{moduleName}}::{{classname}} - -## Properties - -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -{{#vars}}**{{name}}** | {{#isPrimitiveType}}**{{dataType}}**{{/isPrimitiveType}}{{^isPrimitiveType}}[**{{dataType}}**]({{complexType}}.md){{/isPrimitiveType}} | {{description}} | {{^required}}[optional] {{/required}}{{#isReadOnly}}[readonly] {{/isReadOnly}}{{#defaultValue}}[default to {{defaultValue}}]{{/defaultValue}} -{{/vars}} - -## Code Sample - -```ruby -require '{{moduleName}}' - -instance = {{moduleName}}::{{classname}}.new({{#vars}}{{name}}: {{example}}{{^-last}}, - {{/-last}}{{/vars}}) -``` - -{{/model}}{{/models}} +{{#models}} +{{#model}} +{{#oneOf}} +{{#-first}} +{{>partial_oneof_module_doc}} +{{/-first}} +{{/oneOf}} +{{^oneOf}} +{{>partial_model_generic_doc}} +{{/oneOf}} +{{/model}} +{{/models}} diff --git a/modules/openapi-generator/src/main/resources/ruby-client/model_test.mustache b/modules/openapi-generator/src/main/resources/ruby-client/model_test.mustache index 47b8d53c3197..47bd571592e9 100644 --- a/modules/openapi-generator/src/main/resources/ruby-client/model_test.mustache +++ b/modules/openapi-generator/src/main/resources/ruby-client/model_test.mustache @@ -11,19 +11,13 @@ require 'date' # Please update as you see appropriate {{#models}} {{#model}} -describe '{{classname}}' do - before do - # run before each test - @instance = {{moduleName}}::{{classname}}.new - end - - after do - # run after each test - end +describe {{moduleName}}::{{classname}} do +{{^oneOf}} + let(:instance) { {{moduleName}}::{{classname}}.new } describe 'test an instance of {{classname}}' do it 'should create an instance of {{classname}}' do - expect(@instance).to be_instance_of({{moduleName}}::{{classname}}) + expect(instance).to be_instance_of({{moduleName}}::{{classname}}) end end {{#vars}} @@ -33,7 +27,7 @@ describe '{{classname}}' do # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers # validator = Petstore::EnumTest::EnumAttributeValidator.new('{{{dataType}}}', [{{#allowableValues}}{{#enumVars}}{{{value}}}{{^-last}}, {{/-last}}{{/enumVars}}{{/allowableValues}}]) # validator.allowable_values.each do |value| - # expect { @instance.{{name}} = value }.not_to raise_error + # expect { instance.{{name}} = value }.not_to raise_error # end {{/isEnum}} {{^isEnum}} @@ -43,6 +37,42 @@ describe '{{classname}}' do end {{/vars}} +{{/oneOf}} +{{#oneOf}} +{{#-first}} + describe '.openapi_one_of' do + it 'lists the models referenced in the oneOf array' do + expect(described_class.openapi_one_of).to_not be_empty + described_class.openapi_one_of.each { |klass| expect { {{moduleName}}.const_get(klass) }.to_not raise_error } + end + end + + {{#discriminator}} + {{#propertyName}} + describe '.openapi_discriminator_name' do + it 'returns the value of the "discriminator" property' do + expect(described_class.openapi_discriminator_name).to_not be_empty + end + end + + {{/propertyName}} + {{#mappedModels}} + {{#-first}} + describe '.openapi_discriminator_mapping' do + it 'returns the key/values of the "mapping" property' do + expect(described_class.openapi_discriminator_mapping.values.sort).to eq(described_class.openapi_one_of.sort) + end + end + + {{/-first}} + {{/mappedModels}} + {{/discriminator}} + describe '.build' do + it 'returns the correct model' do + end + end +{{/-first}} +{{/oneOf}} end {{/model}} {{/models}} diff --git a/modules/openapi-generator/src/main/resources/ruby-client/partial_model_generic.mustache b/modules/openapi-generator/src/main/resources/ruby-client/partial_model_generic.mustache index e5e491913e53..3a620fc1f222 100644 --- a/modules/openapi-generator/src/main/resources/ruby-client/partial_model_generic.mustache +++ b/modules/openapi-generator/src/main/resources/ruby-client/partial_model_generic.mustache @@ -42,6 +42,16 @@ } end + # Returns all the JSON keys this model knows about{{#parent}}, including the ones defined in its parent(s){{/parent}} + def self.acceptable_attributes + {{^parent}} + attribute_map.values + {{/parent}} + {{#parent}} + attribute_map.values.concat(superclass.acceptable_attributes) + {{/parent}} + end + # Attribute type mapping. def self.openapi_types { @@ -75,19 +85,6 @@ {{/-last}} {{/anyOf}} - {{#oneOf}} - {{#-first}} - # List of class defined in oneOf (OpenAPI v3) - def self.openapi_one_of - [ - {{/-first}} - :'{{{.}}}'{{^-last}},{{/-last}} - {{#-last}} - ] - end - - {{/-last}} - {{/oneOf}} {{#allOf}} {{#-first}} # List of class defined in allOf (OpenAPI v3) @@ -270,26 +267,6 @@ {{/-first}} {{/anyOf}} - {{#oneOf}} - {{#-first}} - _one_of_found = false - self.class.openapi_one_of.each do |_class| - _one_of = {{moduleName}}.const_get(_class).build_from_hash(self.to_hash) - if _one_of.valid? - if _one_of_found - return false - else - _one_of_found = true - end - end - end - - if !_one_of_found - return false - end - - {{/-first}} - {{/oneOf}} true{{#parent}} && super{{/parent}} end @@ -391,4 +368,4 @@ end {{> base_object}} - end \ No newline at end of file + end diff --git a/modules/openapi-generator/src/main/resources/ruby-client/partial_model_generic_doc.mustache b/modules/openapi-generator/src/main/resources/ruby-client/partial_model_generic_doc.mustache new file mode 100644 index 000000000000..72778dff1e61 --- /dev/null +++ b/modules/openapi-generator/src/main/resources/ruby-client/partial_model_generic_doc.mustache @@ -0,0 +1,28 @@ +# {{moduleName}}::{{classname}} + +## Properties + +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +{{#vars}} +| **{{name}}** | {{#isPrimitiveType}}**{{dataType}}**{{/isPrimitiveType}}{{^isPrimitiveType}}[**{{dataType}}**]({{complexType}}.md){{/isPrimitiveType}} | {{description}} | {{^required}}[optional]{{/required}}{{#isReadOnly}}[readonly]{{/isReadOnly}}{{#defaultValue}}[default to {{defaultValue}}]{{/defaultValue}} | +{{/vars}} + +## Code Sample + +```ruby +require '{{{gemName}}}' + +{{^vars}} +instance = {{moduleName}}::{{classname}}.new() +{{/vars}} +{{#vars}} +{{#-first}} +instance = {{moduleName}}::{{classname}}.new( +{{/-first}} + {{name}}: {{example}}{{^-last}},{{/-last}} +{{#-last}} +) +{{/-last}} +{{/vars}} +``` diff --git a/modules/openapi-generator/src/main/resources/ruby-client/partial_oneof_module.mustache b/modules/openapi-generator/src/main/resources/ruby-client/partial_oneof_module.mustache new file mode 100644 index 000000000000..14dc1635bb74 --- /dev/null +++ b/modules/openapi-generator/src/main/resources/ruby-client/partial_oneof_module.mustache @@ -0,0 +1,137 @@ + {{#description}} + # {{{description}}} + {{/description}} + module {{classname}} + class << self + {{#oneOf}} + {{#-first}} + # List of class defined in oneOf (OpenAPI v3) + def openapi_one_of + [ + {{/-first}} + :'{{{.}}}'{{^-last}},{{/-last}} + {{#-last}} + ] + end + + {{/-last}} + {{/oneOf}} + {{#discriminator}} + {{#propertyName}} + # Discriminator's property name (OpenAPI v3) + def openapi_discriminator_name + :'{{{.}}}' + end + + {{/propertyName}} + {{#mappedModels}} + {{#-first}} + # Discriminator's mapping (OpenAPI v3) + def openapi_discriminator_mapping + { + {{/-first}} + :'{{{mappingName}}}' => :'{{{modelName}}}'{{^-last}},{{/-last}} + {{#-last}} + } + end + + {{/-last}} + {{/mappedModels}} + {{/discriminator}} + # Builds the object + # @param [Mixed] Data to be matched against the list of oneOf items + # @return [Object] Returns the model or the data itself + def build(data) + {{#discriminator}} + discriminator_value = data[openapi_discriminator_name] + return nil unless discriminator_value + {{#mappedModels}} + {{#-first}} + + klass = openapi_discriminator_mapping[discriminator_value.to_sym] + return nil unless klass + + {{moduleName}}.const_get(klass).build_from_hash(data) + {{/-first}} + {{/mappedModels}} + {{^mappedModels}} + {{moduleName}}.const_get(discriminator_value).build_from_hash(data) + {{/mappedModels}} + {{/discriminator}} + {{^discriminator}} + # Go through the list of oneOf items and attempt to identify the appropriate one. + # Note: + # - We do not attempt to check whether exactly one item matches. + # - No advanced validation of types in some cases (e.g. "x: { type: string }" will happily match { x: 123 }) + # due to the way the deserialization is made in the base_object template (it just casts without verifying). + # - TODO: scalar values are defacto behaving as if they were nullable. + # - TODO: logging when debugging is set. + openapi_one_of.each do |klass| + begin + next if klass == :AnyType # "nullable: true" + typed_data = find_and_cast_into_type(klass, data) + return typed_data if typed_data + rescue # rescue all errors so we keep iterating even if the current item lookup raises + end + end + + openapi_one_of.include?(:AnyType) ? data : nil + {{/discriminator}} + end + {{^discriminator}} + + private + + SchemaMismatchError = Class.new(StandardError) + + # Note: 'File' is missing here because in the regular case we get the data _after_ a call to JSON.parse. + def find_and_cast_into_type(klass, data) + return if data.nil? + + case klass.to_s + when 'Boolean' + return data if data.instance_of?(TrueClass) || data.instance_of?(FalseClass) + when 'Float' + return data if data.instance_of?(Float) + when 'Integer' + return data if data.instance_of?(Integer) + when 'Time' + return Time.parse(data) + when 'Date' + return Date.parse(data) + when 'String' + return data if data.instance_of?(String) + when 'Object' # "type: object" + return data if data.instance_of?(Hash) + when /\AArray<(?.+)>\z/ # "type: array" + if data.instance_of?(Array) + sub_type = Regexp.last_match[:sub_type] + return data.map { |item| find_and_cast_into_type(sub_type, item) } + end + when /\AHash.+)>\z/ # "type: object" with "additionalProperties: { ... }" + if data.instance_of?(Hash) && data.keys.all? { |k| k.instance_of?(Symbol) || k.instance_of?(String) } + sub_type = Regexp.last_match[:sub_type] + return data.each_with_object({}) { |(k, v), hsh| hsh[k] = find_and_cast_into_type(sub_type, v) } + end + else # model + const = {{moduleName}}.const_get(klass) + if const + if const.respond_to?(:openapi_one_of) # nested oneOf model + model = const.build(data) + return model if model + else + # raise if data contains keys that are not known to the model + raise unless (data.keys - const.acceptable_attributes).empty? + model = const.build_from_hash(data) + return model if model && model.valid? + end + end + end + + raise # if no match by now, raise + rescue + raise SchemaMismatchError, "#{data} doesn't match the #{klass} type" + end + {{/discriminator}} + end + end diff --git a/modules/openapi-generator/src/main/resources/ruby-client/partial_oneof_module_doc.mustache b/modules/openapi-generator/src/main/resources/ruby-client/partial_oneof_module_doc.mustache new file mode 100644 index 000000000000..64a6c32dc854 --- /dev/null +++ b/modules/openapi-generator/src/main/resources/ruby-client/partial_oneof_module_doc.mustache @@ -0,0 +1,92 @@ +# {{moduleName}}::{{classname}} + +## Class instance methods + +### `openapi_one_of` + +Returns the list of classes defined in oneOf. + +#### Example + +```ruby +require '{{{gemName}}}' + +{{moduleName}}::{{classname}}.openapi_one_of +# => +{{#oneOf}} +{{#-first}} +# [ +{{/-first}} +# :'{{{.}}}'{{^-last}},{{/-last}} +{{#-last}} +# ] +{{/-last}} +{{/oneOf}} +``` +{{#discriminator}} +{{#propertyName}} + +### `openapi_discriminator_name` + +Returns the discriminator's property name. + +#### Example + +```ruby +require '{{{gemName}}}' + +{{moduleName}}::{{classname}}.openapi_discriminator_name +# => :'{{{.}}}' +``` +{{/propertyName}} +{{#mappedModels}} +{{#-first}} + +### `openapi_discriminator_name` + +Returns the discriminator's mapping. + +#### Example + +```ruby +require '{{{gemName}}}' + +{{moduleName}}::{{classname}}.openapi_discriminator_mapping +# => +# { +{{/-first}} +# :'{{{mappingName}}}' => :'{{{modelName}}}'{{^-last}},{{/-last}} +{{#-last}} +# } +{{/-last}} +{{/mappedModels}} +{{/discriminator}} + +### build + +Find the appropriate object from the `openapi_one_of` list and casts the data into it. + +#### Example + +```ruby +require '{{{gemName}}}' + +{{moduleName}}::{{classname}}.build(data) +# => {{#oneOf}}{{#-first}}#<{{{.}}}:0x00007fdd4aab02a0>{{/-first}}{{/oneOf}} + +{{moduleName}}::{{classname}}.build(data_that_doesnt_match) +# => nil +``` + +#### Parameters + +| Name | Type | Description | +| ---- | ---- | ----------- | +| **data** | **Mixed** | data to be matched against the list of oneOf items | + +#### Return type + +{{#oneOf}} +- `{{{.}}}` +{{/oneOf}} +- `nil` (if no type matches) diff --git a/modules/openapi-generator/src/test/resources/3_0/petstore-with-fake-endpoints-models-for-testing.yaml b/modules/openapi-generator/src/test/resources/3_0/petstore-with-fake-endpoints-models-for-testing.yaml index f46a2427dde4..8211b6812a68 100644 --- a/modules/openapi-generator/src/test/resources/3_0/petstore-with-fake-endpoints-models-for-testing.yaml +++ b/modules/openapi-generator/src/test/resources/3_0/petstore-with-fake-endpoints-models-for-testing.yaml @@ -1100,16 +1100,16 @@ paths: summary: test http signature authentication operationId: fake-http-signature-test parameters: - - name: query_1 + - name: query_1 in: query description: query parameter - required: optional + required: optional schema: type: string - - name: header_1 - in: header + - name: header_1 + in: header description: header parameter - required: optional + required: optional schema: type: string security: @@ -1198,7 +1198,7 @@ components: bearerFormat: JWT http_signature_test: type: http - scheme: signature + scheme: signature schemas: Foo: type: object diff --git a/samples/client/petstore/ruby-faraday/docs/AdditionalPropertiesClass.md b/samples/client/petstore/ruby-faraday/docs/AdditionalPropertiesClass.md index e0d6811081cd..1806db9d3e6f 100644 --- a/samples/client/petstore/ruby-faraday/docs/AdditionalPropertiesClass.md +++ b/samples/client/petstore/ruby-faraday/docs/AdditionalPropertiesClass.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**map_property** | **Hash<String, String>** | | [optional] -**map_of_map_property** | **Hash<String, Hash<String, String>>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **map_property** | **Hash<String, String>** | | [optional] | +| **map_of_map_property** | **Hash<String, Hash<String, String>>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::AdditionalPropertiesClass.new(map_property: null, - map_of_map_property: null) +instance = Petstore::AdditionalPropertiesClass.new( + map_property: null, + map_of_map_property: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Animal.md b/samples/client/petstore/ruby-faraday/docs/Animal.md index 80e132d13e45..7ebaee441b94 100644 --- a/samples/client/petstore/ruby-faraday/docs/Animal.md +++ b/samples/client/petstore/ruby-faraday/docs/Animal.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**class_name** | **String** | | -**color** | **String** | | [optional] [default to 'red'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **class_name** | **String** | | | +| **color** | **String** | | [optional][default to 'red'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Animal.new(class_name: null, - color: null) +instance = Petstore::Animal.new( + class_name: null, + color: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/AnotherFakeApi.md b/samples/client/petstore/ruby-faraday/docs/AnotherFakeApi.md index d7b52283ea50..d14a8db14ead 100644 --- a/samples/client/petstore/ruby-faraday/docs/AnotherFakeApi.md +++ b/samples/client/petstore/ruby-faraday/docs/AnotherFakeApi.md @@ -2,10 +2,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**call_123_test_special_tags**](AnotherFakeApi.md#call_123_test_special_tags) | **PATCH** /another-fake/dummy | To test special tags - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**call_123_test_special_tags**](AnotherFakeApi.md#call_123_test_special_tags) | **PATCH** /another-fake/dummy | To test special tags | ## call_123_test_special_tags @@ -36,10 +35,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **client** | [**Client**](Client.md)| client model | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | [**Client**](Client.md) | client model | | ### Return type diff --git a/samples/client/petstore/ruby-faraday/docs/ApiResponse.md b/samples/client/petstore/ruby-faraday/docs/ApiResponse.md index c0ac7c4b4c17..4dfc3bab1fa0 100644 --- a/samples/client/petstore/ruby-faraday/docs/ApiResponse.md +++ b/samples/client/petstore/ruby-faraday/docs/ApiResponse.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**code** | **Integer** | | [optional] -**type** | **String** | | [optional] -**message** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **code** | **Integer** | | [optional] | +| **type** | **String** | | [optional] | +| **message** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ApiResponse.new(code: null, - type: null, - message: null) +instance = Petstore::ApiResponse.new( + code: null, + type: null, + message: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/ArrayOfArrayOfNumberOnly.md b/samples/client/petstore/ruby-faraday/docs/ArrayOfArrayOfNumberOnly.md index 5bb9ff33be21..ac0b04278845 100644 --- a/samples/client/petstore/ruby-faraday/docs/ArrayOfArrayOfNumberOnly.md +++ b/samples/client/petstore/ruby-faraday/docs/ArrayOfArrayOfNumberOnly.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**array_array_number** | **Array<Array<Float>>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **array_array_number** | **Array<Array<Float>>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ArrayOfArrayOfNumberOnly.new(array_array_number: null) +instance = Petstore::ArrayOfArrayOfNumberOnly.new( + array_array_number: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/ArrayOfNumberOnly.md b/samples/client/petstore/ruby-faraday/docs/ArrayOfNumberOnly.md index 8adb00978acc..2940cc5a486d 100644 --- a/samples/client/petstore/ruby-faraday/docs/ArrayOfNumberOnly.md +++ b/samples/client/petstore/ruby-faraday/docs/ArrayOfNumberOnly.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**array_number** | **Array<Float>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **array_number** | **Array<Float>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ArrayOfNumberOnly.new(array_number: null) +instance = Petstore::ArrayOfNumberOnly.new( + array_number: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/ArrayTest.md b/samples/client/petstore/ruby-faraday/docs/ArrayTest.md index 76e3866ba9c2..f9a5ffcec1c4 100644 --- a/samples/client/petstore/ruby-faraday/docs/ArrayTest.md +++ b/samples/client/petstore/ruby-faraday/docs/ArrayTest.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**array_of_string** | **Array<String>** | | [optional] -**array_array_of_integer** | **Array<Array<Integer>>** | | [optional] -**array_array_of_model** | **Array<Array<ReadOnlyFirst>>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **array_of_string** | **Array<String>** | | [optional] | +| **array_array_of_integer** | **Array<Array<Integer>>** | | [optional] | +| **array_array_of_model** | **Array<Array<ReadOnlyFirst>>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ArrayTest.new(array_of_string: null, - array_array_of_integer: null, - array_array_of_model: null) +instance = Petstore::ArrayTest.new( + array_of_string: null, + array_array_of_integer: null, + array_array_of_model: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Capitalization.md b/samples/client/petstore/ruby-faraday/docs/Capitalization.md index d1ac69ceb185..58831169b3bf 100644 --- a/samples/client/petstore/ruby-faraday/docs/Capitalization.md +++ b/samples/client/petstore/ruby-faraday/docs/Capitalization.md @@ -2,26 +2,27 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**small_camel** | **String** | | [optional] -**capital_camel** | **String** | | [optional] -**small_snake** | **String** | | [optional] -**capital_snake** | **String** | | [optional] -**sca_eth_flow_points** | **String** | | [optional] -**att_name** | **String** | Name of the pet | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **small_camel** | **String** | | [optional] | +| **capital_camel** | **String** | | [optional] | +| **small_snake** | **String** | | [optional] | +| **capital_snake** | **String** | | [optional] | +| **sca_eth_flow_points** | **String** | | [optional] | +| **att_name** | **String** | Name of the pet | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Capitalization.new(small_camel: null, - capital_camel: null, - small_snake: null, - capital_snake: null, - sca_eth_flow_points: null, - att_name: null) +instance = Petstore::Capitalization.new( + small_camel: null, + capital_camel: null, + small_snake: null, + capital_snake: null, + sca_eth_flow_points: null, + att_name: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Cat.md b/samples/client/petstore/ruby-faraday/docs/Cat.md index 054fbfadafd3..047db885909e 100644 --- a/samples/client/petstore/ruby-faraday/docs/Cat.md +++ b/samples/client/petstore/ruby-faraday/docs/Cat.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**declawed** | **Boolean** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **declawed** | **Boolean** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Cat.new(declawed: null) +instance = Petstore::Cat.new( + declawed: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/CatAllOf.md b/samples/client/petstore/ruby-faraday/docs/CatAllOf.md index a83a6f756620..634ef021d591 100644 --- a/samples/client/petstore/ruby-faraday/docs/CatAllOf.md +++ b/samples/client/petstore/ruby-faraday/docs/CatAllOf.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**declawed** | **Boolean** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **declawed** | **Boolean** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::CatAllOf.new(declawed: null) +instance = Petstore::CatAllOf.new( + declawed: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Category.md b/samples/client/petstore/ruby-faraday/docs/Category.md index 942f88759ea6..d53fbb921cf2 100644 --- a/samples/client/petstore/ruby-faraday/docs/Category.md +++ b/samples/client/petstore/ruby-faraday/docs/Category.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**name** | **String** | | [default to 'default-name'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **name** | **String** | | [default to 'default-name'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Category.new(id: null, - name: null) +instance = Petstore::Category.new( + id: null, + name: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/ClassModel.md b/samples/client/petstore/ruby-faraday/docs/ClassModel.md index faf38fde16d9..111d69eae582 100644 --- a/samples/client/petstore/ruby-faraday/docs/ClassModel.md +++ b/samples/client/petstore/ruby-faraday/docs/ClassModel.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**_class** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **_class** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ClassModel.new(_class: null) +instance = Petstore::ClassModel.new( + _class: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Client.md b/samples/client/petstore/ruby-faraday/docs/Client.md index da87ce113cb3..ec4ef88114cd 100644 --- a/samples/client/petstore/ruby-faraday/docs/Client.md +++ b/samples/client/petstore/ruby-faraday/docs/Client.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**client** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Client.new(client: null) +instance = Petstore::Client.new( + client: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/DefaultApi.md b/samples/client/petstore/ruby-faraday/docs/DefaultApi.md index 9e2e7712f92d..a4f9427829d1 100644 --- a/samples/client/petstore/ruby-faraday/docs/DefaultApi.md +++ b/samples/client/petstore/ruby-faraday/docs/DefaultApi.md @@ -2,10 +2,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**foo_get**](DefaultApi.md#foo_get) | **GET** /foo | - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**foo_get**](DefaultApi.md#foo_get) | **GET** /foo | | ## foo_get diff --git a/samples/client/petstore/ruby-faraday/docs/Dog.md b/samples/client/petstore/ruby-faraday/docs/Dog.md index 68c2e5d7e0e5..cbd924e9bb80 100644 --- a/samples/client/petstore/ruby-faraday/docs/Dog.md +++ b/samples/client/petstore/ruby-faraday/docs/Dog.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**breed** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **breed** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Dog.new(breed: null) +instance = Petstore::Dog.new( + breed: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/DogAllOf.md b/samples/client/petstore/ruby-faraday/docs/DogAllOf.md index 6107fd0c10f5..a7ee66dd9aa4 100644 --- a/samples/client/petstore/ruby-faraday/docs/DogAllOf.md +++ b/samples/client/petstore/ruby-faraday/docs/DogAllOf.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**breed** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **breed** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::DogAllOf.new(breed: null) +instance = Petstore::DogAllOf.new( + breed: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/EnumArrays.md b/samples/client/petstore/ruby-faraday/docs/EnumArrays.md index 18efa20299d0..160e6018036b 100644 --- a/samples/client/petstore/ruby-faraday/docs/EnumArrays.md +++ b/samples/client/petstore/ruby-faraday/docs/EnumArrays.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**just_symbol** | **String** | | [optional] -**array_enum** | **Array<String>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **just_symbol** | **String** | | [optional] | +| **array_enum** | **Array<String>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::EnumArrays.new(just_symbol: null, - array_enum: null) +instance = Petstore::EnumArrays.new( + just_symbol: null, + array_enum: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/EnumClass.md b/samples/client/petstore/ruby-faraday/docs/EnumClass.md index 0fca9b27f5ce..4a44d03a65bf 100644 --- a/samples/client/petstore/ruby-faraday/docs/EnumClass.md +++ b/samples/client/petstore/ruby-faraday/docs/EnumClass.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::EnumClass.new() ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/EnumTest.md b/samples/client/petstore/ruby-faraday/docs/EnumTest.md index 7ea08c8d7b1a..90e5ea4fa4df 100644 --- a/samples/client/petstore/ruby-faraday/docs/EnumTest.md +++ b/samples/client/petstore/ruby-faraday/docs/EnumTest.md @@ -2,30 +2,31 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**enum_string** | **String** | | [optional] -**enum_string_required** | **String** | | -**enum_integer** | **Integer** | | [optional] -**enum_number** | **Float** | | [optional] -**outer_enum** | [**OuterEnum**](OuterEnum.md) | | [optional] -**outer_enum_integer** | [**OuterEnumInteger**](OuterEnumInteger.md) | | [optional] -**outer_enum_default_value** | [**OuterEnumDefaultValue**](OuterEnumDefaultValue.md) | | [optional] [default to 'placed'] -**outer_enum_integer_default_value** | [**OuterEnumIntegerDefaultValue**](OuterEnumIntegerDefaultValue.md) | | [optional] [default to OuterEnumIntegerDefaultValue::N0] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **enum_string** | **String** | | [optional] | +| **enum_string_required** | **String** | | | +| **enum_integer** | **Integer** | | [optional] | +| **enum_number** | **Float** | | [optional] | +| **outer_enum** | [**OuterEnum**](OuterEnum.md) | | [optional] | +| **outer_enum_integer** | [**OuterEnumInteger**](OuterEnumInteger.md) | | [optional] | +| **outer_enum_default_value** | [**OuterEnumDefaultValue**](OuterEnumDefaultValue.md) | | [optional][default to 'placed'] | +| **outer_enum_integer_default_value** | [**OuterEnumIntegerDefaultValue**](OuterEnumIntegerDefaultValue.md) | | [optional][default to OuterEnumIntegerDefaultValue::N0] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::EnumTest.new(enum_string: null, - enum_string_required: null, - enum_integer: null, - enum_number: null, - outer_enum: null, - outer_enum_integer: null, - outer_enum_default_value: null, - outer_enum_integer_default_value: null) +instance = Petstore::EnumTest.new( + enum_string: null, + enum_string_required: null, + enum_integer: null, + enum_number: null, + outer_enum: null, + outer_enum_integer: null, + outer_enum_default_value: null, + outer_enum_integer_default_value: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/FakeApi.md b/samples/client/petstore/ruby-faraday/docs/FakeApi.md index 4e07aa5bce8d..b154297177df 100644 --- a/samples/client/petstore/ruby-faraday/docs/FakeApi.md +++ b/samples/client/petstore/ruby-faraday/docs/FakeApi.md @@ -2,24 +2,23 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**fake_health_get**](FakeApi.md#fake_health_get) | **GET** /fake/health | Health check endpoint -[**fake_http_signature_test**](FakeApi.md#fake_http_signature_test) | **GET** /fake/http-signature-test | test http signature authentication -[**fake_outer_boolean_serialize**](FakeApi.md#fake_outer_boolean_serialize) | **POST** /fake/outer/boolean | -[**fake_outer_composite_serialize**](FakeApi.md#fake_outer_composite_serialize) | **POST** /fake/outer/composite | -[**fake_outer_number_serialize**](FakeApi.md#fake_outer_number_serialize) | **POST** /fake/outer/number | -[**fake_outer_string_serialize**](FakeApi.md#fake_outer_string_serialize) | **POST** /fake/outer/string | -[**test_body_with_file_schema**](FakeApi.md#test_body_with_file_schema) | **PUT** /fake/body-with-file-schema | -[**test_body_with_query_params**](FakeApi.md#test_body_with_query_params) | **PUT** /fake/body-with-query-params | -[**test_client_model**](FakeApi.md#test_client_model) | **PATCH** /fake | To test \"client\" model -[**test_endpoint_parameters**](FakeApi.md#test_endpoint_parameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 -[**test_enum_parameters**](FakeApi.md#test_enum_parameters) | **GET** /fake | To test enum parameters -[**test_group_parameters**](FakeApi.md#test_group_parameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) -[**test_inline_additional_properties**](FakeApi.md#test_inline_additional_properties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties -[**test_json_form_data**](FakeApi.md#test_json_form_data) | **GET** /fake/jsonFormData | test json serialization of form data -[**test_query_parameter_collection_format**](FakeApi.md#test_query_parameter_collection_format) | **PUT** /fake/test-query-paramters | - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**fake_health_get**](FakeApi.md#fake_health_get) | **GET** /fake/health | Health check endpoint | +| [**fake_http_signature_test**](FakeApi.md#fake_http_signature_test) | **GET** /fake/http-signature-test | test http signature authentication | +| [**fake_outer_boolean_serialize**](FakeApi.md#fake_outer_boolean_serialize) | **POST** /fake/outer/boolean | | +| [**fake_outer_composite_serialize**](FakeApi.md#fake_outer_composite_serialize) | **POST** /fake/outer/composite | | +| [**fake_outer_number_serialize**](FakeApi.md#fake_outer_number_serialize) | **POST** /fake/outer/number | | +| [**fake_outer_string_serialize**](FakeApi.md#fake_outer_string_serialize) | **POST** /fake/outer/string | | +| [**test_body_with_file_schema**](FakeApi.md#test_body_with_file_schema) | **PUT** /fake/body-with-file-schema | | +| [**test_body_with_query_params**](FakeApi.md#test_body_with_query_params) | **PUT** /fake/body-with-query-params | | +| [**test_client_model**](FakeApi.md#test_client_model) | **PATCH** /fake | To test \"client\" model | +| [**test_endpoint_parameters**](FakeApi.md#test_endpoint_parameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 | +| [**test_enum_parameters**](FakeApi.md#test_enum_parameters) | **GET** /fake | To test enum parameters | +| [**test_group_parameters**](FakeApi.md#test_group_parameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) | +| [**test_inline_additional_properties**](FakeApi.md#test_inline_additional_properties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties | +| [**test_json_form_data**](FakeApi.md#test_json_form_data) | **GET** /fake/jsonFormData | test json serialization of form data | +| [**test_query_parameter_collection_format**](FakeApi.md#test_query_parameter_collection_format) | **PUT** /fake/test-query-paramters | | ## fake_health_get @@ -95,12 +94,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | - **query_1** | **String**| query parameter | [optional] - **header_1** | **String**| header parameter | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet** | [**Pet**](Pet.md) | Pet object that needs to be added to the store | | +| **query_1** | **String** | query parameter | [optional] | +| **header_1** | **String** | header parameter | [optional] | ### Return type @@ -145,10 +143,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **Boolean**| Input boolean as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **body** | **Boolean** | Input boolean as post body | [optional] | ### Return type @@ -193,10 +190,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **outer_composite** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **outer_composite** | [**OuterComposite**](OuterComposite.md) | Input composite as post body | [optional] | ### Return type @@ -241,10 +237,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **Float**| Input number as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **body** | **Float** | Input number as post body | [optional] | ### Return type @@ -289,10 +284,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **String**| Input string as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **body** | **String** | Input string as post body | [optional] | ### Return type @@ -334,10 +328,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **file_schema_test_class** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **file_schema_test_class** | [**FileSchemaTestClass**](FileSchemaTestClass.md) | | | ### Return type @@ -378,11 +371,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **query** | **String**| | - **user** | [**User**](User.md)| | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **query** | **String** | | | +| **user** | [**User**](User.md) | | | ### Return type @@ -426,10 +418,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **client** | [**Client**](Client.md)| client model | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | [**Client**](Client.md) | client model | | ### Return type @@ -493,23 +484,22 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **number** | **Float**| None | - **double** | **Float**| None | - **pattern_without_delimiter** | **String**| None | - **byte** | **String**| None | - **integer** | **Integer**| None | [optional] - **int32** | **Integer**| None | [optional] - **int64** | **Integer**| None | [optional] - **float** | **Float**| None | [optional] - **string** | **String**| None | [optional] - **binary** | **File**| None | [optional] - **date** | **Date**| None | [optional] - **date_time** | **Time**| None | [optional] - **password** | **String**| None | [optional] - **callback** | **String**| None | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **number** | **Float** | None | | +| **double** | **Float** | None | | +| **pattern_without_delimiter** | **String** | None | | +| **byte** | **String** | None | | +| **integer** | **Integer** | None | [optional] | +| **int32** | **Integer** | None | [optional] | +| **int64** | **Integer** | None | [optional] | +| **float** | **Float** | None | [optional] | +| **string** | **String** | None | [optional] | +| **binary** | **File** | None | [optional] | +| **date** | **Date** | None | [optional] | +| **date_time** | **Time** | None | [optional] | +| **password** | **String** | None | [optional] | +| **callback** | **String** | None | [optional] | ### Return type @@ -561,17 +551,16 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **enum_header_string_array** | [**Array<String>**](String.md)| Header parameter enum test (string array) | [optional] - **enum_header_string** | **String**| Header parameter enum test (string) | [optional] [default to '-efg'] - **enum_query_string_array** | [**Array<String>**](String.md)| Query parameter enum test (string array) | [optional] - **enum_query_string** | **String**| Query parameter enum test (string) | [optional] [default to '-efg'] - **enum_query_integer** | **Integer**| Query parameter enum test (double) | [optional] - **enum_query_double** | **Float**| Query parameter enum test (double) | [optional] - **enum_form_string_array** | [**Array<String>**](String.md)| Form parameter enum test (string array) | [optional] [default to '$'] - **enum_form_string** | **String**| Form parameter enum test (string) | [optional] [default to '-efg'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **enum_header_string_array** | [**Array<String>**](String.md) | Header parameter enum test (string array) | [optional] | +| **enum_header_string** | **String** | Header parameter enum test (string) | [optional][default to '-efg'] | +| **enum_query_string_array** | [**Array<String>**](String.md) | Query parameter enum test (string array) | [optional] | +| **enum_query_string** | **String** | Query parameter enum test (string) | [optional][default to '-efg'] | +| **enum_query_integer** | **Integer** | Query parameter enum test (double) | [optional] | +| **enum_query_double** | **Float** | Query parameter enum test (double) | [optional] | +| **enum_form_string_array** | [**Array<String>**](String.md) | Form parameter enum test (string array) | [optional][default to '$'] | +| **enum_form_string** | **String** | Form parameter enum test (string) | [optional][default to '-efg'] | ### Return type @@ -626,15 +615,14 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **required_string_group** | **Integer**| Required String in group parameters | - **required_boolean_group** | **Boolean**| Required Boolean in group parameters | - **required_int64_group** | **Integer**| Required Integer in group parameters | - **string_group** | **Integer**| String in group parameters | [optional] - **boolean_group** | **Boolean**| Boolean in group parameters | [optional] - **int64_group** | **Integer**| Integer in group parameters | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **required_string_group** | **Integer** | Required String in group parameters | | +| **required_boolean_group** | **Boolean** | Required Boolean in group parameters | | +| **required_int64_group** | **Integer** | Required Integer in group parameters | | +| **string_group** | **Integer** | String in group parameters | [optional] | +| **boolean_group** | **Boolean** | Boolean in group parameters | [optional] | +| **int64_group** | **Integer** | Integer in group parameters | [optional] | ### Return type @@ -675,10 +663,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **request_body** | [**Hash<String, String>**](String.md)| request body | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **request_body** | [**Hash<String, String>**](String.md) | request body | | ### Return type @@ -720,11 +707,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **param** | **String**| field1 | - **param2** | **String**| field2 | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **param** | **String** | field1 | | +| **param2** | **String** | field2 | | ### Return type @@ -770,14 +756,13 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pipe** | [**Array<String>**](String.md)| | - **ioutil** | [**Array<String>**](String.md)| | - **http** | [**Array<String>**](String.md)| | - **url** | [**Array<String>**](String.md)| | - **context** | [**Array<String>**](String.md)| | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pipe** | [**Array<String>**](String.md) | | | +| **ioutil** | [**Array<String>**](String.md) | | | +| **http** | [**Array<String>**](String.md) | | | +| **url** | [**Array<String>**](String.md) | | | +| **context** | [**Array<String>**](String.md) | | | ### Return type diff --git a/samples/client/petstore/ruby-faraday/docs/FakeClassnameTags123Api.md b/samples/client/petstore/ruby-faraday/docs/FakeClassnameTags123Api.md index 4ccb9083cbae..60916d81fd17 100644 --- a/samples/client/petstore/ruby-faraday/docs/FakeClassnameTags123Api.md +++ b/samples/client/petstore/ruby-faraday/docs/FakeClassnameTags123Api.md @@ -2,10 +2,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**test_classname**](FakeClassnameTags123Api.md#test_classname) | **PATCH** /fake_classname_test | To test class name in snake case - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**test_classname**](FakeClassnameTags123Api.md#test_classname) | **PATCH** /fake_classname_test | To test class name in snake case | ## test_classname @@ -43,10 +42,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **client** | [**Client**](Client.md)| client model | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | [**Client**](Client.md) | client model | | ### Return type diff --git a/samples/client/petstore/ruby-faraday/docs/File.md b/samples/client/petstore/ruby-faraday/docs/File.md index ca8a6e9c3136..f395df873fe2 100644 --- a/samples/client/petstore/ruby-faraday/docs/File.md +++ b/samples/client/petstore/ruby-faraday/docs/File.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**source_uri** | **String** | Test capitalization | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **source_uri** | **String** | Test capitalization | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::File.new(source_uri: null) +instance = Petstore::File.new( + source_uri: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/FileSchemaTestClass.md b/samples/client/petstore/ruby-faraday/docs/FileSchemaTestClass.md index 03ee5f7e803b..d16964b9844f 100644 --- a/samples/client/petstore/ruby-faraday/docs/FileSchemaTestClass.md +++ b/samples/client/petstore/ruby-faraday/docs/FileSchemaTestClass.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**file** | **File** | | [optional] -**files** | **Array<File>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **file** | **File** | | [optional] | +| **files** | **Array<File>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::FileSchemaTestClass.new(file: null, - files: null) +instance = Petstore::FileSchemaTestClass.new( + file: null, + files: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Foo.md b/samples/client/petstore/ruby-faraday/docs/Foo.md index 9c55a348168e..9bb2521e88a1 100644 --- a/samples/client/petstore/ruby-faraday/docs/Foo.md +++ b/samples/client/petstore/ruby-faraday/docs/Foo.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [default to 'bar'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **bar** | **String** | | [optional][default to 'bar'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Foo.new(bar: null) +instance = Petstore::Foo.new( + bar: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/FormatTest.md b/samples/client/petstore/ruby-faraday/docs/FormatTest.md index 85558a2cc0ca..25287e4fd4c0 100644 --- a/samples/client/petstore/ruby-faraday/docs/FormatTest.md +++ b/samples/client/petstore/ruby-faraday/docs/FormatTest.md @@ -2,46 +2,47 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integer** | **Integer** | | [optional] -**int32** | **Integer** | | [optional] -**int64** | **Integer** | | [optional] -**number** | **Float** | | -**float** | **Float** | | [optional] -**double** | **Float** | | [optional] -**decimal** | [**Decimal**](Decimal.md) | | [optional] -**string** | **String** | | [optional] -**byte** | **String** | | -**binary** | **File** | | [optional] -**date** | **Date** | | -**date_time** | **Time** | | [optional] -**uuid** | **String** | | [optional] -**password** | **String** | | -**pattern_with_digits** | **String** | A string that is a 10 digit number. Can have leading zeros. | [optional] -**pattern_with_digits_and_delimiter** | **String** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **integer** | **Integer** | | [optional] | +| **int32** | **Integer** | | [optional] | +| **int64** | **Integer** | | [optional] | +| **number** | **Float** | | | +| **float** | **Float** | | [optional] | +| **double** | **Float** | | [optional] | +| **decimal** | [**Decimal**](Decimal.md) | | [optional] | +| **string** | **String** | | [optional] | +| **byte** | **String** | | | +| **binary** | **File** | | [optional] | +| **date** | **Date** | | | +| **date_time** | **Time** | | [optional] | +| **uuid** | **String** | | [optional] | +| **password** | **String** | | | +| **pattern_with_digits** | **String** | A string that is a 10 digit number. Can have leading zeros. | [optional] | +| **pattern_with_digits_and_delimiter** | **String** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::FormatTest.new(integer: null, - int32: null, - int64: null, - number: null, - float: null, - double: null, - decimal: null, - string: null, - byte: null, - binary: null, - date: null, - date_time: null, - uuid: 72f98069-206d-4f12-9f12-3d1e525a8e84, - password: null, - pattern_with_digits: null, - pattern_with_digits_and_delimiter: null) +instance = Petstore::FormatTest.new( + integer: null, + int32: null, + int64: null, + number: null, + float: null, + double: null, + decimal: null, + string: null, + byte: null, + binary: null, + date: null, + date_time: null, + uuid: 72f98069-206d-4f12-9f12-3d1e525a8e84, + password: null, + pattern_with_digits: null, + pattern_with_digits_and_delimiter: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/HasOnlyReadOnly.md b/samples/client/petstore/ruby-faraday/docs/HasOnlyReadOnly.md index a15219a9c7b1..6900c5039e91 100644 --- a/samples/client/petstore/ruby-faraday/docs/HasOnlyReadOnly.md +++ b/samples/client/petstore/ruby-faraday/docs/HasOnlyReadOnly.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [readonly] -**foo** | **String** | | [optional] [readonly] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **bar** | **String** | | [optional][readonly] | +| **foo** | **String** | | [optional][readonly] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::HasOnlyReadOnly.new(bar: null, - foo: null) +instance = Petstore::HasOnlyReadOnly.new( + bar: null, + foo: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/HealthCheckResult.md b/samples/client/petstore/ruby-faraday/docs/HealthCheckResult.md index 0382fa78403e..4aa12dd58e6e 100644 --- a/samples/client/petstore/ruby-faraday/docs/HealthCheckResult.md +++ b/samples/client/petstore/ruby-faraday/docs/HealthCheckResult.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**nullable_message** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **nullable_message** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::HealthCheckResult.new(nullable_message: null) +instance = Petstore::HealthCheckResult.new( + nullable_message: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/InlineObject.md b/samples/client/petstore/ruby-faraday/docs/InlineObject.md index f5211d44464c..8967d77cb6a4 100644 --- a/samples/client/petstore/ruby-faraday/docs/InlineObject.md +++ b/samples/client/petstore/ruby-faraday/docs/InlineObject.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **String** | Updated name of the pet | [optional] -**status** | **String** | Updated status of the pet | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **name** | **String** | Updated name of the pet | [optional] | +| **status** | **String** | Updated status of the pet | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject.new(name: null, - status: null) +instance = Petstore::InlineObject.new( + name: null, + status: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/InlineObject1.md b/samples/client/petstore/ruby-faraday/docs/InlineObject1.md index bac17e753cdc..b2d08a2bea6e 100644 --- a/samples/client/petstore/ruby-faraday/docs/InlineObject1.md +++ b/samples/client/petstore/ruby-faraday/docs/InlineObject1.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**additional_metadata** | **String** | Additional data to pass to server | [optional] -**file** | **File** | file to upload | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | +| **file** | **File** | file to upload | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject1.new(additional_metadata: null, - file: null) +instance = Petstore::InlineObject1.new( + additional_metadata: null, + file: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/InlineObject2.md b/samples/client/petstore/ruby-faraday/docs/InlineObject2.md index 31118c5b262e..74cc2d92fc3d 100644 --- a/samples/client/petstore/ruby-faraday/docs/InlineObject2.md +++ b/samples/client/petstore/ruby-faraday/docs/InlineObject2.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**enum_form_string_array** | **Array<String>** | Form parameter enum test (string array) | [optional] -**enum_form_string** | **String** | Form parameter enum test (string) | [optional] [default to '-efg'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **enum_form_string_array** | **Array<String>** | Form parameter enum test (string array) | [optional] | +| **enum_form_string** | **String** | Form parameter enum test (string) | [optional][default to '-efg'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject2.new(enum_form_string_array: null, - enum_form_string: null) +instance = Petstore::InlineObject2.new( + enum_form_string_array: null, + enum_form_string: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/InlineObject3.md b/samples/client/petstore/ruby-faraday/docs/InlineObject3.md index beaf051468ba..57d6d9088045 100644 --- a/samples/client/petstore/ruby-faraday/docs/InlineObject3.md +++ b/samples/client/petstore/ruby-faraday/docs/InlineObject3.md @@ -2,42 +2,43 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integer** | **Integer** | None | [optional] -**int32** | **Integer** | None | [optional] -**int64** | **Integer** | None | [optional] -**number** | **Float** | None | -**float** | **Float** | None | [optional] -**double** | **Float** | None | -**string** | **String** | None | [optional] -**pattern_without_delimiter** | **String** | None | -**byte** | **String** | None | -**binary** | **File** | None | [optional] -**date** | **Date** | None | [optional] -**date_time** | **Time** | None | [optional] -**password** | **String** | None | [optional] -**callback** | **String** | None | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **integer** | **Integer** | None | [optional] | +| **int32** | **Integer** | None | [optional] | +| **int64** | **Integer** | None | [optional] | +| **number** | **Float** | None | | +| **float** | **Float** | None | [optional] | +| **double** | **Float** | None | | +| **string** | **String** | None | [optional] | +| **pattern_without_delimiter** | **String** | None | | +| **byte** | **String** | None | | +| **binary** | **File** | None | [optional] | +| **date** | **Date** | None | [optional] | +| **date_time** | **Time** | None | [optional] | +| **password** | **String** | None | [optional] | +| **callback** | **String** | None | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject3.new(integer: null, - int32: null, - int64: null, - number: null, - float: null, - double: null, - string: null, - pattern_without_delimiter: null, - byte: null, - binary: null, - date: null, - date_time: null, - password: null, - callback: null) +instance = Petstore::InlineObject3.new( + integer: null, + int32: null, + int64: null, + number: null, + float: null, + double: null, + string: null, + pattern_without_delimiter: null, + byte: null, + binary: null, + date: null, + date_time: null, + password: null, + callback: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/InlineObject4.md b/samples/client/petstore/ruby-faraday/docs/InlineObject4.md index 97179c3e3772..155dc45fbdc3 100644 --- a/samples/client/petstore/ruby-faraday/docs/InlineObject4.md +++ b/samples/client/petstore/ruby-faraday/docs/InlineObject4.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**param** | **String** | field1 | -**param2** | **String** | field2 | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **param** | **String** | field1 | | +| **param2** | **String** | field2 | | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject4.new(param: null, - param2: null) +instance = Petstore::InlineObject4.new( + param: null, + param2: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/InlineObject5.md b/samples/client/petstore/ruby-faraday/docs/InlineObject5.md index 23c1df99ffeb..b82651bd134c 100644 --- a/samples/client/petstore/ruby-faraday/docs/InlineObject5.md +++ b/samples/client/petstore/ruby-faraday/docs/InlineObject5.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**additional_metadata** | **String** | Additional data to pass to server | [optional] -**required_file** | **File** | file to upload | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | +| **required_file** | **File** | file to upload | | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject5.new(additional_metadata: null, - required_file: null) +instance = Petstore::InlineObject5.new( + additional_metadata: null, + required_file: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/InlineResponseDefault.md b/samples/client/petstore/ruby-faraday/docs/InlineResponseDefault.md index b89dc59aa330..c0ee67fdeb93 100644 --- a/samples/client/petstore/ruby-faraday/docs/InlineResponseDefault.md +++ b/samples/client/petstore/ruby-faraday/docs/InlineResponseDefault.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**string** | [**Foo**](Foo.md) | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **string** | [**Foo**](Foo.md) | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineResponseDefault.new(string: null) +instance = Petstore::InlineResponseDefault.new( + string: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/List.md b/samples/client/petstore/ruby-faraday/docs/List.md index 4add9c3fd230..cbae6cf2acd4 100644 --- a/samples/client/petstore/ruby-faraday/docs/List.md +++ b/samples/client/petstore/ruby-faraday/docs/List.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**_123_list** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **_123_list** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::List.new(_123_list: null) +instance = Petstore::List.new( + _123_list: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/MapTest.md b/samples/client/petstore/ruby-faraday/docs/MapTest.md index 9bf1793ec082..fea648930858 100644 --- a/samples/client/petstore/ruby-faraday/docs/MapTest.md +++ b/samples/client/petstore/ruby-faraday/docs/MapTest.md @@ -2,22 +2,23 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**map_map_of_string** | **Hash<String, Hash<String, String>>** | | [optional] -**map_of_enum_string** | **Hash<String, String>** | | [optional] -**direct_map** | **Hash<String, Boolean>** | | [optional] -**indirect_map** | **Hash<String, Boolean>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **map_map_of_string** | **Hash<String, Hash<String, String>>** | | [optional] | +| **map_of_enum_string** | **Hash<String, String>** | | [optional] | +| **direct_map** | **Hash<String, Boolean>** | | [optional] | +| **indirect_map** | **Hash<String, Boolean>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::MapTest.new(map_map_of_string: null, - map_of_enum_string: null, - direct_map: null, - indirect_map: null) +instance = Petstore::MapTest.new( + map_map_of_string: null, + map_of_enum_string: null, + direct_map: null, + indirect_map: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/client/petstore/ruby-faraday/docs/MixedPropertiesAndAdditionalPropertiesClass.md index a151e64b5d35..720c142f69ee 100644 --- a/samples/client/petstore/ruby-faraday/docs/MixedPropertiesAndAdditionalPropertiesClass.md +++ b/samples/client/petstore/ruby-faraday/docs/MixedPropertiesAndAdditionalPropertiesClass.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**uuid** | **String** | | [optional] -**date_time** | **Time** | | [optional] -**map** | [**Hash<String, Animal>**](Animal.md) | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **uuid** | **String** | | [optional] | +| **date_time** | **Time** | | [optional] | +| **map** | [**Hash<String, Animal>**](Animal.md) | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::MixedPropertiesAndAdditionalPropertiesClass.new(uuid: null, - date_time: null, - map: null) +instance = Petstore::MixedPropertiesAndAdditionalPropertiesClass.new( + uuid: null, + date_time: null, + map: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Model200Response.md b/samples/client/petstore/ruby-faraday/docs/Model200Response.md index 07a53b603347..155120bb9383 100644 --- a/samples/client/petstore/ruby-faraday/docs/Model200Response.md +++ b/samples/client/petstore/ruby-faraday/docs/Model200Response.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **Integer** | | [optional] -**_class** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **name** | **Integer** | | [optional] | +| **_class** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Model200Response.new(name: null, - _class: null) +instance = Petstore::Model200Response.new( + name: null, + _class: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/ModelReturn.md b/samples/client/petstore/ruby-faraday/docs/ModelReturn.md index 2e155936c898..28d197b2b7c2 100644 --- a/samples/client/petstore/ruby-faraday/docs/ModelReturn.md +++ b/samples/client/petstore/ruby-faraday/docs/ModelReturn.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**_return** | **Integer** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **_return** | **Integer** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ModelReturn.new(_return: null) +instance = Petstore::ModelReturn.new( + _return: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Name.md b/samples/client/petstore/ruby-faraday/docs/Name.md index 17cdbbd35612..9f53f36cddc8 100644 --- a/samples/client/petstore/ruby-faraday/docs/Name.md +++ b/samples/client/petstore/ruby-faraday/docs/Name.md @@ -2,22 +2,23 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **Integer** | | -**snake_case** | **Integer** | | [optional] [readonly] -**property** | **String** | | [optional] -**_123_number** | **Integer** | | [optional] [readonly] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **name** | **Integer** | | | +| **snake_case** | **Integer** | | [optional][readonly] | +| **property** | **String** | | [optional] | +| **_123_number** | **Integer** | | [optional][readonly] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Name.new(name: null, - snake_case: null, - property: null, - _123_number: null) +instance = Petstore::Name.new( + name: null, + snake_case: null, + property: null, + _123_number: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/NullableClass.md b/samples/client/petstore/ruby-faraday/docs/NullableClass.md index 51f89cd32200..6e28739c328e 100644 --- a/samples/client/petstore/ruby-faraday/docs/NullableClass.md +++ b/samples/client/petstore/ruby-faraday/docs/NullableClass.md @@ -2,38 +2,39 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integer_prop** | **Integer** | | [optional] -**number_prop** | **Float** | | [optional] -**boolean_prop** | **Boolean** | | [optional] -**string_prop** | **String** | | [optional] -**date_prop** | **Date** | | [optional] -**datetime_prop** | **Time** | | [optional] -**array_nullable_prop** | **Array<Object>** | | [optional] -**array_and_items_nullable_prop** | **Array<Object>** | | [optional] -**array_items_nullable** | **Array<Object>** | | [optional] -**object_nullable_prop** | **Hash<String, Object>** | | [optional] -**object_and_items_nullable_prop** | **Hash<String, Object>** | | [optional] -**object_items_nullable** | **Hash<String, Object>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **integer_prop** | **Integer** | | [optional] | +| **number_prop** | **Float** | | [optional] | +| **boolean_prop** | **Boolean** | | [optional] | +| **string_prop** | **String** | | [optional] | +| **date_prop** | **Date** | | [optional] | +| **datetime_prop** | **Time** | | [optional] | +| **array_nullable_prop** | **Array<Object>** | | [optional] | +| **array_and_items_nullable_prop** | **Array<Object>** | | [optional] | +| **array_items_nullable** | **Array<Object>** | | [optional] | +| **object_nullable_prop** | **Hash<String, Object>** | | [optional] | +| **object_and_items_nullable_prop** | **Hash<String, Object>** | | [optional] | +| **object_items_nullable** | **Hash<String, Object>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::NullableClass.new(integer_prop: null, - number_prop: null, - boolean_prop: null, - string_prop: null, - date_prop: null, - datetime_prop: null, - array_nullable_prop: null, - array_and_items_nullable_prop: null, - array_items_nullable: null, - object_nullable_prop: null, - object_and_items_nullable_prop: null, - object_items_nullable: null) +instance = Petstore::NullableClass.new( + integer_prop: null, + number_prop: null, + boolean_prop: null, + string_prop: null, + date_prop: null, + datetime_prop: null, + array_nullable_prop: null, + array_and_items_nullable_prop: null, + array_items_nullable: null, + object_nullable_prop: null, + object_and_items_nullable_prop: null, + object_items_nullable: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/NumberOnly.md b/samples/client/petstore/ruby-faraday/docs/NumberOnly.md index 73c5d0a3ab28..bc2e5ae03d8b 100644 --- a/samples/client/petstore/ruby-faraday/docs/NumberOnly.md +++ b/samples/client/petstore/ruby-faraday/docs/NumberOnly.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**just_number** | **Float** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **just_number** | **Float** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::NumberOnly.new(just_number: null) +instance = Petstore::NumberOnly.new( + just_number: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Order.md b/samples/client/petstore/ruby-faraday/docs/Order.md index 54484d31be4a..b30ab51f2aa5 100644 --- a/samples/client/petstore/ruby-faraday/docs/Order.md +++ b/samples/client/petstore/ruby-faraday/docs/Order.md @@ -2,26 +2,27 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**pet_id** | **Integer** | | [optional] -**quantity** | **Integer** | | [optional] -**ship_date** | **Time** | | [optional] -**status** | **String** | Order Status | [optional] -**complete** | **Boolean** | | [optional] [default to false] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **pet_id** | **Integer** | | [optional] | +| **quantity** | **Integer** | | [optional] | +| **ship_date** | **Time** | | [optional] | +| **status** | **String** | Order Status | [optional] | +| **complete** | **Boolean** | | [optional][default to false] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Order.new(id: null, - pet_id: null, - quantity: null, - ship_date: null, - status: null, - complete: null) +instance = Petstore::Order.new( + id: null, + pet_id: null, + quantity: null, + ship_date: null, + status: null, + complete: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/OuterComposite.md b/samples/client/petstore/ruby-faraday/docs/OuterComposite.md index 2716cd298087..f14a9765d0a7 100644 --- a/samples/client/petstore/ruby-faraday/docs/OuterComposite.md +++ b/samples/client/petstore/ruby-faraday/docs/OuterComposite.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**my_number** | **Float** | | [optional] -**my_string** | **String** | | [optional] -**my_boolean** | **Boolean** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **my_number** | **Float** | | [optional] | +| **my_string** | **String** | | [optional] | +| **my_boolean** | **Boolean** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::OuterComposite.new(my_number: null, - my_string: null, - my_boolean: null) +instance = Petstore::OuterComposite.new( + my_number: null, + my_string: null, + my_boolean: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/OuterEnum.md b/samples/client/petstore/ruby-faraday/docs/OuterEnum.md index e919b6bc78ba..3e82b93d05c4 100644 --- a/samples/client/petstore/ruby-faraday/docs/OuterEnum.md +++ b/samples/client/petstore/ruby-faraday/docs/OuterEnum.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnum.new() ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/OuterEnumDefaultValue.md b/samples/client/petstore/ruby-faraday/docs/OuterEnumDefaultValue.md index 01dc64511ecb..3ea073b2dabc 100644 --- a/samples/client/petstore/ruby-faraday/docs/OuterEnumDefaultValue.md +++ b/samples/client/petstore/ruby-faraday/docs/OuterEnumDefaultValue.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnumDefaultValue.new() ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/OuterEnumInteger.md b/samples/client/petstore/ruby-faraday/docs/OuterEnumInteger.md index 4463ff29c957..0c401c428a34 100644 --- a/samples/client/petstore/ruby-faraday/docs/OuterEnumInteger.md +++ b/samples/client/petstore/ruby-faraday/docs/OuterEnumInteger.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnumInteger.new() ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/OuterEnumIntegerDefaultValue.md b/samples/client/petstore/ruby-faraday/docs/OuterEnumIntegerDefaultValue.md index 1623eeaef87a..9f5fda16a7be 100644 --- a/samples/client/petstore/ruby-faraday/docs/OuterEnumIntegerDefaultValue.md +++ b/samples/client/petstore/ruby-faraday/docs/OuterEnumIntegerDefaultValue.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnumIntegerDefaultValue.new() ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/Pet.md b/samples/client/petstore/ruby-faraday/docs/Pet.md index efee63091e47..e87c6321c7c5 100644 --- a/samples/client/petstore/ruby-faraday/docs/Pet.md +++ b/samples/client/petstore/ruby-faraday/docs/Pet.md @@ -2,26 +2,27 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**category** | [**Category**](Category.md) | | [optional] -**name** | **String** | | -**photo_urls** | **Array<String>** | | -**tags** | [**Array<Tag>**](Tag.md) | | [optional] -**status** | **String** | pet status in the store | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **category** | [**Category**](Category.md) | | [optional] | +| **name** | **String** | | | +| **photo_urls** | **Array<String>** | | | +| **tags** | [**Array<Tag>**](Tag.md) | | [optional] | +| **status** | **String** | pet status in the store | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Pet.new(id: null, - category: null, - name: doggie, - photo_urls: null, - tags: null, - status: null) +instance = Petstore::Pet.new( + id: null, + category: null, + name: doggie, + photo_urls: null, + tags: null, + status: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/PetApi.md b/samples/client/petstore/ruby-faraday/docs/PetApi.md index 6e650f534b1b..a7aa7c7afbe2 100644 --- a/samples/client/petstore/ruby-faraday/docs/PetApi.md +++ b/samples/client/petstore/ruby-faraday/docs/PetApi.md @@ -2,18 +2,17 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_pet**](PetApi.md#add_pet) | **POST** /pet | Add a new pet to the store -[**delete_pet**](PetApi.md#delete_pet) | **DELETE** /pet/{petId} | Deletes a pet -[**find_pets_by_status**](PetApi.md#find_pets_by_status) | **GET** /pet/findByStatus | Finds Pets by status -[**find_pets_by_tags**](PetApi.md#find_pets_by_tags) | **GET** /pet/findByTags | Finds Pets by tags -[**get_pet_by_id**](PetApi.md#get_pet_by_id) | **GET** /pet/{petId} | Find pet by ID -[**update_pet**](PetApi.md#update_pet) | **PUT** /pet | Update an existing pet -[**update_pet_with_form**](PetApi.md#update_pet_with_form) | **POST** /pet/{petId} | Updates a pet in the store with form data -[**upload_file**](PetApi.md#upload_file) | **POST** /pet/{petId}/uploadImage | uploads an image -[**upload_file_with_required_file**](PetApi.md#upload_file_with_required_file) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required) - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**add_pet**](PetApi.md#add_pet) | **POST** /pet | Add a new pet to the store | +| [**delete_pet**](PetApi.md#delete_pet) | **DELETE** /pet/{petId} | Deletes a pet | +| [**find_pets_by_status**](PetApi.md#find_pets_by_status) | **GET** /pet/findByStatus | Finds Pets by status | +| [**find_pets_by_tags**](PetApi.md#find_pets_by_tags) | **GET** /pet/findByTags | Finds Pets by tags | +| [**get_pet_by_id**](PetApi.md#get_pet_by_id) | **GET** /pet/{petId} | Find pet by ID | +| [**update_pet**](PetApi.md#update_pet) | **PUT** /pet | Update an existing pet | +| [**update_pet_with_form**](PetApi.md#update_pet_with_form) | **POST** /pet/{petId} | Updates a pet in the store with form data | +| [**upload_file**](PetApi.md#upload_file) | **POST** /pet/{petId}/uploadImage | uploads an image | +| [**upload_file_with_required_file**](PetApi.md#upload_file_with_required_file) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required) | ## add_pet @@ -46,10 +45,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet** | [**Pet**](Pet.md) | Pet object that needs to be added to the store | | ### Return type @@ -98,11 +96,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| Pet id to delete | - **api_key** | **String**| | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | Pet id to delete | | +| **api_key** | **String** | | [optional] | ### Return type @@ -151,10 +148,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **status** | [**Array<String>**](String.md)| Status values that need to be considered for filter | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **status** | [**Array<String>**](String.md) | Status values that need to be considered for filter | | ### Return type @@ -203,10 +199,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **tags** | [**Array<String>**](String.md)| Tags to filter by | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **tags** | [**Array<String>**](String.md) | Tags to filter by | | ### Return type @@ -257,10 +252,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet to return | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet to return | | ### Return type @@ -306,10 +300,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet** | [**Pet**](Pet.md) | Pet object that needs to be added to the store | | ### Return type @@ -359,12 +352,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet that needs to be updated | - **name** | **String**| Updated name of the pet | [optional] - **status** | **String**| Updated status of the pet | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet that needs to be updated | | +| **name** | **String** | Updated name of the pet | [optional] | +| **status** | **String** | Updated status of the pet | [optional] | ### Return type @@ -415,12 +407,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet to update | - **additional_metadata** | **String**| Additional data to pass to server | [optional] - **file** | **File**| file to upload | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet to update | | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | +| **file** | **File** | file to upload | [optional] | ### Return type @@ -471,12 +462,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet to update | - **required_file** | **File**| file to upload | - **additional_metadata** | **String**| Additional data to pass to server | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet to update | | +| **required_file** | **File** | file to upload | | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | ### Return type diff --git a/samples/client/petstore/ruby-faraday/docs/ReadOnlyFirst.md b/samples/client/petstore/ruby-faraday/docs/ReadOnlyFirst.md index f8f76a463a14..ef22742e01c4 100644 --- a/samples/client/petstore/ruby-faraday/docs/ReadOnlyFirst.md +++ b/samples/client/petstore/ruby-faraday/docs/ReadOnlyFirst.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [readonly] -**baz** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **bar** | **String** | | [optional][readonly] | +| **baz** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ReadOnlyFirst.new(bar: null, - baz: null) +instance = Petstore::ReadOnlyFirst.new( + bar: null, + baz: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/SpecialModelName.md b/samples/client/petstore/ruby-faraday/docs/SpecialModelName.md index 498ab811683a..0a8007f80247 100644 --- a/samples/client/petstore/ruby-faraday/docs/SpecialModelName.md +++ b/samples/client/petstore/ruby-faraday/docs/SpecialModelName.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**special_property_name** | **Integer** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **special_property_name** | **Integer** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::SpecialModelName.new(special_property_name: null) +instance = Petstore::SpecialModelName.new( + special_property_name: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/StoreApi.md b/samples/client/petstore/ruby-faraday/docs/StoreApi.md index ffbc1d04b1ef..58aeeb82fc14 100644 --- a/samples/client/petstore/ruby-faraday/docs/StoreApi.md +++ b/samples/client/petstore/ruby-faraday/docs/StoreApi.md @@ -2,13 +2,12 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**delete_order**](StoreApi.md#delete_order) | **DELETE** /store/order/{order_id} | Delete purchase order by ID -[**get_inventory**](StoreApi.md#get_inventory) | **GET** /store/inventory | Returns pet inventories by status -[**get_order_by_id**](StoreApi.md#get_order_by_id) | **GET** /store/order/{order_id} | Find purchase order by ID -[**place_order**](StoreApi.md#place_order) | **POST** /store/order | Place an order for a pet - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**delete_order**](StoreApi.md#delete_order) | **DELETE** /store/order/{order_id} | Delete purchase order by ID | +| [**get_inventory**](StoreApi.md#get_inventory) | **GET** /store/inventory | Returns pet inventories by status | +| [**get_order_by_id**](StoreApi.md#get_order_by_id) | **GET** /store/order/{order_id} | Find purchase order by ID | +| [**place_order**](StoreApi.md#place_order) | **POST** /store/order | Place an order for a pet | ## delete_order @@ -38,10 +37,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **order_id** | **String**| ID of the order that needs to be deleted | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **order_id** | **String** | ID of the order that needs to be deleted | | ### Return type @@ -135,10 +133,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **order_id** | **Integer**| ID of pet that needs to be fetched | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **order_id** | **Integer** | ID of pet that needs to be fetched | | ### Return type @@ -180,10 +177,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **order** | [**Order**](Order.md)| order placed for purchasing the pet | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **order** | [**Order**](Order.md) | order placed for purchasing the pet | | ### Return type diff --git a/samples/client/petstore/ruby-faraday/docs/Tag.md b/samples/client/petstore/ruby-faraday/docs/Tag.md index 54a66a3f294b..30b8363f831a 100644 --- a/samples/client/petstore/ruby-faraday/docs/Tag.md +++ b/samples/client/petstore/ruby-faraday/docs/Tag.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**name** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **name** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Tag.new(id: null, - name: null) +instance = Petstore::Tag.new( + id: null, + name: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/User.md b/samples/client/petstore/ruby-faraday/docs/User.md index 263e96046620..1d45aa900b49 100644 --- a/samples/client/petstore/ruby-faraday/docs/User.md +++ b/samples/client/petstore/ruby-faraday/docs/User.md @@ -2,30 +2,31 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**username** | **String** | | [optional] -**first_name** | **String** | | [optional] -**last_name** | **String** | | [optional] -**email** | **String** | | [optional] -**password** | **String** | | [optional] -**phone** | **String** | | [optional] -**user_status** | **Integer** | User Status | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **username** | **String** | | [optional] | +| **first_name** | **String** | | [optional] | +| **last_name** | **String** | | [optional] | +| **email** | **String** | | [optional] | +| **password** | **String** | | [optional] | +| **phone** | **String** | | [optional] | +| **user_status** | **Integer** | User Status | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::User.new(id: null, - username: null, - first_name: null, - last_name: null, - email: null, - password: null, - phone: null, - user_status: null) +instance = Petstore::User.new( + id: null, + username: null, + first_name: null, + last_name: null, + email: null, + password: null, + phone: null, + user_status: null +) ``` - diff --git a/samples/client/petstore/ruby-faraday/docs/UserApi.md b/samples/client/petstore/ruby-faraday/docs/UserApi.md index 631a65ef1f19..d5c42199234c 100644 --- a/samples/client/petstore/ruby-faraday/docs/UserApi.md +++ b/samples/client/petstore/ruby-faraday/docs/UserApi.md @@ -2,17 +2,16 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_user**](UserApi.md#create_user) | **POST** /user | Create user -[**create_users_with_array_input**](UserApi.md#create_users_with_array_input) | **POST** /user/createWithArray | Creates list of users with given input array -[**create_users_with_list_input**](UserApi.md#create_users_with_list_input) | **POST** /user/createWithList | Creates list of users with given input array -[**delete_user**](UserApi.md#delete_user) | **DELETE** /user/{username} | Delete user -[**get_user_by_name**](UserApi.md#get_user_by_name) | **GET** /user/{username} | Get user by user name -[**login_user**](UserApi.md#login_user) | **GET** /user/login | Logs user into the system -[**logout_user**](UserApi.md#logout_user) | **GET** /user/logout | Logs out current logged in user session -[**update_user**](UserApi.md#update_user) | **PUT** /user/{username} | Updated user - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**create_user**](UserApi.md#create_user) | **POST** /user | Create user | +| [**create_users_with_array_input**](UserApi.md#create_users_with_array_input) | **POST** /user/createWithArray | Creates list of users with given input array | +| [**create_users_with_list_input**](UserApi.md#create_users_with_list_input) | **POST** /user/createWithList | Creates list of users with given input array | +| [**delete_user**](UserApi.md#delete_user) | **DELETE** /user/{username} | Delete user | +| [**get_user_by_name**](UserApi.md#get_user_by_name) | **GET** /user/{username} | Get user by user name | +| [**login_user**](UserApi.md#login_user) | **GET** /user/login | Logs user into the system | +| [**logout_user**](UserApi.md#logout_user) | **GET** /user/logout | Logs out current logged in user session | +| [**update_user**](UserApi.md#update_user) | **PUT** /user/{username} | Updated user | ## create_user @@ -42,10 +41,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**User**](User.md)| Created user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **user** | [**User**](User.md) | Created user object | | ### Return type @@ -86,10 +84,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**Array<User>**](User.md)| List of user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **user** | [**Array<User>**](User.md) | List of user object | | ### Return type @@ -130,10 +127,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**Array<User>**](User.md)| List of user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **user** | [**Array<User>**](User.md) | List of user object | | ### Return type @@ -176,10 +172,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The name that needs to be deleted | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | The name that needs to be deleted | | ### Return type @@ -221,10 +216,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The name that needs to be fetched. Use user1 for testing. | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | The name that needs to be fetched. Use user1 for testing. | | ### Return type @@ -267,11 +261,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The user name for login | - **password** | **String**| The password for login in clear text | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | The user name for login | | +| **password** | **String** | The password for login in clear text | | ### Return type @@ -355,11 +348,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| name that need to be deleted | - **user** | [**User**](User.md)| Updated user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | name that need to be deleted | | +| **user** | [**User**](User.md) | Updated user object | | ### Return type diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/api_client.rb b/samples/client/petstore/ruby-faraday/lib/petstore/api_client.rb index fee10b38d89f..40d47894e78c 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/api_client.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/api_client.rb @@ -280,8 +280,9 @@ def convert_to_type(data, return_type) data.each { |k, v| hash[k] = convert_to_type(v, sub_type) } end else - # models, e.g. Pet - Petstore.const_get(return_type).build_from_hash(data) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(return_type) + klass.respond_to?(:openapi_one_of) ? klass.build(data) : klass.build_from_hash(data) end end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/additional_properties_class.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/additional_properties_class.rb index d46bd4319e2a..77c032dea137 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/additional_properties_class.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/additional_properties_class.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -169,7 +174,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -195,7 +202,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -220,4 +227,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/animal.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/animal.rb index 715abed1f308..a6a8af1493c7 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/animal.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/animal.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -177,7 +182,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -203,7 +210,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -228,4 +235,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/api_response.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/api_response.rb index 9b3e689c71e4..a56b3b266dcf 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/api_response.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/api_response.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -174,7 +179,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -200,7 +207,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -225,4 +232,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_array_of_number_only.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_array_of_number_only.rb index 01a9cf6f4833..c392808c38ce 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_array_of_number_only.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_array_of_number_only.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_number_only.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_number_only.rb index 9768ba2f112a..d199d345d248 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_number_only.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/array_of_number_only.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/array_test.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/array_test.rb index 3538d1135315..2c42ad392c1e 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/array_test.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/array_test.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -180,7 +185,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -206,7 +213,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -231,4 +238,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/capitalization.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/capitalization.rb index 5fc7ad3b6efb..9540dbba0931 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/capitalization.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/capitalization.rb @@ -40,6 +40,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -202,7 +207,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -228,7 +235,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -253,4 +260,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/cat.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/cat.rb index 479b0441dc04..c46e1ab547f7 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/cat.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/cat.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about, including the ones defined in its parent(s) + def self.acceptable_attributes + attribute_map.values.concat(superclass.acceptable_attributes) + end + # Attribute type mapping. def self.openapi_types { @@ -168,7 +173,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -194,7 +201,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -219,4 +226,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/cat_all_of.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/cat_all_of.rb index b5bed52844eb..328946157b0b 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/cat_all_of.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/cat_all_of.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/category.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/category.rb index 306182291559..00cc38a26790 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/category.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/category.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -172,7 +177,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -198,7 +205,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -223,4 +230,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/class_model.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/class_model.rb index 9894e959e53b..cad08030a81a 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/class_model.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/class_model.rb @@ -25,6 +25,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -157,7 +162,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -183,7 +190,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -208,4 +215,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/client.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/client.rb index 7ad4b37cca71..8922e4cffe8c 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/client.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/client.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/dog.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/dog.rb index 362c2cc5d003..221d2b16309c 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/dog.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/dog.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about, including the ones defined in its parent(s) + def self.acceptable_attributes + attribute_map.values.concat(superclass.acceptable_attributes) + end + # Attribute type mapping. def self.openapi_types { @@ -168,7 +173,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -194,7 +201,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -219,4 +226,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/dog_all_of.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/dog_all_of.rb index 0dcb8c32a0ef..b7771c8910bf 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/dog_all_of.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/dog_all_of.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_arrays.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_arrays.rb index d5069f095b10..fe69026a5e58 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_arrays.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_arrays.rb @@ -49,6 +49,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -201,7 +206,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -227,7 +234,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -252,4 +259,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_test.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_test.rb index e9f474b3c5d0..b695d551922e 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_test.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/enum_test.rb @@ -67,6 +67,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -299,7 +304,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -325,7 +332,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -350,4 +357,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/file.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/file.rb index 6b2b307ee41a..97e055c1692f 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/file.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/file.rb @@ -26,6 +26,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/file_schema_test_class.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/file_schema_test_class.rb index dca470b02aba..856aeb716aa2 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/file_schema_test_class.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/file_schema_test_class.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -167,7 +172,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -193,7 +200,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -218,4 +225,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/foo.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/foo.rb index 70853138f796..fbafcb86cd58 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/foo.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/foo.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/format_test.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/format_test.rb index 34a2fd575dbe..b4b408fa9488 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/format_test.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/format_test.rb @@ -71,6 +71,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -516,7 +521,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -542,7 +549,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -567,4 +574,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/has_only_read_only.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/has_only_read_only.rb index 5dedaaf51495..a076ce2e1c07 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/has_only_read_only.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/has_only_read_only.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -165,7 +170,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -191,7 +198,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -216,4 +223,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/health_check_result.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/health_check_result.rb index 7e4529365edb..6de974d91cb5 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/health_check_result.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/health_check_result.rb @@ -25,6 +25,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object.rb index 85e30d1674c4..ab30d0a7cdb3 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -167,7 +172,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -193,7 +200,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -218,4 +225,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object1.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object1.rb index b566d0101193..7fda668343de 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object1.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object1.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -167,7 +172,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -193,7 +200,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -218,4 +225,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object2.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object2.rb index a7e862c4b42f..4218ff5c090b 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object2.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object2.rb @@ -51,6 +51,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -205,7 +210,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -231,7 +238,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -256,4 +263,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object3.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object3.rb index 6d16653ceb0d..fef4fac9195a 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object3.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object3.rb @@ -77,6 +77,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -488,7 +493,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -514,7 +521,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -539,4 +546,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object4.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object4.rb index 56bf6510edc4..cec629a73420 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object4.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object4.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -177,7 +182,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -203,7 +210,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -228,4 +235,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object5.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object5.rb index 78da991c505a..b6f800cb1be5 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object5.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_object5.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -172,7 +177,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -198,7 +205,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -223,4 +230,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_response_default.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_response_default.rb index 076ff2c3c251..d10840aa71be 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_response_default.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/inline_response_default.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/list.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/list.rb index 56a18b30738c..53b4b712a0a8 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/list.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/list.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/map_test.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/map_test.rb index 334e2c5b7780..014d6b8a8db0 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/map_test.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/map_test.rb @@ -55,6 +55,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -213,7 +218,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -239,7 +246,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -264,4 +271,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/mixed_properties_and_additional_properties_class.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/mixed_properties_and_additional_properties_class.rb index 570f0a521bcd..293cdcdc5b9b 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/mixed_properties_and_additional_properties_class.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/mixed_properties_and_additional_properties_class.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -176,7 +181,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -202,7 +209,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -227,4 +234,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/model200_response.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/model200_response.rb index 995912aa9060..750e1b6459c8 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/model200_response.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/model200_response.rb @@ -28,6 +28,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -166,7 +171,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -192,7 +199,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -217,4 +224,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/model_return.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/model_return.rb index aa78a6a89aac..ce3e88c2b3e6 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/model_return.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/model_return.rb @@ -25,6 +25,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -157,7 +162,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -183,7 +190,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -208,4 +215,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/name.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/name.rb index d79d9f71dc72..fc10db2a4c81 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/name.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/name.rb @@ -34,6 +34,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -189,7 +194,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -215,7 +222,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -240,4 +247,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/nullable_class.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/nullable_class.rb index 5f8c2372eaea..2193ccd7228a 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/nullable_class.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/nullable_class.rb @@ -57,6 +57,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -277,7 +282,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -303,7 +310,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -328,4 +335,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/number_only.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/number_only.rb index adcfa322f308..23387d216c8e 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/number_only.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/number_only.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/order.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/order.rb index 41c93ac0fe03..5ec9b5ff4ee3 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/order.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/order.rb @@ -62,6 +62,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -238,7 +243,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -264,7 +271,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -289,4 +296,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/outer_composite.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/outer_composite.rb index 522dc7a30fab..d6c5f2b0351b 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/outer_composite.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/outer_composite.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -174,7 +179,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -200,7 +207,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -225,4 +232,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/pet.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/pet.rb index 33d2b76e09ff..f802b6344e2f 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/pet.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/pet.rb @@ -62,6 +62,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -250,7 +255,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -276,7 +283,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -301,4 +308,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/read_only_first.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/read_only_first.rb index 3bf11964755e..4b530283796d 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/read_only_first.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/read_only_first.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -165,7 +170,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -191,7 +198,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -216,4 +223,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/special_model_name.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/special_model_name.rb index 1c0b391bc312..ae309ee47083 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/special_model_name.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/special_model_name.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/tag.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/tag.rb index 5715f75ce55a..f4126dd42859 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/tag.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/tag.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -165,7 +170,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -191,7 +198,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -216,4 +223,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby-faraday/lib/petstore/models/user.rb b/samples/client/petstore/ruby-faraday/lib/petstore/models/user.rb index 768898f4f5b7..b25915909755 100644 --- a/samples/client/petstore/ruby-faraday/lib/petstore/models/user.rb +++ b/samples/client/petstore/ruby-faraday/lib/petstore/models/user.rb @@ -46,6 +46,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -220,7 +225,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -246,7 +253,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -271,4 +278,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/docs/AdditionalPropertiesClass.md b/samples/client/petstore/ruby/docs/AdditionalPropertiesClass.md index e0d6811081cd..1806db9d3e6f 100644 --- a/samples/client/petstore/ruby/docs/AdditionalPropertiesClass.md +++ b/samples/client/petstore/ruby/docs/AdditionalPropertiesClass.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**map_property** | **Hash<String, String>** | | [optional] -**map_of_map_property** | **Hash<String, Hash<String, String>>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **map_property** | **Hash<String, String>** | | [optional] | +| **map_of_map_property** | **Hash<String, Hash<String, String>>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::AdditionalPropertiesClass.new(map_property: null, - map_of_map_property: null) +instance = Petstore::AdditionalPropertiesClass.new( + map_property: null, + map_of_map_property: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Animal.md b/samples/client/petstore/ruby/docs/Animal.md index 80e132d13e45..7ebaee441b94 100644 --- a/samples/client/petstore/ruby/docs/Animal.md +++ b/samples/client/petstore/ruby/docs/Animal.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**class_name** | **String** | | -**color** | **String** | | [optional] [default to 'red'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **class_name** | **String** | | | +| **color** | **String** | | [optional][default to 'red'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Animal.new(class_name: null, - color: null) +instance = Petstore::Animal.new( + class_name: null, + color: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/AnotherFakeApi.md b/samples/client/petstore/ruby/docs/AnotherFakeApi.md index d7b52283ea50..d14a8db14ead 100644 --- a/samples/client/petstore/ruby/docs/AnotherFakeApi.md +++ b/samples/client/petstore/ruby/docs/AnotherFakeApi.md @@ -2,10 +2,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**call_123_test_special_tags**](AnotherFakeApi.md#call_123_test_special_tags) | **PATCH** /another-fake/dummy | To test special tags - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**call_123_test_special_tags**](AnotherFakeApi.md#call_123_test_special_tags) | **PATCH** /another-fake/dummy | To test special tags | ## call_123_test_special_tags @@ -36,10 +35,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **client** | [**Client**](Client.md)| client model | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | [**Client**](Client.md) | client model | | ### Return type diff --git a/samples/client/petstore/ruby/docs/ApiResponse.md b/samples/client/petstore/ruby/docs/ApiResponse.md index c0ac7c4b4c17..4dfc3bab1fa0 100644 --- a/samples/client/petstore/ruby/docs/ApiResponse.md +++ b/samples/client/petstore/ruby/docs/ApiResponse.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**code** | **Integer** | | [optional] -**type** | **String** | | [optional] -**message** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **code** | **Integer** | | [optional] | +| **type** | **String** | | [optional] | +| **message** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ApiResponse.new(code: null, - type: null, - message: null) +instance = Petstore::ApiResponse.new( + code: null, + type: null, + message: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/ArrayOfArrayOfNumberOnly.md b/samples/client/petstore/ruby/docs/ArrayOfArrayOfNumberOnly.md index 5bb9ff33be21..ac0b04278845 100644 --- a/samples/client/petstore/ruby/docs/ArrayOfArrayOfNumberOnly.md +++ b/samples/client/petstore/ruby/docs/ArrayOfArrayOfNumberOnly.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**array_array_number** | **Array<Array<Float>>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **array_array_number** | **Array<Array<Float>>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ArrayOfArrayOfNumberOnly.new(array_array_number: null) +instance = Petstore::ArrayOfArrayOfNumberOnly.new( + array_array_number: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/ArrayOfNumberOnly.md b/samples/client/petstore/ruby/docs/ArrayOfNumberOnly.md index 8adb00978acc..2940cc5a486d 100644 --- a/samples/client/petstore/ruby/docs/ArrayOfNumberOnly.md +++ b/samples/client/petstore/ruby/docs/ArrayOfNumberOnly.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**array_number** | **Array<Float>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **array_number** | **Array<Float>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ArrayOfNumberOnly.new(array_number: null) +instance = Petstore::ArrayOfNumberOnly.new( + array_number: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/ArrayTest.md b/samples/client/petstore/ruby/docs/ArrayTest.md index 76e3866ba9c2..f9a5ffcec1c4 100644 --- a/samples/client/petstore/ruby/docs/ArrayTest.md +++ b/samples/client/petstore/ruby/docs/ArrayTest.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**array_of_string** | **Array<String>** | | [optional] -**array_array_of_integer** | **Array<Array<Integer>>** | | [optional] -**array_array_of_model** | **Array<Array<ReadOnlyFirst>>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **array_of_string** | **Array<String>** | | [optional] | +| **array_array_of_integer** | **Array<Array<Integer>>** | | [optional] | +| **array_array_of_model** | **Array<Array<ReadOnlyFirst>>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ArrayTest.new(array_of_string: null, - array_array_of_integer: null, - array_array_of_model: null) +instance = Petstore::ArrayTest.new( + array_of_string: null, + array_array_of_integer: null, + array_array_of_model: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Capitalization.md b/samples/client/petstore/ruby/docs/Capitalization.md index d1ac69ceb185..58831169b3bf 100644 --- a/samples/client/petstore/ruby/docs/Capitalization.md +++ b/samples/client/petstore/ruby/docs/Capitalization.md @@ -2,26 +2,27 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**small_camel** | **String** | | [optional] -**capital_camel** | **String** | | [optional] -**small_snake** | **String** | | [optional] -**capital_snake** | **String** | | [optional] -**sca_eth_flow_points** | **String** | | [optional] -**att_name** | **String** | Name of the pet | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **small_camel** | **String** | | [optional] | +| **capital_camel** | **String** | | [optional] | +| **small_snake** | **String** | | [optional] | +| **capital_snake** | **String** | | [optional] | +| **sca_eth_flow_points** | **String** | | [optional] | +| **att_name** | **String** | Name of the pet | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Capitalization.new(small_camel: null, - capital_camel: null, - small_snake: null, - capital_snake: null, - sca_eth_flow_points: null, - att_name: null) +instance = Petstore::Capitalization.new( + small_camel: null, + capital_camel: null, + small_snake: null, + capital_snake: null, + sca_eth_flow_points: null, + att_name: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Cat.md b/samples/client/petstore/ruby/docs/Cat.md index 054fbfadafd3..047db885909e 100644 --- a/samples/client/petstore/ruby/docs/Cat.md +++ b/samples/client/petstore/ruby/docs/Cat.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**declawed** | **Boolean** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **declawed** | **Boolean** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Cat.new(declawed: null) +instance = Petstore::Cat.new( + declawed: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/CatAllOf.md b/samples/client/petstore/ruby/docs/CatAllOf.md index a83a6f756620..634ef021d591 100644 --- a/samples/client/petstore/ruby/docs/CatAllOf.md +++ b/samples/client/petstore/ruby/docs/CatAllOf.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**declawed** | **Boolean** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **declawed** | **Boolean** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::CatAllOf.new(declawed: null) +instance = Petstore::CatAllOf.new( + declawed: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Category.md b/samples/client/petstore/ruby/docs/Category.md index 942f88759ea6..d53fbb921cf2 100644 --- a/samples/client/petstore/ruby/docs/Category.md +++ b/samples/client/petstore/ruby/docs/Category.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**name** | **String** | | [default to 'default-name'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **name** | **String** | | [default to 'default-name'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Category.new(id: null, - name: null) +instance = Petstore::Category.new( + id: null, + name: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/ClassModel.md b/samples/client/petstore/ruby/docs/ClassModel.md index faf38fde16d9..111d69eae582 100644 --- a/samples/client/petstore/ruby/docs/ClassModel.md +++ b/samples/client/petstore/ruby/docs/ClassModel.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**_class** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **_class** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ClassModel.new(_class: null) +instance = Petstore::ClassModel.new( + _class: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Client.md b/samples/client/petstore/ruby/docs/Client.md index da87ce113cb3..ec4ef88114cd 100644 --- a/samples/client/petstore/ruby/docs/Client.md +++ b/samples/client/petstore/ruby/docs/Client.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**client** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Client.new(client: null) +instance = Petstore::Client.new( + client: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/DefaultApi.md b/samples/client/petstore/ruby/docs/DefaultApi.md index 9e2e7712f92d..a4f9427829d1 100644 --- a/samples/client/petstore/ruby/docs/DefaultApi.md +++ b/samples/client/petstore/ruby/docs/DefaultApi.md @@ -2,10 +2,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**foo_get**](DefaultApi.md#foo_get) | **GET** /foo | - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**foo_get**](DefaultApi.md#foo_get) | **GET** /foo | | ## foo_get diff --git a/samples/client/petstore/ruby/docs/Dog.md b/samples/client/petstore/ruby/docs/Dog.md index 68c2e5d7e0e5..cbd924e9bb80 100644 --- a/samples/client/petstore/ruby/docs/Dog.md +++ b/samples/client/petstore/ruby/docs/Dog.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**breed** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **breed** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Dog.new(breed: null) +instance = Petstore::Dog.new( + breed: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/DogAllOf.md b/samples/client/petstore/ruby/docs/DogAllOf.md index 6107fd0c10f5..a7ee66dd9aa4 100644 --- a/samples/client/petstore/ruby/docs/DogAllOf.md +++ b/samples/client/petstore/ruby/docs/DogAllOf.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**breed** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **breed** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::DogAllOf.new(breed: null) +instance = Petstore::DogAllOf.new( + breed: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/EnumArrays.md b/samples/client/petstore/ruby/docs/EnumArrays.md index 18efa20299d0..160e6018036b 100644 --- a/samples/client/petstore/ruby/docs/EnumArrays.md +++ b/samples/client/petstore/ruby/docs/EnumArrays.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**just_symbol** | **String** | | [optional] -**array_enum** | **Array<String>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **just_symbol** | **String** | | [optional] | +| **array_enum** | **Array<String>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::EnumArrays.new(just_symbol: null, - array_enum: null) +instance = Petstore::EnumArrays.new( + just_symbol: null, + array_enum: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/EnumClass.md b/samples/client/petstore/ruby/docs/EnumClass.md index 0fca9b27f5ce..4a44d03a65bf 100644 --- a/samples/client/petstore/ruby/docs/EnumClass.md +++ b/samples/client/petstore/ruby/docs/EnumClass.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::EnumClass.new() ``` - diff --git a/samples/client/petstore/ruby/docs/EnumTest.md b/samples/client/petstore/ruby/docs/EnumTest.md index 7ea08c8d7b1a..90e5ea4fa4df 100644 --- a/samples/client/petstore/ruby/docs/EnumTest.md +++ b/samples/client/petstore/ruby/docs/EnumTest.md @@ -2,30 +2,31 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**enum_string** | **String** | | [optional] -**enum_string_required** | **String** | | -**enum_integer** | **Integer** | | [optional] -**enum_number** | **Float** | | [optional] -**outer_enum** | [**OuterEnum**](OuterEnum.md) | | [optional] -**outer_enum_integer** | [**OuterEnumInteger**](OuterEnumInteger.md) | | [optional] -**outer_enum_default_value** | [**OuterEnumDefaultValue**](OuterEnumDefaultValue.md) | | [optional] [default to 'placed'] -**outer_enum_integer_default_value** | [**OuterEnumIntegerDefaultValue**](OuterEnumIntegerDefaultValue.md) | | [optional] [default to OuterEnumIntegerDefaultValue::N0] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **enum_string** | **String** | | [optional] | +| **enum_string_required** | **String** | | | +| **enum_integer** | **Integer** | | [optional] | +| **enum_number** | **Float** | | [optional] | +| **outer_enum** | [**OuterEnum**](OuterEnum.md) | | [optional] | +| **outer_enum_integer** | [**OuterEnumInteger**](OuterEnumInteger.md) | | [optional] | +| **outer_enum_default_value** | [**OuterEnumDefaultValue**](OuterEnumDefaultValue.md) | | [optional][default to 'placed'] | +| **outer_enum_integer_default_value** | [**OuterEnumIntegerDefaultValue**](OuterEnumIntegerDefaultValue.md) | | [optional][default to OuterEnumIntegerDefaultValue::N0] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::EnumTest.new(enum_string: null, - enum_string_required: null, - enum_integer: null, - enum_number: null, - outer_enum: null, - outer_enum_integer: null, - outer_enum_default_value: null, - outer_enum_integer_default_value: null) +instance = Petstore::EnumTest.new( + enum_string: null, + enum_string_required: null, + enum_integer: null, + enum_number: null, + outer_enum: null, + outer_enum_integer: null, + outer_enum_default_value: null, + outer_enum_integer_default_value: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/FakeApi.md b/samples/client/petstore/ruby/docs/FakeApi.md index 4e07aa5bce8d..b154297177df 100644 --- a/samples/client/petstore/ruby/docs/FakeApi.md +++ b/samples/client/petstore/ruby/docs/FakeApi.md @@ -2,24 +2,23 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**fake_health_get**](FakeApi.md#fake_health_get) | **GET** /fake/health | Health check endpoint -[**fake_http_signature_test**](FakeApi.md#fake_http_signature_test) | **GET** /fake/http-signature-test | test http signature authentication -[**fake_outer_boolean_serialize**](FakeApi.md#fake_outer_boolean_serialize) | **POST** /fake/outer/boolean | -[**fake_outer_composite_serialize**](FakeApi.md#fake_outer_composite_serialize) | **POST** /fake/outer/composite | -[**fake_outer_number_serialize**](FakeApi.md#fake_outer_number_serialize) | **POST** /fake/outer/number | -[**fake_outer_string_serialize**](FakeApi.md#fake_outer_string_serialize) | **POST** /fake/outer/string | -[**test_body_with_file_schema**](FakeApi.md#test_body_with_file_schema) | **PUT** /fake/body-with-file-schema | -[**test_body_with_query_params**](FakeApi.md#test_body_with_query_params) | **PUT** /fake/body-with-query-params | -[**test_client_model**](FakeApi.md#test_client_model) | **PATCH** /fake | To test \"client\" model -[**test_endpoint_parameters**](FakeApi.md#test_endpoint_parameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 -[**test_enum_parameters**](FakeApi.md#test_enum_parameters) | **GET** /fake | To test enum parameters -[**test_group_parameters**](FakeApi.md#test_group_parameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) -[**test_inline_additional_properties**](FakeApi.md#test_inline_additional_properties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties -[**test_json_form_data**](FakeApi.md#test_json_form_data) | **GET** /fake/jsonFormData | test json serialization of form data -[**test_query_parameter_collection_format**](FakeApi.md#test_query_parameter_collection_format) | **PUT** /fake/test-query-paramters | - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**fake_health_get**](FakeApi.md#fake_health_get) | **GET** /fake/health | Health check endpoint | +| [**fake_http_signature_test**](FakeApi.md#fake_http_signature_test) | **GET** /fake/http-signature-test | test http signature authentication | +| [**fake_outer_boolean_serialize**](FakeApi.md#fake_outer_boolean_serialize) | **POST** /fake/outer/boolean | | +| [**fake_outer_composite_serialize**](FakeApi.md#fake_outer_composite_serialize) | **POST** /fake/outer/composite | | +| [**fake_outer_number_serialize**](FakeApi.md#fake_outer_number_serialize) | **POST** /fake/outer/number | | +| [**fake_outer_string_serialize**](FakeApi.md#fake_outer_string_serialize) | **POST** /fake/outer/string | | +| [**test_body_with_file_schema**](FakeApi.md#test_body_with_file_schema) | **PUT** /fake/body-with-file-schema | | +| [**test_body_with_query_params**](FakeApi.md#test_body_with_query_params) | **PUT** /fake/body-with-query-params | | +| [**test_client_model**](FakeApi.md#test_client_model) | **PATCH** /fake | To test \"client\" model | +| [**test_endpoint_parameters**](FakeApi.md#test_endpoint_parameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 | +| [**test_enum_parameters**](FakeApi.md#test_enum_parameters) | **GET** /fake | To test enum parameters | +| [**test_group_parameters**](FakeApi.md#test_group_parameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) | +| [**test_inline_additional_properties**](FakeApi.md#test_inline_additional_properties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties | +| [**test_json_form_data**](FakeApi.md#test_json_form_data) | **GET** /fake/jsonFormData | test json serialization of form data | +| [**test_query_parameter_collection_format**](FakeApi.md#test_query_parameter_collection_format) | **PUT** /fake/test-query-paramters | | ## fake_health_get @@ -95,12 +94,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | - **query_1** | **String**| query parameter | [optional] - **header_1** | **String**| header parameter | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet** | [**Pet**](Pet.md) | Pet object that needs to be added to the store | | +| **query_1** | **String** | query parameter | [optional] | +| **header_1** | **String** | header parameter | [optional] | ### Return type @@ -145,10 +143,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **Boolean**| Input boolean as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **body** | **Boolean** | Input boolean as post body | [optional] | ### Return type @@ -193,10 +190,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **outer_composite** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **outer_composite** | [**OuterComposite**](OuterComposite.md) | Input composite as post body | [optional] | ### Return type @@ -241,10 +237,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **Float**| Input number as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **body** | **Float** | Input number as post body | [optional] | ### Return type @@ -289,10 +284,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **String**| Input string as post body | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **body** | **String** | Input string as post body | [optional] | ### Return type @@ -334,10 +328,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **file_schema_test_class** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **file_schema_test_class** | [**FileSchemaTestClass**](FileSchemaTestClass.md) | | | ### Return type @@ -378,11 +371,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **query** | **String**| | - **user** | [**User**](User.md)| | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **query** | **String** | | | +| **user** | [**User**](User.md) | | | ### Return type @@ -426,10 +418,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **client** | [**Client**](Client.md)| client model | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | [**Client**](Client.md) | client model | | ### Return type @@ -493,23 +484,22 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **number** | **Float**| None | - **double** | **Float**| None | - **pattern_without_delimiter** | **String**| None | - **byte** | **String**| None | - **integer** | **Integer**| None | [optional] - **int32** | **Integer**| None | [optional] - **int64** | **Integer**| None | [optional] - **float** | **Float**| None | [optional] - **string** | **String**| None | [optional] - **binary** | **File**| None | [optional] - **date** | **Date**| None | [optional] - **date_time** | **Time**| None | [optional] - **password** | **String**| None | [optional] - **callback** | **String**| None | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **number** | **Float** | None | | +| **double** | **Float** | None | | +| **pattern_without_delimiter** | **String** | None | | +| **byte** | **String** | None | | +| **integer** | **Integer** | None | [optional] | +| **int32** | **Integer** | None | [optional] | +| **int64** | **Integer** | None | [optional] | +| **float** | **Float** | None | [optional] | +| **string** | **String** | None | [optional] | +| **binary** | **File** | None | [optional] | +| **date** | **Date** | None | [optional] | +| **date_time** | **Time** | None | [optional] | +| **password** | **String** | None | [optional] | +| **callback** | **String** | None | [optional] | ### Return type @@ -561,17 +551,16 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **enum_header_string_array** | [**Array<String>**](String.md)| Header parameter enum test (string array) | [optional] - **enum_header_string** | **String**| Header parameter enum test (string) | [optional] [default to '-efg'] - **enum_query_string_array** | [**Array<String>**](String.md)| Query parameter enum test (string array) | [optional] - **enum_query_string** | **String**| Query parameter enum test (string) | [optional] [default to '-efg'] - **enum_query_integer** | **Integer**| Query parameter enum test (double) | [optional] - **enum_query_double** | **Float**| Query parameter enum test (double) | [optional] - **enum_form_string_array** | [**Array<String>**](String.md)| Form parameter enum test (string array) | [optional] [default to '$'] - **enum_form_string** | **String**| Form parameter enum test (string) | [optional] [default to '-efg'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **enum_header_string_array** | [**Array<String>**](String.md) | Header parameter enum test (string array) | [optional] | +| **enum_header_string** | **String** | Header parameter enum test (string) | [optional][default to '-efg'] | +| **enum_query_string_array** | [**Array<String>**](String.md) | Query parameter enum test (string array) | [optional] | +| **enum_query_string** | **String** | Query parameter enum test (string) | [optional][default to '-efg'] | +| **enum_query_integer** | **Integer** | Query parameter enum test (double) | [optional] | +| **enum_query_double** | **Float** | Query parameter enum test (double) | [optional] | +| **enum_form_string_array** | [**Array<String>**](String.md) | Form parameter enum test (string array) | [optional][default to '$'] | +| **enum_form_string** | **String** | Form parameter enum test (string) | [optional][default to '-efg'] | ### Return type @@ -626,15 +615,14 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **required_string_group** | **Integer**| Required String in group parameters | - **required_boolean_group** | **Boolean**| Required Boolean in group parameters | - **required_int64_group** | **Integer**| Required Integer in group parameters | - **string_group** | **Integer**| String in group parameters | [optional] - **boolean_group** | **Boolean**| Boolean in group parameters | [optional] - **int64_group** | **Integer**| Integer in group parameters | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **required_string_group** | **Integer** | Required String in group parameters | | +| **required_boolean_group** | **Boolean** | Required Boolean in group parameters | | +| **required_int64_group** | **Integer** | Required Integer in group parameters | | +| **string_group** | **Integer** | String in group parameters | [optional] | +| **boolean_group** | **Boolean** | Boolean in group parameters | [optional] | +| **int64_group** | **Integer** | Integer in group parameters | [optional] | ### Return type @@ -675,10 +663,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **request_body** | [**Hash<String, String>**](String.md)| request body | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **request_body** | [**Hash<String, String>**](String.md) | request body | | ### Return type @@ -720,11 +707,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **param** | **String**| field1 | - **param2** | **String**| field2 | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **param** | **String** | field1 | | +| **param2** | **String** | field2 | | ### Return type @@ -770,14 +756,13 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pipe** | [**Array<String>**](String.md)| | - **ioutil** | [**Array<String>**](String.md)| | - **http** | [**Array<String>**](String.md)| | - **url** | [**Array<String>**](String.md)| | - **context** | [**Array<String>**](String.md)| | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pipe** | [**Array<String>**](String.md) | | | +| **ioutil** | [**Array<String>**](String.md) | | | +| **http** | [**Array<String>**](String.md) | | | +| **url** | [**Array<String>**](String.md) | | | +| **context** | [**Array<String>**](String.md) | | | ### Return type diff --git a/samples/client/petstore/ruby/docs/FakeClassnameTags123Api.md b/samples/client/petstore/ruby/docs/FakeClassnameTags123Api.md index 4ccb9083cbae..60916d81fd17 100644 --- a/samples/client/petstore/ruby/docs/FakeClassnameTags123Api.md +++ b/samples/client/petstore/ruby/docs/FakeClassnameTags123Api.md @@ -2,10 +2,9 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**test_classname**](FakeClassnameTags123Api.md#test_classname) | **PATCH** /fake_classname_test | To test class name in snake case - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**test_classname**](FakeClassnameTags123Api.md#test_classname) | **PATCH** /fake_classname_test | To test class name in snake case | ## test_classname @@ -43,10 +42,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **client** | [**Client**](Client.md)| client model | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **client** | [**Client**](Client.md) | client model | | ### Return type diff --git a/samples/client/petstore/ruby/docs/File.md b/samples/client/petstore/ruby/docs/File.md index ca8a6e9c3136..f395df873fe2 100644 --- a/samples/client/petstore/ruby/docs/File.md +++ b/samples/client/petstore/ruby/docs/File.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**source_uri** | **String** | Test capitalization | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **source_uri** | **String** | Test capitalization | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::File.new(source_uri: null) +instance = Petstore::File.new( + source_uri: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/FileSchemaTestClass.md b/samples/client/petstore/ruby/docs/FileSchemaTestClass.md index 03ee5f7e803b..d16964b9844f 100644 --- a/samples/client/petstore/ruby/docs/FileSchemaTestClass.md +++ b/samples/client/petstore/ruby/docs/FileSchemaTestClass.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**file** | **File** | | [optional] -**files** | **Array<File>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **file** | **File** | | [optional] | +| **files** | **Array<File>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::FileSchemaTestClass.new(file: null, - files: null) +instance = Petstore::FileSchemaTestClass.new( + file: null, + files: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Foo.md b/samples/client/petstore/ruby/docs/Foo.md index 9c55a348168e..9bb2521e88a1 100644 --- a/samples/client/petstore/ruby/docs/Foo.md +++ b/samples/client/petstore/ruby/docs/Foo.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [default to 'bar'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **bar** | **String** | | [optional][default to 'bar'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Foo.new(bar: null) +instance = Petstore::Foo.new( + bar: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/FormatTest.md b/samples/client/petstore/ruby/docs/FormatTest.md index 85558a2cc0ca..25287e4fd4c0 100644 --- a/samples/client/petstore/ruby/docs/FormatTest.md +++ b/samples/client/petstore/ruby/docs/FormatTest.md @@ -2,46 +2,47 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integer** | **Integer** | | [optional] -**int32** | **Integer** | | [optional] -**int64** | **Integer** | | [optional] -**number** | **Float** | | -**float** | **Float** | | [optional] -**double** | **Float** | | [optional] -**decimal** | [**Decimal**](Decimal.md) | | [optional] -**string** | **String** | | [optional] -**byte** | **String** | | -**binary** | **File** | | [optional] -**date** | **Date** | | -**date_time** | **Time** | | [optional] -**uuid** | **String** | | [optional] -**password** | **String** | | -**pattern_with_digits** | **String** | A string that is a 10 digit number. Can have leading zeros. | [optional] -**pattern_with_digits_and_delimiter** | **String** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **integer** | **Integer** | | [optional] | +| **int32** | **Integer** | | [optional] | +| **int64** | **Integer** | | [optional] | +| **number** | **Float** | | | +| **float** | **Float** | | [optional] | +| **double** | **Float** | | [optional] | +| **decimal** | [**Decimal**](Decimal.md) | | [optional] | +| **string** | **String** | | [optional] | +| **byte** | **String** | | | +| **binary** | **File** | | [optional] | +| **date** | **Date** | | | +| **date_time** | **Time** | | [optional] | +| **uuid** | **String** | | [optional] | +| **password** | **String** | | | +| **pattern_with_digits** | **String** | A string that is a 10 digit number. Can have leading zeros. | [optional] | +| **pattern_with_digits_and_delimiter** | **String** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::FormatTest.new(integer: null, - int32: null, - int64: null, - number: null, - float: null, - double: null, - decimal: null, - string: null, - byte: null, - binary: null, - date: null, - date_time: null, - uuid: 72f98069-206d-4f12-9f12-3d1e525a8e84, - password: null, - pattern_with_digits: null, - pattern_with_digits_and_delimiter: null) +instance = Petstore::FormatTest.new( + integer: null, + int32: null, + int64: null, + number: null, + float: null, + double: null, + decimal: null, + string: null, + byte: null, + binary: null, + date: null, + date_time: null, + uuid: 72f98069-206d-4f12-9f12-3d1e525a8e84, + password: null, + pattern_with_digits: null, + pattern_with_digits_and_delimiter: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/HasOnlyReadOnly.md b/samples/client/petstore/ruby/docs/HasOnlyReadOnly.md index a15219a9c7b1..6900c5039e91 100644 --- a/samples/client/petstore/ruby/docs/HasOnlyReadOnly.md +++ b/samples/client/petstore/ruby/docs/HasOnlyReadOnly.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [readonly] -**foo** | **String** | | [optional] [readonly] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **bar** | **String** | | [optional][readonly] | +| **foo** | **String** | | [optional][readonly] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::HasOnlyReadOnly.new(bar: null, - foo: null) +instance = Petstore::HasOnlyReadOnly.new( + bar: null, + foo: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/HealthCheckResult.md b/samples/client/petstore/ruby/docs/HealthCheckResult.md index 0382fa78403e..4aa12dd58e6e 100644 --- a/samples/client/petstore/ruby/docs/HealthCheckResult.md +++ b/samples/client/petstore/ruby/docs/HealthCheckResult.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**nullable_message** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **nullable_message** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::HealthCheckResult.new(nullable_message: null) +instance = Petstore::HealthCheckResult.new( + nullable_message: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/InlineObject.md b/samples/client/petstore/ruby/docs/InlineObject.md index f5211d44464c..8967d77cb6a4 100644 --- a/samples/client/petstore/ruby/docs/InlineObject.md +++ b/samples/client/petstore/ruby/docs/InlineObject.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **String** | Updated name of the pet | [optional] -**status** | **String** | Updated status of the pet | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **name** | **String** | Updated name of the pet | [optional] | +| **status** | **String** | Updated status of the pet | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject.new(name: null, - status: null) +instance = Petstore::InlineObject.new( + name: null, + status: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/InlineObject1.md b/samples/client/petstore/ruby/docs/InlineObject1.md index bac17e753cdc..b2d08a2bea6e 100644 --- a/samples/client/petstore/ruby/docs/InlineObject1.md +++ b/samples/client/petstore/ruby/docs/InlineObject1.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**additional_metadata** | **String** | Additional data to pass to server | [optional] -**file** | **File** | file to upload | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | +| **file** | **File** | file to upload | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject1.new(additional_metadata: null, - file: null) +instance = Petstore::InlineObject1.new( + additional_metadata: null, + file: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/InlineObject2.md b/samples/client/petstore/ruby/docs/InlineObject2.md index 31118c5b262e..74cc2d92fc3d 100644 --- a/samples/client/petstore/ruby/docs/InlineObject2.md +++ b/samples/client/petstore/ruby/docs/InlineObject2.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**enum_form_string_array** | **Array<String>** | Form parameter enum test (string array) | [optional] -**enum_form_string** | **String** | Form parameter enum test (string) | [optional] [default to '-efg'] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **enum_form_string_array** | **Array<String>** | Form parameter enum test (string array) | [optional] | +| **enum_form_string** | **String** | Form parameter enum test (string) | [optional][default to '-efg'] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject2.new(enum_form_string_array: null, - enum_form_string: null) +instance = Petstore::InlineObject2.new( + enum_form_string_array: null, + enum_form_string: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/InlineObject3.md b/samples/client/petstore/ruby/docs/InlineObject3.md index beaf051468ba..57d6d9088045 100644 --- a/samples/client/petstore/ruby/docs/InlineObject3.md +++ b/samples/client/petstore/ruby/docs/InlineObject3.md @@ -2,42 +2,43 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integer** | **Integer** | None | [optional] -**int32** | **Integer** | None | [optional] -**int64** | **Integer** | None | [optional] -**number** | **Float** | None | -**float** | **Float** | None | [optional] -**double** | **Float** | None | -**string** | **String** | None | [optional] -**pattern_without_delimiter** | **String** | None | -**byte** | **String** | None | -**binary** | **File** | None | [optional] -**date** | **Date** | None | [optional] -**date_time** | **Time** | None | [optional] -**password** | **String** | None | [optional] -**callback** | **String** | None | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **integer** | **Integer** | None | [optional] | +| **int32** | **Integer** | None | [optional] | +| **int64** | **Integer** | None | [optional] | +| **number** | **Float** | None | | +| **float** | **Float** | None | [optional] | +| **double** | **Float** | None | | +| **string** | **String** | None | [optional] | +| **pattern_without_delimiter** | **String** | None | | +| **byte** | **String** | None | | +| **binary** | **File** | None | [optional] | +| **date** | **Date** | None | [optional] | +| **date_time** | **Time** | None | [optional] | +| **password** | **String** | None | [optional] | +| **callback** | **String** | None | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject3.new(integer: null, - int32: null, - int64: null, - number: null, - float: null, - double: null, - string: null, - pattern_without_delimiter: null, - byte: null, - binary: null, - date: null, - date_time: null, - password: null, - callback: null) +instance = Petstore::InlineObject3.new( + integer: null, + int32: null, + int64: null, + number: null, + float: null, + double: null, + string: null, + pattern_without_delimiter: null, + byte: null, + binary: null, + date: null, + date_time: null, + password: null, + callback: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/InlineObject4.md b/samples/client/petstore/ruby/docs/InlineObject4.md index 97179c3e3772..155dc45fbdc3 100644 --- a/samples/client/petstore/ruby/docs/InlineObject4.md +++ b/samples/client/petstore/ruby/docs/InlineObject4.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**param** | **String** | field1 | -**param2** | **String** | field2 | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **param** | **String** | field1 | | +| **param2** | **String** | field2 | | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject4.new(param: null, - param2: null) +instance = Petstore::InlineObject4.new( + param: null, + param2: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/InlineObject5.md b/samples/client/petstore/ruby/docs/InlineObject5.md index 23c1df99ffeb..b82651bd134c 100644 --- a/samples/client/petstore/ruby/docs/InlineObject5.md +++ b/samples/client/petstore/ruby/docs/InlineObject5.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**additional_metadata** | **String** | Additional data to pass to server | [optional] -**required_file** | **File** | file to upload | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | +| **required_file** | **File** | file to upload | | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineObject5.new(additional_metadata: null, - required_file: null) +instance = Petstore::InlineObject5.new( + additional_metadata: null, + required_file: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/InlineResponseDefault.md b/samples/client/petstore/ruby/docs/InlineResponseDefault.md index b89dc59aa330..c0ee67fdeb93 100644 --- a/samples/client/petstore/ruby/docs/InlineResponseDefault.md +++ b/samples/client/petstore/ruby/docs/InlineResponseDefault.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**string** | [**Foo**](Foo.md) | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **string** | [**Foo**](Foo.md) | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::InlineResponseDefault.new(string: null) +instance = Petstore::InlineResponseDefault.new( + string: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/List.md b/samples/client/petstore/ruby/docs/List.md index 4add9c3fd230..cbae6cf2acd4 100644 --- a/samples/client/petstore/ruby/docs/List.md +++ b/samples/client/petstore/ruby/docs/List.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**_123_list** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **_123_list** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::List.new(_123_list: null) +instance = Petstore::List.new( + _123_list: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/MapTest.md b/samples/client/petstore/ruby/docs/MapTest.md index 9bf1793ec082..fea648930858 100644 --- a/samples/client/petstore/ruby/docs/MapTest.md +++ b/samples/client/petstore/ruby/docs/MapTest.md @@ -2,22 +2,23 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**map_map_of_string** | **Hash<String, Hash<String, String>>** | | [optional] -**map_of_enum_string** | **Hash<String, String>** | | [optional] -**direct_map** | **Hash<String, Boolean>** | | [optional] -**indirect_map** | **Hash<String, Boolean>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **map_map_of_string** | **Hash<String, Hash<String, String>>** | | [optional] | +| **map_of_enum_string** | **Hash<String, String>** | | [optional] | +| **direct_map** | **Hash<String, Boolean>** | | [optional] | +| **indirect_map** | **Hash<String, Boolean>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::MapTest.new(map_map_of_string: null, - map_of_enum_string: null, - direct_map: null, - indirect_map: null) +instance = Petstore::MapTest.new( + map_map_of_string: null, + map_of_enum_string: null, + direct_map: null, + indirect_map: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/client/petstore/ruby/docs/MixedPropertiesAndAdditionalPropertiesClass.md index a151e64b5d35..720c142f69ee 100644 --- a/samples/client/petstore/ruby/docs/MixedPropertiesAndAdditionalPropertiesClass.md +++ b/samples/client/petstore/ruby/docs/MixedPropertiesAndAdditionalPropertiesClass.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**uuid** | **String** | | [optional] -**date_time** | **Time** | | [optional] -**map** | [**Hash<String, Animal>**](Animal.md) | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **uuid** | **String** | | [optional] | +| **date_time** | **Time** | | [optional] | +| **map** | [**Hash<String, Animal>**](Animal.md) | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::MixedPropertiesAndAdditionalPropertiesClass.new(uuid: null, - date_time: null, - map: null) +instance = Petstore::MixedPropertiesAndAdditionalPropertiesClass.new( + uuid: null, + date_time: null, + map: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Model200Response.md b/samples/client/petstore/ruby/docs/Model200Response.md index 07a53b603347..155120bb9383 100644 --- a/samples/client/petstore/ruby/docs/Model200Response.md +++ b/samples/client/petstore/ruby/docs/Model200Response.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **Integer** | | [optional] -**_class** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **name** | **Integer** | | [optional] | +| **_class** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Model200Response.new(name: null, - _class: null) +instance = Petstore::Model200Response.new( + name: null, + _class: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/ModelReturn.md b/samples/client/petstore/ruby/docs/ModelReturn.md index 2e155936c898..28d197b2b7c2 100644 --- a/samples/client/petstore/ruby/docs/ModelReturn.md +++ b/samples/client/petstore/ruby/docs/ModelReturn.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**_return** | **Integer** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **_return** | **Integer** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ModelReturn.new(_return: null) +instance = Petstore::ModelReturn.new( + _return: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Name.md b/samples/client/petstore/ruby/docs/Name.md index 17cdbbd35612..9f53f36cddc8 100644 --- a/samples/client/petstore/ruby/docs/Name.md +++ b/samples/client/petstore/ruby/docs/Name.md @@ -2,22 +2,23 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **Integer** | | -**snake_case** | **Integer** | | [optional] [readonly] -**property** | **String** | | [optional] -**_123_number** | **Integer** | | [optional] [readonly] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **name** | **Integer** | | | +| **snake_case** | **Integer** | | [optional][readonly] | +| **property** | **String** | | [optional] | +| **_123_number** | **Integer** | | [optional][readonly] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Name.new(name: null, - snake_case: null, - property: null, - _123_number: null) +instance = Petstore::Name.new( + name: null, + snake_case: null, + property: null, + _123_number: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/NullableClass.md b/samples/client/petstore/ruby/docs/NullableClass.md index 51f89cd32200..6e28739c328e 100644 --- a/samples/client/petstore/ruby/docs/NullableClass.md +++ b/samples/client/petstore/ruby/docs/NullableClass.md @@ -2,38 +2,39 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integer_prop** | **Integer** | | [optional] -**number_prop** | **Float** | | [optional] -**boolean_prop** | **Boolean** | | [optional] -**string_prop** | **String** | | [optional] -**date_prop** | **Date** | | [optional] -**datetime_prop** | **Time** | | [optional] -**array_nullable_prop** | **Array<Object>** | | [optional] -**array_and_items_nullable_prop** | **Array<Object>** | | [optional] -**array_items_nullable** | **Array<Object>** | | [optional] -**object_nullable_prop** | **Hash<String, Object>** | | [optional] -**object_and_items_nullable_prop** | **Hash<String, Object>** | | [optional] -**object_items_nullable** | **Hash<String, Object>** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **integer_prop** | **Integer** | | [optional] | +| **number_prop** | **Float** | | [optional] | +| **boolean_prop** | **Boolean** | | [optional] | +| **string_prop** | **String** | | [optional] | +| **date_prop** | **Date** | | [optional] | +| **datetime_prop** | **Time** | | [optional] | +| **array_nullable_prop** | **Array<Object>** | | [optional] | +| **array_and_items_nullable_prop** | **Array<Object>** | | [optional] | +| **array_items_nullable** | **Array<Object>** | | [optional] | +| **object_nullable_prop** | **Hash<String, Object>** | | [optional] | +| **object_and_items_nullable_prop** | **Hash<String, Object>** | | [optional] | +| **object_items_nullable** | **Hash<String, Object>** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::NullableClass.new(integer_prop: null, - number_prop: null, - boolean_prop: null, - string_prop: null, - date_prop: null, - datetime_prop: null, - array_nullable_prop: null, - array_and_items_nullable_prop: null, - array_items_nullable: null, - object_nullable_prop: null, - object_and_items_nullable_prop: null, - object_items_nullable: null) +instance = Petstore::NullableClass.new( + integer_prop: null, + number_prop: null, + boolean_prop: null, + string_prop: null, + date_prop: null, + datetime_prop: null, + array_nullable_prop: null, + array_and_items_nullable_prop: null, + array_items_nullable: null, + object_nullable_prop: null, + object_and_items_nullable_prop: null, + object_items_nullable: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/NumberOnly.md b/samples/client/petstore/ruby/docs/NumberOnly.md index 73c5d0a3ab28..bc2e5ae03d8b 100644 --- a/samples/client/petstore/ruby/docs/NumberOnly.md +++ b/samples/client/petstore/ruby/docs/NumberOnly.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**just_number** | **Float** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **just_number** | **Float** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::NumberOnly.new(just_number: null) +instance = Petstore::NumberOnly.new( + just_number: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/Order.md b/samples/client/petstore/ruby/docs/Order.md index 54484d31be4a..b30ab51f2aa5 100644 --- a/samples/client/petstore/ruby/docs/Order.md +++ b/samples/client/petstore/ruby/docs/Order.md @@ -2,26 +2,27 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**pet_id** | **Integer** | | [optional] -**quantity** | **Integer** | | [optional] -**ship_date** | **Time** | | [optional] -**status** | **String** | Order Status | [optional] -**complete** | **Boolean** | | [optional] [default to false] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **pet_id** | **Integer** | | [optional] | +| **quantity** | **Integer** | | [optional] | +| **ship_date** | **Time** | | [optional] | +| **status** | **String** | Order Status | [optional] | +| **complete** | **Boolean** | | [optional][default to false] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Order.new(id: null, - pet_id: null, - quantity: null, - ship_date: null, - status: null, - complete: null) +instance = Petstore::Order.new( + id: null, + pet_id: null, + quantity: null, + ship_date: null, + status: null, + complete: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/OuterComposite.md b/samples/client/petstore/ruby/docs/OuterComposite.md index 2716cd298087..f14a9765d0a7 100644 --- a/samples/client/petstore/ruby/docs/OuterComposite.md +++ b/samples/client/petstore/ruby/docs/OuterComposite.md @@ -2,20 +2,21 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**my_number** | **Float** | | [optional] -**my_string** | **String** | | [optional] -**my_boolean** | **Boolean** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **my_number** | **Float** | | [optional] | +| **my_string** | **String** | | [optional] | +| **my_boolean** | **Boolean** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::OuterComposite.new(my_number: null, - my_string: null, - my_boolean: null) +instance = Petstore::OuterComposite.new( + my_number: null, + my_string: null, + my_boolean: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/OuterEnum.md b/samples/client/petstore/ruby/docs/OuterEnum.md index e919b6bc78ba..3e82b93d05c4 100644 --- a/samples/client/petstore/ruby/docs/OuterEnum.md +++ b/samples/client/petstore/ruby/docs/OuterEnum.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnum.new() ``` - diff --git a/samples/client/petstore/ruby/docs/OuterEnumDefaultValue.md b/samples/client/petstore/ruby/docs/OuterEnumDefaultValue.md index 01dc64511ecb..3ea073b2dabc 100644 --- a/samples/client/petstore/ruby/docs/OuterEnumDefaultValue.md +++ b/samples/client/petstore/ruby/docs/OuterEnumDefaultValue.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnumDefaultValue.new() ``` - diff --git a/samples/client/petstore/ruby/docs/OuterEnumInteger.md b/samples/client/petstore/ruby/docs/OuterEnumInteger.md index 4463ff29c957..0c401c428a34 100644 --- a/samples/client/petstore/ruby/docs/OuterEnumInteger.md +++ b/samples/client/petstore/ruby/docs/OuterEnumInteger.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnumInteger.new() ``` - diff --git a/samples/client/petstore/ruby/docs/OuterEnumIntegerDefaultValue.md b/samples/client/petstore/ruby/docs/OuterEnumIntegerDefaultValue.md index 1623eeaef87a..9f5fda16a7be 100644 --- a/samples/client/petstore/ruby/docs/OuterEnumIntegerDefaultValue.md +++ b/samples/client/petstore/ruby/docs/OuterEnumIntegerDefaultValue.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::OuterEnumIntegerDefaultValue.new() ``` - diff --git a/samples/client/petstore/ruby/docs/Pet.md b/samples/client/petstore/ruby/docs/Pet.md index efee63091e47..e87c6321c7c5 100644 --- a/samples/client/petstore/ruby/docs/Pet.md +++ b/samples/client/petstore/ruby/docs/Pet.md @@ -2,26 +2,27 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**category** | [**Category**](Category.md) | | [optional] -**name** | **String** | | -**photo_urls** | **Array<String>** | | -**tags** | [**Array<Tag>**](Tag.md) | | [optional] -**status** | **String** | pet status in the store | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **category** | [**Category**](Category.md) | | [optional] | +| **name** | **String** | | | +| **photo_urls** | **Array<String>** | | | +| **tags** | [**Array<Tag>**](Tag.md) | | [optional] | +| **status** | **String** | pet status in the store | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Pet.new(id: null, - category: null, - name: doggie, - photo_urls: null, - tags: null, - status: null) +instance = Petstore::Pet.new( + id: null, + category: null, + name: doggie, + photo_urls: null, + tags: null, + status: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/PetApi.md b/samples/client/petstore/ruby/docs/PetApi.md index 6e650f534b1b..a7aa7c7afbe2 100644 --- a/samples/client/petstore/ruby/docs/PetApi.md +++ b/samples/client/petstore/ruby/docs/PetApi.md @@ -2,18 +2,17 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**add_pet**](PetApi.md#add_pet) | **POST** /pet | Add a new pet to the store -[**delete_pet**](PetApi.md#delete_pet) | **DELETE** /pet/{petId} | Deletes a pet -[**find_pets_by_status**](PetApi.md#find_pets_by_status) | **GET** /pet/findByStatus | Finds Pets by status -[**find_pets_by_tags**](PetApi.md#find_pets_by_tags) | **GET** /pet/findByTags | Finds Pets by tags -[**get_pet_by_id**](PetApi.md#get_pet_by_id) | **GET** /pet/{petId} | Find pet by ID -[**update_pet**](PetApi.md#update_pet) | **PUT** /pet | Update an existing pet -[**update_pet_with_form**](PetApi.md#update_pet_with_form) | **POST** /pet/{petId} | Updates a pet in the store with form data -[**upload_file**](PetApi.md#upload_file) | **POST** /pet/{petId}/uploadImage | uploads an image -[**upload_file_with_required_file**](PetApi.md#upload_file_with_required_file) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required) - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**add_pet**](PetApi.md#add_pet) | **POST** /pet | Add a new pet to the store | +| [**delete_pet**](PetApi.md#delete_pet) | **DELETE** /pet/{petId} | Deletes a pet | +| [**find_pets_by_status**](PetApi.md#find_pets_by_status) | **GET** /pet/findByStatus | Finds Pets by status | +| [**find_pets_by_tags**](PetApi.md#find_pets_by_tags) | **GET** /pet/findByTags | Finds Pets by tags | +| [**get_pet_by_id**](PetApi.md#get_pet_by_id) | **GET** /pet/{petId} | Find pet by ID | +| [**update_pet**](PetApi.md#update_pet) | **PUT** /pet | Update an existing pet | +| [**update_pet_with_form**](PetApi.md#update_pet_with_form) | **POST** /pet/{petId} | Updates a pet in the store with form data | +| [**upload_file**](PetApi.md#upload_file) | **POST** /pet/{petId}/uploadImage | uploads an image | +| [**upload_file_with_required_file**](PetApi.md#upload_file_with_required_file) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required) | ## add_pet @@ -46,10 +45,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet** | [**Pet**](Pet.md) | Pet object that needs to be added to the store | | ### Return type @@ -98,11 +96,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| Pet id to delete | - **api_key** | **String**| | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | Pet id to delete | | +| **api_key** | **String** | | [optional] | ### Return type @@ -151,10 +148,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **status** | [**Array<String>**](String.md)| Status values that need to be considered for filter | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **status** | [**Array<String>**](String.md) | Status values that need to be considered for filter | | ### Return type @@ -203,10 +199,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **tags** | [**Array<String>**](String.md)| Tags to filter by | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **tags** | [**Array<String>**](String.md) | Tags to filter by | | ### Return type @@ -257,10 +252,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet to return | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet to return | | ### Return type @@ -306,10 +300,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet** | [**Pet**](Pet.md) | Pet object that needs to be added to the store | | ### Return type @@ -359,12 +352,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet that needs to be updated | - **name** | **String**| Updated name of the pet | [optional] - **status** | **String**| Updated status of the pet | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet that needs to be updated | | +| **name** | **String** | Updated name of the pet | [optional] | +| **status** | **String** | Updated status of the pet | [optional] | ### Return type @@ -415,12 +407,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet to update | - **additional_metadata** | **String**| Additional data to pass to server | [optional] - **file** | **File**| file to upload | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet to update | | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | +| **file** | **File** | file to upload | [optional] | ### Return type @@ -471,12 +462,11 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet_id** | **Integer**| ID of pet to update | - **required_file** | **File**| file to upload | - **additional_metadata** | **String**| Additional data to pass to server | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **pet_id** | **Integer** | ID of pet to update | | +| **required_file** | **File** | file to upload | | +| **additional_metadata** | **String** | Additional data to pass to server | [optional] | ### Return type diff --git a/samples/client/petstore/ruby/docs/ReadOnlyFirst.md b/samples/client/petstore/ruby/docs/ReadOnlyFirst.md index f8f76a463a14..ef22742e01c4 100644 --- a/samples/client/petstore/ruby/docs/ReadOnlyFirst.md +++ b/samples/client/petstore/ruby/docs/ReadOnlyFirst.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [readonly] -**baz** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **bar** | **String** | | [optional][readonly] | +| **baz** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::ReadOnlyFirst.new(bar: null, - baz: null) +instance = Petstore::ReadOnlyFirst.new( + bar: null, + baz: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/SpecialModelName.md b/samples/client/petstore/ruby/docs/SpecialModelName.md index 498ab811683a..0a8007f80247 100644 --- a/samples/client/petstore/ruby/docs/SpecialModelName.md +++ b/samples/client/petstore/ruby/docs/SpecialModelName.md @@ -2,16 +2,17 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**special_property_name** | **Integer** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **special_property_name** | **Integer** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::SpecialModelName.new(special_property_name: null) +instance = Petstore::SpecialModelName.new( + special_property_name: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/StoreApi.md b/samples/client/petstore/ruby/docs/StoreApi.md index ffbc1d04b1ef..58aeeb82fc14 100644 --- a/samples/client/petstore/ruby/docs/StoreApi.md +++ b/samples/client/petstore/ruby/docs/StoreApi.md @@ -2,13 +2,12 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**delete_order**](StoreApi.md#delete_order) | **DELETE** /store/order/{order_id} | Delete purchase order by ID -[**get_inventory**](StoreApi.md#get_inventory) | **GET** /store/inventory | Returns pet inventories by status -[**get_order_by_id**](StoreApi.md#get_order_by_id) | **GET** /store/order/{order_id} | Find purchase order by ID -[**place_order**](StoreApi.md#place_order) | **POST** /store/order | Place an order for a pet - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**delete_order**](StoreApi.md#delete_order) | **DELETE** /store/order/{order_id} | Delete purchase order by ID | +| [**get_inventory**](StoreApi.md#get_inventory) | **GET** /store/inventory | Returns pet inventories by status | +| [**get_order_by_id**](StoreApi.md#get_order_by_id) | **GET** /store/order/{order_id} | Find purchase order by ID | +| [**place_order**](StoreApi.md#place_order) | **POST** /store/order | Place an order for a pet | ## delete_order @@ -38,10 +37,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **order_id** | **String**| ID of the order that needs to be deleted | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **order_id** | **String** | ID of the order that needs to be deleted | | ### Return type @@ -135,10 +133,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **order_id** | **Integer**| ID of pet that needs to be fetched | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **order_id** | **Integer** | ID of pet that needs to be fetched | | ### Return type @@ -180,10 +177,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **order** | [**Order**](Order.md)| order placed for purchasing the pet | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **order** | [**Order**](Order.md) | order placed for purchasing the pet | | ### Return type diff --git a/samples/client/petstore/ruby/docs/Tag.md b/samples/client/petstore/ruby/docs/Tag.md index 54a66a3f294b..30b8363f831a 100644 --- a/samples/client/petstore/ruby/docs/Tag.md +++ b/samples/client/petstore/ruby/docs/Tag.md @@ -2,18 +2,19 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**name** | **String** | | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **name** | **String** | | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::Tag.new(id: null, - name: null) +instance = Petstore::Tag.new( + id: null, + name: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/User.md b/samples/client/petstore/ruby/docs/User.md index 263e96046620..1d45aa900b49 100644 --- a/samples/client/petstore/ruby/docs/User.md +++ b/samples/client/petstore/ruby/docs/User.md @@ -2,30 +2,31 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **Integer** | | [optional] -**username** | **String** | | [optional] -**first_name** | **String** | | [optional] -**last_name** | **String** | | [optional] -**email** | **String** | | [optional] -**password** | **String** | | [optional] -**phone** | **String** | | [optional] -**user_status** | **Integer** | User Status | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **id** | **Integer** | | [optional] | +| **username** | **String** | | [optional] | +| **first_name** | **String** | | [optional] | +| **last_name** | **String** | | [optional] | +| **email** | **String** | | [optional] | +| **password** | **String** | | [optional] | +| **phone** | **String** | | [optional] | +| **user_status** | **Integer** | User Status | [optional] | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' -instance = Petstore::User.new(id: null, - username: null, - first_name: null, - last_name: null, - email: null, - password: null, - phone: null, - user_status: null) +instance = Petstore::User.new( + id: null, + username: null, + first_name: null, + last_name: null, + email: null, + password: null, + phone: null, + user_status: null +) ``` - diff --git a/samples/client/petstore/ruby/docs/UserApi.md b/samples/client/petstore/ruby/docs/UserApi.md index 631a65ef1f19..d5c42199234c 100644 --- a/samples/client/petstore/ruby/docs/UserApi.md +++ b/samples/client/petstore/ruby/docs/UserApi.md @@ -2,17 +2,16 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**create_user**](UserApi.md#create_user) | **POST** /user | Create user -[**create_users_with_array_input**](UserApi.md#create_users_with_array_input) | **POST** /user/createWithArray | Creates list of users with given input array -[**create_users_with_list_input**](UserApi.md#create_users_with_list_input) | **POST** /user/createWithList | Creates list of users with given input array -[**delete_user**](UserApi.md#delete_user) | **DELETE** /user/{username} | Delete user -[**get_user_by_name**](UserApi.md#get_user_by_name) | **GET** /user/{username} | Get user by user name -[**login_user**](UserApi.md#login_user) | **GET** /user/login | Logs user into the system -[**logout_user**](UserApi.md#logout_user) | **GET** /user/logout | Logs out current logged in user session -[**update_user**](UserApi.md#update_user) | **PUT** /user/{username} | Updated user - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**create_user**](UserApi.md#create_user) | **POST** /user | Create user | +| [**create_users_with_array_input**](UserApi.md#create_users_with_array_input) | **POST** /user/createWithArray | Creates list of users with given input array | +| [**create_users_with_list_input**](UserApi.md#create_users_with_list_input) | **POST** /user/createWithList | Creates list of users with given input array | +| [**delete_user**](UserApi.md#delete_user) | **DELETE** /user/{username} | Delete user | +| [**get_user_by_name**](UserApi.md#get_user_by_name) | **GET** /user/{username} | Get user by user name | +| [**login_user**](UserApi.md#login_user) | **GET** /user/login | Logs user into the system | +| [**logout_user**](UserApi.md#logout_user) | **GET** /user/logout | Logs out current logged in user session | +| [**update_user**](UserApi.md#update_user) | **PUT** /user/{username} | Updated user | ## create_user @@ -42,10 +41,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**User**](User.md)| Created user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **user** | [**User**](User.md) | Created user object | | ### Return type @@ -86,10 +84,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**Array<User>**](User.md)| List of user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **user** | [**Array<User>**](User.md) | List of user object | | ### Return type @@ -130,10 +127,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**Array<User>**](User.md)| List of user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **user** | [**Array<User>**](User.md) | List of user object | | ### Return type @@ -176,10 +172,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The name that needs to be deleted | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | The name that needs to be deleted | | ### Return type @@ -221,10 +216,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The name that needs to be fetched. Use user1 for testing. | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | The name that needs to be fetched. Use user1 for testing. | | ### Return type @@ -267,11 +261,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The user name for login | - **password** | **String**| The password for login in clear text | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | The user name for login | | +| **password** | **String** | The password for login in clear text | | ### Return type @@ -355,11 +348,10 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| name that need to be deleted | - **user** | [**User**](User.md)| Updated user object | +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **username** | **String** | name that need to be deleted | | +| **user** | [**User**](User.md) | Updated user object | | ### Return type diff --git a/samples/client/petstore/ruby/lib/petstore/api_client.rb b/samples/client/petstore/ruby/lib/petstore/api_client.rb index 57b1436f5359..f6f0c33deb7d 100644 --- a/samples/client/petstore/ruby/lib/petstore/api_client.rb +++ b/samples/client/petstore/ruby/lib/petstore/api_client.rb @@ -275,8 +275,9 @@ def convert_to_type(data, return_type) data.each { |k, v| hash[k] = convert_to_type(v, sub_type) } end else - # models, e.g. Pet - Petstore.const_get(return_type).build_from_hash(data) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(return_type) + klass.respond_to?(:openapi_one_of) ? klass.build(data) : klass.build_from_hash(data) end end diff --git a/samples/client/petstore/ruby/lib/petstore/models/additional_properties_class.rb b/samples/client/petstore/ruby/lib/petstore/models/additional_properties_class.rb index d46bd4319e2a..77c032dea137 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/additional_properties_class.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/additional_properties_class.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -169,7 +174,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -195,7 +202,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -220,4 +227,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/animal.rb b/samples/client/petstore/ruby/lib/petstore/models/animal.rb index 715abed1f308..a6a8af1493c7 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/animal.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/animal.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -177,7 +182,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -203,7 +210,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -228,4 +235,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/api_response.rb b/samples/client/petstore/ruby/lib/petstore/models/api_response.rb index 9b3e689c71e4..a56b3b266dcf 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/api_response.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/api_response.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -174,7 +179,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -200,7 +207,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -225,4 +232,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/array_of_array_of_number_only.rb b/samples/client/petstore/ruby/lib/petstore/models/array_of_array_of_number_only.rb index 01a9cf6f4833..c392808c38ce 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/array_of_array_of_number_only.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/array_of_array_of_number_only.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/array_of_number_only.rb b/samples/client/petstore/ruby/lib/petstore/models/array_of_number_only.rb index 9768ba2f112a..d199d345d248 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/array_of_number_only.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/array_of_number_only.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/array_test.rb b/samples/client/petstore/ruby/lib/petstore/models/array_test.rb index 3538d1135315..2c42ad392c1e 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/array_test.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/array_test.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -180,7 +185,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -206,7 +213,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -231,4 +238,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/capitalization.rb b/samples/client/petstore/ruby/lib/petstore/models/capitalization.rb index 5fc7ad3b6efb..9540dbba0931 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/capitalization.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/capitalization.rb @@ -40,6 +40,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -202,7 +207,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -228,7 +235,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -253,4 +260,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/cat.rb b/samples/client/petstore/ruby/lib/petstore/models/cat.rb index 479b0441dc04..c46e1ab547f7 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/cat.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/cat.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about, including the ones defined in its parent(s) + def self.acceptable_attributes + attribute_map.values.concat(superclass.acceptable_attributes) + end + # Attribute type mapping. def self.openapi_types { @@ -168,7 +173,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -194,7 +201,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -219,4 +226,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/cat_all_of.rb b/samples/client/petstore/ruby/lib/petstore/models/cat_all_of.rb index b5bed52844eb..328946157b0b 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/cat_all_of.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/cat_all_of.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/category.rb b/samples/client/petstore/ruby/lib/petstore/models/category.rb index 306182291559..00cc38a26790 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/category.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/category.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -172,7 +177,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -198,7 +205,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -223,4 +230,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/class_model.rb b/samples/client/petstore/ruby/lib/petstore/models/class_model.rb index 9894e959e53b..cad08030a81a 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/class_model.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/class_model.rb @@ -25,6 +25,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -157,7 +162,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -183,7 +190,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -208,4 +215,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/client.rb b/samples/client/petstore/ruby/lib/petstore/models/client.rb index 7ad4b37cca71..8922e4cffe8c 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/client.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/client.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/dog.rb b/samples/client/petstore/ruby/lib/petstore/models/dog.rb index 362c2cc5d003..221d2b16309c 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/dog.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/dog.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about, including the ones defined in its parent(s) + def self.acceptable_attributes + attribute_map.values.concat(superclass.acceptable_attributes) + end + # Attribute type mapping. def self.openapi_types { @@ -168,7 +173,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -194,7 +201,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -219,4 +226,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/dog_all_of.rb b/samples/client/petstore/ruby/lib/petstore/models/dog_all_of.rb index 0dcb8c32a0ef..b7771c8910bf 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/dog_all_of.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/dog_all_of.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/enum_arrays.rb b/samples/client/petstore/ruby/lib/petstore/models/enum_arrays.rb index d5069f095b10..fe69026a5e58 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/enum_arrays.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/enum_arrays.rb @@ -49,6 +49,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -201,7 +206,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -227,7 +234,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -252,4 +259,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/enum_test.rb b/samples/client/petstore/ruby/lib/petstore/models/enum_test.rb index e9f474b3c5d0..b695d551922e 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/enum_test.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/enum_test.rb @@ -67,6 +67,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -299,7 +304,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -325,7 +332,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -350,4 +357,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/file.rb b/samples/client/petstore/ruby/lib/petstore/models/file.rb index 6b2b307ee41a..97e055c1692f 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/file.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/file.rb @@ -26,6 +26,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/file_schema_test_class.rb b/samples/client/petstore/ruby/lib/petstore/models/file_schema_test_class.rb index dca470b02aba..856aeb716aa2 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/file_schema_test_class.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/file_schema_test_class.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -167,7 +172,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -193,7 +200,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -218,4 +225,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/foo.rb b/samples/client/petstore/ruby/lib/petstore/models/foo.rb index 70853138f796..fbafcb86cd58 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/foo.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/foo.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/format_test.rb b/samples/client/petstore/ruby/lib/petstore/models/format_test.rb index 34a2fd575dbe..b4b408fa9488 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/format_test.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/format_test.rb @@ -71,6 +71,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -516,7 +521,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -542,7 +549,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -567,4 +574,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/has_only_read_only.rb b/samples/client/petstore/ruby/lib/petstore/models/has_only_read_only.rb index 5dedaaf51495..a076ce2e1c07 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/has_only_read_only.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/has_only_read_only.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -165,7 +170,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -191,7 +198,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -216,4 +223,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/health_check_result.rb b/samples/client/petstore/ruby/lib/petstore/models/health_check_result.rb index 7e4529365edb..6de974d91cb5 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/health_check_result.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/health_check_result.rb @@ -25,6 +25,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -158,7 +163,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -184,7 +191,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -209,4 +216,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/inline_object.rb b/samples/client/petstore/ruby/lib/petstore/models/inline_object.rb index 85e30d1674c4..ab30d0a7cdb3 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/inline_object.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/inline_object.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -167,7 +172,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -193,7 +200,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -218,4 +225,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/inline_object1.rb b/samples/client/petstore/ruby/lib/petstore/models/inline_object1.rb index b566d0101193..7fda668343de 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/inline_object1.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/inline_object1.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -167,7 +172,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -193,7 +200,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -218,4 +225,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/inline_object2.rb b/samples/client/petstore/ruby/lib/petstore/models/inline_object2.rb index a7e862c4b42f..4218ff5c090b 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/inline_object2.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/inline_object2.rb @@ -51,6 +51,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -205,7 +210,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -231,7 +238,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -256,4 +263,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/inline_object3.rb b/samples/client/petstore/ruby/lib/petstore/models/inline_object3.rb index 6d16653ceb0d..fef4fac9195a 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/inline_object3.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/inline_object3.rb @@ -77,6 +77,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -488,7 +493,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -514,7 +521,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -539,4 +546,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/inline_object4.rb b/samples/client/petstore/ruby/lib/petstore/models/inline_object4.rb index 56bf6510edc4..cec629a73420 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/inline_object4.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/inline_object4.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -177,7 +182,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -203,7 +210,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -228,4 +235,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/inline_object5.rb b/samples/client/petstore/ruby/lib/petstore/models/inline_object5.rb index 78da991c505a..b6f800cb1be5 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/inline_object5.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/inline_object5.rb @@ -29,6 +29,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -172,7 +177,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -198,7 +205,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -223,4 +230,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/inline_response_default.rb b/samples/client/petstore/ruby/lib/petstore/models/inline_response_default.rb index 076ff2c3c251..d10840aa71be 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/inline_response_default.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/inline_response_default.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/list.rb b/samples/client/petstore/ruby/lib/petstore/models/list.rb index 56a18b30738c..53b4b712a0a8 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/list.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/list.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/map_test.rb b/samples/client/petstore/ruby/lib/petstore/models/map_test.rb index 334e2c5b7780..014d6b8a8db0 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/map_test.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/map_test.rb @@ -55,6 +55,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -213,7 +218,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -239,7 +246,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -264,4 +271,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/mixed_properties_and_additional_properties_class.rb b/samples/client/petstore/ruby/lib/petstore/models/mixed_properties_and_additional_properties_class.rb index 570f0a521bcd..293cdcdc5b9b 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/mixed_properties_and_additional_properties_class.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/mixed_properties_and_additional_properties_class.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -176,7 +181,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -202,7 +209,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -227,4 +234,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/model200_response.rb b/samples/client/petstore/ruby/lib/petstore/models/model200_response.rb index 995912aa9060..750e1b6459c8 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/model200_response.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/model200_response.rb @@ -28,6 +28,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -166,7 +171,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -192,7 +199,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -217,4 +224,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/model_return.rb b/samples/client/petstore/ruby/lib/petstore/models/model_return.rb index aa78a6a89aac..ce3e88c2b3e6 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/model_return.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/model_return.rb @@ -25,6 +25,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -157,7 +162,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -183,7 +190,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -208,4 +215,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/name.rb b/samples/client/petstore/ruby/lib/petstore/models/name.rb index d79d9f71dc72..fc10db2a4c81 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/name.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/name.rb @@ -34,6 +34,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -189,7 +194,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -215,7 +222,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -240,4 +247,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/nullable_class.rb b/samples/client/petstore/ruby/lib/petstore/models/nullable_class.rb index 5f8c2372eaea..2193ccd7228a 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/nullable_class.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/nullable_class.rb @@ -57,6 +57,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -277,7 +282,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -303,7 +310,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -328,4 +335,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/number_only.rb b/samples/client/petstore/ruby/lib/petstore/models/number_only.rb index adcfa322f308..23387d216c8e 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/number_only.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/number_only.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/order.rb b/samples/client/petstore/ruby/lib/petstore/models/order.rb index 41c93ac0fe03..5ec9b5ff4ee3 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/order.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/order.rb @@ -62,6 +62,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -238,7 +243,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -264,7 +271,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -289,4 +296,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/outer_composite.rb b/samples/client/petstore/ruby/lib/petstore/models/outer_composite.rb index 522dc7a30fab..d6c5f2b0351b 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/outer_composite.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/outer_composite.rb @@ -30,6 +30,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -174,7 +179,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -200,7 +207,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -225,4 +232,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/pet.rb b/samples/client/petstore/ruby/lib/petstore/models/pet.rb index 33d2b76e09ff..f802b6344e2f 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/pet.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/pet.rb @@ -62,6 +62,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -250,7 +255,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -276,7 +283,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -301,4 +308,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/read_only_first.rb b/samples/client/petstore/ruby/lib/petstore/models/read_only_first.rb index 3bf11964755e..4b530283796d 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/read_only_first.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/read_only_first.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -165,7 +170,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -191,7 +198,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -216,4 +223,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/special_model_name.rb b/samples/client/petstore/ruby/lib/petstore/models/special_model_name.rb index 1c0b391bc312..ae309ee47083 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/special_model_name.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/special_model_name.rb @@ -24,6 +24,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -156,7 +161,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -182,7 +189,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -207,4 +214,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/tag.rb b/samples/client/petstore/ruby/lib/petstore/models/tag.rb index 5715f75ce55a..f4126dd42859 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/tag.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/tag.rb @@ -27,6 +27,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -165,7 +170,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -191,7 +198,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -216,4 +223,5 @@ def _to_hash(value) end end + end diff --git a/samples/client/petstore/ruby/lib/petstore/models/user.rb b/samples/client/petstore/ruby/lib/petstore/models/user.rb index 768898f4f5b7..b25915909755 100644 --- a/samples/client/petstore/ruby/lib/petstore/models/user.rb +++ b/samples/client/petstore/ruby/lib/petstore/models/user.rb @@ -46,6 +46,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -220,7 +225,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -246,7 +253,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -271,4 +278,5 @@ def _to_hash(value) end end + end diff --git a/samples/openapi3/client/features/dynamic-servers/ruby/docs/UsageApi.md b/samples/openapi3/client/features/dynamic-servers/ruby/docs/UsageApi.md index decedf4a1f70..bc5fce612774 100644 --- a/samples/openapi3/client/features/dynamic-servers/ruby/docs/UsageApi.md +++ b/samples/openapi3/client/features/dynamic-servers/ruby/docs/UsageApi.md @@ -2,11 +2,10 @@ All URIs are relative to *http://petstore.swagger.io:80/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**custom_server**](UsageApi.md#custom_server) | **GET** /custom | Use custom server -[**default_server**](UsageApi.md#default_server) | **GET** /default | Use default server - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**custom_server**](UsageApi.md#custom_server) | **GET** /custom | Use custom server | +| [**default_server**](UsageApi.md#default_server) | **GET** /default | Use default server | ## custom_server diff --git a/samples/openapi3/client/features/dynamic-servers/ruby/lib/dynamic_servers/api_client.rb b/samples/openapi3/client/features/dynamic-servers/ruby/lib/dynamic_servers/api_client.rb index f8765e494a1d..54e1498b10d2 100644 --- a/samples/openapi3/client/features/dynamic-servers/ruby/lib/dynamic_servers/api_client.rb +++ b/samples/openapi3/client/features/dynamic-servers/ruby/lib/dynamic_servers/api_client.rb @@ -274,8 +274,9 @@ def convert_to_type(data, return_type) data.each { |k, v| hash[k] = convert_to_type(v, sub_type) } end else - # models, e.g. Pet - DynamicServers.const_get(return_type).build_from_hash(data) + # models (e.g. Pet) or oneOf + klass = DynamicServers.const_get(return_type) + klass.respond_to?(:openapi_one_of) ? klass.build(data) : klass.build_from_hash(data) end end diff --git a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/ArrayAlias.md b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/ArrayAlias.md index aaebce0ffe3e..af57d9ecc38b 100644 --- a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/ArrayAlias.md +++ b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/ArrayAlias.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::ArrayAlias.new() ``` - diff --git a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/MapAlias.md b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/MapAlias.md index d65a613ff9c3..38f5824ca3b4 100644 --- a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/MapAlias.md +++ b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/MapAlias.md @@ -2,15 +2,14 @@ ## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | ## Code Sample ```ruby -require 'Petstore' +require 'petstore' instance = Petstore::MapAlias.new() ``` - diff --git a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/UsageApi.md b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/UsageApi.md index b1fa34ab7d6c..c35231e744b7 100644 --- a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/UsageApi.md +++ b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/docs/UsageApi.md @@ -2,11 +2,10 @@ All URIs are relative to *http://petstore.swagger.io/v2* -Method | HTTP request | Description -------------- | ------------- | ------------- -[**array**](UsageApi.md#array) | **GET** /array | Use alias to array -[**map**](UsageApi.md#map) | **GET** /map | Use alias to map - +| Method | HTTP request | Description | +| ------ | ------------ | ----------- | +| [**array**](UsageApi.md#array) | **GET** /array | Use alias to array | +| [**map**](UsageApi.md#map) | **GET** /map | Use alias to map | ## array @@ -39,10 +38,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **array_alias** | [**ArrayAlias**](ArrayAlias.md)| | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **array_alias** | [**ArrayAlias**](ArrayAlias.md) | | [optional] | ### Return type @@ -88,10 +86,9 @@ end ### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **map_alias** | [**MapAlias**](MapAlias.md)| | [optional] +| Name | Type | Description | Notes | +| ---- | ---- | ----------- | ----- | +| **map_alias** | [**MapAlias**](MapAlias.md) | | [optional] | ### Return type diff --git a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/api_client.rb b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/api_client.rb index 4b280426e313..0d903d89d203 100644 --- a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/api_client.rb +++ b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/api_client.rb @@ -274,8 +274,9 @@ def convert_to_type(data, return_type) data.each { |k, v| hash[k] = convert_to_type(v, sub_type) } end else - # models, e.g. Pet - Petstore.const_get(return_type).build_from_hash(data) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(return_type) + klass.respond_to?(:openapi_one_of) ? klass.build(data) : klass.build_from_hash(data) end end diff --git a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/array_alias.rb b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/array_alias.rb index 67be5c444e1a..f416c6a53d2d 100644 --- a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/array_alias.rb +++ b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/array_alias.rb @@ -21,6 +21,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about, including the ones defined in its parent(s) + def self.acceptable_attributes + attribute_map.values.concat(superclass.acceptable_attributes) + end + # Attribute type mapping. def self.openapi_types { @@ -151,7 +156,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -177,7 +184,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -202,4 +209,5 @@ def _to_hash(value) end end + end diff --git a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/map_alias.rb b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/map_alias.rb index 2df647419d65..0682c01b4cd4 100644 --- a/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/map_alias.rb +++ b/samples/openapi3/client/features/generate-alias-as-model/ruby-client/lib/petstore/models/map_alias.rb @@ -21,6 +21,11 @@ def self.attribute_map } end + # Returns all the JSON keys this model knows about + def self.acceptable_attributes + attribute_map.values + end + # Attribute type mapping. def self.openapi_types { @@ -147,7 +152,9 @@ def _deserialize(type, value) end end else # model - Petstore.const_get(type).build_from_hash(value) + # models (e.g. Pet) or oneOf + klass = Petstore.const_get(type) + klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value) end end @@ -173,7 +180,7 @@ def to_hash is_nullable = self.class.openapi_nullable.include?(attr) next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}")) end - + hash[param] = _to_hash(value) end hash @@ -198,4 +205,5 @@ def _to_hash(value) end end + end