emptyMap(), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
}
+ /**
+ * Test form parameter(s) for multipart schema
+ * Test form parameter(s) for multipart schema
+ * 200 - Successful operation
+ * @param marker (required)
+ * @return String
+ * @throws RestClientException if an error occurs while attempting to invoke the API
+ */
+ public String testFormObjectMultipart(TestFormObjectMultipartRequestMarker marker) throws RestClientException {
+ return testFormObjectMultipartWithHttpInfo(marker).getBody();
+ }
+
+ /**
+ * Test form parameter(s) for multipart schema
+ * Test form parameter(s) for multipart schema
+ *
200 - Successful operation
+ * @param marker (required)
+ * @return ResponseEntity<String>
+ * @throws RestClientException if an error occurs while attempting to invoke the API
+ */
+ public ResponseEntity testFormObjectMultipartWithHttpInfo(TestFormObjectMultipartRequestMarker marker) throws RestClientException {
+ Object localVarPostBody = null;
+
+ // verify the required parameter 'marker' is set
+ if (marker == null) {
+ throw new HttpClientErrorException(HttpStatus.BAD_REQUEST, "Missing the required parameter 'marker' when calling testFormObjectMultipart");
+ }
+
+
+ final MultiValueMap localVarQueryParams = new LinkedMultiValueMap();
+ final HttpHeaders localVarHeaderParams = new HttpHeaders();
+ final MultiValueMap localVarCookieParams = new LinkedMultiValueMap();
+ final MultiValueMap localVarFormParams = new LinkedMultiValueMap();
+
+ if (marker != null)
+ localVarFormParams.add("marker", marker);
+
+ final String[] localVarAccepts = {
+ "text/plain"
+ };
+ final List localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
+ final String[] localVarContentTypes = {
+ "multipart/form-data"
+ };
+ final MediaType localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
+
+ String[] localVarAuthNames = new String[] { };
+
+ ParameterizedTypeReference localReturnType = new ParameterizedTypeReference() {};
+ return apiClient.invokeAPI("/form/object/multipart", HttpMethod.POST, Collections.emptyMap(), localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarCookieParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localReturnType);
+ }
/**
* Test form parameter(s) for oneOf schema
* Test form parameter(s) for oneOf schema
diff --git a/samples/client/echo_api/java/resttemplate/src/main/java/org/openapitools/client/model/TestFormObjectMultipartRequestMarker.java b/samples/client/echo_api/java/resttemplate/src/main/java/org/openapitools/client/model/TestFormObjectMultipartRequestMarker.java
new file mode 100644
index 0000000000..84a953d9a7
--- /dev/null
+++ b/samples/client/echo_api/java/resttemplate/src/main/java/org/openapitools/client/model/TestFormObjectMultipartRequestMarker.java
@@ -0,0 +1,104 @@
+/*
+ * Echo Server API
+ * Echo Server API
+ *
+ * The version of the OpenAPI document: 0.1.0
+ * Contact: team@openapitools.org
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
+package org.openapitools.client.model;
+
+import java.util.Objects;
+import java.util.Arrays;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import com.fasterxml.jackson.annotation.JsonTypeName;
+import com.fasterxml.jackson.annotation.JsonValue;
+import com.fasterxml.jackson.annotation.JsonPropertyOrder;
+import com.fasterxml.jackson.annotation.JsonTypeName;
+
+/**
+ * TestFormObjectMultipartRequestMarker
+ */
+@JsonPropertyOrder({
+ TestFormObjectMultipartRequestMarker.JSON_PROPERTY_NAME
+})
+@JsonTypeName("test_form_object_multipart_request_marker")
+@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.5.0-SNAPSHOT")
+public class TestFormObjectMultipartRequestMarker {
+ public static final String JSON_PROPERTY_NAME = "name";
+ private String name;
+
+ public TestFormObjectMultipartRequestMarker() {
+ }
+
+ public TestFormObjectMultipartRequestMarker name(String name) {
+
+ this.name = name;
+ return this;
+ }
+
+ /**
+ * Get name
+ * @return name
+ **/
+ @javax.annotation.Nullable
+ @JsonProperty(JSON_PROPERTY_NAME)
+ @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
+
+ public String getName() {
+ return name;
+ }
+
+
+ @JsonProperty(JSON_PROPERTY_NAME)
+ @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) {
+ return true;
+ }
+ if (o == null || getClass() != o.getClass()) {
+ return false;
+ }
+ TestFormObjectMultipartRequestMarker testFormObjectMultipartRequestMarker = (TestFormObjectMultipartRequestMarker) o;
+ return Objects.equals(this.name, testFormObjectMultipartRequestMarker.name);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(name);
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append("class TestFormObjectMultipartRequestMarker {\n");
+ sb.append(" name: ").append(toIndentedString(name)).append("\n");
+ sb.append("}");
+ return sb.toString();
+ }
+
+ /**
+ * Convert the given object to string with each line indented by 4 spaces
+ * (except the first line).
+ */
+ private String toIndentedString(Object o) {
+ if (o == null) {
+ return "null";
+ }
+ return o.toString().replace("\n", "\n ");
+ }
+
+}
+
diff --git a/samples/client/echo_api/java/resttemplate/src/test/java/org/openapitools/client/model/TestFormObjectMultipartRequestMarkerTest.java b/samples/client/echo_api/java/resttemplate/src/test/java/org/openapitools/client/model/TestFormObjectMultipartRequestMarkerTest.java
new file mode 100644
index 0000000000..cdb7c02c0f
--- /dev/null
+++ b/samples/client/echo_api/java/resttemplate/src/test/java/org/openapitools/client/model/TestFormObjectMultipartRequestMarkerTest.java
@@ -0,0 +1,47 @@
+/*
+ * Echo Server API
+ * Echo Server API
+ *
+ * The version of the OpenAPI document: 0.1.0
+ * Contact: team@openapitools.org
+ *
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
+ * https://openapi-generator.tech
+ * Do not edit the class manually.
+ */
+
+
+package org.openapitools.client.model;
+
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import com.fasterxml.jackson.annotation.JsonTypeName;
+import com.fasterxml.jackson.annotation.JsonValue;
+import org.junit.Assert;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * Model tests for TestFormObjectMultipartRequestMarker
+ */
+public class TestFormObjectMultipartRequestMarkerTest {
+ private final TestFormObjectMultipartRequestMarker model = new TestFormObjectMultipartRequestMarker();
+
+ /**
+ * Model tests for TestFormObjectMultipartRequestMarker
+ */
+ @Test
+ public void testTestFormObjectMultipartRequestMarker() {
+ // TODO: test TestFormObjectMultipartRequestMarker
+ }
+
+ /**
+ * Test the property 'name'
+ */
+ @Test
+ public void nameTest() {
+ // TODO: test name
+ }
+
+}
diff --git a/samples/client/echo_api/php-nextgen/.openapi-generator/FILES b/samples/client/echo_api/php-nextgen/.openapi-generator/FILES
index 82705c8ca1..c51141c743 100644
--- a/samples/client/echo_api/php-nextgen/.openapi-generator/FILES
+++ b/samples/client/echo_api/php-nextgen/.openapi-generator/FILES
@@ -19,6 +19,7 @@ docs/Model/Pet.md
docs/Model/Query.md
docs/Model/StringEnumRef.md
docs/Model/Tag.md
+docs/Model/TestFormObjectMultipartRequestMarker.md
docs/Model/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/Model/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
@@ -42,6 +43,7 @@ src/Model/Pet.php
src/Model/Query.php
src/Model/StringEnumRef.php
src/Model/Tag.php
+src/Model/TestFormObjectMultipartRequestMarker.php
src/Model/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.php
src/Model/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.php
src/ObjectSerializer.php
diff --git a/samples/client/echo_api/php-nextgen/README.md b/samples/client/echo_api/php-nextgen/README.md
index 6a9854bf22..c251282b62 100644
--- a/samples/client/echo_api/php-nextgen/README.md
+++ b/samples/client/echo_api/php-nextgen/README.md
@@ -89,6 +89,7 @@ Class | Method | HTTP request | Description
*BodyApi* | [**testEchoBodyStringEnum**](docs/Api/BodyApi.md#testechobodystringenum) | **POST** /echo/body/string_enum | Test string enum response body
*BodyApi* | [**testEchoBodyTagResponseString**](docs/Api/BodyApi.md#testechobodytagresponsestring) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*FormApi* | [**testFormIntegerBooleanString**](docs/Api/FormApi.md#testformintegerbooleanstring) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*FormApi* | [**testFormObjectMultipart**](docs/Api/FormApi.md#testformobjectmultipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*FormApi* | [**testFormOneof**](docs/Api/FormApi.md#testformoneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*HeaderApi* | [**testHeaderIntegerBooleanStringEnums**](docs/Api/HeaderApi.md#testheaderintegerbooleanstringenums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*PathApi* | [**testsPathStringPathStringIntegerPathIntegerEnumNonrefStringPathEnumRefStringPath**](docs/Api/PathApi.md#testspathstringpathstringintegerpathintegerenumnonrefstringpathenumrefstringpath) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -114,6 +115,7 @@ Class | Method | HTTP request | Description
- [Query](docs/Model/Query.md)
- [StringEnumRef](docs/Model/StringEnumRef.md)
- [Tag](docs/Model/Tag.md)
+- [TestFormObjectMultipartRequestMarker](docs/Model/TestFormObjectMultipartRequestMarker.md)
- [TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/Model/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/Model/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/php-nextgen/docs/Api/FormApi.md b/samples/client/echo_api/php-nextgen/docs/Api/FormApi.md
index 1321378cc0..f9236a1721 100644
--- a/samples/client/echo_api/php-nextgen/docs/Api/FormApi.md
+++ b/samples/client/echo_api/php-nextgen/docs/Api/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to http://localhost:3000, except if the operation defines
| Method | HTTP request | Description |
| ------------- | ------------- | ------------- |
| [**testFormIntegerBooleanString()**](FormApi.md#testFormIntegerBooleanString) | **POST** /form/integer/boolean/string | Test form parameter(s) |
+| [**testFormObjectMultipart()**](FormApi.md#testFormObjectMultipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema |
| [**testFormOneof()**](FormApi.md#testFormOneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema |
@@ -68,6 +69,62 @@ No authorization required
[[Back to Model list]](../../README.md#models)
[[Back to README]](../../README.md)
+## `testFormObjectMultipart()`
+
+```php
+testFormObjectMultipart($marker): string
+```
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Example
+
+```php
+testFormObjectMultipart($marker);
+ print_r($result);
+} catch (Exception $e) {
+ echo 'Exception when calling FormApi->testFormObjectMultipart: ', $e->getMessage(), PHP_EOL;
+}
+```
+
+### Parameters
+
+| Name | Type | Description | Notes |
+| ------------- | ------------- | ------------- | ------------- |
+| **marker** | [**\OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker**](../Model/TestFormObjectMultipartRequestMarker.md)| | |
+
+### Return type
+
+**string**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+- **Content-Type**: `multipart/form-data`
+- **Accept**: `text/plain`
+
+[[Back to top]](#) [[Back to API list]](../../README.md#endpoints)
+[[Back to Model list]](../../README.md#models)
+[[Back to README]](../../README.md)
+
## `testFormOneof()`
```php
diff --git a/samples/client/echo_api/php-nextgen/docs/Model/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/php-nextgen/docs/Model/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..212a07554a
--- /dev/null
+++ b/samples/client/echo_api/php-nextgen/docs/Model/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,9 @@
+# # TestFormObjectMultipartRequestMarker
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **string** | | [optional]
+
+[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
diff --git a/samples/client/echo_api/php-nextgen/src/Api/FormApi.php b/samples/client/echo_api/php-nextgen/src/Api/FormApi.php
index 9c929585d0..483dfc3f99 100644
--- a/samples/client/echo_api/php-nextgen/src/Api/FormApi.php
+++ b/samples/client/echo_api/php-nextgen/src/Api/FormApi.php
@@ -75,6 +75,9 @@ class FormApi
'testFormIntegerBooleanString' => [
'application/x-www-form-urlencoded',
],
+ 'testFormObjectMultipart' => [
+ 'multipart/form-data',
+ ],
'testFormOneof' => [
'application/x-www-form-urlencoded',
],
@@ -468,6 +471,324 @@ class FormApi
);
}
+ /**
+ * Operation testFormObjectMultipart
+ *
+ * Test form parameter(s) for multipart schema
+ *
+ * @param \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker marker (required)
+ * @param string $contentType The value for the Content-Type header. Check self::contentTypes['testFormObjectMultipart'] to see the possible values for this operation
+ *
+ * @throws ApiException on non-2xx response or if the response body is not in the expected format
+ * @throws InvalidArgumentException
+ * @return string
+ */
+ public function testFormObjectMultipart(
+ \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker,
+ string $contentType = self::contentTypes['testFormObjectMultipart'][0]
+ ): string
+ {
+ list($response) = $this->testFormObjectMultipartWithHttpInfo($marker, $contentType);
+ return $response;
+ }
+
+ /**
+ * Operation testFormObjectMultipartWithHttpInfo
+ *
+ * Test form parameter(s) for multipart schema
+ *
+ * @param \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker (required)
+ * @param string $contentType The value for the Content-Type header. Check self::contentTypes['testFormObjectMultipart'] to see the possible values for this operation
+ *
+ * @throws ApiException on non-2xx response or if the response body is not in the expected format
+ * @throws InvalidArgumentException
+ * @return array of string, HTTP status code, HTTP response headers (array of strings)
+ */
+ public function testFormObjectMultipartWithHttpInfo(
+ \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker,
+ string $contentType = self::contentTypes['testFormObjectMultipart'][0]
+ ): array
+ {
+ $request = $this->testFormObjectMultipartRequest($marker, $contentType);
+
+ try {
+ $options = $this->createHttpClientOption();
+ try {
+ $response = $this->client->send($request, $options);
+ } catch (RequestException $e) {
+ throw new ApiException(
+ "[{$e->getCode()}] {$e->getMessage()}",
+ (int) $e->getCode(),
+ $e->getResponse() ? $e->getResponse()->getHeaders() : null,
+ $e->getResponse() ? (string) $e->getResponse()->getBody() : null
+ );
+ } catch (ConnectException $e) {
+ throw new ApiException(
+ "[{$e->getCode()}] {$e->getMessage()}",
+ (int) $e->getCode(),
+ null,
+ null
+ );
+ }
+
+ $statusCode = $response->getStatusCode();
+
+ if ($statusCode < 200 || $statusCode > 299) {
+ throw new ApiException(
+ sprintf(
+ '[%d] Error connecting to the API (%s)',
+ $statusCode,
+ (string) $request->getUri()
+ ),
+ $statusCode,
+ $response->getHeaders(),
+ (string) $response->getBody()
+ );
+ }
+
+ switch($statusCode) {
+ case 200:
+ if ('string' === '\SplFileObject') {
+ $content = $response->getBody(); //stream goes to serializer
+ } else {
+ $content = (string) $response->getBody();
+ if ('string' !== 'string') {
+ try {
+ $content = json_decode($content, false, 512, JSON_THROW_ON_ERROR);
+ } catch (\JsonException $exception) {
+ throw new ApiException(
+ sprintf(
+ 'Error JSON decoding server response (%s)',
+ $request->getUri()
+ ),
+ $statusCode,
+ $response->getHeaders(),
+ $content
+ );
+ }
+ }
+ }
+
+ return [
+ ObjectSerializer::deserialize($content, 'string', []),
+ $response->getStatusCode(),
+ $response->getHeaders()
+ ];
+ }
+
+ $returnType = 'string';
+ if ($returnType === '\SplFileObject') {
+ $content = $response->getBody(); //stream goes to serializer
+ } else {
+ $content = (string) $response->getBody();
+ if ($returnType !== 'string') {
+ try {
+ $content = json_decode($content, false, 512, JSON_THROW_ON_ERROR);
+ } catch (\JsonException $exception) {
+ throw new ApiException(
+ sprintf(
+ 'Error JSON decoding server response (%s)',
+ $request->getUri()
+ ),
+ $statusCode,
+ $response->getHeaders(),
+ $content
+ );
+ }
+ }
+ }
+
+ return [
+ ObjectSerializer::deserialize($content, $returnType, []),
+ $response->getStatusCode(),
+ $response->getHeaders()
+ ];
+
+ } catch (ApiException $e) {
+ switch ($e->getCode()) {
+ case 200:
+ $data = ObjectSerializer::deserialize(
+ $e->getResponseBody(),
+ 'string',
+ $e->getResponseHeaders()
+ );
+ $e->setResponseObject($data);
+ break;
+ }
+ throw $e;
+ }
+ }
+
+ /**
+ * Operation testFormObjectMultipartAsync
+ *
+ * Test form parameter(s) for multipart schema
+ *
+ * @param \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker (required)
+ * @param string $contentType The value for the Content-Type header. Check self::contentTypes['testFormObjectMultipart'] to see the possible values for this operation
+ *
+ * @throws InvalidArgumentException
+ * @return PromiseInterface
+ */
+ public function testFormObjectMultipartAsync(
+ \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker,
+ string $contentType = self::contentTypes['testFormObjectMultipart'][0]
+ ): PromiseInterface
+ {
+ return $this->testFormObjectMultipartAsyncWithHttpInfo($marker, $contentType)
+ ->then(
+ function ($response) {
+ return $response[0];
+ }
+ );
+ }
+
+ /**
+ * Operation testFormObjectMultipartAsyncWithHttpInfo
+ *
+ * Test form parameter(s) for multipart schema
+ *
+ * @param \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker (required)
+ * @param string $contentType The value for the Content-Type header. Check self::contentTypes['testFormObjectMultipart'] to see the possible values for this operation
+ *
+ * @throws InvalidArgumentException
+ * @return PromiseInterface
+ */
+ public function testFormObjectMultipartAsyncWithHttpInfo(
+ $marker,
+ string $contentType = self::contentTypes['testFormObjectMultipart'][0]
+ ): PromiseInterface
+ {
+ $returnType = 'string';
+ $request = $this->testFormObjectMultipartRequest($marker, $contentType);
+
+ return $this->client
+ ->sendAsync($request, $this->createHttpClientOption())
+ ->then(
+ function ($response) use ($returnType) {
+ if ($returnType === '\SplFileObject') {
+ $content = $response->getBody(); //stream goes to serializer
+ } else {
+ $content = (string) $response->getBody();
+ if ($returnType !== 'string') {
+ $content = json_decode($content);
+ }
+ }
+
+ return [
+ ObjectSerializer::deserialize($content, $returnType, []),
+ $response->getStatusCode(),
+ $response->getHeaders()
+ ];
+ },
+ function ($exception) {
+ $response = $exception->getResponse();
+ $statusCode = $response->getStatusCode();
+ throw new ApiException(
+ sprintf(
+ '[%d] Error connecting to the API (%s)',
+ $statusCode,
+ $exception->getRequest()->getUri()
+ ),
+ $statusCode,
+ $response->getHeaders(),
+ (string) $response->getBody()
+ );
+ }
+ );
+ }
+
+ /**
+ * Create request for operation 'testFormObjectMultipart'
+ *
+ * @param \OpenAPI\Client\Model\TestFormObjectMultipartRequestMarker $marker (required)
+ * @param string $contentType The value for the Content-Type header. Check self::contentTypes['testFormObjectMultipart'] to see the possible values for this operation
+ *
+ * @throws InvalidArgumentException
+ * @return \GuzzleHttp\Psr7\Request
+ */
+ public function testFormObjectMultipartRequest(
+ $marker,
+ string $contentType = self::contentTypes['testFormObjectMultipart'][0]
+ ): Request
+ {
+
+ // verify the required parameter 'marker' is set
+ if ($marker === null || (is_array($marker) && count($marker) === 0)) {
+ throw new InvalidArgumentException(
+ 'Missing the required parameter $marker when calling testFormObjectMultipart'
+ );
+ }
+
+
+ $resourcePath = '/form/object/multipart';
+ $formParams = [];
+ $queryParams = [];
+ $headerParams = [];
+ $httpBody = '';
+ $multipart = false;
+
+
+
+
+ // form params
+ if ($marker !== null) {
+ $formParams['marker'] = ObjectSerializer::toFormValue($marker);
+ }
+
+ $headers = $this->headerSelector->selectHeaders(
+ ['text/plain', ],
+ $contentType,
+ $multipart
+ );
+
+ // for model (json/xml)
+ if (count($formParams) > 0) {
+ if ($multipart) {
+ $multipartContents = [];
+ foreach ($formParams as $formParamName => $formParamValue) {
+ $formParamValueItems = is_array($formParamValue) ? $formParamValue : [$formParamValue];
+ foreach ($formParamValueItems as $formParamValueItem) {
+ $multipartContents[] = [
+ 'name' => $formParamName,
+ 'contents' => $formParamValueItem
+ ];
+ }
+ }
+ // for HTTP post (form)
+ $httpBody = new MultipartStream($multipartContents);
+
+ } elseif (stripos($headers['Content-Type'], 'application/json') !== false) {
+ # if Content-Type contains "application/json", json_encode the form parameters
+ $httpBody = \GuzzleHttp\Utils::jsonEncode($formParams);
+ } else {
+ // for HTTP post (form)
+ $httpBody = ObjectSerializer::buildQuery($formParams);
+ }
+ }
+
+
+ $defaultHeaders = [];
+ if ($this->config->getUserAgent()) {
+ $defaultHeaders['User-Agent'] = $this->config->getUserAgent();
+ }
+
+ $headers = array_merge(
+ $defaultHeaders,
+ $headerParams,
+ $headers
+ );
+
+ $operationHost = $this->config->getHost();
+ $query = ObjectSerializer::buildQuery($queryParams);
+ return new Request(
+ 'POST',
+ $operationHost . $resourcePath . ($query ? "?{$query}" : ''),
+ $headers,
+ $httpBody
+ );
+ }
+
/**
* Operation testFormOneof
*
diff --git a/samples/client/echo_api/php-nextgen/src/Model/TestFormObjectMultipartRequestMarker.php b/samples/client/echo_api/php-nextgen/src/Model/TestFormObjectMultipartRequestMarker.php
new file mode 100644
index 0000000000..1ee131c14b
--- /dev/null
+++ b/samples/client/echo_api/php-nextgen/src/Model/TestFormObjectMultipartRequestMarker.php
@@ -0,0 +1,408 @@
+
+ */
+class TestFormObjectMultipartRequestMarker implements ModelInterface, ArrayAccess, JsonSerializable
+{
+ public const DISCRIMINATOR = null;
+
+ /**
+ * The original name of the model.
+ *
+ * @var string
+ */
+ protected static string $openAPIModelName = 'test_form_object_multipart_request_marker';
+
+ /**
+ * Array of property to type mappings. Used for (de)serialization
+ *
+ * @var array
+ */
+ protected static array $openAPITypes = [
+ 'name' => 'string'
+ ];
+
+ /**
+ * Array of property to format mappings. Used for (de)serialization
+ *
+ * @var array
+ */
+ protected static array $openAPIFormats = [
+ 'name' => null
+ ];
+
+ /**
+ * Array of nullable properties. Used for (de)serialization
+ *
+ * @var array
+ */
+ protected static array $openAPINullables = [
+ 'name' => false
+ ];
+
+ /**
+ * If a nullable field gets set to null, insert it here
+ *
+ * @var array
+ */
+ protected array $openAPINullablesSetToNull = [];
+
+ /**
+ * Array of property to type mappings. Used for (de)serialization
+ *
+ * @return array
+ */
+ public static function openAPITypes(): array
+ {
+ return self::$openAPITypes;
+ }
+
+ /**
+ * Array of property to format mappings. Used for (de)serialization
+ *
+ * @return array
+ */
+ public static function openAPIFormats(): array
+ {
+ return self::$openAPIFormats;
+ }
+
+ /**
+ * Array of nullable properties
+ *
+ * @return array
+ */
+ protected static function openAPINullables(): array
+ {
+ return self::$openAPINullables;
+ }
+
+ /**
+ * Array of nullable field names deliberately set to null
+ *
+ * @return array
+ */
+ private function getOpenAPINullablesSetToNull(): array
+ {
+ return $this->openAPINullablesSetToNull;
+ }
+
+ /**
+ * Setter - Array of nullable field names deliberately set to null
+ *
+ * @param array $openAPINullablesSetToNull
+ */
+ private function setOpenAPINullablesSetToNull(array $openAPINullablesSetToNull): void
+ {
+ $this->openAPINullablesSetToNull = $openAPINullablesSetToNull;
+ }
+
+ /**
+ * Checks if a property is nullable
+ *
+ * @param string $property
+ * @return bool
+ */
+ public static function isNullable(string $property): bool
+ {
+ return self::openAPINullables()[$property] ?? false;
+ }
+
+ /**
+ * Checks if a nullable property is set to null.
+ *
+ * @param string $property
+ * @return bool
+ */
+ public function isNullableSetToNull(string $property): bool
+ {
+ return in_array($property, $this->getOpenAPINullablesSetToNull(), true);
+ }
+
+ /**
+ * Array of attributes where the key is the local name,
+ * and the value is the original name
+ *
+ * @var array
+ */
+ protected static array $attributeMap = [
+ 'name' => 'name'
+ ];
+
+ /**
+ * Array of attributes to setter functions (for deserialization of responses)
+ *
+ * @var array
+ */
+ protected static array $setters = [
+ 'name' => 'setName'
+ ];
+
+ /**
+ * Array of attributes to getter functions (for serialization of requests)
+ *
+ * @var array
+ */
+ protected static array $getters = [
+ 'name' => 'getName'
+ ];
+
+ /**
+ * Array of attributes where the key is the local name,
+ * and the value is the original name
+ *
+ * @return array
+ */
+ public static function attributeMap(): array
+ {
+ return self::$attributeMap;
+ }
+
+ /**
+ * Array of attributes to setter functions (for deserialization of responses)
+ *
+ * @return array
+ */
+ public static function setters(): array
+ {
+ return self::$setters;
+ }
+
+ /**
+ * Array of attributes to getter functions (for serialization of requests)
+ *
+ * @return array
+ */
+ public static function getters(): array
+ {
+ return self::$getters;
+ }
+
+ /**
+ * The original name of the model.
+ *
+ * @return string
+ */
+ public function getModelName(): string
+ {
+ return self::$openAPIModelName;
+ }
+
+
+ /**
+ * Associative array for storing property values
+ *
+ * @var array
+ */
+ protected array $container = [];
+
+ /**
+ * Constructor
+ *
+ * @param array $data Associated array of property values initializing the model
+ */
+ public function __construct(array $data = null)
+ {
+ $this->setIfExists('name', $data ?? [], null);
+ }
+
+ /**
+ * Sets $this->container[$variableName] to the given data or to the given default Value; if $variableName
+ * is nullable and its value is set to null in the $fields array, then mark it as "set to null" in the
+ * $this->openAPINullablesSetToNull array
+ *
+ * @param string $variableName
+ * @param array $fields
+ * @param mixed $defaultValue
+ */
+ private function setIfExists(string $variableName, array $fields, mixed $defaultValue): void
+ {
+ if (self::isNullable($variableName) && array_key_exists($variableName, $fields) && is_null($fields[$variableName])) {
+ $this->openAPINullablesSetToNull[] = $variableName;
+ }
+
+ $this->container[$variableName] = $fields[$variableName] ?? $defaultValue;
+ }
+
+ /**
+ * Show all the invalid properties with reasons.
+ *
+ * @return string[] invalid properties with reasons
+ */
+ public function listInvalidProperties(): array
+ {
+ $invalidProperties = [];
+
+ return $invalidProperties;
+ }
+
+ /**
+ * Validate all the properties in the model
+ * return true if all passed
+ *
+ * @return bool True if all properties are valid
+ */
+ public function valid(): bool
+ {
+ return count($this->listInvalidProperties()) === 0;
+ }
+
+
+ /**
+ * Gets name
+ *
+ * @return string|null
+ */
+ public function getName(): ?string
+ {
+ return $this->container['name'];
+ }
+
+ /**
+ * Sets name
+ *
+ * @param string|null $name name
+ *
+ * @return $this
+ */
+ public function setName(?string $name): static
+ {
+ if (is_null($name)) {
+ throw new InvalidArgumentException('non-nullable name cannot be null');
+ }
+ $this->container['name'] = $name;
+
+ return $this;
+ }
+ /**
+ * Returns true if offset exists. False otherwise.
+ *
+ * @param integer $offset Offset
+ *
+ * @return boolean
+ */
+ public function offsetExists(mixed $offset): bool
+ {
+ return isset($this->container[$offset]);
+ }
+
+ /**
+ * Gets offset.
+ *
+ * @param integer $offset Offset
+ *
+ * @return mixed|null
+ */
+ #[ReturnTypeWillChange]
+ public function offsetGet(mixed $offset): mixed
+ {
+ return $this->container[$offset] ?? null;
+ }
+
+ /**
+ * Sets value based on offset.
+ *
+ * @param int|null $offset Offset
+ * @param mixed $value Value to be set
+ *
+ * @return void
+ */
+ public function offsetSet(mixed $offset, mixed $value): void
+ {
+ if (is_null($offset)) {
+ $this->container[] = $value;
+ } else {
+ $this->container[$offset] = $value;
+ }
+ }
+
+ /**
+ * Unsets offset.
+ *
+ * @param integer $offset Offset
+ *
+ * @return void
+ */
+ public function offsetUnset(mixed $offset): void
+ {
+ unset($this->container[$offset]);
+ }
+
+ /**
+ * Serializes the object to a value that can be serialized natively by json_encode().
+ * @link https://www.php.net/manual/en/jsonserializable.jsonserialize.php
+ *
+ * @return mixed Returns data which can be serialized by json_encode(), which is a value
+ * of any type other than a resource.
+ */
+ #[ReturnTypeWillChange]
+ public function jsonSerialize(): mixed
+ {
+ return ObjectSerializer::sanitizeForSerialization($this);
+ }
+
+ /**
+ * Gets the string presentation of the object
+ *
+ * @return string
+ */
+ public function __toString(): string
+ {
+ return json_encode(
+ ObjectSerializer::sanitizeForSerialization($this),
+ JSON_PRETTY_PRINT
+ );
+ }
+
+ /**
+ * Gets a header-safe presentation of the object
+ *
+ * @return string
+ */
+ public function toHeaderValue(): string
+ {
+ return json_encode(ObjectSerializer::sanitizeForSerialization($this));
+ }
+}
+
+
diff --git a/samples/client/echo_api/php-nextgen/tests/Model/TestFormObjectMultipartRequestMarkerTest.php b/samples/client/echo_api/php-nextgen/tests/Model/TestFormObjectMultipartRequestMarkerTest.php
new file mode 100644
index 0000000000..30eb64c636
--- /dev/null
+++ b/samples/client/echo_api/php-nextgen/tests/Model/TestFormObjectMultipartRequestMarkerTest.php
@@ -0,0 +1,89 @@
+
+# **Test-FormObjectMultipart**
+> String Test-FormObjectMultipart
+> [-Marker]
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Example
+```powershell
+$TestFormObjectMultipartRequestMarker = Initialize-TestFormObjectMultipartRequestMarker -Name "MyName" # TestFormObjectMultipartRequestMarker |
+
+# Test form parameter(s) for multipart schema
+try {
+ $Result = Test-FormObjectMultipart -Marker $Marker
+} catch {
+ Write-Host ("Exception occurred when calling Test-FormObjectMultipart: {0}" -f ($_.ErrorDetails | ConvertFrom-Json))
+ Write-Host ("Response headers: {0}" -f ($_.Exception.Response.Headers | ConvertTo-Json))
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **Marker** | [**TestFormObjectMultipartRequestMarker**](TestFormObjectMultipartRequestMarker.md)| |
+
+### Return type
+
+**String**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+ - **Content-Type**: multipart/form-data
+ - **Accept**: text/plain
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
# **Test-FormOneof**
> String Test-FormOneof
diff --git a/samples/client/echo_api/powershell/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/powershell/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..4356abc98d
--- /dev/null
+++ b/samples/client/echo_api/powershell/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,21 @@
+# TestFormObjectMultipartRequestMarker
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**Name** | **String** | | [optional]
+
+## Examples
+
+- Prepare the resource
+```powershell
+$TestFormObjectMultipartRequestMarker = Initialize-PSOpenAPIToolsTestFormObjectMultipartRequestMarker -Name null
+```
+
+- Convert the resource to JSON
+```powershell
+$TestFormObjectMultipartRequestMarker | ConvertTo-JSON
+```
+
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
diff --git a/samples/client/echo_api/powershell/src/PSOpenAPITools/Api/FormApi.ps1 b/samples/client/echo_api/powershell/src/PSOpenAPITools/Api/FormApi.ps1
index 677221d160..7d7a960ae1 100644
--- a/samples/client/echo_api/powershell/src/PSOpenAPITools/Api/FormApi.ps1
+++ b/samples/client/echo_api/powershell/src/PSOpenAPITools/Api/FormApi.ps1
@@ -105,6 +105,83 @@ function Test-FormIntegerBooleanString {
<#
.SYNOPSIS
+Test form parameter(s) for multipart schema
+
+.DESCRIPTION
+
+No description available.
+
+.PARAMETER Marker
+No description available.
+
+.PARAMETER WithHttpInfo
+
+A switch when turned on will return a hash table of Response, StatusCode and Headers instead of just the Response
+
+.OUTPUTS
+
+String
+#>
+function Test-FormObjectMultipart {
+ [CmdletBinding()]
+ Param (
+ [Parameter(Position = 0, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Mandatory = $false)]
+ [PSCustomObject]
+ ${Marker},
+ [Switch]
+ $WithHttpInfo
+ )
+
+ Process {
+ 'Calling method: Test-FormObjectMultipart' | Write-Debug
+ $PSBoundParameters | Out-DebugParameter | Write-Debug
+
+ $LocalVarAccepts = @()
+ $LocalVarContentTypes = @()
+ $LocalVarQueryParameters = @{}
+ $LocalVarHeaderParameters = @{}
+ $LocalVarFormParameters = @{}
+ $LocalVarPathParameters = @{}
+ $LocalVarCookieParameters = @{}
+ $LocalVarBodyParameter = $null
+
+ $Configuration = Get-Configuration
+ # HTTP header 'Accept' (if needed)
+ $LocalVarAccepts = @('text/plain')
+
+ # HTTP header 'Content-Type'
+ $LocalVarContentTypes = @('multipart/form-data')
+
+ $LocalVarUri = '/form/object/multipart'
+
+ if (!$Marker) {
+ throw "Error! The required parameter `Marker` missing when calling test_form_object_multipart."
+ }
+ $LocalVarFormParameters['marker'] = $Marker
+
+ $LocalVarResult = Invoke-ApiClient -Method 'POST' `
+ -Uri $LocalVarUri `
+ -Accepts $LocalVarAccepts `
+ -ContentTypes $LocalVarContentTypes `
+ -Body $LocalVarBodyParameter `
+ -HeaderParameters $LocalVarHeaderParameters `
+ -QueryParameters $LocalVarQueryParameters `
+ -FormParameters $LocalVarFormParameters `
+ -CookieParameters $LocalVarCookieParameters `
+ -ReturnType "String" `
+ -IsBodyNullable $false
+
+ if ($WithHttpInfo.IsPresent) {
+ return $LocalVarResult
+ } else {
+ return $LocalVarResult["Response"]
+ }
+ }
+}
+
+<#
+.SYNOPSIS
+
Test form parameter(s) for oneOf schema
.DESCRIPTION
diff --git a/samples/client/echo_api/powershell/src/PSOpenAPITools/Model/TestFormObjectMultipartRequestMarker.ps1 b/samples/client/echo_api/powershell/src/PSOpenAPITools/Model/TestFormObjectMultipartRequestMarker.ps1
new file mode 100644
index 0000000000..b7dc812a97
--- /dev/null
+++ b/samples/client/echo_api/powershell/src/PSOpenAPITools/Model/TestFormObjectMultipartRequestMarker.ps1
@@ -0,0 +1,98 @@
+#
+# Echo Server API
+# Echo Server API
+# Version: 0.1.0
+# Contact: team@openapitools.org
+# Generated by OpenAPI Generator: https://openapi-generator.tech
+#
+
+<#
+.SYNOPSIS
+
+No summary available.
+
+.DESCRIPTION
+
+No description available.
+
+.PARAMETER Name
+No description available.
+.OUTPUTS
+
+TestFormObjectMultipartRequestMarker
+#>
+
+function Initialize-TestFormObjectMultipartRequestMarker {
+ [CmdletBinding()]
+ Param (
+ [Parameter(Position = 0, ValueFromPipelineByPropertyName = $true)]
+ [String]
+ ${Name}
+ )
+
+ Process {
+ 'Creating PSCustomObject: PSOpenAPITools => TestFormObjectMultipartRequestMarker' | Write-Debug
+ $PSBoundParameters | Out-DebugParameter | Write-Debug
+
+
+ $PSO = [PSCustomObject]@{
+ "name" = ${Name}
+ }
+
+
+ return $PSO
+ }
+}
+
+<#
+.SYNOPSIS
+
+Convert from JSON to TestFormObjectMultipartRequestMarker
+
+.DESCRIPTION
+
+Convert from JSON to TestFormObjectMultipartRequestMarker
+
+.PARAMETER Json
+
+Json object
+
+.OUTPUTS
+
+TestFormObjectMultipartRequestMarker
+#>
+function ConvertFrom-JsonToTestFormObjectMultipartRequestMarker {
+ Param(
+ [AllowEmptyString()]
+ [string]$Json
+ )
+
+ Process {
+ 'Converting JSON to PSCustomObject: PSOpenAPITools => TestFormObjectMultipartRequestMarker' | Write-Debug
+ $PSBoundParameters | Out-DebugParameter | Write-Debug
+
+ $JsonParameters = ConvertFrom-Json -InputObject $Json
+
+ # check if Json contains properties not defined in TestFormObjectMultipartRequestMarker
+ $AllProperties = ("name")
+ foreach ($name in $JsonParameters.PsObject.Properties.Name) {
+ if (!($AllProperties.Contains($name))) {
+ throw "Error! JSON key '$name' not found in the properties: $($AllProperties)"
+ }
+ }
+
+ if (!([bool]($JsonParameters.PSobject.Properties.name -match "name"))) { #optional property not found
+ $Name = $null
+ } else {
+ $Name = $JsonParameters.PSobject.Properties["name"].value
+ }
+
+ $PSO = [PSCustomObject]@{
+ "name" = ${Name}
+ }
+
+ return $PSO
+ }
+
+}
+
diff --git a/samples/client/echo_api/powershell/tests/Model/TestFormObjectMultipartRequestMarker.Tests.ps1 b/samples/client/echo_api/powershell/tests/Model/TestFormObjectMultipartRequestMarker.Tests.ps1
new file mode 100644
index 0000000000..1fa8c774ab
--- /dev/null
+++ b/samples/client/echo_api/powershell/tests/Model/TestFormObjectMultipartRequestMarker.Tests.ps1
@@ -0,0 +1,18 @@
+#
+# Echo Server API
+# Echo Server API
+# Version: 0.1.0
+# Contact: team@openapitools.org
+# Generated by OpenAPI Generator: https://openapi-generator.tech
+#
+
+Describe -tag 'PSOpenAPITools' -name 'TestFormObjectMultipartRequestMarker' {
+ Context 'TestFormObjectMultipartRequestMarker' {
+ It 'Initialize-TestFormObjectMultipartRequestMarker' {
+ # a simple test to create an object
+ #$NewObject = Initialize-TestFormObjectMultipartRequestMarker -Name "TEST_VALUE"
+ #$NewObject | Should -BeOfType TestFormObjectMultipartRequestMarker
+ #$NewObject.property | Should -Be 0
+ }
+ }
+}
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/.openapi-generator/FILES b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/.openapi-generator/FILES
index 0723c3ab0d..a7c64d3f55 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/.openapi-generator/FILES
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/.openapi-generator/FILES
@@ -18,6 +18,7 @@ docs/Query.md
docs/QueryApi.md
docs/StringEnumRef.md
docs/Tag.md
+docs/TestFormObjectMultipartRequestMarker.md
docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
@@ -43,6 +44,7 @@ openapi_client/models/pet.py
openapi_client/models/query.py
openapi_client/models/string_enum_ref.py
openapi_client/models/tag.py
+openapi_client/models/test_form_object_multipart_request_marker.py
openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
openapi_client/py.typed
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/README.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/README.md
index 42487c28d4..22e4678998 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/README.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/README.md
@@ -107,6 +107,7 @@ Class | Method | HTTP request | Description
*BodyApi* | [**test_echo_body_string_enum**](docs/BodyApi.md#test_echo_body_string_enum) | **POST** /echo/body/string_enum | Test string enum response body
*BodyApi* | [**test_echo_body_tag_response_string**](docs/BodyApi.md#test_echo_body_tag_response_string) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*FormApi* | [**test_form_integer_boolean_string**](docs/FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*FormApi* | [**test_form_object_multipart**](docs/FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*FormApi* | [**test_form_oneof**](docs/FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*HeaderApi* | [**test_header_integer_boolean_string_enums**](docs/HeaderApi.md#test_header_integer_boolean_string_enums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*PathApi* | [**tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path**](docs/PathApi.md#tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -133,6 +134,7 @@ Class | Method | HTTP request | Description
- [Query](docs/Query.md)
- [StringEnumRef](docs/StringEnumRef.md)
- [Tag](docs/Tag.md)
+ - [TestFormObjectMultipartRequestMarker](docs/TestFormObjectMultipartRequestMarker.md)
- [TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/FormApi.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/FormApi.md
index 94205cd60e..86ae2be369 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/FormApi.md
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost:3000*
Method | HTTP request | Description
------------- | ------------- | -------------
[**test_form_integer_boolean_string**](FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+[**test_form_object_multipart**](FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
[**test_form_oneof**](FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
@@ -79,6 +80,74 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+# **test_form_object_multipart**
+> str test_form_object_multipart(marker)
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Example
+
+
+```python
+import openapi_client
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+from openapi_client.rest import ApiException
+from pprint import pprint
+
+# Defining the host is optional and defaults to http://localhost:3000
+# See configuration.py for a list of all supported configuration parameters.
+configuration = openapi_client.Configuration(
+ host = "http://localhost:3000"
+)
+
+
+# Enter a context with an instance of the API client
+with openapi_client.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = openapi_client.FormApi(api_client)
+ marker = openapi_client.TestFormObjectMultipartRequestMarker() # TestFormObjectMultipartRequestMarker |
+
+ try:
+ # Test form parameter(s) for multipart schema
+ api_response = api_instance.test_form_object_multipart(marker)
+ print("The response of FormApi->test_form_object_multipart:\n")
+ pprint(api_response)
+ except Exception as e:
+ print("Exception when calling FormApi->test_form_object_multipart: %s\n" % e)
+```
+
+
+
+### Parameters
+
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **marker** | [**TestFormObjectMultipartRequestMarker**](TestFormObjectMultipartRequestMarker.md)| |
+
+### Return type
+
+**str**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+ - **Content-Type**: multipart/form-data
+ - **Accept**: text/plain
+
+### HTTP response details
+
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+**200** | Successful operation | - |
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
# **test_form_oneof**
> str test_form_oneof(form1=form1, form2=form2, form3=form3, form4=form4, id=id, name=name)
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..254c3b6a04
--- /dev/null
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,29 @@
+# TestFormObjectMultipartRequestMarker
+
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **str** | | [optional]
+
+## Example
+
+```python
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of TestFormObjectMultipartRequestMarker from a JSON string
+test_form_object_multipart_request_marker_instance = TestFormObjectMultipartRequestMarker.from_json(json)
+# print the JSON string representation of the object
+print(TestFormObjectMultipartRequestMarker.to_json())
+
+# convert the object into a dict
+test_form_object_multipart_request_marker_dict = test_form_object_multipart_request_marker_instance.to_dict()
+# create an instance of TestFormObjectMultipartRequestMarker from a dict
+test_form_object_multipart_request_marker_form_dict = test_form_object_multipart_request_marker.from_dict(test_form_object_multipart_request_marker_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/__init__.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/__init__.py
index 7b67f7c597..3f63fe12ab 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/__init__.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/__init__.py
@@ -46,5 +46,6 @@ from openapi_client.models.pet import Pet
from openapi_client.models.query import Query
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.tag import Tag
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.models.test_query_style_deep_object_explode_true_object_all_of_query_object_parameter import TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py
index 7c0959bd94..48f4dcf80b 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/api/form_api.py
@@ -19,6 +19,7 @@ from typing_extensions import Annotated
from pydantic import StrictBool, StrictInt, StrictStr
from typing import Optional
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.api_client import ApiClient, RequestSerialized
from openapi_client.api_response import ApiResponse
@@ -338,6 +339,276 @@ class FormApi:
+ @validate_call
+ def test_form_object_multipart(
+ self,
+ marker: TestFormObjectMultipartRequestMarker,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> str:
+ """Test form parameter(s) for multipart schema
+
+ Test form parameter(s) for multipart schema
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._test_form_object_multipart_serialize(
+ marker=marker,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "str",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ ).data
+
+
+ @validate_call
+ def test_form_object_multipart_with_http_info(
+ self,
+ marker: TestFormObjectMultipartRequestMarker,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> ApiResponse[str]:
+ """Test form parameter(s) for multipart schema
+
+ Test form parameter(s) for multipart schema
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._test_form_object_multipart_serialize(
+ marker=marker,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "str",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ )
+
+
+ @validate_call
+ def test_form_object_multipart_without_preload_content(
+ self,
+ marker: TestFormObjectMultipartRequestMarker,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> RESTResponseType:
+ """Test form parameter(s) for multipart schema
+
+ Test form parameter(s) for multipart schema
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._test_form_object_multipart_serialize(
+ marker=marker,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "str",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ return response_data.response
+
+
+ def _test_form_object_multipart_serialize(
+ self,
+ marker,
+ _request_auth,
+ _content_type,
+ _headers,
+ _host_index,
+ ) -> RequestSerialized:
+
+ _host = None
+
+ _collection_formats: Dict[str, str] = {
+ }
+
+ _path_params: Dict[str, str] = {}
+ _query_params: List[Tuple[str, str]] = []
+ _header_params: Dict[str, Optional[str]] = _headers or {}
+ _form_params: List[Tuple[str, str]] = []
+ _files: Dict[str, Union[str, bytes]] = {}
+ _body_params: Optional[bytes] = None
+
+ # process the path parameters
+ # process the query parameters
+ # process the header parameters
+ # process the form parameters
+ if marker is not None:
+ _form_params.append(('marker', marker))
+ # process the body parameter
+
+
+ # set the HTTP header `Accept`
+ _header_params['Accept'] = self.api_client.select_header_accept(
+ [
+ 'text/plain'
+ ]
+ )
+
+ # set the HTTP header `Content-Type`
+ if _content_type:
+ _header_params['Content-Type'] = _content_type
+ else:
+ _default_content_type = (
+ self.api_client.select_header_content_type(
+ [
+ 'multipart/form-data'
+ ]
+ )
+ )
+ if _default_content_type is not None:
+ _header_params['Content-Type'] = _default_content_type
+
+ # authentication setting
+ _auth_settings: List[str] = [
+ ]
+
+ return self.api_client.param_serialize(
+ method='POST',
+ resource_path='/form/object/multipart',
+ path_params=_path_params,
+ query_params=_query_params,
+ header_params=_header_params,
+ body=_body_params,
+ post_params=_form_params,
+ files=_files,
+ auth_settings=_auth_settings,
+ collection_formats=_collection_formats,
+ _host=_host,
+ _request_auth=_request_auth
+ )
+
+
+
+
@validate_call
def test_form_oneof(
self,
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/__init__.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/__init__.py
index 4b981699e6..f070f63231 100644
--- a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/__init__.py
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/__init__.py
@@ -24,5 +24,6 @@ from openapi_client.models.pet import Pet
from openapi_client.models.query import Query
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.tag import Tag
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.models.test_query_style_deep_object_explode_true_object_all_of_query_object_parameter import TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_form_object_multipart_request_marker.py
new file mode 100644
index 0000000000..9fab70ea17
--- /dev/null
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/openapi_client/models/test_form_object_multipart_request_marker.py
@@ -0,0 +1,93 @@
+# coding: utf-8
+
+"""
+ Echo Server API
+
+ Echo Server API
+
+ The version of the OpenAPI document: 0.1.0
+ Contact: team@openapitools.org
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+from __future__ import annotations
+import pprint
+import re # noqa: F401
+import json
+
+from pydantic import BaseModel, ConfigDict, StrictStr
+from typing import Any, ClassVar, Dict, List, Optional
+from typing import Optional, Set
+from typing_extensions import Self
+
+class TestFormObjectMultipartRequestMarker(BaseModel):
+ """
+ TestFormObjectMultipartRequestMarker
+ """ # noqa: E501
+ name: Optional[StrictStr] = None
+ __properties: ClassVar[List[str]] = ["name"]
+
+ model_config = ConfigDict(
+ populate_by_name=True,
+ validate_assignment=True,
+ protected_namespaces=(),
+ )
+
+
+ def to_str(self) -> str:
+ """Returns the string representation of the model using alias"""
+ return pprint.pformat(self.model_dump(by_alias=True))
+
+ def to_json(self) -> str:
+ """Returns the JSON representation of the model using alias"""
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
+ return json.dumps(self.to_dict())
+
+ @classmethod
+ def from_json(cls, json_str: str) -> Optional[Self]:
+ """Create an instance of TestFormObjectMultipartRequestMarker from a JSON string"""
+ return cls.from_dict(json.loads(json_str))
+
+ def to_dict(self) -> Dict[str, Any]:
+ """Return the dictionary representation of the model using alias.
+
+ This has the following differences from calling pydantic's
+ `self.model_dump(by_alias=True)`:
+
+ * `None` is only added to the output dict for nullable fields that
+ were set at model initialization. Other fields with value `None`
+ are ignored.
+ """
+ excluded_fields: Set[str] = set([
+ ])
+
+ _dict = self.model_dump(
+ by_alias=True,
+ exclude=excluded_fields,
+ exclude_none=True,
+ )
+ return _dict
+
+ @classmethod
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ """Create an instance of TestFormObjectMultipartRequestMarker from a dict"""
+ if obj is None:
+ return None
+
+ if not isinstance(obj, dict):
+ return cls.model_validate(obj)
+
+ # raise errors for additional fields in the input
+ for _key in obj.keys():
+ if _key not in cls.__properties:
+ raise ValueError("Error due to additional fields (not defined in TestFormObjectMultipartRequestMarker) in the input: " + _key)
+
+ _obj = cls.model_validate({
+ "name": obj.get("name")
+ })
+ return _obj
+
+
diff --git a/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/test/test_test_form_object_multipart_request_marker.py b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/test/test_test_form_object_multipart_request_marker.py
new file mode 100644
index 0000000000..d499742860
--- /dev/null
+++ b/samples/client/echo_api/python-disallowAdditionalPropertiesIfNotPresent/test/test_test_form_object_multipart_request_marker.py
@@ -0,0 +1,52 @@
+# coding: utf-8
+
+"""
+ Echo Server API
+
+ Echo Server API
+
+ The version of the OpenAPI document: 0.1.0
+ Contact: team@openapitools.org
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+import unittest
+
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+
+class TestTestFormObjectMultipartRequestMarker(unittest.TestCase):
+ """TestFormObjectMultipartRequestMarker unit test stubs"""
+
+ def setUp(self):
+ pass
+
+ def tearDown(self):
+ pass
+
+ def make_instance(self, include_optional) -> TestFormObjectMultipartRequestMarker:
+ """Test TestFormObjectMultipartRequestMarker
+ include_option is a boolean, when False only required
+ params are included, when True both required and
+ optional params are included """
+ # uncomment below to create an instance of `TestFormObjectMultipartRequestMarker`
+ """
+ model = TestFormObjectMultipartRequestMarker()
+ if include_optional:
+ return TestFormObjectMultipartRequestMarker(
+ name = ''
+ )
+ else:
+ return TestFormObjectMultipartRequestMarker(
+ )
+ """
+
+ def testTestFormObjectMultipartRequestMarker(self):
+ """Test TestFormObjectMultipartRequestMarker"""
+ # inst_req_only = self.make_instance(include_optional=False)
+ # inst_req_and_optional = self.make_instance(include_optional=True)
+
+if __name__ == '__main__':
+ unittest.main()
diff --git a/samples/client/echo_api/python-pydantic-v1/.openapi-generator/FILES b/samples/client/echo_api/python-pydantic-v1/.openapi-generator/FILES
index 0723c3ab0d..a7c64d3f55 100644
--- a/samples/client/echo_api/python-pydantic-v1/.openapi-generator/FILES
+++ b/samples/client/echo_api/python-pydantic-v1/.openapi-generator/FILES
@@ -18,6 +18,7 @@ docs/Query.md
docs/QueryApi.md
docs/StringEnumRef.md
docs/Tag.md
+docs/TestFormObjectMultipartRequestMarker.md
docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
@@ -43,6 +44,7 @@ openapi_client/models/pet.py
openapi_client/models/query.py
openapi_client/models/string_enum_ref.py
openapi_client/models/tag.py
+openapi_client/models/test_form_object_multipart_request_marker.py
openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
openapi_client/py.typed
diff --git a/samples/client/echo_api/python-pydantic-v1/README.md b/samples/client/echo_api/python-pydantic-v1/README.md
index a566e0673e..87aa115b3d 100644
--- a/samples/client/echo_api/python-pydantic-v1/README.md
+++ b/samples/client/echo_api/python-pydantic-v1/README.md
@@ -108,6 +108,7 @@ Class | Method | HTTP request | Description
*BodyApi* | [**test_echo_body_string_enum**](docs/BodyApi.md#test_echo_body_string_enum) | **POST** /echo/body/string_enum | Test string enum response body
*BodyApi* | [**test_echo_body_tag_response_string**](docs/BodyApi.md#test_echo_body_tag_response_string) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*FormApi* | [**test_form_integer_boolean_string**](docs/FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*FormApi* | [**test_form_object_multipart**](docs/FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*FormApi* | [**test_form_oneof**](docs/FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*HeaderApi* | [**test_header_integer_boolean_string_enums**](docs/HeaderApi.md#test_header_integer_boolean_string_enums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*PathApi* | [**tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path**](docs/PathApi.md#tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -134,6 +135,7 @@ Class | Method | HTTP request | Description
- [Query](docs/Query.md)
- [StringEnumRef](docs/StringEnumRef.md)
- [Tag](docs/Tag.md)
+ - [TestFormObjectMultipartRequestMarker](docs/TestFormObjectMultipartRequestMarker.md)
- [TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/FormApi.md b/samples/client/echo_api/python-pydantic-v1/docs/FormApi.md
index c823e4b82a..56841c42d4 100644
--- a/samples/client/echo_api/python-pydantic-v1/docs/FormApi.md
+++ b/samples/client/echo_api/python-pydantic-v1/docs/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost:3000*
Method | HTTP request | Description
------------- | ------------- | -------------
[**test_form_integer_boolean_string**](FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+[**test_form_object_multipart**](FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
[**test_form_oneof**](FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
@@ -78,6 +79,73 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+# **test_form_object_multipart**
+> str test_form_object_multipart(marker)
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Example
+
+```python
+import time
+import os
+import openapi_client
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+from openapi_client.rest import ApiException
+from pprint import pprint
+
+# Defining the host is optional and defaults to http://localhost:3000
+# See configuration.py for a list of all supported configuration parameters.
+configuration = openapi_client.Configuration(
+ host = "http://localhost:3000"
+)
+
+
+# Enter a context with an instance of the API client
+with openapi_client.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = openapi_client.FormApi(api_client)
+ marker = openapi_client.TestFormObjectMultipartRequestMarker() # TestFormObjectMultipartRequestMarker |
+
+ try:
+ # Test form parameter(s) for multipart schema
+ api_response = api_instance.test_form_object_multipart(marker)
+ print("The response of FormApi->test_form_object_multipart:\n")
+ pprint(api_response)
+ except Exception as e:
+ print("Exception when calling FormApi->test_form_object_multipart: %s\n" % e)
+```
+
+
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **marker** | [**TestFormObjectMultipartRequestMarker**](TestFormObjectMultipartRequestMarker.md)| |
+
+### Return type
+
+**str**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+ - **Content-Type**: multipart/form-data
+ - **Accept**: text/plain
+
+### HTTP response details
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+**200** | Successful operation | - |
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
# **test_form_oneof**
> str test_form_oneof(form1=form1, form2=form2, form3=form3, form4=form4, id=id, name=name)
diff --git a/samples/client/echo_api/python-pydantic-v1/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/python-pydantic-v1/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..bccc9a9405
--- /dev/null
+++ b/samples/client/echo_api/python-pydantic-v1/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,28 @@
+# TestFormObjectMultipartRequestMarker
+
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **str** | | [optional]
+
+## Example
+
+```python
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of TestFormObjectMultipartRequestMarker from a JSON string
+test_form_object_multipart_request_marker_instance = TestFormObjectMultipartRequestMarker.from_json(json)
+# print the JSON string representation of the object
+print TestFormObjectMultipartRequestMarker.to_json()
+
+# convert the object into a dict
+test_form_object_multipart_request_marker_dict = test_form_object_multipart_request_marker_instance.to_dict()
+# create an instance of TestFormObjectMultipartRequestMarker from a dict
+test_form_object_multipart_request_marker_form_dict = test_form_object_multipart_request_marker.from_dict(test_form_object_multipart_request_marker_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/__init__.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/__init__.py
index 7b67f7c597..3f63fe12ab 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/__init__.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/__init__.py
@@ -46,5 +46,6 @@ from openapi_client.models.pet import Pet
from openapi_client.models.query import Query
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.tag import Tag
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.models.test_query_style_deep_object_explode_true_object_all_of_query_object_parameter import TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/api/form_api.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/api/form_api.py
index 7b0f9720c6..4d33489816 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/api/form_api.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/api/form_api.py
@@ -23,6 +23,7 @@ from pydantic import StrictBool, StrictInt, StrictStr
from typing import Optional
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.api_client import ApiClient
from openapi_client.api_response import ApiResponse
@@ -207,6 +208,153 @@ class FormApi:
collection_formats=_collection_formats,
_request_auth=_params.get('_request_auth'))
+ @validate_arguments
+ def test_form_object_multipart(self, marker : TestFormObjectMultipartRequestMarker, **kwargs) -> str: # noqa: E501
+ """Test form parameter(s) for multipart schema # noqa: E501
+
+ Test form parameter(s) for multipart schema # noqa: E501
+ This method makes a synchronous HTTP request by default. To make an
+ asynchronous HTTP request, please pass async_req=True
+
+ >>> thread = api.test_form_object_multipart(marker, async_req=True)
+ >>> result = thread.get()
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
+ :param _request_timeout: timeout setting for this request.
+ If one number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :return: Returns the result object.
+ If the method is called asynchronously,
+ returns the request thread.
+ :rtype: str
+ """
+ kwargs['_return_http_data_only'] = True
+ if '_preload_content' in kwargs:
+ message = "Error! Please call the test_form_object_multipart_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data" # noqa: E501
+ raise ValueError(message)
+ return self.test_form_object_multipart_with_http_info(marker, **kwargs) # noqa: E501
+
+ @validate_arguments
+ def test_form_object_multipart_with_http_info(self, marker : TestFormObjectMultipartRequestMarker, **kwargs) -> ApiResponse: # noqa: E501
+ """Test form parameter(s) for multipart schema # noqa: E501
+
+ Test form parameter(s) for multipart schema # noqa: E501
+ This method makes a synchronous HTTP request by default. To make an
+ asynchronous HTTP request, please pass async_req=True
+
+ >>> thread = api.test_form_object_multipart_with_http_info(marker, async_req=True)
+ >>> result = thread.get()
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param async_req: Whether to execute the request asynchronously.
+ :type async_req: bool, optional
+ :param _preload_content: if False, the ApiResponse.data will
+ be set to none and raw_data will store the
+ HTTP response body without reading/decoding.
+ Default is True.
+ :type _preload_content: bool, optional
+ :param _return_http_data_only: response data instead of ApiResponse
+ object with status code, headers, etc
+ :type _return_http_data_only: bool, optional
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the authentication
+ in the spec for a single request.
+ :type _request_auth: dict, optional
+ :type _content_type: string, optional: force content-type for the request
+ :return: Returns the result object.
+ If the method is called asynchronously,
+ returns the request thread.
+ :rtype: tuple(str, status_code(int), headers(HTTPHeaderDict))
+ """
+
+ _params = locals()
+
+ _all_params = [
+ 'marker'
+ ]
+ _all_params.extend(
+ [
+ 'async_req',
+ '_return_http_data_only',
+ '_preload_content',
+ '_request_timeout',
+ '_request_auth',
+ '_content_type',
+ '_headers'
+ ]
+ )
+
+ # validate the arguments
+ for _key, _val in _params['kwargs'].items():
+ if _key not in _all_params:
+ raise ApiTypeError(
+ "Got an unexpected keyword argument '%s'"
+ " to method test_form_object_multipart" % _key
+ )
+ _params[_key] = _val
+ del _params['kwargs']
+
+ _collection_formats = {}
+
+ # process the path parameters
+ _path_params = {}
+
+ # process the query parameters
+ _query_params = []
+ # process the header parameters
+ _header_params = dict(_params.get('_headers', {}))
+ # process the form parameters
+ _form_params = []
+ _files = {}
+ if _params['marker'] is not None:
+ _form_params.append(('marker', _params['marker']))
+
+ # process the body parameter
+ _body_params = None
+ # set the HTTP header `Accept`
+ _header_params['Accept'] = self.api_client.select_header_accept(
+ ['text/plain']) # noqa: E501
+
+ # set the HTTP header `Content-Type`
+ _content_types_list = _params.get('_content_type',
+ self.api_client.select_header_content_type(
+ ['multipart/form-data']))
+ if _content_types_list:
+ _header_params['Content-Type'] = _content_types_list
+
+ # authentication setting
+ _auth_settings = [] # noqa: E501
+
+ _response_types_map = {
+ '200': "str",
+ }
+
+ return self.api_client.call_api(
+ '/form/object/multipart', 'POST',
+ _path_params,
+ _query_params,
+ _header_params,
+ body=_body_params,
+ post_params=_form_params,
+ files=_files,
+ response_types_map=_response_types_map,
+ auth_settings=_auth_settings,
+ async_req=_params.get('async_req'),
+ _return_http_data_only=_params.get('_return_http_data_only'), # noqa: E501
+ _preload_content=_params.get('_preload_content', True),
+ _request_timeout=_params.get('_request_timeout'),
+ collection_formats=_collection_formats,
+ _request_auth=_params.get('_request_auth'))
+
@validate_arguments
def test_form_oneof(self, form1 : Optional[StrictStr] = None, form2 : Optional[StrictInt] = None, form3 : Optional[StrictStr] = None, form4 : Optional[StrictBool] = None, id : Optional[StrictInt] = None, name : Optional[StrictStr] = None, **kwargs) -> str: # noqa: E501
"""Test form parameter(s) for oneOf schema # noqa: E501
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/__init__.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/__init__.py
index 4b981699e6..f070f63231 100644
--- a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/__init__.py
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/__init__.py
@@ -24,5 +24,6 @@ from openapi_client.models.pet import Pet
from openapi_client.models.query import Query
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.tag import Tag
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.models.test_query_style_deep_object_explode_true_object_all_of_query_object_parameter import TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
diff --git a/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py
new file mode 100644
index 0000000000..54ea54fd8d
--- /dev/null
+++ b/samples/client/echo_api/python-pydantic-v1/openapi_client/models/test_form_object_multipart_request_marker.py
@@ -0,0 +1,72 @@
+# coding: utf-8
+
+"""
+ Echo Server API
+
+ Echo Server API
+
+ The version of the OpenAPI document: 0.1.0
+ Contact: team@openapitools.org
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+from __future__ import annotations
+import pprint
+import re # noqa: F401
+import json
+
+
+from typing import Optional
+from pydantic import BaseModel, StrictStr
+
+class TestFormObjectMultipartRequestMarker(BaseModel):
+ """
+ TestFormObjectMultipartRequestMarker
+ """
+ name: Optional[StrictStr] = None
+ __properties = ["name"]
+
+ class Config:
+ """Pydantic configuration"""
+ allow_population_by_field_name = True
+ validate_assignment = True
+
+ def to_str(self) -> str:
+ """Returns the string representation of the model using alias"""
+ return pprint.pformat(self.dict(by_alias=True))
+
+ def to_json(self) -> str:
+ """Returns the JSON representation of the model using alias"""
+ return json.dumps(self.to_dict())
+
+ @classmethod
+ def from_json(cls, json_str: str) -> TestFormObjectMultipartRequestMarker:
+ """Create an instance of TestFormObjectMultipartRequestMarker from a JSON string"""
+ return cls.from_dict(json.loads(json_str))
+
+ def to_dict(self):
+ """Returns the dictionary representation of the model using alias"""
+ _dict = self.dict(by_alias=True,
+ exclude={
+ },
+ exclude_none=True)
+ return _dict
+
+ @classmethod
+ def from_dict(cls, obj: dict) -> TestFormObjectMultipartRequestMarker:
+ """Create an instance of TestFormObjectMultipartRequestMarker from a dict"""
+ if obj is None:
+ return None
+
+ if not isinstance(obj, dict):
+ return TestFormObjectMultipartRequestMarker.parse_obj(obj)
+
+ _obj = TestFormObjectMultipartRequestMarker.parse_obj({
+ "name": obj.get("name")
+ })
+ return _obj
+
+
diff --git a/samples/client/echo_api/python-pydantic-v1/test/test_test_form_object_multipart_request_marker.py b/samples/client/echo_api/python-pydantic-v1/test/test_test_form_object_multipart_request_marker.py
new file mode 100644
index 0000000000..4dfd5a5c62
--- /dev/null
+++ b/samples/client/echo_api/python-pydantic-v1/test/test_test_form_object_multipart_request_marker.py
@@ -0,0 +1,53 @@
+# coding: utf-8
+
+"""
+ Echo Server API
+
+ Echo Server API
+
+ The version of the OpenAPI document: 0.1.0
+ Contact: team@openapitools.org
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+import unittest
+import datetime
+
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker # noqa: E501
+
+class TestTestFormObjectMultipartRequestMarker(unittest.TestCase):
+ """TestFormObjectMultipartRequestMarker unit test stubs"""
+
+ def setUp(self):
+ pass
+
+ def tearDown(self):
+ pass
+
+ def make_instance(self, include_optional) -> TestFormObjectMultipartRequestMarker:
+ """Test TestFormObjectMultipartRequestMarker
+ include_option is a boolean, when False only required
+ params are included, when True both required and
+ optional params are included """
+ # uncomment below to create an instance of `TestFormObjectMultipartRequestMarker`
+ """
+ model = TestFormObjectMultipartRequestMarker() # noqa: E501
+ if include_optional:
+ return TestFormObjectMultipartRequestMarker(
+ name = ''
+ )
+ else:
+ return TestFormObjectMultipartRequestMarker(
+ )
+ """
+
+ def testTestFormObjectMultipartRequestMarker(self):
+ """Test TestFormObjectMultipartRequestMarker"""
+ # inst_req_only = self.make_instance(include_optional=False)
+ # inst_req_and_optional = self.make_instance(include_optional=True)
+
+if __name__ == '__main__':
+ unittest.main()
diff --git a/samples/client/echo_api/python/.openapi-generator/FILES b/samples/client/echo_api/python/.openapi-generator/FILES
index 0723c3ab0d..a7c64d3f55 100644
--- a/samples/client/echo_api/python/.openapi-generator/FILES
+++ b/samples/client/echo_api/python/.openapi-generator/FILES
@@ -18,6 +18,7 @@ docs/Query.md
docs/QueryApi.md
docs/StringEnumRef.md
docs/Tag.md
+docs/TestFormObjectMultipartRequestMarker.md
docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
@@ -43,6 +44,7 @@ openapi_client/models/pet.py
openapi_client/models/query.py
openapi_client/models/string_enum_ref.py
openapi_client/models/tag.py
+openapi_client/models/test_form_object_multipart_request_marker.py
openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.py
openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.py
openapi_client/py.typed
diff --git a/samples/client/echo_api/python/README.md b/samples/client/echo_api/python/README.md
index 42487c28d4..22e4678998 100644
--- a/samples/client/echo_api/python/README.md
+++ b/samples/client/echo_api/python/README.md
@@ -107,6 +107,7 @@ Class | Method | HTTP request | Description
*BodyApi* | [**test_echo_body_string_enum**](docs/BodyApi.md#test_echo_body_string_enum) | **POST** /echo/body/string_enum | Test string enum response body
*BodyApi* | [**test_echo_body_tag_response_string**](docs/BodyApi.md#test_echo_body_tag_response_string) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*FormApi* | [**test_form_integer_boolean_string**](docs/FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*FormApi* | [**test_form_object_multipart**](docs/FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*FormApi* | [**test_form_oneof**](docs/FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*HeaderApi* | [**test_header_integer_boolean_string_enums**](docs/HeaderApi.md#test_header_integer_boolean_string_enums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*PathApi* | [**tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path**](docs/PathApi.md#tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -133,6 +134,7 @@ Class | Method | HTTP request | Description
- [Query](docs/Query.md)
- [StringEnumRef](docs/StringEnumRef.md)
- [Tag](docs/Tag.md)
+ - [TestFormObjectMultipartRequestMarker](docs/TestFormObjectMultipartRequestMarker.md)
- [TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/python/docs/FormApi.md b/samples/client/echo_api/python/docs/FormApi.md
index 94205cd60e..86ae2be369 100644
--- a/samples/client/echo_api/python/docs/FormApi.md
+++ b/samples/client/echo_api/python/docs/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost:3000*
Method | HTTP request | Description
------------- | ------------- | -------------
[**test_form_integer_boolean_string**](FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+[**test_form_object_multipart**](FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
[**test_form_oneof**](FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
@@ -79,6 +80,74 @@ No authorization required
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+# **test_form_object_multipart**
+> str test_form_object_multipart(marker)
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Example
+
+
+```python
+import openapi_client
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+from openapi_client.rest import ApiException
+from pprint import pprint
+
+# Defining the host is optional and defaults to http://localhost:3000
+# See configuration.py for a list of all supported configuration parameters.
+configuration = openapi_client.Configuration(
+ host = "http://localhost:3000"
+)
+
+
+# Enter a context with an instance of the API client
+with openapi_client.ApiClient(configuration) as api_client:
+ # Create an instance of the API class
+ api_instance = openapi_client.FormApi(api_client)
+ marker = openapi_client.TestFormObjectMultipartRequestMarker() # TestFormObjectMultipartRequestMarker |
+
+ try:
+ # Test form parameter(s) for multipart schema
+ api_response = api_instance.test_form_object_multipart(marker)
+ print("The response of FormApi->test_form_object_multipart:\n")
+ pprint(api_response)
+ except Exception as e:
+ print("Exception when calling FormApi->test_form_object_multipart: %s\n" % e)
+```
+
+
+
+### Parameters
+
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **marker** | [**TestFormObjectMultipartRequestMarker**](TestFormObjectMultipartRequestMarker.md)| |
+
+### Return type
+
+**str**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+ - **Content-Type**: multipart/form-data
+ - **Accept**: text/plain
+
+### HTTP response details
+
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+**200** | Successful operation | - |
+
+[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
+
# **test_form_oneof**
> str test_form_oneof(form1=form1, form2=form2, form3=form3, form4=form4, id=id, name=name)
diff --git a/samples/client/echo_api/python/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/python/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..254c3b6a04
--- /dev/null
+++ b/samples/client/echo_api/python/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,29 @@
+# TestFormObjectMultipartRequestMarker
+
+
+## Properties
+
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **str** | | [optional]
+
+## Example
+
+```python
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+
+# TODO update the JSON string below
+json = "{}"
+# create an instance of TestFormObjectMultipartRequestMarker from a JSON string
+test_form_object_multipart_request_marker_instance = TestFormObjectMultipartRequestMarker.from_json(json)
+# print the JSON string representation of the object
+print(TestFormObjectMultipartRequestMarker.to_json())
+
+# convert the object into a dict
+test_form_object_multipart_request_marker_dict = test_form_object_multipart_request_marker_instance.to_dict()
+# create an instance of TestFormObjectMultipartRequestMarker from a dict
+test_form_object_multipart_request_marker_form_dict = test_form_object_multipart_request_marker.from_dict(test_form_object_multipart_request_marker_dict)
+```
+[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
+
+
diff --git a/samples/client/echo_api/python/openapi_client/__init__.py b/samples/client/echo_api/python/openapi_client/__init__.py
index 7b67f7c597..3f63fe12ab 100644
--- a/samples/client/echo_api/python/openapi_client/__init__.py
+++ b/samples/client/echo_api/python/openapi_client/__init__.py
@@ -46,5 +46,6 @@ from openapi_client.models.pet import Pet
from openapi_client.models.query import Query
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.tag import Tag
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.models.test_query_style_deep_object_explode_true_object_all_of_query_object_parameter import TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
diff --git a/samples/client/echo_api/python/openapi_client/api/form_api.py b/samples/client/echo_api/python/openapi_client/api/form_api.py
index 7c0959bd94..48f4dcf80b 100644
--- a/samples/client/echo_api/python/openapi_client/api/form_api.py
+++ b/samples/client/echo_api/python/openapi_client/api/form_api.py
@@ -19,6 +19,7 @@ from typing_extensions import Annotated
from pydantic import StrictBool, StrictInt, StrictStr
from typing import Optional
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.api_client import ApiClient, RequestSerialized
from openapi_client.api_response import ApiResponse
@@ -338,6 +339,276 @@ class FormApi:
+ @validate_call
+ def test_form_object_multipart(
+ self,
+ marker: TestFormObjectMultipartRequestMarker,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> str:
+ """Test form parameter(s) for multipart schema
+
+ Test form parameter(s) for multipart schema
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._test_form_object_multipart_serialize(
+ marker=marker,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "str",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ ).data
+
+
+ @validate_call
+ def test_form_object_multipart_with_http_info(
+ self,
+ marker: TestFormObjectMultipartRequestMarker,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> ApiResponse[str]:
+ """Test form parameter(s) for multipart schema
+
+ Test form parameter(s) for multipart schema
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._test_form_object_multipart_serialize(
+ marker=marker,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "str",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ response_data.read()
+ return self.api_client.response_deserialize(
+ response_data=response_data,
+ response_types_map=_response_types_map,
+ )
+
+
+ @validate_call
+ def test_form_object_multipart_without_preload_content(
+ self,
+ marker: TestFormObjectMultipartRequestMarker,
+ _request_timeout: Union[
+ None,
+ Annotated[StrictFloat, Field(gt=0)],
+ Tuple[
+ Annotated[StrictFloat, Field(gt=0)],
+ Annotated[StrictFloat, Field(gt=0)]
+ ]
+ ] = None,
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
+ _content_type: Optional[StrictStr] = None,
+ _headers: Optional[Dict[StrictStr, Any]] = None,
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
+ ) -> RESTResponseType:
+ """Test form parameter(s) for multipart schema
+
+ Test form parameter(s) for multipart schema
+
+ :param marker: (required)
+ :type marker: TestFormObjectMultipartRequestMarker
+ :param _request_timeout: timeout setting for this request. If one
+ number provided, it will be total request
+ timeout. It can also be a pair (tuple) of
+ (connection, read) timeouts.
+ :type _request_timeout: int, tuple(int, int), optional
+ :param _request_auth: set to override the auth_settings for an a single
+ request; this effectively ignores the
+ authentication in the spec for a single request.
+ :type _request_auth: dict, optional
+ :param _content_type: force content-type for the request.
+ :type _content_type: str, Optional
+ :param _headers: set to override the headers for a single
+ request; this effectively ignores the headers
+ in the spec for a single request.
+ :type _headers: dict, optional
+ :param _host_index: set to override the host_index for a single
+ request; this effectively ignores the host_index
+ in the spec for a single request.
+ :type _host_index: int, optional
+ :return: Returns the result object.
+ """ # noqa: E501
+
+ _param = self._test_form_object_multipart_serialize(
+ marker=marker,
+ _request_auth=_request_auth,
+ _content_type=_content_type,
+ _headers=_headers,
+ _host_index=_host_index
+ )
+
+ _response_types_map: Dict[str, Optional[str]] = {
+ '200': "str",
+ }
+ response_data = self.api_client.call_api(
+ *_param,
+ _request_timeout=_request_timeout
+ )
+ return response_data.response
+
+
+ def _test_form_object_multipart_serialize(
+ self,
+ marker,
+ _request_auth,
+ _content_type,
+ _headers,
+ _host_index,
+ ) -> RequestSerialized:
+
+ _host = None
+
+ _collection_formats: Dict[str, str] = {
+ }
+
+ _path_params: Dict[str, str] = {}
+ _query_params: List[Tuple[str, str]] = []
+ _header_params: Dict[str, Optional[str]] = _headers or {}
+ _form_params: List[Tuple[str, str]] = []
+ _files: Dict[str, Union[str, bytes]] = {}
+ _body_params: Optional[bytes] = None
+
+ # process the path parameters
+ # process the query parameters
+ # process the header parameters
+ # process the form parameters
+ if marker is not None:
+ _form_params.append(('marker', marker))
+ # process the body parameter
+
+
+ # set the HTTP header `Accept`
+ _header_params['Accept'] = self.api_client.select_header_accept(
+ [
+ 'text/plain'
+ ]
+ )
+
+ # set the HTTP header `Content-Type`
+ if _content_type:
+ _header_params['Content-Type'] = _content_type
+ else:
+ _default_content_type = (
+ self.api_client.select_header_content_type(
+ [
+ 'multipart/form-data'
+ ]
+ )
+ )
+ if _default_content_type is not None:
+ _header_params['Content-Type'] = _default_content_type
+
+ # authentication setting
+ _auth_settings: List[str] = [
+ ]
+
+ return self.api_client.param_serialize(
+ method='POST',
+ resource_path='/form/object/multipart',
+ path_params=_path_params,
+ query_params=_query_params,
+ header_params=_header_params,
+ body=_body_params,
+ post_params=_form_params,
+ files=_files,
+ auth_settings=_auth_settings,
+ collection_formats=_collection_formats,
+ _host=_host,
+ _request_auth=_request_auth
+ )
+
+
+
+
@validate_call
def test_form_oneof(
self,
diff --git a/samples/client/echo_api/python/openapi_client/models/__init__.py b/samples/client/echo_api/python/openapi_client/models/__init__.py
index 4b981699e6..f070f63231 100644
--- a/samples/client/echo_api/python/openapi_client/models/__init__.py
+++ b/samples/client/echo_api/python/openapi_client/models/__init__.py
@@ -24,5 +24,6 @@ from openapi_client.models.pet import Pet
from openapi_client.models.query import Query
from openapi_client.models.string_enum_ref import StringEnumRef
from openapi_client.models.tag import Tag
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
from openapi_client.models.test_query_style_deep_object_explode_true_object_all_of_query_object_parameter import TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter
from openapi_client.models.test_query_style_form_explode_true_array_string_query_object_parameter import TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter
diff --git a/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py
new file mode 100644
index 0000000000..9f7747151b
--- /dev/null
+++ b/samples/client/echo_api/python/openapi_client/models/test_form_object_multipart_request_marker.py
@@ -0,0 +1,88 @@
+# coding: utf-8
+
+"""
+ Echo Server API
+
+ Echo Server API
+
+ The version of the OpenAPI document: 0.1.0
+ Contact: team@openapitools.org
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+from __future__ import annotations
+import pprint
+import re # noqa: F401
+import json
+
+from pydantic import BaseModel, ConfigDict, StrictStr
+from typing import Any, ClassVar, Dict, List, Optional
+from typing import Optional, Set
+from typing_extensions import Self
+
+class TestFormObjectMultipartRequestMarker(BaseModel):
+ """
+ TestFormObjectMultipartRequestMarker
+ """ # noqa: E501
+ name: Optional[StrictStr] = None
+ __properties: ClassVar[List[str]] = ["name"]
+
+ model_config = ConfigDict(
+ populate_by_name=True,
+ validate_assignment=True,
+ protected_namespaces=(),
+ )
+
+
+ def to_str(self) -> str:
+ """Returns the string representation of the model using alias"""
+ return pprint.pformat(self.model_dump(by_alias=True))
+
+ def to_json(self) -> str:
+ """Returns the JSON representation of the model using alias"""
+ # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead
+ return json.dumps(self.to_dict())
+
+ @classmethod
+ def from_json(cls, json_str: str) -> Optional[Self]:
+ """Create an instance of TestFormObjectMultipartRequestMarker from a JSON string"""
+ return cls.from_dict(json.loads(json_str))
+
+ def to_dict(self) -> Dict[str, Any]:
+ """Return the dictionary representation of the model using alias.
+
+ This has the following differences from calling pydantic's
+ `self.model_dump(by_alias=True)`:
+
+ * `None` is only added to the output dict for nullable fields that
+ were set at model initialization. Other fields with value `None`
+ are ignored.
+ """
+ excluded_fields: Set[str] = set([
+ ])
+
+ _dict = self.model_dump(
+ by_alias=True,
+ exclude=excluded_fields,
+ exclude_none=True,
+ )
+ return _dict
+
+ @classmethod
+ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
+ """Create an instance of TestFormObjectMultipartRequestMarker from a dict"""
+ if obj is None:
+ return None
+
+ if not isinstance(obj, dict):
+ return cls.model_validate(obj)
+
+ _obj = cls.model_validate({
+ "name": obj.get("name")
+ })
+ return _obj
+
+
diff --git a/samples/client/echo_api/python/test/test_test_form_object_multipart_request_marker.py b/samples/client/echo_api/python/test/test_test_form_object_multipart_request_marker.py
new file mode 100644
index 0000000000..d499742860
--- /dev/null
+++ b/samples/client/echo_api/python/test/test_test_form_object_multipart_request_marker.py
@@ -0,0 +1,52 @@
+# coding: utf-8
+
+"""
+ Echo Server API
+
+ Echo Server API
+
+ The version of the OpenAPI document: 0.1.0
+ Contact: team@openapitools.org
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
+
+ Do not edit the class manually.
+""" # noqa: E501
+
+
+import unittest
+
+from openapi_client.models.test_form_object_multipart_request_marker import TestFormObjectMultipartRequestMarker
+
+class TestTestFormObjectMultipartRequestMarker(unittest.TestCase):
+ """TestFormObjectMultipartRequestMarker unit test stubs"""
+
+ def setUp(self):
+ pass
+
+ def tearDown(self):
+ pass
+
+ def make_instance(self, include_optional) -> TestFormObjectMultipartRequestMarker:
+ """Test TestFormObjectMultipartRequestMarker
+ include_option is a boolean, when False only required
+ params are included, when True both required and
+ optional params are included """
+ # uncomment below to create an instance of `TestFormObjectMultipartRequestMarker`
+ """
+ model = TestFormObjectMultipartRequestMarker()
+ if include_optional:
+ return TestFormObjectMultipartRequestMarker(
+ name = ''
+ )
+ else:
+ return TestFormObjectMultipartRequestMarker(
+ )
+ """
+
+ def testTestFormObjectMultipartRequestMarker(self):
+ """Test TestFormObjectMultipartRequestMarker"""
+ # inst_req_only = self.make_instance(include_optional=False)
+ # inst_req_and_optional = self.make_instance(include_optional=True)
+
+if __name__ == '__main__':
+ unittest.main()
diff --git a/samples/client/echo_api/python/tests/test_manual.py b/samples/client/echo_api/python/tests/test_manual.py
index 02737e9578..42ae3aafd8 100644
--- a/samples/client/echo_api/python/tests/test_manual.py
+++ b/samples/client/echo_api/python/tests/test_manual.py
@@ -265,6 +265,19 @@ User-Agent: OpenAPI-Generator/1.0.0/python
self.assertEqual(e.headers["Accept"], 'text/plain')
self.assertEqual(e.method, 'POST')
+ def test_form_object_multipart(self):
+ api_instance = openapi_client.FormApi()
+ marker = openapi_client.TestFormObjectMultipartRequestMarker(
+ name="name",
+ )
+ api_response = api_instance.test_form_object_multipart(
+ marker=marker,
+ )
+ e = EchoServerResponseParser(api_response)
+ self.assertEqual(e.path, "/form/object/multipart")
+ self.assertTrue(e.headers["Content-Type"].startswith("multipart/form-data"))
+ self.assertTrue("boundary=" in e.headers["Content-Type"])
+
class EchoServerResponseParser():
def __init__(self, http_response):
if http_response is None:
diff --git a/samples/client/echo_api/r/.openapi-generator/FILES b/samples/client/echo_api/r/.openapi-generator/FILES
index 00661ff72f..cf3034e39d 100644
--- a/samples/client/echo_api/r/.openapi-generator/FILES
+++ b/samples/client/echo_api/r/.openapi-generator/FILES
@@ -22,6 +22,7 @@ R/query.R
R/query_api.R
R/string_enum_ref.R
R/tag.R
+R/test_form_object_multipart_request_marker.R
R/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.R
R/test_query_style_form_explode_true_array_string_query_object_parameter.R
README.md
@@ -40,6 +41,7 @@ docs/Query.md
docs/QueryApi.md
docs/StringEnumRef.md
docs/Tag.md
+docs/TestFormObjectMultipartRequestMarker.md
docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
diff --git a/samples/client/echo_api/r/NAMESPACE b/samples/client/echo_api/r/NAMESPACE
index ba08b5eee5..c4148c7cee 100644
--- a/samples/client/echo_api/r/NAMESPACE
+++ b/samples/client/echo_api/r/NAMESPACE
@@ -22,6 +22,7 @@ export(Pet)
export(Query)
export(StringEnumRef)
export(Tag)
+export(TestFormObjectMultipartRequestMarker)
export(TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter)
export(TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter)
diff --git a/samples/client/echo_api/r/R/form_api.R b/samples/client/echo_api/r/R/form_api.R
index a25adbde06..17f7c520ca 100644
--- a/samples/client/echo_api/r/R/form_api.R
+++ b/samples/client/echo_api/r/R/form_api.R
@@ -32,6 +32,22 @@
#' }
#' }
#'
+#' \strong{ TestFormObjectMultipart } \emph{ Test form parameter(s) for multipart schema }
+#' Test form parameter(s) for multipart schema
+#'
+#' \itemize{
+#' \item \emph{ @param } marker \link{TestFormObjectMultipartRequestMarker}
+#'
+#'
+#' \item status code : 200 | Successful operation
+#'
+#' \item return type : character
+#' \item response headers :
+#'
+#' \tabular{ll}{
+#' }
+#' }
+#'
#' \strong{ TestFormOneof } \emph{ Test form parameter(s) for oneOf schema }
#' Test form parameter(s) for oneOf schema
#'
@@ -74,6 +90,20 @@
#' dput(result)
#'
#'
+#' #################### TestFormObjectMultipart ####################
+#'
+#' library(openapi)
+#' var_marker <- test_form_object_multipart_request_marker$new("name_example") # TestFormObjectMultipartRequestMarker |
+#'
+#' #Test form parameter(s) for multipart schema
+#' api_instance <- FormApi$new()
+#'
+#' # to save the result into a file, simply add the optional `data_file` parameter, e.g.
+#' # result <- api_instance$TestFormObjectMultipart(var_markerdata_file = "result.txt")
+#' result <- api_instance$TestFormObjectMultipart(var_marker)
+#' dput(result)
+#'
+#'
#' #################### TestFormOneof ####################
#'
#' library(openapi)
@@ -213,6 +243,100 @@ FormApi <- R6::R6Class(
local_var_resp
}
},
+ #' Test form parameter(s) for multipart schema
+ #'
+ #' @description
+ #' Test form parameter(s) for multipart schema
+ #'
+ #' @param marker
+ #' @param data_file (optional) name of the data file to save the result
+ #' @param ... Other optional arguments
+ #' @return character
+ #' @export
+ TestFormObjectMultipart = function(marker, data_file = NULL, ...) {
+ local_var_response <- self$TestFormObjectMultipartWithHttpInfo(marker, data_file = data_file, ...)
+ if (local_var_response$status_code >= 200 && local_var_response$status_code <= 299) {
+ local_var_response$content
+ } else if (local_var_response$status_code >= 300 && local_var_response$status_code <= 399) {
+ local_var_response
+ } else if (local_var_response$status_code >= 400 && local_var_response$status_code <= 499) {
+ local_var_response
+ } else if (local_var_response$status_code >= 500 && local_var_response$status_code <= 599) {
+ local_var_response
+ }
+ },
+ #' Test form parameter(s) for multipart schema
+ #'
+ #' @description
+ #' Test form parameter(s) for multipart schema
+ #'
+ #' @param marker
+ #' @param data_file (optional) name of the data file to save the result
+ #' @param ... Other optional arguments
+ #' @return API response (character) with additional information such as HTTP status code, headers
+ #' @export
+ TestFormObjectMultipartWithHttpInfo = function(marker, data_file = NULL, ...) {
+ args <- list(...)
+ query_params <- list()
+ header_params <- c()
+ form_params <- list()
+ file_params <- list()
+ local_var_body <- NULL
+ oauth_scopes <- NULL
+ is_oauth <- FALSE
+
+ if (missing(`marker`)) {
+ stop("Missing required parameter `marker`.")
+ }
+
+
+ form_params["marker"] <- `marker`
+ local_var_url_path <- "/form/object/multipart"
+
+ # The Accept request HTTP header
+ local_var_accepts <- list("text/plain")
+
+ # The Content-Type representation header
+ local_var_content_types <- list("multipart/form-data")
+
+ local_var_resp <- self$api_client$CallApi(url = paste0(self$api_client$base_path, local_var_url_path),
+ method = "POST",
+ query_params = query_params,
+ header_params = header_params,
+ form_params = form_params,
+ file_params = file_params,
+ accepts = local_var_accepts,
+ content_types = local_var_content_types,
+ body = local_var_body,
+ is_oauth = is_oauth,
+ oauth_scopes = oauth_scopes,
+ ...)
+
+ if (local_var_resp$status_code >= 200 && local_var_resp$status_code <= 299) {
+ # save response in a file
+ if (!is.null(data_file)) {
+ write(local_var_resp$response, data_file)
+ }
+
+ deserialized_resp_obj <- tryCatch(
+ self$api_client$deserialize(local_var_resp$response_as_text(), "character", loadNamespace("openapi")),
+ error = function(e) {
+ stop("Failed to deserialize response")
+ }
+ )
+ local_var_resp$content <- deserialized_resp_obj
+ local_var_resp
+ } else if (local_var_resp$status_code >= 300 && local_var_resp$status_code <= 399) {
+ ApiResponse$new(paste("Server returned ", local_var_resp$status_code, " response status code."), local_var_resp)
+ } else if (local_var_resp$status_code >= 400 && local_var_resp$status_code <= 499) {
+ ApiResponse$new("API client error", local_var_resp)
+ } else if (local_var_resp$status_code >= 500 && local_var_resp$status_code <= 599) {
+ if (is.null(local_var_resp$response) || local_var_resp$response == "") {
+ local_var_resp$response <- "API server error"
+ }
+ local_var_resp
+ }
+ },
#' Test form parameter(s) for oneOf schema
#'
#' @description
diff --git a/samples/client/echo_api/r/R/test_form_object_multipart_request_marker.R b/samples/client/echo_api/r/R/test_form_object_multipart_request_marker.R
new file mode 100644
index 0000000000..0be30ca5f6
--- /dev/null
+++ b/samples/client/echo_api/r/R/test_form_object_multipart_request_marker.R
@@ -0,0 +1,163 @@
+#' Create a new TestFormObjectMultipartRequestMarker
+#'
+#' @description
+#' TestFormObjectMultipartRequestMarker Class
+#'
+#' @docType class
+#' @title TestFormObjectMultipartRequestMarker
+#' @description TestFormObjectMultipartRequestMarker Class
+#' @format An \code{R6Class} generator object
+#' @field name character [optional]
+#' @importFrom R6 R6Class
+#' @importFrom jsonlite fromJSON toJSON
+#' @export
+TestFormObjectMultipartRequestMarker <- R6::R6Class(
+ "TestFormObjectMultipartRequestMarker",
+ public = list(
+ `name` = NULL,
+ #' Initialize a new TestFormObjectMultipartRequestMarker class.
+ #'
+ #' @description
+ #' Initialize a new TestFormObjectMultipartRequestMarker class.
+ #'
+ #' @param name name
+ #' @param ... Other optional arguments.
+ #' @export
+ initialize = function(`name` = NULL, ...) {
+ if (!is.null(`name`)) {
+ if (!(is.character(`name`) && length(`name`) == 1)) {
+ stop(paste("Error! Invalid data for `name`. Must be a string:", `name`))
+ }
+ self$`name` <- `name`
+ }
+ },
+ #' To JSON string
+ #'
+ #' @description
+ #' To JSON String
+ #'
+ #' @return TestFormObjectMultipartRequestMarker in JSON format
+ #' @export
+ toJSON = function() {
+ TestFormObjectMultipartRequestMarkerObject <- list()
+ if (!is.null(self$`name`)) {
+ TestFormObjectMultipartRequestMarkerObject[["name"]] <-
+ self$`name`
+ }
+ TestFormObjectMultipartRequestMarkerObject
+ },
+ #' Deserialize JSON string into an instance of TestFormObjectMultipartRequestMarker
+ #'
+ #' @description
+ #' Deserialize JSON string into an instance of TestFormObjectMultipartRequestMarker
+ #'
+ #' @param input_json the JSON input
+ #' @return the instance of TestFormObjectMultipartRequestMarker
+ #' @export
+ fromJSON = function(input_json) {
+ this_object <- jsonlite::fromJSON(input_json)
+ if (!is.null(this_object$`name`)) {
+ self$`name` <- this_object$`name`
+ }
+ self
+ },
+ #' To JSON string
+ #'
+ #' @description
+ #' To JSON String
+ #'
+ #' @return TestFormObjectMultipartRequestMarker in JSON format
+ #' @export
+ toJSONString = function() {
+ jsoncontent <- c(
+ if (!is.null(self$`name`)) {
+ sprintf(
+ '"name":
+ "%s"
+ ',
+ self$`name`
+ )
+ }
+ )
+ jsoncontent <- paste(jsoncontent, collapse = ",")
+ json_string <- as.character(jsonlite::minify(paste("{", jsoncontent, "}", sep = "")))
+ },
+ #' Deserialize JSON string into an instance of TestFormObjectMultipartRequestMarker
+ #'
+ #' @description
+ #' Deserialize JSON string into an instance of TestFormObjectMultipartRequestMarker
+ #'
+ #' @param input_json the JSON input
+ #' @return the instance of TestFormObjectMultipartRequestMarker
+ #' @export
+ fromJSONString = function(input_json) {
+ this_object <- jsonlite::fromJSON(input_json)
+ self$`name` <- this_object$`name`
+ self
+ },
+ #' Validate JSON input with respect to TestFormObjectMultipartRequestMarker
+ #'
+ #' @description
+ #' Validate JSON input with respect to TestFormObjectMultipartRequestMarker and throw an exception if invalid
+ #'
+ #' @param input the JSON input
+ #' @export
+ validateJSON = function(input) {
+ input_json <- jsonlite::fromJSON(input)
+ },
+ #' To string (JSON format)
+ #'
+ #' @description
+ #' To string (JSON format)
+ #'
+ #' @return String representation of TestFormObjectMultipartRequestMarker
+ #' @export
+ toString = function() {
+ self$toJSONString()
+ },
+ #' Return true if the values in all fields are valid.
+ #'
+ #' @description
+ #' Return true if the values in all fields are valid.
+ #'
+ #' @return true if the values in all fields are valid.
+ #' @export
+ isValid = function() {
+ TRUE
+ },
+ #' Return a list of invalid fields (if any).
+ #'
+ #' @description
+ #' Return a list of invalid fields (if any).
+ #'
+ #' @return A list of invalid fields (if any).
+ #' @export
+ getInvalidFields = function() {
+ invalid_fields <- list()
+ invalid_fields
+ },
+ #' Print the object
+ #'
+ #' @description
+ #' Print the object
+ #'
+ #' @export
+ print = function() {
+ print(jsonlite::prettify(self$toJSONString()))
+ invisible(self)
+ }
+ ),
+ # Lock the class to prevent modifications to the method or field
+ lock_class = TRUE
+)
+## Uncomment below to unlock the class to allow modifications of the method or field
+# TestFormObjectMultipartRequestMarker$unlock()
+#
+## Below is an example to define the print function
+# TestFormObjectMultipartRequestMarker$set("public", "print", function(...) {
+# print(jsonlite::prettify(self$toJSONString()))
+# invisible(self)
+# })
+## Uncomment below to lock the class to prevent modifications to the method or field
+# TestFormObjectMultipartRequestMarker$lock()
+
diff --git a/samples/client/echo_api/r/README.md b/samples/client/echo_api/r/README.md
index d2e0edd131..068477a665 100644
--- a/samples/client/echo_api/r/README.md
+++ b/samples/client/echo_api/r/README.md
@@ -86,6 +86,7 @@ Class | Method | HTTP request | Description
*BodyApi* | [**TestEchoBodyStringEnum**](docs/BodyApi.md#TestEchoBodyStringEnum) | **POST** /echo/body/string_enum | Test string enum response body
*BodyApi* | [**TestEchoBodyTagResponseString**](docs/BodyApi.md#TestEchoBodyTagResponseString) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*FormApi* | [**TestFormIntegerBooleanString**](docs/FormApi.md#TestFormIntegerBooleanString) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*FormApi* | [**TestFormObjectMultipart**](docs/FormApi.md#TestFormObjectMultipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*FormApi* | [**TestFormOneof**](docs/FormApi.md#TestFormOneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*HeaderApi* | [**TestHeaderIntegerBooleanStringEnums**](docs/HeaderApi.md#TestHeaderIntegerBooleanStringEnums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*PathApi* | [**TestsPathStringPathStringIntegerPathIntegerEnumNonrefStringPathEnumRefStringPath**](docs/PathApi.md#TestsPathStringPathStringIntegerPathIntegerEnumNonrefStringPathEnumRefStringPath) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -112,6 +113,7 @@ Class | Method | HTTP request | Description
- [Query](docs/Query.md)
- [StringEnumRef](docs/StringEnumRef.md)
- [Tag](docs/Tag.md)
+ - [TestFormObjectMultipartRequestMarker](docs/TestFormObjectMultipartRequestMarker.md)
- [TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/r/docs/FormApi.md b/samples/client/echo_api/r/docs/FormApi.md
index b444d98794..96623e44bc 100644
--- a/samples/client/echo_api/r/docs/FormApi.md
+++ b/samples/client/echo_api/r/docs/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost:3000*
Method | HTTP request | Description
------------- | ------------- | -------------
[**TestFormIntegerBooleanString**](FormApi.md#TestFormIntegerBooleanString) | **POST** /form/integer/boolean/string | Test form parameter(s)
+[**TestFormObjectMultipart**](FormApi.md#TestFormObjectMultipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
[**TestFormOneof**](FormApi.md#TestFormOneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
@@ -59,6 +60,53 @@ No authorization required
|-------------|-------------|------------------|
| **200** | Successful operation | - |
+# **TestFormObjectMultipart**
+> character TestFormObjectMultipart(marker)
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Example
+```R
+library(openapi)
+
+# Test form parameter(s) for multipart schema
+#
+# prepare function argument(s)
+var_marker <- test_form_object_multipart_request_marker$new("name_example") # TestFormObjectMultipartRequestMarker |
+
+api_instance <- FormApi$new()
+# to save the result into a file, simply add the optional `data_file` parameter, e.g.
+# result <- api_instance$TestFormObjectMultipart(var_markerdata_file = "result.txt")
+result <- api_instance$TestFormObjectMultipart(var_marker)
+dput(result)
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **marker** | [**TestFormObjectMultipartRequestMarker**](test_form_object_multipart_request_marker.md)| |
+
+### Return type
+
+**character**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+ - **Content-Type**: multipart/form-data
+ - **Accept**: text/plain
+
+### HTTP response details
+| Status code | Description | Response headers |
+|-------------|-------------|------------------|
+| **200** | Successful operation | - |
+
# **TestFormOneof**
> character TestFormOneof(form1 = var.form1, form2 = var.form2, form3 = var.form3, form4 = var.form4, id = var.id, name = var.name)
diff --git a/samples/client/echo_api/r/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/r/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..a263b985da
--- /dev/null
+++ b/samples/client/echo_api/r/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,9 @@
+# openapi::TestFormObjectMultipartRequestMarker
+
+
+## Properties
+Name | Type | Description | Notes
+------------ | ------------- | ------------- | -------------
+**name** | **character** | | [optional]
+
+
diff --git a/samples/client/echo_api/r/tests/testthat/test_test_form_object_multipart_request_marker.R b/samples/client/echo_api/r/tests/testthat/test_test_form_object_multipart_request_marker.R
new file mode 100644
index 0000000000..0a934c9fdf
--- /dev/null
+++ b/samples/client/echo_api/r/tests/testthat/test_test_form_object_multipart_request_marker.R
@@ -0,0 +1,13 @@
+# Automatically generated by openapi-generator (https://openapi-generator.tech)
+# Please update as you see appropriate
+
+context("Test TestFormObjectMultipartRequestMarker")
+
+model_instance <- TestFormObjectMultipartRequestMarker$new()
+
+test_that("name", {
+ # tests for the property `name` (character)
+
+ # uncomment below to test the property
+ #expect_equal(model.instance$`name`, "EXPECTED_RESULT")
+})
diff --git a/samples/client/echo_api/ruby-faraday/.openapi-generator/FILES b/samples/client/echo_api/ruby-faraday/.openapi-generator/FILES
index a54b808c26..dd4431c035 100644
--- a/samples/client/echo_api/ruby-faraday/.openapi-generator/FILES
+++ b/samples/client/echo_api/ruby-faraday/.openapi-generator/FILES
@@ -21,6 +21,7 @@ docs/Query.md
docs/QueryApi.md
docs/StringEnumRef.md
docs/Tag.md
+docs/TestFormObjectMultipartRequestMarker.md
docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
@@ -43,6 +44,7 @@ lib/openapi_client/models/pet.rb
lib/openapi_client/models/query.rb
lib/openapi_client/models/string_enum_ref.rb
lib/openapi_client/models/tag.rb
+lib/openapi_client/models/test_form_object_multipart_request_marker.rb
lib/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.rb
lib/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.rb
lib/openapi_client/version.rb
diff --git a/samples/client/echo_api/ruby-faraday/README.md b/samples/client/echo_api/ruby-faraday/README.md
index ea43d48e48..7cd83142ea 100644
--- a/samples/client/echo_api/ruby-faraday/README.md
+++ b/samples/client/echo_api/ruby-faraday/README.md
@@ -97,6 +97,7 @@ Class | Method | HTTP request | Description
*OpenapiClient::BodyApi* | [**test_echo_body_string_enum**](docs/BodyApi.md#test_echo_body_string_enum) | **POST** /echo/body/string_enum | Test string enum response body
*OpenapiClient::BodyApi* | [**test_echo_body_tag_response_string**](docs/BodyApi.md#test_echo_body_tag_response_string) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*OpenapiClient::FormApi* | [**test_form_integer_boolean_string**](docs/FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*OpenapiClient::FormApi* | [**test_form_object_multipart**](docs/FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*OpenapiClient::FormApi* | [**test_form_oneof**](docs/FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*OpenapiClient::HeaderApi* | [**test_header_integer_boolean_string_enums**](docs/HeaderApi.md#test_header_integer_boolean_string_enums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*OpenapiClient::PathApi* | [**tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path**](docs/PathApi.md#tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -123,6 +124,7 @@ Class | Method | HTTP request | Description
- [OpenapiClient::Query](docs/Query.md)
- [OpenapiClient::StringEnumRef](docs/StringEnumRef.md)
- [OpenapiClient::Tag](docs/Tag.md)
+ - [OpenapiClient::TestFormObjectMultipartRequestMarker](docs/TestFormObjectMultipartRequestMarker.md)
- [OpenapiClient::TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [OpenapiClient::TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/ruby-faraday/docs/FormApi.md b/samples/client/echo_api/ruby-faraday/docs/FormApi.md
index 632949e8b8..8cfafc83e8 100644
--- a/samples/client/echo_api/ruby-faraday/docs/FormApi.md
+++ b/samples/client/echo_api/ruby-faraday/docs/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost:3000*
| Method | HTTP request | Description |
| ------ | ------------ | ----------- |
| [**test_form_integer_boolean_string**](FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s) |
+| [**test_form_object_multipart**](FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema |
| [**test_form_oneof**](FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema |
@@ -78,6 +79,70 @@ No authorization required
- **Accept**: text/plain
+## test_form_object_multipart
+
+> String test_form_object_multipart(marker)
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Examples
+
+```ruby
+require 'time'
+require 'openapi_client'
+
+api_instance = OpenapiClient::FormApi.new
+marker = OpenapiClient::TestFormObjectMultipartRequestMarker.new # TestFormObjectMultipartRequestMarker |
+
+begin
+ # Test form parameter(s) for multipart schema
+ result = api_instance.test_form_object_multipart(marker)
+ p result
+rescue OpenapiClient::ApiError => e
+ puts "Error when calling FormApi->test_form_object_multipart: #{e}"
+end
+```
+
+#### Using the test_form_object_multipart_with_http_info variant
+
+This returns an Array which contains the response data, status code and headers.
+
+> test_form_object_multipart_with_http_info(marker)
+
+```ruby
+begin
+ # Test form parameter(s) for multipart schema
+ data, status_code, headers = api_instance.test_form_object_multipart_with_http_info(marker)
+ p status_code # => 2xx
+ p headers # => { ... }
+ p data # => String
+rescue OpenapiClient::ApiError => e
+ puts "Error when calling FormApi->test_form_object_multipart_with_http_info: #{e}"
+end
+```
+
+### Parameters
+
+| Name | Type | Description | Notes |
+| ---- | ---- | ----------- | ----- |
+| **marker** | [**TestFormObjectMultipartRequestMarker**](TestFormObjectMultipartRequestMarker.md) | | |
+
+### Return type
+
+**String**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+- **Content-Type**: multipart/form-data
+- **Accept**: text/plain
+
+
## test_form_oneof
> String test_form_oneof(opts)
diff --git a/samples/client/echo_api/ruby-faraday/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/ruby-faraday/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..caf8f83317
--- /dev/null
+++ b/samples/client/echo_api/ruby-faraday/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,18 @@
+# OpenapiClient::TestFormObjectMultipartRequestMarker
+
+## Properties
+
+| Name | Type | Description | Notes |
+| ---- | ---- | ----------- | ----- |
+| **name** | **String** | | [optional] |
+
+## Example
+
+```ruby
+require 'openapi_client'
+
+instance = OpenapiClient::TestFormObjectMultipartRequestMarker.new(
+ name: null
+)
+```
+
diff --git a/samples/client/echo_api/ruby-faraday/lib/openapi_client.rb b/samples/client/echo_api/ruby-faraday/lib/openapi_client.rb
index a320248f0f..7f1a8a0232 100644
--- a/samples/client/echo_api/ruby-faraday/lib/openapi_client.rb
+++ b/samples/client/echo_api/ruby-faraday/lib/openapi_client.rb
@@ -25,6 +25,7 @@ require 'openapi_client/models/pet'
require 'openapi_client/models/query'
require 'openapi_client/models/string_enum_ref'
require 'openapi_client/models/tag'
+require 'openapi_client/models/test_form_object_multipart_request_marker'
require 'openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter'
require 'openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter'
require 'openapi_client/models/data_query'
diff --git a/samples/client/echo_api/ruby-faraday/lib/openapi_client/api/form_api.rb b/samples/client/echo_api/ruby-faraday/lib/openapi_client/api/form_api.rb
index 4f6af01ac5..8725588023 100644
--- a/samples/client/echo_api/ruby-faraday/lib/openapi_client/api/form_api.rb
+++ b/samples/client/echo_api/ruby-faraday/lib/openapi_client/api/form_api.rb
@@ -90,6 +90,75 @@ module OpenapiClient
return data, status_code, headers
end
+ # Test form parameter(s) for multipart schema
+ # Test form parameter(s) for multipart schema
+ # @param marker [TestFormObjectMultipartRequestMarker]
+ # @param [Hash] opts the optional parameters
+ # @return [String]
+ def test_form_object_multipart(marker, opts = {})
+ data, _status_code, _headers = test_form_object_multipart_with_http_info(marker, opts)
+ data
+ end
+
+ # Test form parameter(s) for multipart schema
+ # Test form parameter(s) for multipart schema
+ # @param marker [TestFormObjectMultipartRequestMarker]
+ # @param [Hash] opts the optional parameters
+ # @return [Array<(String, Integer, Hash)>] String data, response status code and response headers
+ def test_form_object_multipart_with_http_info(marker, opts = {})
+ if @api_client.config.debugging
+ @api_client.config.logger.debug 'Calling API: FormApi.test_form_object_multipart ...'
+ end
+ # verify the required parameter 'marker' is set
+ if @api_client.config.client_side_validation && marker.nil?
+ fail ArgumentError, "Missing the required parameter 'marker' when calling FormApi.test_form_object_multipart"
+ end
+ # resource path
+ local_var_path = '/form/object/multipart'
+
+ # query parameters
+ query_params = opts[:query_params] || {}
+
+ # header parameters
+ header_params = opts[:header_params] || {}
+ # HTTP header 'Accept' (if needed)
+ header_params['Accept'] = @api_client.select_header_accept(['text/plain'])
+ # HTTP header 'Content-Type'
+ content_type = @api_client.select_header_content_type(['multipart/form-data'])
+ if !content_type.nil?
+ header_params['Content-Type'] = content_type
+ end
+
+ # form parameters
+ form_params = opts[:form_params] || {}
+ form_params['marker'] = marker
+
+ # http body (model)
+ post_body = opts[:debug_body]
+
+ # return_type
+ return_type = opts[:debug_return_type] || 'String'
+
+ # auth_names
+ auth_names = opts[:debug_auth_names] || []
+
+ new_options = opts.merge(
+ :operation => :"FormApi.test_form_object_multipart",
+ :header_params => header_params,
+ :query_params => query_params,
+ :form_params => form_params,
+ :body => post_body,
+ :auth_names => auth_names,
+ :return_type => return_type
+ )
+
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
+ if @api_client.config.debugging
+ @api_client.config.logger.debug "API called: FormApi#test_form_object_multipart\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
+ end
+ return data, status_code, headers
+ end
+
# Test form parameter(s) for oneOf schema
# Test form parameter(s) for oneOf schema
# @param [Hash] opts the optional parameters
diff --git a/samples/client/echo_api/ruby-faraday/lib/openapi_client/models/test_form_object_multipart_request_marker.rb b/samples/client/echo_api/ruby-faraday/lib/openapi_client/models/test_form_object_multipart_request_marker.rb
new file mode 100644
index 0000000000..253bbed63f
--- /dev/null
+++ b/samples/client/echo_api/ruby-faraday/lib/openapi_client/models/test_form_object_multipart_request_marker.rb
@@ -0,0 +1,214 @@
+=begin
+#Echo Server API
+
+#Echo Server API
+
+The version of the OpenAPI document: 0.1.0
+Contact: team@openapitools.org
+Generated by: https://openapi-generator.tech
+Generator version: 7.5.0-SNAPSHOT
+
+=end
+
+require 'date'
+require 'time'
+
+module OpenapiClient
+ class TestFormObjectMultipartRequestMarker
+ attr_accessor :name
+
+ # Attribute mapping from ruby-style variable name to JSON key.
+ def self.attribute_map
+ {
+ :'name' => :'name'
+ }
+ end
+
+ # Returns all the JSON keys this model knows about
+ def self.acceptable_attributes
+ attribute_map.values
+ end
+
+ # Attribute type mapping.
+ def self.openapi_types
+ {
+ :'name' => :'String'
+ }
+ end
+
+ # List of attributes with nullable: true
+ def self.openapi_nullable
+ Set.new([
+ ])
+ end
+
+ # Initializes the object
+ # @param [Hash] attributes Model attributes in the form of hash
+ def initialize(attributes = {})
+ if (!attributes.is_a?(Hash))
+ fail ArgumentError, "The input argument (attributes) must be a hash in `OpenapiClient::TestFormObjectMultipartRequestMarker` initialize method"
+ end
+
+ # check to see if the attribute exists and convert string to symbol for hash key
+ attributes = attributes.each_with_object({}) { |(k, v), h|
+ if (!self.class.attribute_map.key?(k.to_sym))
+ fail ArgumentError, "`#{k}` is not a valid attribute in `OpenapiClient::TestFormObjectMultipartRequestMarker`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
+ end
+ h[k.to_sym] = v
+ }
+
+ if attributes.key?(:'name')
+ self.name = attributes[:'name']
+ end
+ end
+
+ # Show invalid properties with the reasons. Usually used together with valid?
+ # @return Array for valid properties with the reasons
+ def list_invalid_properties
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
+ invalid_properties = Array.new
+ invalid_properties
+ end
+
+ # Check to see if the all the properties in the model are valid
+ # @return true if the model is valid
+ def valid?
+ warn '[DEPRECATED] the `valid?` method is obsolete'
+ true
+ end
+
+ # Checks equality by comparing each attribute.
+ # @param [Object] Object to be compared
+ def ==(o)
+ return true if self.equal?(o)
+ self.class == o.class &&
+ name == o.name
+ end
+
+ # @see the `==` method
+ # @param [Object] Object to be compared
+ def eql?(o)
+ self == o
+ end
+
+ # Calculates hash code according to all attributes.
+ # @return [Integer] Hash code
+ def hash
+ [name].hash
+ end
+
+ # Builds the object from hash
+ # @param [Hash] attributes Model attributes in the form of hash
+ # @return [Object] Returns the model itself
+ def self.build_from_hash(attributes)
+ return nil unless attributes.is_a?(Hash)
+ attributes = attributes.transform_keys(&:to_sym)
+ transformed_hash = {}
+ openapi_types.each_pair do |key, type|
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
+ transformed_hash["#{key}"] = nil
+ elsif type =~ /\AArray<(.*)>/i
+ # check to ensure the input is an array given that the attribute
+ # is documented as an array but the input is not
+ if attributes[attribute_map[key]].is_a?(Array)
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
+ end
+ elsif !attributes[attribute_map[key]].nil?
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
+ end
+ end
+ new(transformed_hash)
+ end
+
+ # Deserializes the data based on type
+ # @param string type Data type
+ # @param string value Value to be deserialized
+ # @return [Object] Deserialized data
+ def self._deserialize(type, value)
+ case type.to_sym
+ when :Time
+ Time.parse(value)
+ when :Date
+ Date.parse(value)
+ when :String
+ value.to_s
+ when :Integer
+ value.to_i
+ when :Float
+ value.to_f
+ when :Boolean
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
+ true
+ else
+ false
+ end
+ when :Object
+ # generic object (usually a Hash), return directly
+ value
+ when /\AArray<(?.+)>\z/
+ inner_type = Regexp.last_match[:inner_type]
+ value.map { |v| _deserialize(inner_type, v) }
+ when /\AHash<(?.+?), (?.+)>\z/
+ k_type = Regexp.last_match[:k_type]
+ v_type = Regexp.last_match[:v_type]
+ {}.tap do |hash|
+ value.each do |k, v|
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
+ end
+ end
+ else # model
+ # models (e.g. Pet) or oneOf
+ klass = OpenapiClient.const_get(type)
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
+ end
+ end
+
+ # Returns the string representation of the object
+ # @return [String] String presentation of the object
+ def to_s
+ to_hash.to_s
+ end
+
+ # to_body is an alias to to_hash (backward compatibility)
+ # @return [Hash] Returns the object in the form of hash
+ def to_body
+ to_hash
+ end
+
+ # Returns the object in the form of hash
+ # @return [Hash] Returns the object in the form of hash
+ def to_hash
+ hash = {}
+ self.class.attribute_map.each_pair do |attr, param|
+ value = self.send(attr)
+ if value.nil?
+ is_nullable = self.class.openapi_nullable.include?(attr)
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
+ end
+
+ hash[param] = _to_hash(value)
+ end
+ hash
+ end
+
+ # Outputs non-array value in the form of hash
+ # For object, use to_hash. Otherwise, just return the value
+ # @param [Object] value Any valid value
+ # @return [Hash] Returns the value in the form of hash
+ def _to_hash(value)
+ if value.is_a?(Array)
+ value.compact.map { |v| _to_hash(v) }
+ elsif value.is_a?(Hash)
+ {}.tap do |hash|
+ value.each { |k, v| hash[k] = _to_hash(v) }
+ end
+ elsif value.respond_to? :to_hash
+ value.to_hash
+ else
+ value
+ end
+ end
+
+ end
+
+end
diff --git a/samples/client/echo_api/ruby-faraday/spec/models/test_form_object_multipart_request_marker_spec.rb b/samples/client/echo_api/ruby-faraday/spec/models/test_form_object_multipart_request_marker_spec.rb
new file mode 100644
index 0000000000..9cfa1af80f
--- /dev/null
+++ b/samples/client/echo_api/ruby-faraday/spec/models/test_form_object_multipart_request_marker_spec.rb
@@ -0,0 +1,36 @@
+=begin
+#Echo Server API
+
+#Echo Server API
+
+The version of the OpenAPI document: 0.1.0
+Contact: team@openapitools.org
+Generated by: https://openapi-generator.tech
+Generator version: 7.5.0-SNAPSHOT
+
+=end
+
+require 'spec_helper'
+require 'json'
+require 'date'
+
+# Unit tests for OpenapiClient::TestFormObjectMultipartRequestMarker
+# Automatically generated by openapi-generator (https://openapi-generator.tech)
+# Please update as you see appropriate
+describe OpenapiClient::TestFormObjectMultipartRequestMarker do
+ let(:instance) { OpenapiClient::TestFormObjectMultipartRequestMarker.new }
+
+ describe 'test an instance of TestFormObjectMultipartRequestMarker' do
+ it 'should create an instance of TestFormObjectMultipartRequestMarker' do
+ # uncomment below to test the instance creation
+ #expect(instance).to be_instance_of(OpenapiClient::TestFormObjectMultipartRequestMarker)
+ end
+ end
+
+ describe 'test attribute "name"' do
+ it 'should work' do
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
+ end
+ end
+
+end
diff --git a/samples/client/echo_api/ruby-httpx/.openapi-generator/FILES b/samples/client/echo_api/ruby-httpx/.openapi-generator/FILES
index a54b808c26..dd4431c035 100644
--- a/samples/client/echo_api/ruby-httpx/.openapi-generator/FILES
+++ b/samples/client/echo_api/ruby-httpx/.openapi-generator/FILES
@@ -21,6 +21,7 @@ docs/Query.md
docs/QueryApi.md
docs/StringEnumRef.md
docs/Tag.md
+docs/TestFormObjectMultipartRequestMarker.md
docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
@@ -43,6 +44,7 @@ lib/openapi_client/models/pet.rb
lib/openapi_client/models/query.rb
lib/openapi_client/models/string_enum_ref.rb
lib/openapi_client/models/tag.rb
+lib/openapi_client/models/test_form_object_multipart_request_marker.rb
lib/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.rb
lib/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.rb
lib/openapi_client/version.rb
diff --git a/samples/client/echo_api/ruby-httpx/README.md b/samples/client/echo_api/ruby-httpx/README.md
index 0f0a1dac7e..58fecf447d 100644
--- a/samples/client/echo_api/ruby-httpx/README.md
+++ b/samples/client/echo_api/ruby-httpx/README.md
@@ -97,6 +97,7 @@ Class | Method | HTTP request | Description
*OpenapiClient::BodyApi* | [**test_echo_body_string_enum**](docs/BodyApi.md#test_echo_body_string_enum) | **POST** /echo/body/string_enum | Test string enum response body
*OpenapiClient::BodyApi* | [**test_echo_body_tag_response_string**](docs/BodyApi.md#test_echo_body_tag_response_string) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*OpenapiClient::FormApi* | [**test_form_integer_boolean_string**](docs/FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*OpenapiClient::FormApi* | [**test_form_object_multipart**](docs/FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*OpenapiClient::FormApi* | [**test_form_oneof**](docs/FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*OpenapiClient::HeaderApi* | [**test_header_integer_boolean_string_enums**](docs/HeaderApi.md#test_header_integer_boolean_string_enums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*OpenapiClient::PathApi* | [**tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path**](docs/PathApi.md#tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -123,6 +124,7 @@ Class | Method | HTTP request | Description
- [OpenapiClient::Query](docs/Query.md)
- [OpenapiClient::StringEnumRef](docs/StringEnumRef.md)
- [OpenapiClient::Tag](docs/Tag.md)
+ - [OpenapiClient::TestFormObjectMultipartRequestMarker](docs/TestFormObjectMultipartRequestMarker.md)
- [OpenapiClient::TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [OpenapiClient::TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/ruby-httpx/docs/FormApi.md b/samples/client/echo_api/ruby-httpx/docs/FormApi.md
index 632949e8b8..8cfafc83e8 100644
--- a/samples/client/echo_api/ruby-httpx/docs/FormApi.md
+++ b/samples/client/echo_api/ruby-httpx/docs/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost:3000*
| Method | HTTP request | Description |
| ------ | ------------ | ----------- |
| [**test_form_integer_boolean_string**](FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s) |
+| [**test_form_object_multipart**](FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema |
| [**test_form_oneof**](FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema |
@@ -78,6 +79,70 @@ No authorization required
- **Accept**: text/plain
+## test_form_object_multipart
+
+> String test_form_object_multipart(marker)
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Examples
+
+```ruby
+require 'time'
+require 'openapi_client'
+
+api_instance = OpenapiClient::FormApi.new
+marker = OpenapiClient::TestFormObjectMultipartRequestMarker.new # TestFormObjectMultipartRequestMarker |
+
+begin
+ # Test form parameter(s) for multipart schema
+ result = api_instance.test_form_object_multipart(marker)
+ p result
+rescue OpenapiClient::ApiError => e
+ puts "Error when calling FormApi->test_form_object_multipart: #{e}"
+end
+```
+
+#### Using the test_form_object_multipart_with_http_info variant
+
+This returns an Array which contains the response data, status code and headers.
+
+> test_form_object_multipart_with_http_info(marker)
+
+```ruby
+begin
+ # Test form parameter(s) for multipart schema
+ data, status_code, headers = api_instance.test_form_object_multipart_with_http_info(marker)
+ p status_code # => 2xx
+ p headers # => { ... }
+ p data # => String
+rescue OpenapiClient::ApiError => e
+ puts "Error when calling FormApi->test_form_object_multipart_with_http_info: #{e}"
+end
+```
+
+### Parameters
+
+| Name | Type | Description | Notes |
+| ---- | ---- | ----------- | ----- |
+| **marker** | [**TestFormObjectMultipartRequestMarker**](TestFormObjectMultipartRequestMarker.md) | | |
+
+### Return type
+
+**String**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+- **Content-Type**: multipart/form-data
+- **Accept**: text/plain
+
+
## test_form_oneof
> String test_form_oneof(opts)
diff --git a/samples/client/echo_api/ruby-httpx/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/ruby-httpx/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..caf8f83317
--- /dev/null
+++ b/samples/client/echo_api/ruby-httpx/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,18 @@
+# OpenapiClient::TestFormObjectMultipartRequestMarker
+
+## Properties
+
+| Name | Type | Description | Notes |
+| ---- | ---- | ----------- | ----- |
+| **name** | **String** | | [optional] |
+
+## Example
+
+```ruby
+require 'openapi_client'
+
+instance = OpenapiClient::TestFormObjectMultipartRequestMarker.new(
+ name: null
+)
+```
+
diff --git a/samples/client/echo_api/ruby-httpx/lib/openapi_client.rb b/samples/client/echo_api/ruby-httpx/lib/openapi_client.rb
index a320248f0f..7f1a8a0232 100644
--- a/samples/client/echo_api/ruby-httpx/lib/openapi_client.rb
+++ b/samples/client/echo_api/ruby-httpx/lib/openapi_client.rb
@@ -25,6 +25,7 @@ require 'openapi_client/models/pet'
require 'openapi_client/models/query'
require 'openapi_client/models/string_enum_ref'
require 'openapi_client/models/tag'
+require 'openapi_client/models/test_form_object_multipart_request_marker'
require 'openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter'
require 'openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter'
require 'openapi_client/models/data_query'
diff --git a/samples/client/echo_api/ruby-httpx/lib/openapi_client/api/form_api.rb b/samples/client/echo_api/ruby-httpx/lib/openapi_client/api/form_api.rb
index 4f6af01ac5..8725588023 100644
--- a/samples/client/echo_api/ruby-httpx/lib/openapi_client/api/form_api.rb
+++ b/samples/client/echo_api/ruby-httpx/lib/openapi_client/api/form_api.rb
@@ -90,6 +90,75 @@ module OpenapiClient
return data, status_code, headers
end
+ # Test form parameter(s) for multipart schema
+ # Test form parameter(s) for multipart schema
+ # @param marker [TestFormObjectMultipartRequestMarker]
+ # @param [Hash] opts the optional parameters
+ # @return [String]
+ def test_form_object_multipart(marker, opts = {})
+ data, _status_code, _headers = test_form_object_multipart_with_http_info(marker, opts)
+ data
+ end
+
+ # Test form parameter(s) for multipart schema
+ # Test form parameter(s) for multipart schema
+ # @param marker [TestFormObjectMultipartRequestMarker]
+ # @param [Hash] opts the optional parameters
+ # @return [Array<(String, Integer, Hash)>] String data, response status code and response headers
+ def test_form_object_multipart_with_http_info(marker, opts = {})
+ if @api_client.config.debugging
+ @api_client.config.logger.debug 'Calling API: FormApi.test_form_object_multipart ...'
+ end
+ # verify the required parameter 'marker' is set
+ if @api_client.config.client_side_validation && marker.nil?
+ fail ArgumentError, "Missing the required parameter 'marker' when calling FormApi.test_form_object_multipart"
+ end
+ # resource path
+ local_var_path = '/form/object/multipart'
+
+ # query parameters
+ query_params = opts[:query_params] || {}
+
+ # header parameters
+ header_params = opts[:header_params] || {}
+ # HTTP header 'Accept' (if needed)
+ header_params['Accept'] = @api_client.select_header_accept(['text/plain'])
+ # HTTP header 'Content-Type'
+ content_type = @api_client.select_header_content_type(['multipart/form-data'])
+ if !content_type.nil?
+ header_params['Content-Type'] = content_type
+ end
+
+ # form parameters
+ form_params = opts[:form_params] || {}
+ form_params['marker'] = marker
+
+ # http body (model)
+ post_body = opts[:debug_body]
+
+ # return_type
+ return_type = opts[:debug_return_type] || 'String'
+
+ # auth_names
+ auth_names = opts[:debug_auth_names] || []
+
+ new_options = opts.merge(
+ :operation => :"FormApi.test_form_object_multipart",
+ :header_params => header_params,
+ :query_params => query_params,
+ :form_params => form_params,
+ :body => post_body,
+ :auth_names => auth_names,
+ :return_type => return_type
+ )
+
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
+ if @api_client.config.debugging
+ @api_client.config.logger.debug "API called: FormApi#test_form_object_multipart\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
+ end
+ return data, status_code, headers
+ end
+
# Test form parameter(s) for oneOf schema
# Test form parameter(s) for oneOf schema
# @param [Hash] opts the optional parameters
diff --git a/samples/client/echo_api/ruby-httpx/lib/openapi_client/models/test_form_object_multipart_request_marker.rb b/samples/client/echo_api/ruby-httpx/lib/openapi_client/models/test_form_object_multipart_request_marker.rb
new file mode 100644
index 0000000000..253bbed63f
--- /dev/null
+++ b/samples/client/echo_api/ruby-httpx/lib/openapi_client/models/test_form_object_multipart_request_marker.rb
@@ -0,0 +1,214 @@
+=begin
+#Echo Server API
+
+#Echo Server API
+
+The version of the OpenAPI document: 0.1.0
+Contact: team@openapitools.org
+Generated by: https://openapi-generator.tech
+Generator version: 7.5.0-SNAPSHOT
+
+=end
+
+require 'date'
+require 'time'
+
+module OpenapiClient
+ class TestFormObjectMultipartRequestMarker
+ attr_accessor :name
+
+ # Attribute mapping from ruby-style variable name to JSON key.
+ def self.attribute_map
+ {
+ :'name' => :'name'
+ }
+ end
+
+ # Returns all the JSON keys this model knows about
+ def self.acceptable_attributes
+ attribute_map.values
+ end
+
+ # Attribute type mapping.
+ def self.openapi_types
+ {
+ :'name' => :'String'
+ }
+ end
+
+ # List of attributes with nullable: true
+ def self.openapi_nullable
+ Set.new([
+ ])
+ end
+
+ # Initializes the object
+ # @param [Hash] attributes Model attributes in the form of hash
+ def initialize(attributes = {})
+ if (!attributes.is_a?(Hash))
+ fail ArgumentError, "The input argument (attributes) must be a hash in `OpenapiClient::TestFormObjectMultipartRequestMarker` initialize method"
+ end
+
+ # check to see if the attribute exists and convert string to symbol for hash key
+ attributes = attributes.each_with_object({}) { |(k, v), h|
+ if (!self.class.attribute_map.key?(k.to_sym))
+ fail ArgumentError, "`#{k}` is not a valid attribute in `OpenapiClient::TestFormObjectMultipartRequestMarker`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
+ end
+ h[k.to_sym] = v
+ }
+
+ if attributes.key?(:'name')
+ self.name = attributes[:'name']
+ end
+ end
+
+ # Show invalid properties with the reasons. Usually used together with valid?
+ # @return Array for valid properties with the reasons
+ def list_invalid_properties
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
+ invalid_properties = Array.new
+ invalid_properties
+ end
+
+ # Check to see if the all the properties in the model are valid
+ # @return true if the model is valid
+ def valid?
+ warn '[DEPRECATED] the `valid?` method is obsolete'
+ true
+ end
+
+ # Checks equality by comparing each attribute.
+ # @param [Object] Object to be compared
+ def ==(o)
+ return true if self.equal?(o)
+ self.class == o.class &&
+ name == o.name
+ end
+
+ # @see the `==` method
+ # @param [Object] Object to be compared
+ def eql?(o)
+ self == o
+ end
+
+ # Calculates hash code according to all attributes.
+ # @return [Integer] Hash code
+ def hash
+ [name].hash
+ end
+
+ # Builds the object from hash
+ # @param [Hash] attributes Model attributes in the form of hash
+ # @return [Object] Returns the model itself
+ def self.build_from_hash(attributes)
+ return nil unless attributes.is_a?(Hash)
+ attributes = attributes.transform_keys(&:to_sym)
+ transformed_hash = {}
+ openapi_types.each_pair do |key, type|
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
+ transformed_hash["#{key}"] = nil
+ elsif type =~ /\AArray<(.*)>/i
+ # check to ensure the input is an array given that the attribute
+ # is documented as an array but the input is not
+ if attributes[attribute_map[key]].is_a?(Array)
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
+ end
+ elsif !attributes[attribute_map[key]].nil?
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
+ end
+ end
+ new(transformed_hash)
+ end
+
+ # Deserializes the data based on type
+ # @param string type Data type
+ # @param string value Value to be deserialized
+ # @return [Object] Deserialized data
+ def self._deserialize(type, value)
+ case type.to_sym
+ when :Time
+ Time.parse(value)
+ when :Date
+ Date.parse(value)
+ when :String
+ value.to_s
+ when :Integer
+ value.to_i
+ when :Float
+ value.to_f
+ when :Boolean
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
+ true
+ else
+ false
+ end
+ when :Object
+ # generic object (usually a Hash), return directly
+ value
+ when /\AArray<(?.+)>\z/
+ inner_type = Regexp.last_match[:inner_type]
+ value.map { |v| _deserialize(inner_type, v) }
+ when /\AHash<(?.+?), (?.+)>\z/
+ k_type = Regexp.last_match[:k_type]
+ v_type = Regexp.last_match[:v_type]
+ {}.tap do |hash|
+ value.each do |k, v|
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
+ end
+ end
+ else # model
+ # models (e.g. Pet) or oneOf
+ klass = OpenapiClient.const_get(type)
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
+ end
+ end
+
+ # Returns the string representation of the object
+ # @return [String] String presentation of the object
+ def to_s
+ to_hash.to_s
+ end
+
+ # to_body is an alias to to_hash (backward compatibility)
+ # @return [Hash] Returns the object in the form of hash
+ def to_body
+ to_hash
+ end
+
+ # Returns the object in the form of hash
+ # @return [Hash] Returns the object in the form of hash
+ def to_hash
+ hash = {}
+ self.class.attribute_map.each_pair do |attr, param|
+ value = self.send(attr)
+ if value.nil?
+ is_nullable = self.class.openapi_nullable.include?(attr)
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
+ end
+
+ hash[param] = _to_hash(value)
+ end
+ hash
+ end
+
+ # Outputs non-array value in the form of hash
+ # For object, use to_hash. Otherwise, just return the value
+ # @param [Object] value Any valid value
+ # @return [Hash] Returns the value in the form of hash
+ def _to_hash(value)
+ if value.is_a?(Array)
+ value.compact.map { |v| _to_hash(v) }
+ elsif value.is_a?(Hash)
+ {}.tap do |hash|
+ value.each { |k, v| hash[k] = _to_hash(v) }
+ end
+ elsif value.respond_to? :to_hash
+ value.to_hash
+ else
+ value
+ end
+ end
+
+ end
+
+end
diff --git a/samples/client/echo_api/ruby-httpx/spec/models/test_form_object_multipart_request_marker_spec.rb b/samples/client/echo_api/ruby-httpx/spec/models/test_form_object_multipart_request_marker_spec.rb
new file mode 100644
index 0000000000..9cfa1af80f
--- /dev/null
+++ b/samples/client/echo_api/ruby-httpx/spec/models/test_form_object_multipart_request_marker_spec.rb
@@ -0,0 +1,36 @@
+=begin
+#Echo Server API
+
+#Echo Server API
+
+The version of the OpenAPI document: 0.1.0
+Contact: team@openapitools.org
+Generated by: https://openapi-generator.tech
+Generator version: 7.5.0-SNAPSHOT
+
+=end
+
+require 'spec_helper'
+require 'json'
+require 'date'
+
+# Unit tests for OpenapiClient::TestFormObjectMultipartRequestMarker
+# Automatically generated by openapi-generator (https://openapi-generator.tech)
+# Please update as you see appropriate
+describe OpenapiClient::TestFormObjectMultipartRequestMarker do
+ let(:instance) { OpenapiClient::TestFormObjectMultipartRequestMarker.new }
+
+ describe 'test an instance of TestFormObjectMultipartRequestMarker' do
+ it 'should create an instance of TestFormObjectMultipartRequestMarker' do
+ # uncomment below to test the instance creation
+ #expect(instance).to be_instance_of(OpenapiClient::TestFormObjectMultipartRequestMarker)
+ end
+ end
+
+ describe 'test attribute "name"' do
+ it 'should work' do
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
+ end
+ end
+
+end
diff --git a/samples/client/echo_api/ruby-typhoeus/.openapi-generator/FILES b/samples/client/echo_api/ruby-typhoeus/.openapi-generator/FILES
index a54b808c26..dd4431c035 100644
--- a/samples/client/echo_api/ruby-typhoeus/.openapi-generator/FILES
+++ b/samples/client/echo_api/ruby-typhoeus/.openapi-generator/FILES
@@ -21,6 +21,7 @@ docs/Query.md
docs/QueryApi.md
docs/StringEnumRef.md
docs/Tag.md
+docs/TestFormObjectMultipartRequestMarker.md
docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md
docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md
git_push.sh
@@ -43,6 +44,7 @@ lib/openapi_client/models/pet.rb
lib/openapi_client/models/query.rb
lib/openapi_client/models/string_enum_ref.rb
lib/openapi_client/models/tag.rb
+lib/openapi_client/models/test_form_object_multipart_request_marker.rb
lib/openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter.rb
lib/openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter.rb
lib/openapi_client/version.rb
diff --git a/samples/client/echo_api/ruby-typhoeus/README.md b/samples/client/echo_api/ruby-typhoeus/README.md
index 4601a9a3bd..4cff638043 100644
--- a/samples/client/echo_api/ruby-typhoeus/README.md
+++ b/samples/client/echo_api/ruby-typhoeus/README.md
@@ -95,6 +95,7 @@ Class | Method | HTTP request | Description
*OpenapiClient::BodyApi* | [**test_echo_body_string_enum**](docs/BodyApi.md#test_echo_body_string_enum) | **POST** /echo/body/string_enum | Test string enum response body
*OpenapiClient::BodyApi* | [**test_echo_body_tag_response_string**](docs/BodyApi.md#test_echo_body_tag_response_string) | **POST** /echo/body/Tag/response_string | Test empty json (request body)
*OpenapiClient::FormApi* | [**test_form_integer_boolean_string**](docs/FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s)
+*OpenapiClient::FormApi* | [**test_form_object_multipart**](docs/FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema
*OpenapiClient::FormApi* | [**test_form_oneof**](docs/FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema
*OpenapiClient::HeaderApi* | [**test_header_integer_boolean_string_enums**](docs/HeaderApi.md#test_header_integer_boolean_string_enums) | **GET** /header/integer/boolean/string/enums | Test header parameter(s)
*OpenapiClient::PathApi* | [**tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path**](docs/PathApi.md#tests_path_string_path_string_integer_path_integer_enum_nonref_string_path_enum_ref_string_path) | **GET** /path/string/{path_string}/integer/{path_integer}/{enum_nonref_string_path}/{enum_ref_string_path} | Test path parameter(s)
@@ -121,6 +122,7 @@ Class | Method | HTTP request | Description
- [OpenapiClient::Query](docs/Query.md)
- [OpenapiClient::StringEnumRef](docs/StringEnumRef.md)
- [OpenapiClient::Tag](docs/Tag.md)
+ - [OpenapiClient::TestFormObjectMultipartRequestMarker](docs/TestFormObjectMultipartRequestMarker.md)
- [OpenapiClient::TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter](docs/TestQueryStyleDeepObjectExplodeTrueObjectAllOfQueryObjectParameter.md)
- [OpenapiClient::TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter](docs/TestQueryStyleFormExplodeTrueArrayStringQueryObjectParameter.md)
diff --git a/samples/client/echo_api/ruby-typhoeus/docs/FormApi.md b/samples/client/echo_api/ruby-typhoeus/docs/FormApi.md
index 632949e8b8..8cfafc83e8 100644
--- a/samples/client/echo_api/ruby-typhoeus/docs/FormApi.md
+++ b/samples/client/echo_api/ruby-typhoeus/docs/FormApi.md
@@ -5,6 +5,7 @@ All URIs are relative to *http://localhost:3000*
| Method | HTTP request | Description |
| ------ | ------------ | ----------- |
| [**test_form_integer_boolean_string**](FormApi.md#test_form_integer_boolean_string) | **POST** /form/integer/boolean/string | Test form parameter(s) |
+| [**test_form_object_multipart**](FormApi.md#test_form_object_multipart) | **POST** /form/object/multipart | Test form parameter(s) for multipart schema |
| [**test_form_oneof**](FormApi.md#test_form_oneof) | **POST** /form/oneof | Test form parameter(s) for oneOf schema |
@@ -78,6 +79,70 @@ No authorization required
- **Accept**: text/plain
+## test_form_object_multipart
+
+> String test_form_object_multipart(marker)
+
+Test form parameter(s) for multipart schema
+
+Test form parameter(s) for multipart schema
+
+### Examples
+
+```ruby
+require 'time'
+require 'openapi_client'
+
+api_instance = OpenapiClient::FormApi.new
+marker = OpenapiClient::TestFormObjectMultipartRequestMarker.new # TestFormObjectMultipartRequestMarker |
+
+begin
+ # Test form parameter(s) for multipart schema
+ result = api_instance.test_form_object_multipart(marker)
+ p result
+rescue OpenapiClient::ApiError => e
+ puts "Error when calling FormApi->test_form_object_multipart: #{e}"
+end
+```
+
+#### Using the test_form_object_multipart_with_http_info variant
+
+This returns an Array which contains the response data, status code and headers.
+
+> test_form_object_multipart_with_http_info(marker)
+
+```ruby
+begin
+ # Test form parameter(s) for multipart schema
+ data, status_code, headers = api_instance.test_form_object_multipart_with_http_info(marker)
+ p status_code # => 2xx
+ p headers # => { ... }
+ p data # => String
+rescue OpenapiClient::ApiError => e
+ puts "Error when calling FormApi->test_form_object_multipart_with_http_info: #{e}"
+end
+```
+
+### Parameters
+
+| Name | Type | Description | Notes |
+| ---- | ---- | ----------- | ----- |
+| **marker** | [**TestFormObjectMultipartRequestMarker**](TestFormObjectMultipartRequestMarker.md) | | |
+
+### Return type
+
+**String**
+
+### Authorization
+
+No authorization required
+
+### HTTP request headers
+
+- **Content-Type**: multipart/form-data
+- **Accept**: text/plain
+
+
## test_form_oneof
> String test_form_oneof(opts)
diff --git a/samples/client/echo_api/ruby-typhoeus/docs/TestFormObjectMultipartRequestMarker.md b/samples/client/echo_api/ruby-typhoeus/docs/TestFormObjectMultipartRequestMarker.md
new file mode 100644
index 0000000000..caf8f83317
--- /dev/null
+++ b/samples/client/echo_api/ruby-typhoeus/docs/TestFormObjectMultipartRequestMarker.md
@@ -0,0 +1,18 @@
+# OpenapiClient::TestFormObjectMultipartRequestMarker
+
+## Properties
+
+| Name | Type | Description | Notes |
+| ---- | ---- | ----------- | ----- |
+| **name** | **String** | | [optional] |
+
+## Example
+
+```ruby
+require 'openapi_client'
+
+instance = OpenapiClient::TestFormObjectMultipartRequestMarker.new(
+ name: null
+)
+```
+
diff --git a/samples/client/echo_api/ruby-typhoeus/lib/openapi_client.rb b/samples/client/echo_api/ruby-typhoeus/lib/openapi_client.rb
index a320248f0f..7f1a8a0232 100644
--- a/samples/client/echo_api/ruby-typhoeus/lib/openapi_client.rb
+++ b/samples/client/echo_api/ruby-typhoeus/lib/openapi_client.rb
@@ -25,6 +25,7 @@ require 'openapi_client/models/pet'
require 'openapi_client/models/query'
require 'openapi_client/models/string_enum_ref'
require 'openapi_client/models/tag'
+require 'openapi_client/models/test_form_object_multipart_request_marker'
require 'openapi_client/models/test_query_style_deep_object_explode_true_object_all_of_query_object_parameter'
require 'openapi_client/models/test_query_style_form_explode_true_array_string_query_object_parameter'
require 'openapi_client/models/data_query'
diff --git a/samples/client/echo_api/ruby-typhoeus/lib/openapi_client/api/form_api.rb b/samples/client/echo_api/ruby-typhoeus/lib/openapi_client/api/form_api.rb
index 4f6af01ac5..8725588023 100644
--- a/samples/client/echo_api/ruby-typhoeus/lib/openapi_client/api/form_api.rb
+++ b/samples/client/echo_api/ruby-typhoeus/lib/openapi_client/api/form_api.rb
@@ -90,6 +90,75 @@ module OpenapiClient
return data, status_code, headers
end
+ # Test form parameter(s) for multipart schema
+ # Test form parameter(s) for multipart schema
+ # @param marker [TestFormObjectMultipartRequestMarker]
+ # @param [Hash] opts the optional parameters
+ # @return [String]
+ def test_form_object_multipart(marker, opts = {})
+ data, _status_code, _headers = test_form_object_multipart_with_http_info(marker, opts)
+ data
+ end
+
+ # Test form parameter(s) for multipart schema
+ # Test form parameter(s) for multipart schema
+ # @param marker [TestFormObjectMultipartRequestMarker]
+ # @param [Hash] opts the optional parameters
+ # @return [Array<(String, Integer, Hash)>] String data, response status code and response headers
+ def test_form_object_multipart_with_http_info(marker, opts = {})
+ if @api_client.config.debugging
+ @api_client.config.logger.debug 'Calling API: FormApi.test_form_object_multipart ...'
+ end
+ # verify the required parameter 'marker' is set
+ if @api_client.config.client_side_validation && marker.nil?
+ fail ArgumentError, "Missing the required parameter 'marker' when calling FormApi.test_form_object_multipart"
+ end
+ # resource path
+ local_var_path = '/form/object/multipart'
+
+ # query parameters
+ query_params = opts[:query_params] || {}
+
+ # header parameters
+ header_params = opts[:header_params] || {}
+ # HTTP header 'Accept' (if needed)
+ header_params['Accept'] = @api_client.select_header_accept(['text/plain'])
+ # HTTP header 'Content-Type'
+ content_type = @api_client.select_header_content_type(['multipart/form-data'])
+ if !content_type.nil?
+ header_params['Content-Type'] = content_type
+ end
+
+ # form parameters
+ form_params = opts[:form_params] || {}
+ form_params['marker'] = marker
+
+ # http body (model)
+ post_body = opts[:debug_body]
+
+ # return_type
+ return_type = opts[:debug_return_type] || 'String'
+
+ # auth_names
+ auth_names = opts[:debug_auth_names] || []
+
+ new_options = opts.merge(
+ :operation => :"FormApi.test_form_object_multipart",
+ :header_params => header_params,
+ :query_params => query_params,
+ :form_params => form_params,
+ :body => post_body,
+ :auth_names => auth_names,
+ :return_type => return_type
+ )
+
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
+ if @api_client.config.debugging
+ @api_client.config.logger.debug "API called: FormApi#test_form_object_multipart\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
+ end
+ return data, status_code, headers
+ end
+
# Test form parameter(s) for oneOf schema
# Test form parameter(s) for oneOf schema
# @param [Hash] opts the optional parameters
diff --git a/samples/client/echo_api/ruby-typhoeus/lib/openapi_client/models/test_form_object_multipart_request_marker.rb b/samples/client/echo_api/ruby-typhoeus/lib/openapi_client/models/test_form_object_multipart_request_marker.rb
new file mode 100644
index 0000000000..253bbed63f
--- /dev/null
+++ b/samples/client/echo_api/ruby-typhoeus/lib/openapi_client/models/test_form_object_multipart_request_marker.rb
@@ -0,0 +1,214 @@
+=begin
+#Echo Server API
+
+#Echo Server API
+
+The version of the OpenAPI document: 0.1.0
+Contact: team@openapitools.org
+Generated by: https://openapi-generator.tech
+Generator version: 7.5.0-SNAPSHOT
+
+=end
+
+require 'date'
+require 'time'
+
+module OpenapiClient
+ class TestFormObjectMultipartRequestMarker
+ attr_accessor :name
+
+ # Attribute mapping from ruby-style variable name to JSON key.
+ def self.attribute_map
+ {
+ :'name' => :'name'
+ }
+ end
+
+ # Returns all the JSON keys this model knows about
+ def self.acceptable_attributes
+ attribute_map.values
+ end
+
+ # Attribute type mapping.
+ def self.openapi_types
+ {
+ :'name' => :'String'
+ }
+ end
+
+ # List of attributes with nullable: true
+ def self.openapi_nullable
+ Set.new([
+ ])
+ end
+
+ # Initializes the object
+ # @param [Hash] attributes Model attributes in the form of hash
+ def initialize(attributes = {})
+ if (!attributes.is_a?(Hash))
+ fail ArgumentError, "The input argument (attributes) must be a hash in `OpenapiClient::TestFormObjectMultipartRequestMarker` initialize method"
+ end
+
+ # check to see if the attribute exists and convert string to symbol for hash key
+ attributes = attributes.each_with_object({}) { |(k, v), h|
+ if (!self.class.attribute_map.key?(k.to_sym))
+ fail ArgumentError, "`#{k}` is not a valid attribute in `OpenapiClient::TestFormObjectMultipartRequestMarker`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
+ end
+ h[k.to_sym] = v
+ }
+
+ if attributes.key?(:'name')
+ self.name = attributes[:'name']
+ end
+ end
+
+ # Show invalid properties with the reasons. Usually used together with valid?
+ # @return Array for valid properties with the reasons
+ def list_invalid_properties
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
+ invalid_properties = Array.new
+ invalid_properties
+ end
+
+ # Check to see if the all the properties in the model are valid
+ # @return true if the model is valid
+ def valid?
+ warn '[DEPRECATED] the `valid?` method is obsolete'
+ true
+ end
+
+ # Checks equality by comparing each attribute.
+ # @param [Object] Object to be compared
+ def ==(o)
+ return true if self.equal?(o)
+ self.class == o.class &&
+ name == o.name
+ end
+
+ # @see the `==` method
+ # @param [Object] Object to be compared
+ def eql?(o)
+ self == o
+ end
+
+ # Calculates hash code according to all attributes.
+ # @return [Integer] Hash code
+ def hash
+ [name].hash
+ end
+
+ # Builds the object from hash
+ # @param [Hash] attributes Model attributes in the form of hash
+ # @return [Object] Returns the model itself
+ def self.build_from_hash(attributes)
+ return nil unless attributes.is_a?(Hash)
+ attributes = attributes.transform_keys(&:to_sym)
+ transformed_hash = {}
+ openapi_types.each_pair do |key, type|
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
+ transformed_hash["#{key}"] = nil
+ elsif type =~ /\AArray<(.*)>/i
+ # check to ensure the input is an array given that the attribute
+ # is documented as an array but the input is not
+ if attributes[attribute_map[key]].is_a?(Array)
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
+ end
+ elsif !attributes[attribute_map[key]].nil?
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
+ end
+ end
+ new(transformed_hash)
+ end
+
+ # Deserializes the data based on type
+ # @param string type Data type
+ # @param string value Value to be deserialized
+ # @return [Object] Deserialized data
+ def self._deserialize(type, value)
+ case type.to_sym
+ when :Time
+ Time.parse(value)
+ when :Date
+ Date.parse(value)
+ when :String
+ value.to_s
+ when :Integer
+ value.to_i
+ when :Float
+ value.to_f
+ when :Boolean
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
+ true
+ else
+ false
+ end
+ when :Object
+ # generic object (usually a Hash), return directly
+ value
+ when /\AArray<(?.+)>\z/
+ inner_type = Regexp.last_match[:inner_type]
+ value.map { |v| _deserialize(inner_type, v) }
+ when /\AHash<(?.+?), (?.+)>\z/
+ k_type = Regexp.last_match[:k_type]
+ v_type = Regexp.last_match[:v_type]
+ {}.tap do |hash|
+ value.each do |k, v|
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
+ end
+ end
+ else # model
+ # models (e.g. Pet) or oneOf
+ klass = OpenapiClient.const_get(type)
+ klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
+ end
+ end
+
+ # Returns the string representation of the object
+ # @return [String] String presentation of the object
+ def to_s
+ to_hash.to_s
+ end
+
+ # to_body is an alias to to_hash (backward compatibility)
+ # @return [Hash] Returns the object in the form of hash
+ def to_body
+ to_hash
+ end
+
+ # Returns the object in the form of hash
+ # @return [Hash] Returns the object in the form of hash
+ def to_hash
+ hash = {}
+ self.class.attribute_map.each_pair do |attr, param|
+ value = self.send(attr)
+ if value.nil?
+ is_nullable = self.class.openapi_nullable.include?(attr)
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
+ end
+
+ hash[param] = _to_hash(value)
+ end
+ hash
+ end
+
+ # Outputs non-array value in the form of hash
+ # For object, use to_hash. Otherwise, just return the value
+ # @param [Object] value Any valid value
+ # @return [Hash] Returns the value in the form of hash
+ def _to_hash(value)
+ if value.is_a?(Array)
+ value.compact.map { |v| _to_hash(v) }
+ elsif value.is_a?(Hash)
+ {}.tap do |hash|
+ value.each { |k, v| hash[k] = _to_hash(v) }
+ end
+ elsif value.respond_to? :to_hash
+ value.to_hash
+ else
+ value
+ end
+ end
+
+ end
+
+end
diff --git a/samples/client/echo_api/ruby-typhoeus/spec/models/test_form_object_multipart_request_marker_spec.rb b/samples/client/echo_api/ruby-typhoeus/spec/models/test_form_object_multipart_request_marker_spec.rb
new file mode 100644
index 0000000000..9cfa1af80f
--- /dev/null
+++ b/samples/client/echo_api/ruby-typhoeus/spec/models/test_form_object_multipart_request_marker_spec.rb
@@ -0,0 +1,36 @@
+=begin
+#Echo Server API
+
+#Echo Server API
+
+The version of the OpenAPI document: 0.1.0
+Contact: team@openapitools.org
+Generated by: https://openapi-generator.tech
+Generator version: 7.5.0-SNAPSHOT
+
+=end
+
+require 'spec_helper'
+require 'json'
+require 'date'
+
+# Unit tests for OpenapiClient::TestFormObjectMultipartRequestMarker
+# Automatically generated by openapi-generator (https://openapi-generator.tech)
+# Please update as you see appropriate
+describe OpenapiClient::TestFormObjectMultipartRequestMarker do
+ let(:instance) { OpenapiClient::TestFormObjectMultipartRequestMarker.new }
+
+ describe 'test an instance of TestFormObjectMultipartRequestMarker' do
+ it 'should create an instance of TestFormObjectMultipartRequestMarker' do
+ # uncomment below to test the instance creation
+ #expect(instance).to be_instance_of(OpenapiClient::TestFormObjectMultipartRequestMarker)
+ end
+ end
+
+ describe 'test attribute "name"' do
+ it 'should work' do
+ # assertion here. ref: https://rspec.info/features/3-12/rspec-expectations/built-in-matchers/
+ end
+ end
+
+end
diff --git a/samples/client/echo_api/typescript-axios/build/api.ts b/samples/client/echo_api/typescript-axios/build/api.ts
index c6874e7a43..384ba1cdfc 100644
--- a/samples/client/echo_api/typescript-axios/build/api.ts
+++ b/samples/client/echo_api/typescript-axios/build/api.ts
@@ -291,6 +291,19 @@ export interface Tag {
*/
'name'?: string;
}
+/**
+ *
+ * @export
+ * @interface TestFormObjectMultipartRequestMarker
+ */
+export interface TestFormObjectMultipartRequestMarker {
+ /**
+ *
+ * @type {string}
+ * @memberof TestFormObjectMultipartRequestMarker
+ */
+ 'name'?: string;
+}
/**
*
* @export
@@ -1298,6 +1311,47 @@ export const FormApiAxiosParamCreator = function (configuration?: Configuration)
options: localVarRequestOptions,
};
},
+ /**
+ * Test form parameter(s) for multipart schema
+ * @summary Test form parameter(s) for multipart schema
+ * @param {TestFormObjectMultipartRequestMarker} marker
+ * @param {*} [options] Override http request option.
+ * @throws {RequiredError}
+ */
+ testFormObjectMultipart: async (marker: TestFormObjectMultipartRequestMarker, options: RawAxiosRequestConfig = {}): Promise => {
+ // verify required parameter 'marker' is not null or undefined
+ assertParamExists('testFormObjectMultipart', 'marker', marker)
+ const localVarPath = `/form/object/multipart`;
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
+ let baseOptions;
+ if (configuration) {
+ baseOptions = configuration.baseOptions;
+ }
+
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
+ const localVarHeaderParameter = {} as any;
+ const localVarQueryParameter = {} as any;
+ const localVarFormParams = new ((configuration && configuration.formDataCtor) || FormData)();
+
+
+ if (marker !== undefined) {
+ localVarFormParams.append('marker', new Blob([JSON.stringify(marker)], { type: "application/json", }));
+ }
+
+
+ localVarHeaderParameter['Content-Type'] = 'multipart/form-data';
+
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
+ localVarRequestOptions.data = localVarFormParams;
+
+ return {
+ url: toPathString(localVarUrlObj),
+ options: localVarRequestOptions,
+ };
+ },
/**
* Test form parameter(s) for oneOf schema
* @summary Test form parameter(s) for oneOf schema
@@ -1387,6 +1441,19 @@ export const FormApiFp = function(configuration?: Configuration) {
const localVarOperationServerBasePath = operationServerMap['FormApi.testFormIntegerBooleanString']?.[localVarOperationServerIndex]?.url;
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
},
+ /**
+ * Test form parameter(s) for multipart schema
+ * @summary Test form parameter(s) for multipart schema
+ * @param {TestFormObjectMultipartRequestMarker} marker
+ * @param {*} [options] Override http request option.
+ * @throws {RequiredError}
+ */
+ async testFormObjectMultipart(marker: TestFormObjectMultipartRequestMarker, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> {
+ const localVarAxiosArgs = await localVarAxiosParamCreator.testFormObjectMultipart(marker, options);
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
+ const localVarOperationServerBasePath = operationServerMap['FormApi.testFormObjectMultipart']?.[localVarOperationServerIndex]?.url;
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
+ },
/**
* Test form parameter(s) for oneOf schema
* @summary Test form parameter(s) for oneOf schema
@@ -1427,6 +1494,16 @@ export const FormApiFactory = function (configuration?: Configuration, basePath?
testFormIntegerBooleanString(integerForm?: number, booleanForm?: boolean, stringForm?: string, options?: any): AxiosPromise {
return localVarFp.testFormIntegerBooleanString(integerForm, booleanForm, stringForm, options).then((request) => request(axios, basePath));
},
+ /**
+ * Test form parameter(s) for multipart schema
+ * @summary Test form parameter(s) for multipart schema
+ * @param {TestFormObjectMultipartRequestMarker} marker
+ * @param {*} [options] Override http request option.
+ * @throws {RequiredError}
+ */
+ testFormObjectMultipart(marker: TestFormObjectMultipartRequestMarker, options?: any): AxiosPromise {
+ return localVarFp.testFormObjectMultipart(marker, options).then((request) => request(axios, basePath));
+ },
/**
* Test form parameter(s) for oneOf schema
* @summary Test form parameter(s) for oneOf schema
@@ -1466,6 +1543,18 @@ export class FormApi extends BaseAPI {
return FormApiFp(this.configuration).testFormIntegerBooleanString(integerForm, booleanForm, stringForm, options).then((request) => request(this.axios, this.basePath));
}
+ /**
+ * Test form parameter(s) for multipart schema
+ * @summary Test form parameter(s) for multipart schema
+ * @param {TestFormObjectMultipartRequestMarker} marker
+ * @param {*} [options] Override http request option.
+ * @throws {RequiredError}
+ * @memberof FormApi
+ */
+ public testFormObjectMultipart(marker: TestFormObjectMultipartRequestMarker, options?: RawAxiosRequestConfig) {
+ return FormApiFp(this.configuration).testFormObjectMultipart(marker, options).then((request) => request(this.axios, this.basePath));
+ }
+
/**
* Test form parameter(s) for oneOf schema
* @summary Test form parameter(s) for oneOf schema