fix decimal mapping (#7875)

This commit is contained in:
William Cheng 2020-11-08 11:46:33 +08:00 committed by GitHub
parent 08fb59009a
commit eacf61de7e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
32 changed files with 53 additions and 53 deletions

View File

@ -217,7 +217,7 @@ public class Swift5ClientCodegen extends DefaultCodegen implements CodegenConfig
typeMapping.put("ByteArray", "Data");
typeMapping.put("UUID", "UUID");
typeMapping.put("URI", "String");
typeMapping.put("BigDecimal", "Decimal");
typeMapping.put("decimal", "Decimal");
typeMapping.put("object", "Any");
typeMapping.put("AnyType", "Any");

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -26,7 +26,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let pet = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let pet = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(pet: pet) { (response, error) in
@ -274,7 +274,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let pet = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let pet = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(pet: pet) { (response, error) in

View File

@ -244,7 +244,7 @@ internal class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
internal func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(_id: 123, category: Category(_id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(_id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(_id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(_id: 123, category: Category(_id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(_id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(_id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -216,7 +216,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body).then {
// when the promise is fulfilled

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body).then {
@ -260,7 +260,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body).then {

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -192,7 +192,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
// TODO RxSwift sample code not yet implemented. To contribute, please open a ticket via http://github.com/OpenAPITools/openapi-generator/issues/new
```

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// TODO RxSwift sample code not yet implemented. To contribute, please open a ticket via http://github.com/OpenAPITools/openapi-generator/issues/new
```
@ -225,7 +225,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// TODO RxSwift sample code not yet implemented. To contribute, please open a ticket via http://github.com/OpenAPITools/openapi-generator/issues/new
```

View File

@ -244,7 +244,7 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
}
open func buildHeaders() -> [String: String] {
var httpHeaders: [String : String] = [:]
var httpHeaders: [String: String] = [:]
for (key, value) in self.headers {
httpHeaders[key] = value
}

View File

@ -228,7 +228,7 @@ For this test, the body for this request much reference a schema named `File`.
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = FileSchemaTestClass(file: File(sourceURI: "sourceURI_example"), files: [File(sourceURI: "sourceURI_example")]) // FileSchemaTestClass |
let body = FileSchemaTestClass(file: {...}, files: [{...}]) // FileSchemaTestClass |
FakeAPI.testBodyWithFileSchema(body: body) { (response, error) in
guard error == nil else {

View File

@ -27,7 +27,7 @@ Add a new pet to the store
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Add a new pet to the store
PetAPI.addPet(body: body) { (response, error) in
@ -275,7 +275,7 @@ Update an existing pet
// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import PetstoreClient
let body = Pet(id: 123, category: Category(id: 123, name: "name_example"), name: "name_example", photoUrls: ["photoUrls_example"], tags: [Tag(id: 123, name: "name_example")], status: "status_example") // Pet | Pet object that needs to be added to the store
let body = Pet(id: 123, category: {...}, name: "name_example", photoUrls: ["photoUrls_example"], tags: [{...}], status: "status_example") // Pet | Pet object that needs to be added to the store
// Update an existing pet
PetAPI.updatePet(body: body) { (response, error) in