forked from loafle/openapi-generator-original
Minor improvement to Go client generator, move test case (#430)
* move test cases to under fake endpoint * remove trailing spaces in the template * update samples * add new file * minor fix to OAS3 spec
This commit is contained in:
parent
412923ab5f
commit
862fe79f32
@ -21,14 +21,14 @@ type {{classname}}Service service
|
||||
{{#operation}}
|
||||
|
||||
/*
|
||||
{{{classname}}}Service{{#summary}} {{.}}{{/summary}}
|
||||
{{{classname}}}Service{{#summary}} {{{.}}}{{/summary}}
|
||||
{{#notes}}
|
||||
{{notes}}
|
||||
{{/notes}}
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
{{#allParams}}
|
||||
{{#required}}
|
||||
* @param {{paramName}}{{#description}} {{.}}{{/description}}
|
||||
* @param {{paramName}}{{#description}} {{{.}}}{{/description}}
|
||||
{{/required}}
|
||||
{{/allParams}}
|
||||
{{#hasOptionalParams}}
|
||||
@ -243,8 +243,12 @@ func (a *{{{classname}}}Service) {{{nickname}}}(ctx context.Context{{#hasParams}
|
||||
} else {
|
||||
key = auth.Key
|
||||
}
|
||||
{{#isKeyInHeader}}localVarHeaderParams["{{keyParamName}}"] = key{{/isKeyInHeader}}
|
||||
{{#isKeyInQuery}}localVarQueryParams.Add("{{keyParamName}}", key){{/isKeyInQuery}}
|
||||
{{#isKeyInHeader}}
|
||||
localVarHeaderParams["{{keyParamName}}"] = key
|
||||
{{/isKeyInHeader}}
|
||||
{{#isKeyInQuery}}
|
||||
localVarQueryParams.Add("{{keyParamName}}", key)
|
||||
{{/isKeyInQuery}}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -272,43 +272,6 @@ paths:
|
||||
- petstore_auth:
|
||||
- 'write:pets'
|
||||
- 'read:pets'
|
||||
'/pet/{petId}/uploadImageWithRequiredFile':
|
||||
post:
|
||||
tags:
|
||||
- pet
|
||||
summary: uploads an image
|
||||
description: ''
|
||||
operationId: uploadFileWithRequiredFile
|
||||
consumes:
|
||||
- multipart/form-data
|
||||
produces:
|
||||
- application/json
|
||||
parameters:
|
||||
- name: petId
|
||||
in: path
|
||||
description: ID of pet to update
|
||||
required: true
|
||||
type: integer
|
||||
format: int64
|
||||
- name: additionalMetadata
|
||||
in: formData
|
||||
description: Additional data to pass to server
|
||||
required: false
|
||||
type: string
|
||||
- name: file
|
||||
in: formData
|
||||
description: file to upload
|
||||
required: true
|
||||
type: file
|
||||
responses:
|
||||
'200':
|
||||
description: successful operation
|
||||
schema:
|
||||
$ref: '#/definitions/ApiResponse'
|
||||
security:
|
||||
- petstore_auth:
|
||||
- 'write:pets'
|
||||
- 'read:pets'
|
||||
/store/inventory:
|
||||
get:
|
||||
tags:
|
||||
@ -984,6 +947,43 @@ paths:
|
||||
description: successful operation
|
||||
schema:
|
||||
$ref: '#/definitions/Client'
|
||||
'/fake/{petId}/uploadImageWithRequiredFile':
|
||||
post:
|
||||
tags:
|
||||
- pet
|
||||
summary: uploads an image (required)
|
||||
description: ''
|
||||
operationId: uploadFileWithRequiredFile
|
||||
consumes:
|
||||
- multipart/form-data
|
||||
produces:
|
||||
- application/json
|
||||
parameters:
|
||||
- name: petId
|
||||
in: path
|
||||
description: ID of pet to update
|
||||
required: true
|
||||
type: integer
|
||||
format: int64
|
||||
- name: additionalMetadata
|
||||
in: formData
|
||||
description: Additional data to pass to server
|
||||
required: false
|
||||
type: string
|
||||
- name: file
|
||||
in: formData
|
||||
description: file to upload
|
||||
required: true
|
||||
type: file
|
||||
responses:
|
||||
'200':
|
||||
description: successful operation
|
||||
schema:
|
||||
$ref: '#/definitions/ApiResponse'
|
||||
security:
|
||||
- petstore_auth:
|
||||
- 'write:pets'
|
||||
- 'read:pets'
|
||||
securityDefinitions:
|
||||
petstore_auth:
|
||||
type: oauth2
|
||||
|
@ -67,6 +67,7 @@ paths:
|
||||
description: Status values that need to be considered for filter
|
||||
required: true
|
||||
style: form
|
||||
explode: false
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
@ -111,6 +112,7 @@ paths:
|
||||
description: Tags to filter by
|
||||
required: true
|
||||
style: form
|
||||
explode: false
|
||||
schema:
|
||||
type: array
|
||||
items:
|
||||
@ -265,47 +267,6 @@ paths:
|
||||
description: file to upload
|
||||
type: string
|
||||
format: binary
|
||||
'/pet/{petId}/uploadImageWithRequiredFile':
|
||||
post:
|
||||
tags:
|
||||
- pet
|
||||
summary: uploads an image
|
||||
description: ''
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- name: petId
|
||||
in: path
|
||||
description: ID of pet to update
|
||||
required: true
|
||||
schema:
|
||||
type: integer
|
||||
format: int64
|
||||
responses:
|
||||
'200':
|
||||
description: successful operation
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
security:
|
||||
- petstore_auth:
|
||||
- 'write:pets'
|
||||
- 'read:pets'
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
type: string
|
||||
format: binary
|
||||
required:
|
||||
- file
|
||||
/store/inventory:
|
||||
get:
|
||||
tags:
|
||||
@ -612,6 +573,7 @@ paths:
|
||||
parameters:
|
||||
- name: enum_header_string_array
|
||||
in: header
|
||||
explode: true
|
||||
description: Header parameter enum test (string array)
|
||||
schema:
|
||||
type: array
|
||||
@ -950,6 +912,47 @@ paths:
|
||||
$ref: '#/components/schemas/Client'
|
||||
requestBody:
|
||||
$ref: '#/components/requestBodies/Client'
|
||||
'/fake/{petId}/uploadImageWithRequiredFile':
|
||||
post:
|
||||
tags:
|
||||
- pet
|
||||
summary: uploads an image (required)
|
||||
description: ''
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- name: petId
|
||||
in: path
|
||||
description: ID of pet to update
|
||||
required: true
|
||||
schema:
|
||||
type: integer
|
||||
format: int64
|
||||
responses:
|
||||
'200':
|
||||
description: successful operation
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
security:
|
||||
- petstore_auth:
|
||||
- 'write:pets'
|
||||
- 'read:pets'
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
type: string
|
||||
format: binary
|
||||
required:
|
||||
- file
|
||||
components:
|
||||
requestBodies:
|
||||
UserArray:
|
||||
|
@ -1 +1 @@
|
||||
3.0.3-SNAPSHOT
|
||||
3.1.0-SNAPSHOT
|
@ -50,6 +50,7 @@ Class | Method | HTTP request | Description
|
||||
*PetApi* | [**UpdatePet**](docs/PetApi.md#updatepet) | **Put** /pet | Update an existing pet
|
||||
*PetApi* | [**UpdatePetWithForm**](docs/PetApi.md#updatepetwithform) | **Post** /pet/{petId} | Updates a pet in the store with form data
|
||||
*PetApi* | [**UploadFile**](docs/PetApi.md#uploadfile) | **Post** /pet/{petId}/uploadImage | uploads an image
|
||||
*PetApi* | [**UploadFileWithRequiredFile**](docs/PetApi.md#uploadfilewithrequiredfile) | **Post** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
*StoreApi* | [**DeleteOrder**](docs/StoreApi.md#deleteorder) | **Delete** /store/order/{order_id} | Delete purchase order by ID
|
||||
*StoreApi* | [**GetInventory**](docs/StoreApi.md#getinventory) | **Get** /store/inventory | Returns pet inventories by status
|
||||
*StoreApi* | [**GetOrderById**](docs/StoreApi.md#getorderbyid) | **Get** /store/order/{order_id} | Find purchase order by ID
|
||||
@ -97,6 +98,7 @@ Class | Method | HTTP request | Description
|
||||
- [ReadOnlyFirst](docs/ReadOnlyFirst.md)
|
||||
- [Return](docs/Return.md)
|
||||
- [SpecialModelName](docs/SpecialModelName.md)
|
||||
- [StringBooleanMap](docs/StringBooleanMap.md)
|
||||
- [Tag](docs/Tag.md)
|
||||
- [User](docs/User.md)
|
||||
|
||||
|
@ -973,6 +973,46 @@ paths:
|
||||
summary: To test special tags
|
||||
tags:
|
||||
- $another-fake?
|
||||
/fake/{petId}/uploadImageWithRequiredFile:
|
||||
post:
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- description: ID of pet to update
|
||||
in: path
|
||||
name: petId
|
||||
required: true
|
||||
schema:
|
||||
format: int64
|
||||
type: integer
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
format: binary
|
||||
type: string
|
||||
required:
|
||||
- file
|
||||
required: true
|
||||
responses:
|
||||
200:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
description: successful operation
|
||||
security:
|
||||
- petstore_auth:
|
||||
- write:pets
|
||||
- read:pets
|
||||
summary: uploads an image (required)
|
||||
tags:
|
||||
- pet
|
||||
components:
|
||||
schemas:
|
||||
Category:
|
||||
@ -1276,14 +1316,18 @@ components:
|
||||
type: array
|
||||
type: object
|
||||
OuterComposite:
|
||||
example: {}
|
||||
example:
|
||||
my_string: my_string
|
||||
my_number: 0.80082819046101150206595775671303272247314453125
|
||||
my_boolean: true
|
||||
properties:
|
||||
my_number:
|
||||
$ref: '#/components/schemas/OuterNumber'
|
||||
type: number
|
||||
my_string:
|
||||
$ref: '#/components/schemas/OuterString'
|
||||
type: string
|
||||
my_boolean:
|
||||
$ref: '#/components/schemas/OuterBoolean'
|
||||
type: boolean
|
||||
x-codegen-body-parameter-name: boolean_post_body
|
||||
type: object
|
||||
format_test:
|
||||
properties:
|
||||
@ -1381,6 +1425,10 @@ components:
|
||||
required:
|
||||
- className
|
||||
type: object
|
||||
StringBooleanMap:
|
||||
additionalProperties:
|
||||
type: boolean
|
||||
type: object
|
||||
Cat:
|
||||
allOf:
|
||||
- $ref: '#/components/schemas/Animal'
|
||||
@ -1403,6 +1451,12 @@ components:
|
||||
- lower
|
||||
type: string
|
||||
type: object
|
||||
direct_map:
|
||||
additionalProperties:
|
||||
type: boolean
|
||||
type: object
|
||||
indirect_map:
|
||||
$ref: '#/components/schemas/StringBooleanMap'
|
||||
type: object
|
||||
Tag:
|
||||
example:
|
||||
|
@ -483,7 +483,7 @@ func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query stri
|
||||
}
|
||||
|
||||
/*
|
||||
FakeApiService To test \"client\" model
|
||||
FakeApiService To test \"client\" model
|
||||
To test \"client\" model
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
* @param client client model
|
||||
|
@ -75,7 +75,6 @@ func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, clie
|
||||
} else {
|
||||
key = auth.Key
|
||||
}
|
||||
|
||||
localVarQueryParams.Add("api_key_query", key)
|
||||
}
|
||||
}
|
||||
|
@ -391,7 +391,6 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
||||
key = auth.Key
|
||||
}
|
||||
localVarHeaderParams["api_key"] = key
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -696,3 +695,106 @@ func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOpt
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
||||
/*
|
||||
PetApiService uploads an image (required)
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
* @param petId ID of pet to update
|
||||
* @param file file to upload
|
||||
* @param optional nil or *UploadFileWithRequiredFileOpts - Optional Parameters:
|
||||
* @param "AdditionalMetadata" (optional.String) - Additional data to pass to server
|
||||
@return ApiResponse
|
||||
*/
|
||||
|
||||
type UploadFileWithRequiredFileOpts struct {
|
||||
AdditionalMetadata optional.String
|
||||
}
|
||||
|
||||
func (a *PetApiService) UploadFileWithRequiredFile(ctx context.Context, petId int64, file *os.File, localVarOptionals *UploadFileWithRequiredFileOpts) (ApiResponse, *http.Response, error) {
|
||||
var (
|
||||
localVarHttpMethod = strings.ToUpper("Post")
|
||||
localVarPostBody interface{}
|
||||
localVarFileName string
|
||||
localVarFileBytes []byte
|
||||
localVarReturnValue ApiResponse
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
localVarPath := a.client.cfg.BasePath + "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
localVarPath = strings.Replace(localVarPath, "{"+"petId"+"}", fmt.Sprintf("%v", petId), -1)
|
||||
|
||||
localVarHeaderParams := make(map[string]string)
|
||||
localVarQueryParams := url.Values{}
|
||||
localVarFormParams := url.Values{}
|
||||
|
||||
// to determine the Content-Type header
|
||||
localVarHttpContentTypes := []string{"multipart/form-data"}
|
||||
|
||||
// set Content-Type header
|
||||
localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
|
||||
if localVarHttpContentType != "" {
|
||||
localVarHeaderParams["Content-Type"] = localVarHttpContentType
|
||||
}
|
||||
|
||||
// to determine the Accept header
|
||||
localVarHttpHeaderAccepts := []string{"application/json"}
|
||||
|
||||
// set Accept header
|
||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||
if localVarHttpHeaderAccept != "" {
|
||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||
}
|
||||
if localVarOptionals != nil && localVarOptionals.AdditionalMetadata.IsSet() {
|
||||
localVarFormParams.Add("additionalMetadata", parameterToString(localVarOptionals.AdditionalMetadata.Value(), ""))
|
||||
}
|
||||
localVarFile := file
|
||||
if localVarFile != nil {
|
||||
fbs, _ := ioutil.ReadAll(localVarFile)
|
||||
localVarFileBytes = fbs
|
||||
localVarFileName = localVarFile.Name()
|
||||
localVarFile.Close()
|
||||
}
|
||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||
if err != nil {
|
||||
return localVarReturnValue, nil, err
|
||||
}
|
||||
|
||||
localVarHttpResponse, err := a.client.callAPI(r)
|
||||
if err != nil || localVarHttpResponse == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
|
||||
localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body)
|
||||
localVarHttpResponse.Body.Close()
|
||||
if err != nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
|
||||
if localVarHttpResponse.StatusCode < 300 {
|
||||
// If we succeed, return the data, otherwise pass on to decode error.
|
||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
if err == nil {
|
||||
return localVarReturnValue, localVarHttpResponse, err
|
||||
}
|
||||
}
|
||||
|
||||
if localVarHttpResponse.StatusCode >= 300 {
|
||||
newErr := GenericOpenAPIError{
|
||||
body: localVarBody,
|
||||
error: localVarHttpResponse.Status,
|
||||
}
|
||||
if localVarHttpResponse.StatusCode == 200 {
|
||||
var v ApiResponse
|
||||
err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||
if err != nil {
|
||||
newErr.error = err.Error()
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
}
|
||||
newErr.model = v
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
}
|
||||
return localVarReturnValue, localVarHttpResponse, newErr
|
||||
}
|
||||
|
||||
return localVarReturnValue, localVarHttpResponse, nil
|
||||
}
|
||||
|
@ -140,7 +140,6 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
||||
key = auth.Key
|
||||
}
|
||||
localVarHeaderParams["api_key"] = key
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -5,6 +5,8 @@ Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**MapMapOfString** | [**map[string]map[string]string**](map.md) | | [optional]
|
||||
**MapOfEnumString** | **map[string]string** | | [optional]
|
||||
**DirectMap** | **map[string]bool** | | [optional]
|
||||
**IndirectMap** | [**StringBooleanMap**](StringBooleanMap.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
@ -12,6 +12,7 @@ Method | HTTP request | Description
|
||||
[**UpdatePet**](PetApi.md#UpdatePet) | **Put** /pet | Update an existing pet
|
||||
[**UpdatePetWithForm**](PetApi.md#UpdatePetWithForm) | **Post** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**UploadFile**](PetApi.md#UploadFile) | **Post** /pet/{petId}/uploadImage | uploads an image
|
||||
[**UploadFileWithRequiredFile**](PetApi.md#UploadFileWithRequiredFile) | **Post** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
# **AddPet**
|
||||
@ -257,3 +258,40 @@ Name | Type | Description | Notes
|
||||
|
||||
[[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)
|
||||
|
||||
# **UploadFileWithRequiredFile**
|
||||
> ApiResponse UploadFileWithRequiredFile(ctx, petId, file, optional)
|
||||
uploads an image (required)
|
||||
|
||||
### Required Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||
**petId** | **int64**| ID of pet to update |
|
||||
**file** | ***os.File*****os.File**| file to upload |
|
||||
**optional** | ***UploadFileWithRequiredFileOpts** | optional parameters | nil if no parameters
|
||||
|
||||
### Optional Parameters
|
||||
Optional parameters are passed through a pointer to a UploadFileWithRequiredFileOpts struct
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
|
||||
|
||||
**additionalMetadata** | **optional.String**| Additional data to pass to server |
|
||||
|
||||
### Return type
|
||||
|
||||
[**ApiResponse**](ApiResponse.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: multipart/form-data
|
||||
- **Accept**: application/json
|
||||
|
||||
[[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)
|
||||
|
||||
|
@ -0,0 +1,9 @@
|
||||
# StringBooleanMap
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
@ -12,4 +12,6 @@ package petstore
|
||||
type MapTest struct {
|
||||
MapMapOfString map[string]map[string]string `json:"map_map_of_string,omitempty" xml:"map_map_of_string"`
|
||||
MapOfEnumString map[string]string `json:"map_of_enum_string,omitempty" xml:"map_of_enum_string"`
|
||||
DirectMap map[string]bool `json:"direct_map,omitempty" xml:"direct_map"`
|
||||
IndirectMap StringBooleanMap `json:"indirect_map,omitempty" xml:"indirect_map"`
|
||||
}
|
||||
|
@ -0,0 +1,13 @@
|
||||
/*
|
||||
* OpenAPI Petstore
|
||||
*
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* API version: 1.0.0
|
||||
* Generated by: OpenAPI Generator (https://openapi-generator.tech)
|
||||
*/
|
||||
|
||||
package petstore
|
||||
|
||||
type StringBooleanMap struct {
|
||||
}
|
@ -1 +1 @@
|
||||
3.0.3
|
||||
3.1.0-SNAPSHOT
|
@ -50,7 +50,7 @@ Class | Method | HTTP request | Description
|
||||
*PetApi* | [**UpdatePet**](docs/PetApi.md#updatepet) | **Put** /pet | Update an existing pet
|
||||
*PetApi* | [**UpdatePetWithForm**](docs/PetApi.md#updatepetwithform) | **Post** /pet/{petId} | Updates a pet in the store with form data
|
||||
*PetApi* | [**UploadFile**](docs/PetApi.md#uploadfile) | **Post** /pet/{petId}/uploadImage | uploads an image
|
||||
*PetApi* | [**UploadFileWithRequiredFile**](docs/PetApi.md#uploadfilewithrequiredfile) | **Post** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
*PetApi* | [**UploadFileWithRequiredFile**](docs/PetApi.md#uploadfilewithrequiredfile) | **Post** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
*StoreApi* | [**DeleteOrder**](docs/StoreApi.md#deleteorder) | **Delete** /store/order/{order_id} | Delete purchase order by ID
|
||||
*StoreApi* | [**GetInventory**](docs/StoreApi.md#getinventory) | **Get** /store/inventory | Returns pet inventories by status
|
||||
*StoreApi* | [**GetOrderById**](docs/StoreApi.md#getorderbyid) | **Get** /store/order/{order_id} | Find purchase order by ID
|
||||
|
@ -282,46 +282,6 @@ paths:
|
||||
summary: uploads an image
|
||||
tags:
|
||||
- pet
|
||||
/pet/{petId}/uploadImageWithRequiredFile:
|
||||
post:
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- description: ID of pet to update
|
||||
in: path
|
||||
name: petId
|
||||
required: true
|
||||
schema:
|
||||
format: int64
|
||||
type: integer
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
format: binary
|
||||
type: string
|
||||
required:
|
||||
- file
|
||||
required: true
|
||||
responses:
|
||||
200:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
description: successful operation
|
||||
security:
|
||||
- petstore_auth:
|
||||
- write:pets
|
||||
- read:pets
|
||||
summary: uploads an image
|
||||
tags:
|
||||
- pet
|
||||
/store/inventory:
|
||||
get:
|
||||
description: Returns a map of status codes to quantities
|
||||
@ -1013,6 +973,46 @@ paths:
|
||||
summary: To test special tags
|
||||
tags:
|
||||
- $another-fake?
|
||||
/fake/{petId}/uploadImageWithRequiredFile:
|
||||
post:
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- description: ID of pet to update
|
||||
in: path
|
||||
name: petId
|
||||
required: true
|
||||
schema:
|
||||
format: int64
|
||||
type: integer
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
format: binary
|
||||
type: string
|
||||
required:
|
||||
- file
|
||||
required: true
|
||||
responses:
|
||||
200:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
description: successful operation
|
||||
security:
|
||||
- petstore_auth:
|
||||
- write:pets
|
||||
- read:pets
|
||||
summary: uploads an image (required)
|
||||
tags:
|
||||
- pet
|
||||
components:
|
||||
schemas:
|
||||
Category:
|
||||
|
@ -483,7 +483,7 @@ func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query stri
|
||||
}
|
||||
|
||||
/*
|
||||
FakeApiService To test \"client\" model
|
||||
FakeApiService To test \"client\" model
|
||||
To test \"client\" model
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
* @param client client model
|
||||
|
@ -75,7 +75,6 @@ func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, clie
|
||||
} else {
|
||||
key = auth.Key
|
||||
}
|
||||
|
||||
localVarQueryParams.Add("api_key_query", key)
|
||||
}
|
||||
}
|
||||
|
@ -391,7 +391,6 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
||||
key = auth.Key
|
||||
}
|
||||
localVarHeaderParams["api_key"] = key
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -698,7 +697,7 @@ func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOpt
|
||||
}
|
||||
|
||||
/*
|
||||
PetApiService uploads an image
|
||||
PetApiService uploads an image (required)
|
||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||
* @param petId ID of pet to update
|
||||
* @param file file to upload
|
||||
@ -721,7 +720,7 @@ func (a *PetApiService) UploadFileWithRequiredFile(ctx context.Context, petId in
|
||||
)
|
||||
|
||||
// create path and map variables
|
||||
localVarPath := a.client.cfg.BasePath + "/pet/{petId}/uploadImageWithRequiredFile"
|
||||
localVarPath := a.client.cfg.BasePath + "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
localVarPath = strings.Replace(localVarPath, "{"+"petId"+"}", fmt.Sprintf("%v", petId), -1)
|
||||
|
||||
localVarHeaderParams := make(map[string]string)
|
||||
|
@ -140,7 +140,6 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
||||
key = auth.Key
|
||||
}
|
||||
localVarHeaderParams["api_key"] = key
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -6,7 +6,7 @@ Name | Type | Description | Notes
|
||||
**MapMapOfString** | [**map[string]map[string]string**](map.md) | | [optional]
|
||||
**MapOfEnumString** | **map[string]string** | | [optional]
|
||||
**DirectMap** | **map[string]bool** | | [optional]
|
||||
**IndirectMap** | [***StringBooleanMap**](StringBooleanMap.md) | | [optional]
|
||||
**IndirectMap** | [**StringBooleanMap**](StringBooleanMap.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**UpdatePet**](PetApi.md#UpdatePet) | **Put** /pet | Update an existing pet
|
||||
[**UpdatePetWithForm**](PetApi.md#UpdatePetWithForm) | **Post** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**UploadFile**](PetApi.md#UploadFile) | **Post** /pet/{petId}/uploadImage | uploads an image
|
||||
[**UploadFileWithRequiredFile**](PetApi.md#UploadFileWithRequiredFile) | **Post** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**UploadFileWithRequiredFile**](PetApi.md#UploadFileWithRequiredFile) | **Post** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
# **AddPet**
|
||||
@ -260,7 +260,7 @@ Name | Type | Description | Notes
|
||||
|
||||
# **UploadFileWithRequiredFile**
|
||||
> ApiResponse UploadFileWithRequiredFile(ctx, petId, file, optional)
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Required Parameters
|
||||
|
||||
|
@ -13,5 +13,5 @@ type MapTest struct {
|
||||
MapMapOfString map[string]map[string]string `json:"map_map_of_string,omitempty"`
|
||||
MapOfEnumString map[string]string `json:"map_of_enum_string,omitempty"`
|
||||
DirectMap map[string]bool `json:"direct_map,omitempty"`
|
||||
IndirectMap *StringBooleanMap `json:"indirect_map,omitempty"`
|
||||
IndirectMap StringBooleanMap `json:"indirect_map,omitempty"`
|
||||
}
|
||||
|
@ -184,14 +184,14 @@ public interface PetApi extends ApiClient.Api {
|
||||
ModelApiResponse uploadFile(@Param("petId") Long petId, @Param("additionalMetadata") String additionalMetadata, @Param("file") File file);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
* @param additionalMetadata Additional data to pass to server (optional, default to null)
|
||||
* @return ModelApiResponse
|
||||
*/
|
||||
@RequestLine("POST /pet/{petId}/uploadImageWithRequiredFile")
|
||||
@RequestLine("POST /fake/{petId}/uploadImageWithRequiredFile")
|
||||
@Headers({
|
||||
"Content-Type: multipart/form-data",
|
||||
"Accept: application/json",
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -716,7 +716,7 @@ public class PetApi {
|
||||
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
* <p><b>200</b> - successful operation
|
||||
* @param petId ID of pet to update
|
||||
* @param file file to upload
|
||||
@ -731,7 +731,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
* <p><b>200</b> - successful operation
|
||||
* @param petId ID of pet to update
|
||||
* @param file file to upload
|
||||
@ -756,7 +756,7 @@ public class PetApi {
|
||||
// create a map of path variables
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
uriVariables.put("petId", petId);
|
||||
UriBuilder uriBuilder = UriBuilder.fromUri(apiClient.getBasePath() + "/pet/{petId}/uploadImageWithRequiredFile");
|
||||
UriBuilder uriBuilder = UriBuilder.fromUri(apiClient.getBasePath() + "/fake/{petId}/uploadImageWithRequiredFile");
|
||||
|
||||
String url = uriBuilder.buildFromMap(uriVariables).toString();
|
||||
GenericUrl genericUrl = new GenericUrl(url);
|
||||
@ -776,7 +776,7 @@ public class PetApi {
|
||||
// create a map of path variables
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
uriVariables.put("petId", petId);
|
||||
UriBuilder uriBuilder = UriBuilder.fromUri(apiClient.getBasePath() + "/pet/{petId}/uploadImageWithRequiredFile");
|
||||
UriBuilder uriBuilder = UriBuilder.fromUri(apiClient.getBasePath() + "/fake/{petId}/uploadImageWithRequiredFile");
|
||||
|
||||
// Copy the params argument if present, to allow passing in immutable maps
|
||||
Map<String, Object> allParams = params == null ? new HashMap<String, Object>() : new HashMap<String, Object>(params);
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -406,7 +406,7 @@ if (file != null)
|
||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -428,7 +428,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
|
||||
// query params
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -480,7 +480,7 @@ if (file != null)
|
||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -493,7 +493,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -515,7 +515,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
|
||||
// query params
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -480,7 +480,7 @@ if (file != null)
|
||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -493,7 +493,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -515,7 +515,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
|
||||
// query params
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -480,7 +480,7 @@ if (file != null)
|
||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -493,7 +493,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -515,7 +515,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
|
||||
// query params
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -1077,7 +1077,7 @@ public class PetApi {
|
||||
Object localVarPostBody = new Object();
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
@ -1139,7 +1139,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -1153,7 +1153,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -1168,7 +1168,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image (asynchronously)
|
||||
* uploads an image (required) (asynchronously)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -1077,7 +1077,7 @@ public class PetApi {
|
||||
Object localVarPostBody = new Object();
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
|
||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
||||
@ -1139,7 +1139,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -1153,7 +1153,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -1168,7 +1168,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image (asynchronously)
|
||||
* uploads an image (required) (asynchronously)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -350,7 +350,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -743,7 +743,7 @@ public class PetApi {
|
||||
}
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
*
|
||||
* @see #petIdPath ID of pet to update (required)
|
||||
@ -753,7 +753,7 @@ public class PetApi {
|
||||
*/
|
||||
public class UploadFileWithRequiredFileOper {
|
||||
|
||||
public static final String REQ_URI = "/pet/{petId}/uploadImageWithRequiredFile";
|
||||
public static final String REQ_URI = "/fake/{petId}/uploadImageWithRequiredFile";
|
||||
|
||||
private RequestSpecBuilder reqSpec;
|
||||
|
||||
@ -774,7 +774,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* POST /pet/{petId}/uploadImageWithRequiredFile
|
||||
* POST /fake/{petId}/uploadImageWithRequiredFile
|
||||
* @param handler handler
|
||||
* @param <T> type
|
||||
* @return type
|
||||
@ -784,7 +784,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* POST /pet/{petId}/uploadImageWithRequiredFile
|
||||
* POST /fake/{petId}/uploadImageWithRequiredFile
|
||||
* @param handler handler
|
||||
* @return ModelApiResponse
|
||||
*/
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -384,7 +384,7 @@ if (file != null)
|
||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -406,7 +406,7 @@ if (file != null)
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile".replaceAll("\\{format\\}","json")
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile".replaceAll("\\{format\\}","json")
|
||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||
|
||||
// query params
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -356,7 +356,7 @@ public class PetApi {
|
||||
return apiClient.invokeAPI(path, HttpMethod.POST, queryParams, postBody, headerParams, formParams, accept, contentType, authNames, returnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* <p><b>200</b> - successful operation
|
||||
* @param petId ID of pet to update
|
||||
@ -381,7 +381,7 @@ public class PetApi {
|
||||
// create path and map variables
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
uriVariables.put("petId", petId);
|
||||
String path = UriComponentsBuilder.fromPath("/pet/{petId}/uploadImageWithRequiredFile").buildAndExpand(uriVariables).toUriString();
|
||||
String path = UriComponentsBuilder.fromPath("/fake/{petId}/uploadImageWithRequiredFile").buildAndExpand(uriVariables).toUriString();
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -356,7 +356,7 @@ public class PetApi {
|
||||
return apiClient.invokeAPI(path, HttpMethod.POST, queryParams, postBody, headerParams, formParams, accept, contentType, authNames, returnType);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* <p><b>200</b> - successful operation
|
||||
* @param petId ID of pet to update
|
||||
@ -381,7 +381,7 @@ public class PetApi {
|
||||
// create path and map variables
|
||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||
uriVariables.put("petId", petId);
|
||||
String path = UriComponentsBuilder.fromPath("/pet/{petId}/uploadImageWithRequiredFile").buildAndExpand(uriVariables).toUriString();
|
||||
String path = UriComponentsBuilder.fromPath("/fake/{petId}/uploadImageWithRequiredFile").buildAndExpand(uriVariables).toUriString();
|
||||
|
||||
final MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||
final HttpHeaders headerParams = new HttpHeaders();
|
||||
|
@ -223,7 +223,7 @@ public interface PetApi {
|
||||
@retrofit.http.Path("petId") Long petId, @retrofit.http.Part("additionalMetadata") String additionalMetadata, @retrofit.http.Part("file") TypedFile file, Callback<ModelApiResponse> cb
|
||||
);
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
* Sync method
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
@ -233,13 +233,13 @@ public interface PetApi {
|
||||
*/
|
||||
|
||||
@retrofit.http.Multipart
|
||||
@POST("/pet/{petId}/uploadImageWithRequiredFile")
|
||||
@POST("/fake/{petId}/uploadImageWithRequiredFile")
|
||||
ModelApiResponse uploadFileWithRequiredFile(
|
||||
@retrofit.http.Path("petId") Long petId, @retrofit.http.Part("file") TypedFile file, @retrofit.http.Part("additionalMetadata") String additionalMetadata
|
||||
);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
* Async method
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -248,7 +248,7 @@ public interface PetApi {
|
||||
*/
|
||||
|
||||
@retrofit.http.Multipart
|
||||
@POST("/pet/{petId}/uploadImageWithRequiredFile")
|
||||
@POST("/fake/{petId}/uploadImageWithRequiredFile")
|
||||
void uploadFileWithRequiredFile(
|
||||
@retrofit.http.Path("petId") Long petId, @retrofit.http.Part("file") TypedFile file, @retrofit.http.Part("additionalMetadata") String additionalMetadata, Callback<ModelApiResponse> cb
|
||||
);
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -126,7 +126,7 @@ public interface PetApi {
|
||||
);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -134,7 +134,7 @@ public interface PetApi {
|
||||
* @return Call<ModelApiResponse>
|
||||
*/
|
||||
@retrofit2.http.Multipart
|
||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
||||
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||
F.Promise<Response<ModelApiResponse>> uploadFileWithRequiredFile(
|
||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
||||
);
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -126,7 +126,7 @@ public interface PetApi {
|
||||
);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -134,7 +134,7 @@ public interface PetApi {
|
||||
* @return Call<ModelApiResponse>
|
||||
*/
|
||||
@retrofit2.http.Multipart
|
||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
||||
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||
CompletionStage<Response<ModelApiResponse>> uploadFileWithRequiredFile(
|
||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
||||
);
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -123,7 +123,7 @@ public interface PetApi {
|
||||
);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -131,7 +131,7 @@ public interface PetApi {
|
||||
* @return Call<ModelApiResponse>
|
||||
*/
|
||||
@retrofit2.http.Multipart
|
||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
||||
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||
Call<ModelApiResponse> uploadFileWithRequiredFile(
|
||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
||||
);
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -123,7 +123,7 @@ public interface PetApi {
|
||||
);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -131,7 +131,7 @@ public interface PetApi {
|
||||
* @return Observable<ModelApiResponse>
|
||||
*/
|
||||
@retrofit2.http.Multipart
|
||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
||||
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||
Observable<ModelApiResponse> uploadFileWithRequiredFile(
|
||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
||||
);
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -124,7 +124,7 @@ public interface PetApi {
|
||||
);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -132,7 +132,7 @@ public interface PetApi {
|
||||
* @return Observable<ModelApiResponse>
|
||||
*/
|
||||
@retrofit2.http.Multipart
|
||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
||||
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||
Observable<ModelApiResponse> uploadFileWithRequiredFile(
|
||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
||||
);
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
<a name="addPet"></a>
|
||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```java
|
||||
|
@ -325,7 +325,7 @@ if (file != null) localVarFormParams.put("file", file);
|
||||
apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarBody, localVarHeaderParams, localVarFormParams, localVarAccepts, localVarContentTypes, localVarAuthNames, localVarReturnType, resultHandler);
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -348,7 +348,7 @@ if (file != null) localVarFormParams.put("file", file);
|
||||
}
|
||||
|
||||
// create path and map variables
|
||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile".replaceAll("\\{" + "petId" + "\\}", petId.toString());
|
||||
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile".replaceAll("\\{" + "petId" + "\\}", petId.toString());
|
||||
|
||||
// query params
|
||||
List<Pair> localVarQueryParams = new ArrayList<>();
|
||||
|
@ -202,7 +202,7 @@ public class PetApi {
|
||||
}));
|
||||
}
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
@ -214,7 +214,7 @@ public class PetApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param petId ID of pet to update (required)
|
||||
* @param file file to upload (required)
|
||||
|
@ -99,7 +99,7 @@ Class | Method | HTTP request | Description
|
||||
*PetApi* | [**updatePet**](docs/Api/PetApi.md#updatepet) | **PUT** /pet | Update an existing pet
|
||||
*PetApi* | [**updatePetWithForm**](docs/Api/PetApi.md#updatepetwithform) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
*PetApi* | [**uploadFile**](docs/Api/PetApi.md#uploadfile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
*PetApi* | [**uploadFileWithRequiredFile**](docs/Api/PetApi.md#uploadfilewithrequiredfile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
*PetApi* | [**uploadFileWithRequiredFile**](docs/Api/PetApi.md#uploadfilewithrequiredfile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
*StoreApi* | [**deleteOrder**](docs/Api/StoreApi.md#deleteorder) | **DELETE** /store/order/{order_id} | Delete purchase order by ID
|
||||
*StoreApi* | [**getInventory**](docs/Api/StoreApi.md#getinventory) | **GET** /store/inventory | Returns pet inventories by status
|
||||
*StoreApi* | [**getOrderById**](docs/Api/StoreApi.md#getorderbyid) | **GET** /store/order/{order_id} | Find purchase order by ID
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
# **addPet**
|
||||
@ -440,7 +440,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> \OpenAPI\Client\Model\ApiResponse uploadFileWithRequiredFile($pet_id, $file, $additional_metadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```php
|
||||
|
@ -2177,7 +2177,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFile
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2196,7 +2196,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFileWithHttpInfo
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2292,7 +2292,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFileAsync
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2314,7 +2314,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFileAsyncWithHttpInfo
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2390,7 +2390,7 @@ class PetApi
|
||||
);
|
||||
}
|
||||
|
||||
$resourcePath = '/pet/{petId}/uploadImageWithRequiredFile';
|
||||
$resourcePath = '/fake/{petId}/uploadImageWithRequiredFile';
|
||||
$formParams = [];
|
||||
$queryParams = [];
|
||||
$headerParams = [];
|
||||
|
@ -154,7 +154,7 @@ class PetApiTest extends \PHPUnit_Framework_TestCase
|
||||
/**
|
||||
* Test case for uploadFileWithRequiredFile
|
||||
*
|
||||
* uploads an image.
|
||||
* uploads an image (required).
|
||||
*
|
||||
*/
|
||||
public function testUploadFileWithRequiredFile()
|
||||
|
@ -93,7 +93,7 @@ Class | Method | HTTP request | Description
|
||||
*Petstore::PetApi* | [**update_pet**](docs/PetApi.md#update_pet) | **PUT** /pet | Update an existing pet
|
||||
*Petstore::PetApi* | [**update_pet_with_form**](docs/PetApi.md#update_pet_with_form) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
*Petstore::PetApi* | [**upload_file**](docs/PetApi.md#upload_file) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
*Petstore::PetApi* | [**upload_file_with_required_file**](docs/PetApi.md#upload_file_with_required_file) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
*Petstore::PetApi* | [**upload_file_with_required_file**](docs/PetApi.md#upload_file_with_required_file) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
*Petstore::StoreApi* | [**delete_order**](docs/StoreApi.md#delete_order) | **DELETE** /store/order/{order_id} | Delete purchase order by ID
|
||||
*Petstore::StoreApi* | [**get_inventory**](docs/StoreApi.md#get_inventory) | **GET** /store/inventory | Returns pet inventories by status
|
||||
*Petstore::StoreApi* | [**get_order_by_id**](docs/StoreApi.md#get_order_by_id) | **GET** /store/order/{order_id} | Find purchase order by ID
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**update_pet**](PetApi.md#update_pet) | **PUT** /pet | Update an existing pet
|
||||
[**update_pet_with_form**](PetApi.md#update_pet_with_form) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**upload_file**](PetApi.md#upload_file) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**upload_file_with_required_file**](PetApi.md#upload_file_with_required_file) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**upload_file_with_required_file**](PetApi.md#upload_file_with_required_file) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
# **add_pet**
|
||||
@ -422,7 +422,7 @@ Name | Type | Description | Notes
|
||||
# **upload_file_with_required_file**
|
||||
> ApiResponse upload_file_with_required_file(pet_id, file, opts)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```ruby
|
||||
@ -442,7 +442,7 @@ opts = {
|
||||
}
|
||||
|
||||
begin
|
||||
#uploads an image
|
||||
#uploads an image (required)
|
||||
result = api_instance.upload_file_with_required_file(pet_id, file, opts)
|
||||
p result
|
||||
rescue Petstore::ApiError => e
|
||||
|
@ -438,7 +438,7 @@ module Petstore
|
||||
end
|
||||
return data, status_code, headers
|
||||
end
|
||||
# uploads an image
|
||||
# uploads an image (required)
|
||||
# @param pet_id ID of pet to update
|
||||
# @param file file to upload
|
||||
# @param [Hash] opts the optional parameters
|
||||
@ -449,7 +449,7 @@ module Petstore
|
||||
data
|
||||
end
|
||||
|
||||
# uploads an image
|
||||
# uploads an image (required)
|
||||
# @param pet_id ID of pet to update
|
||||
# @param file file to upload
|
||||
# @param [Hash] opts the optional parameters
|
||||
@ -468,7 +468,7 @@ module Petstore
|
||||
fail ArgumentError, "Missing the required parameter 'file' when calling PetApi.upload_file_with_required_file"
|
||||
end
|
||||
# resource path
|
||||
local_var_path = '/pet/{petId}/uploadImageWithRequiredFile'.sub('{' + 'petId' + '}', pet_id.to_s)
|
||||
local_var_path = '/fake/{petId}/uploadImageWithRequiredFile'.sub('{' + 'petId' + '}', pet_id.to_s)
|
||||
|
||||
# query parameters
|
||||
query_params = {}
|
||||
|
@ -99,7 +99,7 @@ Class | Method | HTTP request | Description
|
||||
*PetApi* | [**updatePet**](docs/Api/PetApi.md#updatepet) | **PUT** /pet | Update an existing pet
|
||||
*PetApi* | [**updatePetWithForm**](docs/Api/PetApi.md#updatepetwithform) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
*PetApi* | [**uploadFile**](docs/Api/PetApi.md#uploadfile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
*PetApi* | [**uploadFileWithRequiredFile**](docs/Api/PetApi.md#uploadfilewithrequiredfile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
*PetApi* | [**uploadFileWithRequiredFile**](docs/Api/PetApi.md#uploadfilewithrequiredfile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
*StoreApi* | [**deleteOrder**](docs/Api/StoreApi.md#deleteorder) | **DELETE** /store/order/{order_id} | Delete purchase order by ID
|
||||
*StoreApi* | [**getInventory**](docs/Api/StoreApi.md#getinventory) | **GET** /store/inventory | Returns pet inventories by status
|
||||
*StoreApi* | [**getOrderById**](docs/Api/StoreApi.md#getorderbyid) | **GET** /store/order/{order_id} | Find purchase order by ID
|
||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
||||
[**updatePetWithForm**](PetApi.md#updatePetWithForm) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**uploadFile**](PetApi.md#uploadFile) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /pet/{petId}/uploadImageWithRequiredFile | uploads an image
|
||||
[**uploadFileWithRequiredFile**](PetApi.md#uploadFileWithRequiredFile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||
|
||||
|
||||
# **addPet**
|
||||
@ -440,7 +440,7 @@ Name | Type | Description | Notes
|
||||
# **uploadFileWithRequiredFile**
|
||||
> \OpenAPI\Client\Model\ApiResponse uploadFileWithRequiredFile($pet_id, $file, $additional_metadata)
|
||||
|
||||
uploads an image
|
||||
uploads an image (required)
|
||||
|
||||
### Example
|
||||
```php
|
||||
|
@ -756,7 +756,7 @@ class PetApi
|
||||
|
||||
// query params
|
||||
if (is_array($status)) {
|
||||
$status = ObjectSerializer::serializeCollection($status, 'multi', true);
|
||||
$status = ObjectSerializer::serializeCollection($status, 'csv', true);
|
||||
}
|
||||
if ($status !== null) {
|
||||
$queryParams['status'] = ObjectSerializer::toQueryValue($status);
|
||||
@ -1040,7 +1040,7 @@ class PetApi
|
||||
|
||||
// query params
|
||||
if (is_array($tags)) {
|
||||
$tags = ObjectSerializer::serializeCollection($tags, 'multi', true);
|
||||
$tags = ObjectSerializer::serializeCollection($tags, 'csv', true);
|
||||
}
|
||||
if ($tags !== null) {
|
||||
$queryParams['tags'] = ObjectSerializer::toQueryValue($tags);
|
||||
@ -2177,7 +2177,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFile
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2196,7 +2196,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFileWithHttpInfo
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2292,7 +2292,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFileAsync
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2314,7 +2314,7 @@ class PetApi
|
||||
/**
|
||||
* Operation uploadFileWithRequiredFileAsyncWithHttpInfo
|
||||
*
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
* @param int $pet_id ID of pet to update (required)
|
||||
* @param \SplFileObject $file file to upload (required)
|
||||
@ -2390,7 +2390,7 @@ class PetApi
|
||||
);
|
||||
}
|
||||
|
||||
$resourcePath = '/pet/{petId}/uploadImageWithRequiredFile';
|
||||
$resourcePath = '/fake/{petId}/uploadImageWithRequiredFile';
|
||||
$formParams = [];
|
||||
$queryParams = [];
|
||||
$headerParams = [];
|
||||
|
@ -154,7 +154,7 @@ class PetApiTest extends \PHPUnit_Framework_TestCase
|
||||
/**
|
||||
* Test case for uploadFileWithRequiredFile
|
||||
*
|
||||
* uploads an image.
|
||||
* uploads an image (required).
|
||||
*
|
||||
*/
|
||||
public function testUploadFileWithRequiredFile()
|
||||
|
@ -140,14 +140,14 @@ public interface PetApi {
|
||||
public ModelApiResponse uploadFile(@PathParam("petId") Long petId, @Multipart(value = "additionalMetadata", required = false) String additionalMetadata, @Multipart(value = "file" , required = false) Attachment fileDetail);
|
||||
|
||||
/**
|
||||
* uploads an image
|
||||
* uploads an image (required)
|
||||
*
|
||||
*/
|
||||
@POST
|
||||
@Path("/pet/{petId}/uploadImageWithRequiredFile")
|
||||
@Path("/fake/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@ApiOperation(value = "uploads an image", tags={ "pet" })
|
||||
@ApiOperation(value = "uploads an image (required)", tags={ "pet" })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public ModelApiResponse uploadFileWithRequiredFile(@PathParam("petId") Long petId, @Multipart(value = "file" ) Attachment fileDetail, @Multipart(value = "additionalMetadata", required = false) String additionalMetadata);
|
||||
|
@ -12,6 +12,7 @@ import org.openapitools.model.Client;
|
||||
import java.io.File;
|
||||
import java.time.LocalDate;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import java.time.OffsetDateTime;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
@ -211,4 +212,25 @@ public class FakeApi {
|
||||
throws NotFoundException {
|
||||
return delegate.testJsonFormData(param,param2,securityContext);
|
||||
}
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image (required)", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet", })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public Response uploadFileWithRequiredFile(@ApiParam(value = "ID of pet to update",required=true) @PathParam("petId") Long petId
|
||||
,
|
||||
@FormDataParam("file") InputStream fileInputStream,
|
||||
@FormDataParam("file") FormDataContentDisposition fileDetail
|
||||
,@ApiParam(value = "Additional data to pass to server", defaultValue="null")@FormDataParam("additionalMetadata") String additionalMetadata
|
||||
,@Context SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFileWithRequiredFile(petId,fileInputStream, fileDetail,additionalMetadata,securityContext);
|
||||
}
|
||||
}
|
||||
|
@ -10,6 +10,7 @@ import org.openapitools.model.Client;
|
||||
import java.io.File;
|
||||
import java.time.LocalDate;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import java.time.OffsetDateTime;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
@ -34,4 +35,5 @@ public abstract class FakeApiService {
|
||||
public abstract Response testEnumParameters(List<String> enumHeaderStringArray,String enumHeaderString, List<String> enumQueryStringArray, String enumQueryString, Integer enumQueryInteger, Double enumQueryDouble,List<String> enumFormStringArray,String enumFormString,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response testInlineAdditionalProperties(Map<String, String> requestBody,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response testJsonFormData(String param,String param2,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response uploadFileWithRequiredFile(Long petId,InputStream fileInputStream, FormDataContentDisposition fileDetail,String additionalMetadata,SecurityContext securityContext) throws NotFoundException;
|
||||
}
|
||||
|
@ -208,25 +208,4 @@ public class PetApi {
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFile(petId,additionalMetadata,fileInputStream, fileDetail,securityContext);
|
||||
}
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet", })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public Response uploadFileWithRequiredFile(@ApiParam(value = "ID of pet to update",required=true) @PathParam("petId") Long petId
|
||||
,
|
||||
@FormDataParam("file") InputStream fileInputStream,
|
||||
@FormDataParam("file") FormDataContentDisposition fileDetail
|
||||
,@ApiParam(value = "Additional data to pass to server", defaultValue="null")@FormDataParam("additionalMetadata") String additionalMetadata
|
||||
,@Context SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFileWithRequiredFile(petId,fileInputStream, fileDetail,additionalMetadata,securityContext);
|
||||
}
|
||||
}
|
||||
|
@ -27,5 +27,4 @@ public abstract class PetApiService {
|
||||
public abstract Response updatePet(Pet pet,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response updatePetWithForm(Long petId,String name,String status,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response uploadFile(Long petId,String additionalMetadata,InputStream fileInputStream, FormDataContentDisposition fileDetail,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response uploadFileWithRequiredFile(Long petId,InputStream fileInputStream, FormDataContentDisposition fileDetail,String additionalMetadata,SecurityContext securityContext) throws NotFoundException;
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ import org.openapitools.model.Client;
|
||||
import java.io.File;
|
||||
import java.time.LocalDate;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import java.time.OffsetDateTime;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
@ -74,4 +75,9 @@ public class FakeApiServiceImpl extends FakeApiService {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
@Override
|
||||
public Response uploadFileWithRequiredFile(Long petId, InputStream fileInputStream, FormDataContentDisposition fileDetail, String additionalMetadata, SecurityContext securityContext) throws NotFoundException {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
}
|
||||
|
@ -59,9 +59,4 @@ public class PetApiServiceImpl extends PetApiService {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
@Override
|
||||
public Response uploadFileWithRequiredFile(Long petId, InputStream fileInputStream, FormDataContentDisposition fileDetail, String additionalMetadata, SecurityContext securityContext) throws NotFoundException {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
}
|
||||
|
@ -6,6 +6,7 @@ import java.util.Date;
|
||||
import java.io.File;
|
||||
import org.joda.time.LocalDate;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -101,8 +102,23 @@ public interface FakeApi {
|
||||
@GET
|
||||
@Path("/jsonFormData")
|
||||
@Consumes({ "application/x-www-form-urlencoded" })
|
||||
@ApiOperation(value = "test json serialization of form data", notes = "", tags={ "fake" })
|
||||
@ApiOperation(value = "test json serialization of form data", notes = "", tags={ "fake", })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
|
||||
void testJsonFormData(@FormParam(value = "param") String param,@FormParam(value = "param2") String param2);
|
||||
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@ApiOperation(value = "uploads an image (required)", notes = "", authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet" })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
ModelApiResponse uploadFileWithRequiredFile(@PathParam("petId") @ApiParam("ID of pet to update") Long petId, @FormParam(value = "file") InputStream fileInputStream,
|
||||
@FormParam(value = "file") Attachment fileDetail,@FormParam(value = "additionalMetadata") String additionalMetadata);
|
||||
}
|
||||
|
@ -118,24 +118,9 @@ public interface PetApi {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet", })
|
||||
}, tags={ "pet" })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
ModelApiResponse uploadFile(@PathParam("petId") @ApiParam("ID of pet to update") Long petId,@FormParam(value = "additionalMetadata") String additionalMetadata, @FormParam(value = "file") InputStream fileInputStream,
|
||||
@FormParam(value = "file") Attachment fileDetail);
|
||||
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@ApiOperation(value = "uploads an image", notes = "", authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet" })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
ModelApiResponse uploadFileWithRequiredFile(@PathParam("petId") @ApiParam("ID of pet to update") Long petId, @FormParam(value = "file") InputStream fileInputStream,
|
||||
@FormParam(value = "file") Attachment fileDetail,@FormParam(value = "additionalMetadata") String additionalMetadata);
|
||||
}
|
||||
|
@ -298,48 +298,6 @@ paths:
|
||||
- pet
|
||||
x-tags:
|
||||
- tag: pet
|
||||
/pet/{petId}/uploadImageWithRequiredFile:
|
||||
post:
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- description: ID of pet to update
|
||||
in: path
|
||||
name: petId
|
||||
required: true
|
||||
schema:
|
||||
format: int64
|
||||
type: integer
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
format: binary
|
||||
type: string
|
||||
required:
|
||||
- file
|
||||
required: true
|
||||
responses:
|
||||
200:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
description: successful operation
|
||||
security:
|
||||
- petstore_auth:
|
||||
- write:pets
|
||||
- read:pets
|
||||
summary: uploads an image
|
||||
tags:
|
||||
- pet
|
||||
x-tags:
|
||||
- tag: pet
|
||||
/store/inventory:
|
||||
get:
|
||||
description: Returns a map of status codes to quantities
|
||||
@ -1079,6 +1037,48 @@ paths:
|
||||
- $another-fake?
|
||||
x-tags:
|
||||
- tag: $another-fake?
|
||||
/fake/{petId}/uploadImageWithRequiredFile:
|
||||
post:
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- description: ID of pet to update
|
||||
in: path
|
||||
name: petId
|
||||
required: true
|
||||
schema:
|
||||
format: int64
|
||||
type: integer
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
format: binary
|
||||
type: string
|
||||
required:
|
||||
- file
|
||||
required: true
|
||||
responses:
|
||||
200:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
description: successful operation
|
||||
security:
|
||||
- petstore_auth:
|
||||
- write:pets
|
||||
- read:pets
|
||||
summary: uploads an image (required)
|
||||
tags:
|
||||
- pet
|
||||
x-tags:
|
||||
- tag: pet
|
||||
components:
|
||||
schemas:
|
||||
Category:
|
||||
|
@ -6,6 +6,7 @@ import java.util.Date;
|
||||
import java.io.File;
|
||||
import org.joda.time.LocalDate;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -128,11 +129,29 @@ public class FakeApi {
|
||||
@GET
|
||||
@Path("/jsonFormData")
|
||||
@Consumes({ "application/x-www-form-urlencoded" })
|
||||
@ApiOperation(value = "test json serialization of form data", notes = "", response = Void.class, tags={ "fake" })
|
||||
@ApiOperation(value = "test json serialization of form data", notes = "", response = Void.class, tags={ "fake", })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = Void.class)
|
||||
})
|
||||
public Response testJsonFormData(@FormParam(value = "param") String param,@FormParam(value = "param2") String param2) {
|
||||
return Response.ok().entity("magic!").build();
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@ApiOperation(value = "uploads an image (required)", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet" })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class)
|
||||
})
|
||||
public Response uploadFileWithRequiredFile(@PathParam("petId") @ApiParam("ID of pet to update") Long petId, @FormParam(value = "file") InputStream fileInputStream,
|
||||
@FormParam(value = "file") Attachment fileDetail,@FormParam(value = "additionalMetadata") String additionalMetadata) {
|
||||
return Response.ok().entity("magic!").build();
|
||||
}
|
||||
}
|
||||
|
@ -139,7 +139,7 @@ public class PetApi {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet", })
|
||||
}, tags={ "pet" })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class)
|
||||
})
|
||||
@ -147,22 +147,4 @@ public class PetApi {
|
||||
@FormParam(value = "file") Attachment fileDetail) {
|
||||
return Response.ok().entity("magic!").build();
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@ApiOperation(value = "uploads an image", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@Authorization(value = "petstore_auth", scopes = {
|
||||
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet" })
|
||||
@ApiResponses(value = {
|
||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class)
|
||||
})
|
||||
public Response uploadFileWithRequiredFile(@PathParam("petId") @ApiParam("ID of pet to update") Long petId, @FormParam(value = "file") InputStream fileInputStream,
|
||||
@FormParam(value = "file") Attachment fileDetail,@FormParam(value = "additionalMetadata") String additionalMetadata) {
|
||||
return Response.ok().entity("magic!").build();
|
||||
}
|
||||
}
|
||||
|
@ -298,48 +298,6 @@ paths:
|
||||
- pet
|
||||
x-tags:
|
||||
- tag: pet
|
||||
/pet/{petId}/uploadImageWithRequiredFile:
|
||||
post:
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- description: ID of pet to update
|
||||
in: path
|
||||
name: petId
|
||||
required: true
|
||||
schema:
|
||||
format: int64
|
||||
type: integer
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
format: binary
|
||||
type: string
|
||||
required:
|
||||
- file
|
||||
required: true
|
||||
responses:
|
||||
200:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
description: successful operation
|
||||
security:
|
||||
- petstore_auth:
|
||||
- write:pets
|
||||
- read:pets
|
||||
summary: uploads an image
|
||||
tags:
|
||||
- pet
|
||||
x-tags:
|
||||
- tag: pet
|
||||
/store/inventory:
|
||||
get:
|
||||
description: Returns a map of status codes to quantities
|
||||
@ -1079,6 +1037,48 @@ paths:
|
||||
- $another-fake?
|
||||
x-tags:
|
||||
- tag: $another-fake?
|
||||
/fake/{petId}/uploadImageWithRequiredFile:
|
||||
post:
|
||||
operationId: uploadFileWithRequiredFile
|
||||
parameters:
|
||||
- description: ID of pet to update
|
||||
in: path
|
||||
name: petId
|
||||
required: true
|
||||
schema:
|
||||
format: int64
|
||||
type: integer
|
||||
requestBody:
|
||||
content:
|
||||
multipart/form-data:
|
||||
schema:
|
||||
properties:
|
||||
additionalMetadata:
|
||||
description: Additional data to pass to server
|
||||
type: string
|
||||
file:
|
||||
description: file to upload
|
||||
format: binary
|
||||
type: string
|
||||
required:
|
||||
- file
|
||||
required: true
|
||||
responses:
|
||||
200:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ApiResponse'
|
||||
description: successful operation
|
||||
security:
|
||||
- petstore_auth:
|
||||
- write:pets
|
||||
- read:pets
|
||||
summary: uploads an image (required)
|
||||
tags:
|
||||
- pet
|
||||
x-tags:
|
||||
- tag: pet
|
||||
components:
|
||||
schemas:
|
||||
Category:
|
||||
|
@ -193,7 +193,7 @@ public class PetApi {
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image (required)", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
|
@ -15,6 +15,7 @@ import org.openapitools.model.Client;
|
||||
import java.util.Date;
|
||||
import java.io.File;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -187,7 +188,7 @@ public class FakeApi {
|
||||
@Path("/jsonFormData")
|
||||
@Consumes({ "application/x-www-form-urlencoded" })
|
||||
|
||||
@io.swagger.annotations.ApiOperation(value = "test json serialization of form data", notes = "", response = Void.class, tags={ "fake" })
|
||||
@io.swagger.annotations.ApiOperation(value = "test json serialization of form data", notes = "", response = Void.class, tags={ "fake", })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = Void.class) })
|
||||
public Response testJsonFormData(
|
||||
@ -197,4 +198,25 @@ public class FakeApi {
|
||||
throws NotFoundException {
|
||||
return delegate.testJsonFormData(param,param2,securityContext);
|
||||
}
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image (required)", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet" })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public Response uploadFileWithRequiredFile(
|
||||
@ApiParam(value = "ID of pet to update",required=true) @PathParam("petId") Long petId,
|
||||
@FormDataParam("file") InputStream inputStream,
|
||||
@FormDataParam("file") FormDataContentDisposition fileDetail,
|
||||
@FormDataParam("additionalMetadata") String additionalMetadata,
|
||||
@Context SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFileWithRequiredFile(petId,inputStream, fileDetail,additionalMetadata,securityContext);
|
||||
}
|
||||
}
|
||||
|
@ -10,6 +10,7 @@ import org.openapitools.model.Client;
|
||||
import java.util.Date;
|
||||
import java.io.File;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -46,4 +47,6 @@ public abstract class FakeApiService {
|
||||
throws NotFoundException;
|
||||
public abstract Response testJsonFormData(String param,String param2,SecurityContext securityContext)
|
||||
throws NotFoundException;
|
||||
public abstract Response uploadFileWithRequiredFile(Long petId,InputStream fileInputStream, FormDataContentDisposition fileDetail,String additionalMetadata,SecurityContext securityContext)
|
||||
throws NotFoundException;
|
||||
}
|
||||
|
@ -177,7 +177,7 @@ public class PetApi {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet", })
|
||||
}, tags={ "pet" })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public Response uploadFile(
|
||||
@ -189,25 +189,4 @@ public class PetApi {
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFile(petId,additionalMetadata,inputStream, fileDetail,securityContext);
|
||||
}
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet" })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public Response uploadFileWithRequiredFile(
|
||||
@ApiParam(value = "ID of pet to update",required=true) @PathParam("petId") Long petId,
|
||||
@FormDataParam("file") InputStream inputStream,
|
||||
@FormDataParam("file") FormDataContentDisposition fileDetail,
|
||||
@FormDataParam("additionalMetadata") String additionalMetadata,
|
||||
@Context SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFileWithRequiredFile(petId,inputStream, fileDetail,additionalMetadata,securityContext);
|
||||
}
|
||||
}
|
||||
|
@ -38,6 +38,4 @@ public abstract class PetApiService {
|
||||
throws NotFoundException;
|
||||
public abstract Response uploadFile(Long petId,String additionalMetadata,InputStream fileInputStream, FormDataContentDisposition fileDetail,SecurityContext securityContext)
|
||||
throws NotFoundException;
|
||||
public abstract Response uploadFileWithRequiredFile(Long petId,InputStream fileInputStream, FormDataContentDisposition fileDetail,String additionalMetadata,SecurityContext securityContext)
|
||||
throws NotFoundException;
|
||||
}
|
||||
|
@ -10,6 +10,7 @@ import org.openapitools.model.Client;
|
||||
import java.util.Date;
|
||||
import java.io.File;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -86,4 +87,10 @@ public class FakeApiServiceImpl extends FakeApiService {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
@Override
|
||||
public Response uploadFileWithRequiredFile(Long petId, InputStream fileInputStream, FormDataContentDisposition fileDetail, String additionalMetadata, SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
}
|
||||
|
@ -70,10 +70,4 @@ public class PetApiServiceImpl extends PetApiService {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
@Override
|
||||
public Response uploadFileWithRequiredFile(Long petId, InputStream fileInputStream, FormDataContentDisposition fileDetail, String additionalMetadata, SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
}
|
||||
|
@ -212,7 +212,7 @@ public class PetApi {
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image (required)", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
|
@ -12,6 +12,7 @@ import org.openapitools.model.Client;
|
||||
import java.util.Date;
|
||||
import java.io.File;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -210,4 +211,25 @@ public class FakeApi {
|
||||
throws NotFoundException {
|
||||
return delegate.testJsonFormData(param,param2,securityContext);
|
||||
}
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image (required)", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet", })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public Response uploadFileWithRequiredFile(@ApiParam(value = "ID of pet to update",required=true) @PathParam("petId") Long petId
|
||||
,
|
||||
@FormDataParam("file") InputStream fileInputStream,
|
||||
@FormDataParam("file") FormDataContentDisposition fileDetail
|
||||
,@ApiParam(value = "Additional data to pass to server", defaultValue="null")@FormDataParam("additionalMetadata") String additionalMetadata
|
||||
,@Context SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFileWithRequiredFile(petId,fileInputStream, fileDetail,additionalMetadata,securityContext);
|
||||
}
|
||||
}
|
||||
|
@ -10,6 +10,7 @@ import org.openapitools.model.Client;
|
||||
import java.util.Date;
|
||||
import java.io.File;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -33,4 +34,5 @@ public abstract class FakeApiService {
|
||||
public abstract Response testEnumParameters(List<String> enumHeaderStringArray,String enumHeaderString, List<String> enumQueryStringArray, String enumQueryString, Integer enumQueryInteger, Double enumQueryDouble,List<String> enumFormStringArray,String enumFormString,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response testInlineAdditionalProperties(Map<String, String> requestBody,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response testJsonFormData(String param,String param2,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response uploadFileWithRequiredFile(Long petId,InputStream fileInputStream, FormDataContentDisposition fileDetail,String additionalMetadata,SecurityContext securityContext) throws NotFoundException;
|
||||
}
|
||||
|
@ -208,25 +208,4 @@ public class PetApi {
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFile(petId,additionalMetadata,fileInputStream, fileDetail,securityContext);
|
||||
}
|
||||
@POST
|
||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||
@Consumes({ "multipart/form-data" })
|
||||
@Produces({ "application/json" })
|
||||
@io.swagger.annotations.ApiOperation(value = "uploads an image", notes = "", response = ModelApiResponse.class, authorizations = {
|
||||
@io.swagger.annotations.Authorization(value = "petstore_auth", scopes = {
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||
})
|
||||
}, tags={ "pet", })
|
||||
@io.swagger.annotations.ApiResponses(value = {
|
||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||
public Response uploadFileWithRequiredFile(@ApiParam(value = "ID of pet to update",required=true) @PathParam("petId") Long petId
|
||||
,
|
||||
@FormDataParam("file") InputStream fileInputStream,
|
||||
@FormDataParam("file") FormDataContentDisposition fileDetail
|
||||
,@ApiParam(value = "Additional data to pass to server", defaultValue="null")@FormDataParam("additionalMetadata") String additionalMetadata
|
||||
,@Context SecurityContext securityContext)
|
||||
throws NotFoundException {
|
||||
return delegate.uploadFileWithRequiredFile(petId,fileInputStream, fileDetail,additionalMetadata,securityContext);
|
||||
}
|
||||
}
|
||||
|
@ -27,5 +27,4 @@ public abstract class PetApiService {
|
||||
public abstract Response updatePet(Pet pet,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response updatePetWithForm(Long petId,String name,String status,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response uploadFile(Long petId,String additionalMetadata,InputStream fileInputStream, FormDataContentDisposition fileDetail,SecurityContext securityContext) throws NotFoundException;
|
||||
public abstract Response uploadFileWithRequiredFile(Long petId,InputStream fileInputStream, FormDataContentDisposition fileDetail,String additionalMetadata,SecurityContext securityContext) throws NotFoundException;
|
||||
}
|
||||
|
@ -8,6 +8,7 @@ import org.openapitools.model.Client;
|
||||
import java.util.Date;
|
||||
import java.io.File;
|
||||
import java.util.Map;
|
||||
import org.openapitools.model.ModelApiResponse;
|
||||
import org.openapitools.model.OuterComposite;
|
||||
import org.openapitools.model.User;
|
||||
|
||||
@ -73,4 +74,9 @@ public class FakeApiServiceImpl extends FakeApiService {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
@Override
|
||||
public Response uploadFileWithRequiredFile(Long petId, InputStream fileInputStream, FormDataContentDisposition fileDetail, String additionalMetadata, SecurityContext securityContext) throws NotFoundException {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
}
|
||||
|
@ -59,9 +59,4 @@ public class PetApiServiceImpl extends PetApiService {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
@Override
|
||||
public Response uploadFileWithRequiredFile(Long petId, InputStream fileInputStream, FormDataContentDisposition fileDetail, String additionalMetadata, SecurityContext securityContext) throws NotFoundException {
|
||||
// do some magic!
|
||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
||||
}
|
||||
}
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user