Fix CircleCI failures (#9503)

* Fix go-echo-server sample not running in CircleCI

* remove wrong argument

* [dart] Fix petstore sample tests & Multipart not working

* follow up to #9392
* `MultipartRequest(null, null)` is no longer valid after `http` package upgrade
* fix petstore sample project not compiling
* disable live petstore tests
* use template to strip out unused code blocks
This commit is contained in:
Peter Leibiger 2021-05-18 17:09:29 +02:00 committed by GitHub
parent 93166dd6b5
commit 55b95bc9c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
29 changed files with 298 additions and 1586 deletions

View File

@ -99,12 +99,9 @@ class {{{classname}}} {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[{{#authMethods}}'{{{name}}}'{{^-last}}, {{/-last}}{{/authMethods}}]; final authNames = <String>[{{#authMethods}}'{{{name}}}'{{^-last}}, {{/-last}}{{/authMethods}}];
if ( {{#isMultipart}}
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false; bool hasFields = false;
final mp = MultipartRequest(null, null); final mp = MultipartRequest('{{{httpMethod}}}', Uri.parse(path));
{{#formParams}} {{#formParams}}
{{^isFile}} {{^isFile}}
if ({{{paramName}}} != null) { if ({{{paramName}}} != null) {
@ -123,7 +120,8 @@ class {{{classname}}} {
if (hasFields) { if (hasFields) {
postBody = mp; postBody = mp;
} }
} else { {{/isMultipart}}
{{^isMultipart}}
{{#formParams}} {{#formParams}}
{{^isFile}} {{^isFile}}
if ({{{paramName}}} != null) { if ({{{paramName}}} != null) {
@ -131,7 +129,7 @@ class {{{classname}}} {
} }
{{/isFile}} {{/isFile}}
{{/formParams}} {{/formParams}}
} {{/isMultipart}}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -1,2 +0,0 @@
analyzer:
strong-mode: true

View File

@ -1,13 +1,18 @@
name: petstore_client name: petstore_client
version: 1.0.0 version: 1.0.0
description: Petstore client using OpenAPI library description: Petstore client using OpenAPI library
publish_to: none
environment: environment:
sdk: '>=2.5.0 <3.0.0' sdk: '>=2.11.0 <3.0.0'
dependencies: dependencies:
openapi: openapi:
path: ../petstore_client_lib path: ../petstore_client_lib
dev_dependencies: dev_dependencies:
test: ^1.8.0 test: ^1.8.0
mockito: ^4.1.1 mockito: ^4.1.1
http: ^0.12.0 http: ^0.13.0
collection: ^1.14.12 collection: ^1.14.12

View File

@ -21,9 +21,9 @@ class FakeClient extends Fake implements Client {
this.expectedPutRequestBody, this.expectedPutRequestBody,
this.putResponseBody, this.putResponseBody,
this.sendResponseBody, this.sendResponseBody,
this.expectedUrl, String expectedUrl,
this.expectedHeaders = null, this.expectedHeaders = null,
}); }) : this.expectedUrl = Uri.parse(expectedUrl);
Exception throwException; Exception throwException;
Object expectedPostRequestBody; Object expectedPostRequestBody;
@ -34,12 +34,12 @@ class FakeClient extends Fake implements Client {
String expectedPutRequestBody; String expectedPutRequestBody;
String putResponseBody; String putResponseBody;
String sendResponseBody; String sendResponseBody;
String expectedUrl; Uri expectedUrl;
Map<String, String> expectedHeaders; Map<String, String> expectedHeaders;
@override @override
Future<Response> post(url, Future<Response> post(Uri url,
{Map<String, String> headers, body, Encoding encoding}) async { {Map<String, String> headers, Object body, Encoding encoding}) async {
// check that the request was made with expected values // check that the request was made with expected values
if (url != expectedUrl) { if (url != expectedUrl) {
throw StateError( throw StateError(
@ -67,7 +67,7 @@ class FakeClient extends Fake implements Client {
} }
@override @override
Future<Response> get(url, {Map<String, String> headers}) async { Future<Response> get(Uri url, {Map<String, String> headers}) async {
// check that the request was made with expected values // check that the request was made with expected values
if (url != expectedUrl) { if (url != expectedUrl) {
throw StateError( throw StateError(
@ -85,7 +85,8 @@ class FakeClient extends Fake implements Client {
} }
@override @override
Future<Response> delete(url, {Map<String, String> headers}) async { Future<Response> delete(Uri url,
{Map<String, String> headers, Object body, Encoding encoding}) async {
// check that the request was made with expected values // check that the request was made with expected values
if (url != expectedUrl) { if (url != expectedUrl) {
throw StateError( throw StateError(
@ -103,8 +104,8 @@ class FakeClient extends Fake implements Client {
} }
@override @override
Future<Response> put(url, Future<Response> put(Uri url,
{Map<String, String> headers, body, Encoding encoding}) async { {Map<String, String> headers, Object body, Encoding encoding}) async {
// check that the request was made with expected values // check that the request was made with expected values
if (url != expectedUrl) { if (url != expectedUrl) {
throw StateError( throw StateError(

View File

@ -26,11 +26,10 @@ void main() {
..id = 124321 ..id = 124321
..name = 'Jose' ..name = 'Jose'
]; ];
return Pet() return Pet(name: name)
..id = id ..id = id
..category = category ..category = category
..tags = tags ..tags = tags
..name = name
..status = PetStatusEnum.fromJson(status) ..status = PetStatusEnum.fromJson(status)
..photoUrls = ['https://petstore.com/sample/photo1.jpg']; ..photoUrls = ['https://petstore.com/sample/photo1.jpg'];
} }
@ -53,8 +52,7 @@ void main() {
// use the pet api to add a pet // use the pet api to add a pet
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/pet', expectedUrl: 'http://petstore.swagger.io/v2/pet',
expectedPostRequestBody: expectedPostRequestBody: await petApi.apiClient.serializeAsync(newPet),
await petApi.apiClient.serializeAsync(newPet),
postResponseBody: await petApi.apiClient.serializeAsync(newPet), postResponseBody: await petApi.apiClient.serializeAsync(newPet),
expectedHeaders: {'Content-Type': 'application/json'}); expectedHeaders: {'Content-Type': 'application/json'});
await petApi.addPet(newPet); await petApi.addPet(newPet);
@ -76,8 +74,7 @@ void main() {
expectedUrl: 'http://petstore.swagger.io/v2/pet/$id', expectedUrl: 'http://petstore.swagger.io/v2/pet/$id',
throwException: ApiException(400, 'not found'), throwException: ApiException(400, 'not found'),
); );
expect( expect(petApi.getPetById(id), throwsA(equals(TypeMatcher<ApiException>())));
petApi.getPetById(id), throwsA(equals(TypeMatcher<ApiException>())));
}); });
test('deletes existing pet by id', () async { test('deletes existing pet by id', () async {
@ -87,8 +84,7 @@ void main() {
// add a new pet // add a new pet
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/pet', expectedUrl: 'http://petstore.swagger.io/v2/pet',
expectedPostRequestBody: expectedPostRequestBody: await petApi.apiClient.serializeAsync(newPet),
await petApi.apiClient.serializeAsync(newPet),
postResponseBody: await petApi.apiClient.serializeAsync(newPet), postResponseBody: await petApi.apiClient.serializeAsync(newPet),
expectedHeaders: {'Content-Type': 'application/json'}); expectedHeaders: {'Content-Type': 'application/json'});
await petApi.addPet(newPet); await petApi.addPet(newPet);
@ -106,8 +102,7 @@ void main() {
expectedUrl: 'http://petstore.swagger.io/v2/pet/$id', expectedUrl: 'http://petstore.swagger.io/v2/pet/$id',
throwException: ApiException(400, 'Not found'), throwException: ApiException(400, 'Not found'),
); );
expect( expect(petApi.getPetById(id), throwsA(equals(TypeMatcher<ApiException>())));
petApi.getPetById(id), throwsA(equals(TypeMatcher<ApiException>())));
}); });
test('updates pet with form', () async { test('updates pet with form', () async {
@ -117,16 +112,11 @@ void main() {
// add a new pet // add a new pet
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/pet', expectedUrl: 'http://petstore.swagger.io/v2/pet',
expectedPostRequestBody: expectedPostRequestBody: await petApi.apiClient.serializeAsync(newPet),
await petApi.apiClient.serializeAsync(newPet),
postResponseBody: await petApi.apiClient.serializeAsync(newPet), postResponseBody: await petApi.apiClient.serializeAsync(newPet),
expectedHeaders: {'Content-Type': 'application/json'}); expectedHeaders: {'Content-Type': 'application/json'});
await petApi.addPet(newPet); await petApi.addPet(newPet);
final multipartRequest = MultipartRequest(null, null);
multipartRequest.fields['name'] = 'Doge';
multipartRequest.fields['status'] = '';
// update with form // update with form
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/pet/$id', expectedUrl: 'http://petstore.swagger.io/v2/pet/$id',
@ -157,8 +147,7 @@ void main() {
// add a new pet // add a new pet
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/pet', expectedUrl: 'http://petstore.swagger.io/v2/pet',
expectedPostRequestBody: expectedPostRequestBody: await petApi.apiClient.serializeAsync(newPet),
await petApi.apiClient.serializeAsync(newPet),
postResponseBody: await petApi.apiClient.serializeAsync(newPet), postResponseBody: await petApi.apiClient.serializeAsync(newPet),
expectedHeaders: {'Content-Type': 'application/json'}); expectedHeaders: {'Content-Type': 'application/json'});
await petApi.addPet(newPet); await petApi.addPet(newPet);
@ -166,8 +155,7 @@ void main() {
// update the same pet // update the same pet
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/pet', expectedUrl: 'http://petstore.swagger.io/v2/pet',
expectedPutRequestBody: expectedPutRequestBody: await petApi.apiClient.serializeAsync(updatePet),
await petApi.apiClient.serializeAsync(updatePet),
putResponseBody: await petApi.apiClient.serializeAsync(updatePet), putResponseBody: await petApi.apiClient.serializeAsync(updatePet),
expectedHeaders: {'Content-Type': 'application/json'}); expectedHeaders: {'Content-Type': 'application/json'});
await petApi.updatePet(updatePet); await petApi.updatePet(updatePet);
@ -196,15 +184,13 @@ void main() {
// retrieve pets by status // retrieve pets by status
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: expectedUrl: 'http://petstore.swagger.io/v2/pet/findByStatus?status=$status',
'http://petstore.swagger.io/v2/pet/findByStatus?status=$status',
getResponseBody: await petApi.apiClient.serializeAsync([pet1, pet2]), getResponseBody: await petApi.apiClient.serializeAsync([pet1, pet2]),
); );
final pets = await petApi.findPetsByStatus([status]); final pets = await petApi.findPetsByStatus([status]);
// tests serialisation and deserialisation of enum // tests serialisation and deserialisation of enum
final petsByStatus = final petsByStatus = pets.where((p) => p.status == PetStatusEnum.available);
pets.where((p) => p.status == PetStatusEnum.available);
expect(petsByStatus.length, equals(2)); expect(petsByStatus.length, equals(2));
final petIds = pets.map((pet) => pet.id).toList(); final petIds = pets.map((pet) => pet.id).toList();
expect(petIds, contains(id1)); expect(petIds, contains(id1));
@ -216,14 +202,12 @@ void main() {
final id = newId(); final id = newId();
final newPet = makePet(id: id); final newPet = makePet(id: id);
// get some test data (recorded from live response) // get some test data (recorded from live response)
final uploadResponse = final uploadResponse = await File('test/file_upload_response.json').readAsString();
await File('test/file_upload_response.json').readAsString();
// add a new pet // add a new pet
petApi.apiClient.client = FakeClient( petApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/pet', expectedUrl: 'http://petstore.swagger.io/v2/pet',
expectedPostRequestBody: expectedPostRequestBody: await petApi.apiClient.serializeAsync(newPet),
await petApi.apiClient.serializeAsync(newPet),
postResponseBody: await petApi.apiClient.serializeAsync(newPet), postResponseBody: await petApi.apiClient.serializeAsync(newPet),
expectedHeaders: {'Content-Type': 'application/json'}); expectedHeaders: {'Content-Type': 'application/json'});
await petApi.addPet(newPet); await petApi.addPet(newPet);
@ -232,9 +216,8 @@ void main() {
expectedUrl: 'http://petstore.swagger.io/v2/pet', expectedUrl: 'http://petstore.swagger.io/v2/pet',
sendResponseBody: uploadResponse, sendResponseBody: uploadResponse,
); );
final file = final file = new MultipartFile.fromBytes('file', [104, 101, 108, 108, 111]);
new MultipartFile.fromBytes('file', [104, 101, 108, 108, 111]); await petApi.uploadFile(id, file: file);
await petApi.uploadFile(id, additionalMetadata: '', file: file);
}); });
}); });
} }

View File

@ -1,5 +1,4 @@
import 'dart:async'; @Skip('Needs real petstore')
import 'package:http/http.dart'; import 'package:http/http.dart';
import 'package:openapi/api.dart'; import 'package:openapi/api.dart';
import 'package:test/test.dart'; import 'package:test/test.dart';
@ -46,16 +45,14 @@ void main() {
}); });
test('doesn\'t get non-existing pet by id', () { test('doesn\'t get non-existing pet by id', () {
expect(petApi.getPetById(newId()), expect(petApi.getPetById(newId()), throwsA(equals(TypeMatcher<ApiException>())));
throwsA(equals(TypeMatcher<ApiException>())));
}); });
test('deletes existing pet by id', () async { test('deletes existing pet by id', () async {
var id = newId(); var id = newId();
await petApi.addPet(makePet(id: id)); await petApi.addPet(makePet(id: id));
await petApi.deletePet(id, apiKey: 'special-key'); await petApi.deletePet(id, apiKey: 'special-key');
expect( expect(petApi.getPetById(id), throwsA(equals(TypeMatcher<ApiException>())));
petApi.getPetById(id), throwsA(equals(TypeMatcher<ApiException>())));
}); });
test('updates pet with form', () async { test('updates pet with form', () async {
@ -100,5 +97,5 @@ void main() {
var file = new MultipartFile.fromBytes('file', [104, 101, 108, 108, 111]); var file = new MultipartFile.fromBytes('file', [104, 101, 108, 108, 111]);
await petApi.uploadFile(id, additionalMetadata: '', file: file); await petApi.uploadFile(id, additionalMetadata: '', file: file);
}); });
}, skip: 'e2e tests for CI'); });
} }

View File

@ -21,62 +21,56 @@ void main() {
group('Store API with faked client', () { group('Store API with faked client', () {
test('places an order and gets it by id', () async { test('places an order and gets it by id', () async {
// TODO: Please uncomment this after a content type of the petstore order in petstore.yaml is fixed. final id = newId();
// final id = newId(); final newOrder = makeOrder(id: id);
// final newOrder = makeOrder(id: id);
// // use the store api to add an order // use the store api to add an order
// storeApi.apiClient.client = FakeClient( storeApi.apiClient.client = FakeClient(
// expectedUrl: 'http://petstore.swagger.io/v2/store/order', expectedUrl: 'http://petstore.swagger.io/v2/store/order',
// expectedPostRequestBody: await storeApi.apiClient.serializeAsync(newOrder), expectedPostRequestBody: await storeApi.apiClient.serializeAsync(newOrder),
// postResponseBody: await storeApi.apiClient.serializeAsync(newOrder), postResponseBody: await storeApi.apiClient.serializeAsync(newOrder),
// expectedHeaders: {"Content-Type": "application/json"} expectedHeaders: {"Content-Type": "application/json"});
// ); await storeApi.placeOrder(newOrder);
// await storeApi.placeOrder(newOrder);
// // retrieve the same order by id // retrieve the same order by id
// storeApi.apiClient.client = FakeClient( storeApi.apiClient.client = FakeClient(
// expectedUrl: 'http://petstore.swagger.io/v2/store/order/$id', expectedUrl: 'http://petstore.swagger.io/v2/store/order/$id',
// getResponseBody: await storeApi.apiClient.serializeAsync(newOrder), getResponseBody: await storeApi.apiClient.serializeAsync(newOrder),
// ); );
// final placedOrder = await storeApi.getOrderById(id); final placedOrder = await storeApi.getOrderById(id);
// expect(placedOrder.id, equals(id)); expect(placedOrder.id, equals(id));
}); });
test('deletes an order', () async { test('deletes an order', () async {
// TODO: Please uncomment this after a content type of the petstore order in petstore.yaml is fixed. final id = newId();
// final id = newId(); final newOrder = makeOrder(id: id);
// final newOrder = makeOrder(id: id);
// // use the store api to add an order // use the store api to add an order
// storeApi.apiClient.client = FakeClient( storeApi.apiClient.client = FakeClient(
// expectedUrl: 'http://petstore.swagger.io/v2/store/order', expectedUrl: 'http://petstore.swagger.io/v2/store/order',
// expectedPostRequestBody: await storeApi.apiClient.serializeAsync(newOrder), expectedPostRequestBody: await storeApi.apiClient.serializeAsync(newOrder),
// postResponseBody: await storeApi.apiClient.serializeAsync(newOrder), postResponseBody: await storeApi.apiClient.serializeAsync(newOrder),
// expectedHeaders: {"Content-Type": "application/json"} expectedHeaders: {"Content-Type": "application/json"});
// ); await storeApi.placeOrder(newOrder);
// await storeApi.placeOrder(newOrder);
// // delete the same order // delete the same order
// storeApi.apiClient.client = FakeClient( storeApi.apiClient.client = FakeClient(
// expectedUrl: 'http://petstore.swagger.io/v2/store/order/$id', expectedUrl: 'http://petstore.swagger.io/v2/store/order/$id',
// deleteResponseBody: '', deleteResponseBody: '',
// ); );
// await storeApi.deleteOrder(id.toString()); await storeApi.deleteOrder(id.toString());
// // try and retrieve the order // try and retrieve the order
// storeApi.apiClient.client = FakeClient( storeApi.apiClient.client = FakeClient(
// expectedUrl: 'http://petstore.swagger.io/v2/store/order/$id', expectedUrl: 'http://petstore.swagger.io/v2/store/order/$id',
// throwException: ApiException(400, 'Not found'), throwException: ApiException(400, 'Not found'),
// ); );
// expect(storeApi.getOrderById(id), expect(storeApi.getOrderById(id), throwsA(equals(TypeMatcher<ApiException>())));
// throwsA(equals(TypeMatcher<ApiException>())));
}); });
test('gets the store inventory', () async { test('gets the store inventory', () async {
// get some test data (recorded from live response) // get some test data (recorded from live response)
final inventoryResponse = final inventoryResponse = await File('test/inventory_response.json').readAsString();
await File('test/inventory_response.json').readAsString();
// use the store api to get the inventory // use the store api to get the inventory
storeApi.apiClient.client = FakeClient( storeApi.apiClient.client = FakeClient(
expectedUrl: 'http://petstore.swagger.io/v2/store/inventory', expectedUrl: 'http://petstore.swagger.io/v2/store/inventory',

View File

@ -1,3 +1,4 @@
@Skip('Needs real petstore')
import 'package:openapi/api.dart'; import 'package:openapi/api.dart';
import 'package:test/test.dart'; import 'package:test/test.dart';
@ -18,27 +19,24 @@ void main() {
group('Store API with live client', () { group('Store API with live client', () {
test('places an order and gets it by id', () async { test('places an order and gets it by id', () async {
// TODO: Please uncomment this after a content type of the petstore order in petstore.yaml is fixed. var id = newId();
// var id = newId();
// await storeApi.placeOrder(makeOrder(id: id)); await storeApi.placeOrder(makeOrder(id: id));
// var order = await storeApi.getOrderById(id); var order = await storeApi.getOrderById(id);
// expect(order.id, equals(id)); expect(order.id, equals(id));
}); });
test('deletes an order', () async { test('deletes an order', () async {
// TODO: Please uncomment this after a content type of the petstore order in petstore.yaml is fixed. var id = newId();
// var id = newId();
// await storeApi.placeOrder(makeOrder(id: id)); await storeApi.placeOrder(makeOrder(id: id));
// await storeApi.deleteOrder(id.toString()); await storeApi.deleteOrder(id.toString());
// expect(storeApi.getOrderById(id), expect(storeApi.getOrderById(id), throwsA(equals(TypeMatcher<ApiException>())));
// throwsA(equals(TypeMatcher<ApiException>())));
}); });
test('gets the store inventory', () async { test('gets the store inventory', () async {
Map<String, int> inventory = await storeApi.getInventory(); Map<String, int> inventory = await storeApi.getInventory();
expect(inventory.length, isNot(equals(0))); expect(inventory.length, isNot(equals(0)));
}); });
}); // , skip: 'e2e tests for CI' });
} }

View File

@ -1,3 +1,4 @@
@Skip('Needs real petstore')
import 'package:openapi/api.dart'; import 'package:openapi/api.dart';
import 'package:test/test.dart'; import 'package:test/test.dart';
@ -6,8 +7,7 @@ import 'random_id.dart';
void main() { void main() {
var userApi = new UserApi(); var userApi = new UserApi();
User makeUser( User makeUser({int id, String userName = 'username', String password = 'password'}) {
{int id, String userName = 'username', String password = 'password'}) {
return User() return User()
..id = id ..id = id
..username = userName ..username = userName
@ -63,8 +63,7 @@ void main() {
var username = 'Riddlem325'; var username = 'Riddlem325';
await userApi.createUser(makeUser(id: newId(), userName: username)); await userApi.createUser(makeUser(id: newId(), userName: username));
await userApi.deleteUser(username); await userApi.deleteUser(username);
expect(userApi.getUserByName(username), expect(userApi.getUserByName(username), throwsA(TypeMatcher<ApiException>()));
throwsA(TypeMatcher<ApiException>()));
}); });
test('logs a user in', () async { test('logs a user in', () async {
@ -76,5 +75,5 @@ void main() {
var result = await userApi.loginUser(username, password); var result = await userApi.loginUser(username, password);
expect(result, contains('logged in user session:')); expect(result, contains('logged in user session:'));
}); });
}, skip: 'e2e tests for CI'); });
} }

View File

@ -41,17 +41,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -118,17 +107,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -187,17 +165,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -265,17 +232,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -342,17 +298,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -414,17 +359,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -491,31 +425,12 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (name != null) {
hasFields = true;
mp.fields[r'name'] = parameterToString(name);
}
if (status != null) {
hasFields = true;
mp.fields[r'status'] = parameterToString(status);
}
if (hasFields) {
postBody = mp;
}
} else {
if (name != null) { if (name != null) {
formParams[r'name'] = parameterToString(name); formParams[r'name'] = parameterToString(name);
} }
if (status != null) { if (status != null) {
formParams[r'status'] = parameterToString(status); formParams[r'status'] = parameterToString(status);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -581,12 +496,8 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false; bool hasFields = false;
final mp = MultipartRequest(null, null); final mp = MultipartRequest('POST', Uri.parse(path));
if (additionalMetadata != null) { if (additionalMetadata != null) {
hasFields = true; hasFields = true;
mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata); mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata);
@ -599,11 +510,6 @@ class PetApi {
if (hasFields) { if (hasFields) {
postBody = mp; postBody = mp;
} }
} else {
if (additionalMetadata != null) {
formParams[r'additionalMetadata'] = parameterToString(additionalMetadata);
}
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -44,17 +44,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -101,17 +90,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -171,17 +149,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -243,17 +210,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -43,17 +43,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -108,17 +97,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -171,17 +149,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -237,17 +204,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -303,17 +259,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -382,17 +327,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -445,17 +379,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -512,17 +435,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -43,17 +43,6 @@ class AnotherFakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -29,17 +29,6 @@ class DefaultApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -31,17 +31,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -110,17 +99,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['http_signature_test']; final authNames = <String>['http_signature_test'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -176,17 +154,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -243,17 +210,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -310,17 +266,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -377,17 +322,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -447,17 +381,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -516,17 +439,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -581,17 +493,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -645,17 +546,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -767,73 +657,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['http_basic_test']; final authNames = <String>['http_basic_test'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (integer != null) {
hasFields = true;
mp.fields[r'integer'] = parameterToString(integer);
}
if (int32 != null) {
hasFields = true;
mp.fields[r'int32'] = parameterToString(int32);
}
if (int64 != null) {
hasFields = true;
mp.fields[r'int64'] = parameterToString(int64);
}
if (number != null) {
hasFields = true;
mp.fields[r'number'] = parameterToString(number);
}
if (float != null) {
hasFields = true;
mp.fields[r'float'] = parameterToString(float);
}
if (double_ != null) {
hasFields = true;
mp.fields[r'double'] = parameterToString(double_);
}
if (string != null) {
hasFields = true;
mp.fields[r'string'] = parameterToString(string);
}
if (patternWithoutDelimiter != null) {
hasFields = true;
mp.fields[r'pattern_without_delimiter'] = parameterToString(patternWithoutDelimiter);
}
if (byte != null) {
hasFields = true;
mp.fields[r'byte'] = parameterToString(byte);
}
if (binary != null) {
hasFields = true;
mp.fields[r'binary'] = binary.field;
mp.files.add(binary);
}
if (date != null) {
hasFields = true;
mp.fields[r'date'] = parameterToString(date);
}
if (dateTime != null) {
hasFields = true;
mp.fields[r'dateTime'] = parameterToString(dateTime);
}
if (password != null) {
hasFields = true;
mp.fields[r'password'] = parameterToString(password);
}
if (callback != null) {
hasFields = true;
mp.fields[r'callback'] = parameterToString(callback);
}
if (hasFields) {
postBody = mp;
}
} else {
if (integer != null) { if (integer != null) {
formParams[r'integer'] = parameterToString(integer); formParams[r'integer'] = parameterToString(integer);
} }
@ -873,7 +696,6 @@ class FakeApi {
if (callback != null) { if (callback != null) {
formParams[r'callback'] = parameterToString(callback); formParams[r'callback'] = parameterToString(callback);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1007,31 +829,12 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (enumFormStringArray != null) {
hasFields = true;
mp.fields[r'enum_form_string_array'] = parameterToString(enumFormStringArray);
}
if (enumFormString != null) {
hasFields = true;
mp.fields[r'enum_form_string'] = parameterToString(enumFormString);
}
if (hasFields) {
postBody = mp;
}
} else {
if (enumFormStringArray != null) { if (enumFormStringArray != null) {
formParams[r'enum_form_string_array'] = parameterToString(enumFormStringArray); formParams[r'enum_form_string_array'] = parameterToString(enumFormStringArray);
} }
if (enumFormString != null) { if (enumFormString != null) {
formParams[r'enum_form_string'] = parameterToString(enumFormString); formParams[r'enum_form_string'] = parameterToString(enumFormString);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1144,17 +947,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['bearer_test']; final authNames = <String>['bearer_test'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1224,17 +1016,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1293,31 +1074,12 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (param != null) {
hasFields = true;
mp.fields[r'param'] = parameterToString(param);
}
if (param2 != null) {
hasFields = true;
mp.fields[r'param2'] = parameterToString(param2);
}
if (hasFields) {
postBody = mp;
}
} else {
if (param != null) { if (param != null) {
formParams[r'param'] = parameterToString(param); formParams[r'param'] = parameterToString(param);
} }
if (param2 != null) { if (param2 != null) {
formParams[r'param2'] = parameterToString(param2); formParams[r'param2'] = parameterToString(param2);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1398,17 +1160,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -43,17 +43,6 @@ class FakeClassnameTags123Api {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key_query']; final authNames = <String>['api_key_query'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -41,17 +41,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -111,17 +100,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -180,17 +158,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -258,17 +225,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -335,17 +291,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -407,17 +352,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -477,31 +411,12 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (name != null) {
hasFields = true;
mp.fields[r'name'] = parameterToString(name);
}
if (status != null) {
hasFields = true;
mp.fields[r'status'] = parameterToString(status);
}
if (hasFields) {
postBody = mp;
}
} else {
if (name != null) { if (name != null) {
formParams[r'name'] = parameterToString(name); formParams[r'name'] = parameterToString(name);
} }
if (status != null) { if (status != null) {
formParams[r'status'] = parameterToString(status); formParams[r'status'] = parameterToString(status);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -567,12 +482,8 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false; bool hasFields = false;
final mp = MultipartRequest(null, null); final mp = MultipartRequest('POST', Uri.parse(path));
if (additionalMetadata != null) { if (additionalMetadata != null) {
hasFields = true; hasFields = true;
mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata); mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata);
@ -585,11 +496,6 @@ class PetApi {
if (hasFields) { if (hasFields) {
postBody = mp; postBody = mp;
} }
} else {
if (additionalMetadata != null) {
formParams[r'additionalMetadata'] = parameterToString(additionalMetadata);
}
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -665,12 +571,8 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false; bool hasFields = false;
final mp = MultipartRequest(null, null); final mp = MultipartRequest('POST', Uri.parse(path));
if (additionalMetadata != null) { if (additionalMetadata != null) {
hasFields = true; hasFields = true;
mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata); mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata);
@ -683,11 +585,6 @@ class PetApi {
if (hasFields) { if (hasFields) {
postBody = mp; postBody = mp;
} }
} else {
if (additionalMetadata != null) {
formParams[r'additionalMetadata'] = parameterToString(additionalMetadata);
}
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -44,17 +44,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -101,17 +90,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -171,17 +149,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -243,17 +210,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -43,17 +43,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -108,17 +97,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -171,17 +149,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -237,17 +204,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -303,17 +259,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -382,17 +327,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -445,17 +379,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -512,17 +435,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -43,17 +43,6 @@ class AnotherFakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -29,17 +29,6 @@ class DefaultApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -31,17 +31,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -111,17 +100,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['http_signature_test']; final authNames = <String>['http_signature_test'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -177,17 +155,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -245,17 +212,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -313,17 +269,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -381,17 +326,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -452,17 +386,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -522,17 +445,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -587,17 +499,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -651,17 +552,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -774,73 +664,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['http_basic_test']; final authNames = <String>['http_basic_test'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (integer != null) {
hasFields = true;
mp.fields[r'integer'] = parameterToString(integer);
}
if (int32 != null) {
hasFields = true;
mp.fields[r'int32'] = parameterToString(int32);
}
if (int64 != null) {
hasFields = true;
mp.fields[r'int64'] = parameterToString(int64);
}
if (number != null) {
hasFields = true;
mp.fields[r'number'] = parameterToString(number);
}
if (float != null) {
hasFields = true;
mp.fields[r'float'] = parameterToString(float);
}
if (double_ != null) {
hasFields = true;
mp.fields[r'double'] = parameterToString(double_);
}
if (string != null) {
hasFields = true;
mp.fields[r'string'] = parameterToString(string);
}
if (patternWithoutDelimiter != null) {
hasFields = true;
mp.fields[r'pattern_without_delimiter'] = parameterToString(patternWithoutDelimiter);
}
if (byte != null) {
hasFields = true;
mp.fields[r'byte'] = parameterToString(byte);
}
if (binary != null) {
hasFields = true;
mp.fields[r'binary'] = binary.field;
mp.files.add(binary);
}
if (date != null) {
hasFields = true;
mp.fields[r'date'] = parameterToString(date);
}
if (dateTime != null) {
hasFields = true;
mp.fields[r'dateTime'] = parameterToString(dateTime);
}
if (password != null) {
hasFields = true;
mp.fields[r'password'] = parameterToString(password);
}
if (callback != null) {
hasFields = true;
mp.fields[r'callback'] = parameterToString(callback);
}
if (hasFields) {
postBody = mp;
}
} else {
if (integer != null) { if (integer != null) {
formParams[r'integer'] = parameterToString(integer); formParams[r'integer'] = parameterToString(integer);
} }
@ -880,7 +703,6 @@ class FakeApi {
if (callback != null) { if (callback != null) {
formParams[r'callback'] = parameterToString(callback); formParams[r'callback'] = parameterToString(callback);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1014,31 +836,12 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (enumFormStringArray != null) {
hasFields = true;
mp.fields[r'enum_form_string_array'] = parameterToString(enumFormStringArray);
}
if (enumFormString != null) {
hasFields = true;
mp.fields[r'enum_form_string'] = parameterToString(enumFormString);
}
if (hasFields) {
postBody = mp;
}
} else {
if (enumFormStringArray != null) { if (enumFormStringArray != null) {
formParams[r'enum_form_string_array'] = parameterToString(enumFormStringArray); formParams[r'enum_form_string_array'] = parameterToString(enumFormStringArray);
} }
if (enumFormString != null) { if (enumFormString != null) {
formParams[r'enum_form_string'] = parameterToString(enumFormString); formParams[r'enum_form_string'] = parameterToString(enumFormString);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1151,17 +954,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['bearer_test']; final authNames = <String>['bearer_test'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1231,17 +1023,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1300,31 +1081,12 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (param != null) {
hasFields = true;
mp.fields[r'param'] = parameterToString(param);
}
if (param2 != null) {
hasFields = true;
mp.fields[r'param2'] = parameterToString(param2);
}
if (hasFields) {
postBody = mp;
}
} else {
if (param != null) { if (param != null) {
formParams[r'param'] = parameterToString(param); formParams[r'param'] = parameterToString(param);
} }
if (param2 != null) { if (param2 != null) {
formParams[r'param2'] = parameterToString(param2); formParams[r'param2'] = parameterToString(param2);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -1405,17 +1167,6 @@ class FakeApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -43,17 +43,6 @@ class FakeClassnameTags123Api {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key_query']; final authNames = <String>['api_key_query'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -41,17 +41,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -111,17 +100,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -180,17 +158,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -259,17 +226,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -337,17 +293,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -410,17 +355,6 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -480,31 +414,12 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (name != null) {
hasFields = true;
mp.fields[r'name'] = parameterToString(name);
}
if (status != null) {
hasFields = true;
mp.fields[r'status'] = parameterToString(status);
}
if (hasFields) {
postBody = mp;
}
} else {
if (name != null) { if (name != null) {
formParams[r'name'] = parameterToString(name); formParams[r'name'] = parameterToString(name);
} }
if (status != null) { if (status != null) {
formParams[r'status'] = parameterToString(status); formParams[r'status'] = parameterToString(status);
} }
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -570,12 +485,8 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false; bool hasFields = false;
final mp = MultipartRequest(null, null); final mp = MultipartRequest('POST', Uri.parse(path));
if (additionalMetadata != null) { if (additionalMetadata != null) {
hasFields = true; hasFields = true;
mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata); mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata);
@ -588,11 +499,6 @@ class PetApi {
if (hasFields) { if (hasFields) {
postBody = mp; postBody = mp;
} }
} else {
if (additionalMetadata != null) {
formParams[r'additionalMetadata'] = parameterToString(additionalMetadata);
}
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -669,12 +575,8 @@ class PetApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['petstore_auth']; final authNames = <String>['petstore_auth'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false; bool hasFields = false;
final mp = MultipartRequest(null, null); final mp = MultipartRequest('POST', Uri.parse(path));
if (additionalMetadata != null) { if (additionalMetadata != null) {
hasFields = true; hasFields = true;
mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata); mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata);
@ -687,11 +589,6 @@ class PetApi {
if (hasFields) { if (hasFields) {
postBody = mp; postBody = mp;
} }
} else {
if (additionalMetadata != null) {
formParams[r'additionalMetadata'] = parameterToString(additionalMetadata);
}
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -44,17 +44,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -101,17 +90,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>['api_key']; final authNames = <String>['api_key'];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -172,17 +150,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -245,17 +212,6 @@ class StoreApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -43,17 +43,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -108,17 +97,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -171,17 +149,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -237,17 +204,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -303,17 +259,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -383,17 +328,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -447,17 +381,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,
@ -514,17 +437,6 @@ class UserApi {
final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null; final nullableContentType = contentTypes.isNotEmpty ? contentTypes[0] : null;
final authNames = <String>[]; final authNames = <String>[];
if (
nullableContentType != null &&
nullableContentType.toLowerCase().startsWith('multipart/form-data')
) {
bool hasFields = false;
final mp = MultipartRequest(null, null);
if (hasFields) {
postBody = mp;
}
} else {
}
return await apiClient.invokeAPI( return await apiClient.invokeAPI(
path, path,

View File

@ -35,7 +35,6 @@
<configuration> <configuration>
<executable>go</executable> <executable>go</executable>
<arguments> <arguments>
<argument>go</argument>
<argument>mod</argument> <argument>mod</argument>
<argument>download</argument> <argument>download</argument>
</arguments> </arguments>