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
@ -20,15 +20,15 @@ var (
|
|||||||
type {{classname}}Service service
|
type {{classname}}Service service
|
||||||
{{#operation}}
|
{{#operation}}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
{{{classname}}}Service{{#summary}} {{.}}{{/summary}}
|
{{{classname}}}Service{{#summary}} {{{.}}}{{/summary}}
|
||||||
{{#notes}}
|
{{#notes}}
|
||||||
{{notes}}
|
{{notes}}
|
||||||
{{/notes}}
|
{{/notes}}
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
{{#allParams}}
|
{{#allParams}}
|
||||||
{{#required}}
|
{{#required}}
|
||||||
* @param {{paramName}}{{#description}} {{.}}{{/description}}
|
* @param {{paramName}}{{#description}} {{{.}}}{{/description}}
|
||||||
{{/required}}
|
{{/required}}
|
||||||
{{/allParams}}
|
{{/allParams}}
|
||||||
{{#hasOptionalParams}}
|
{{#hasOptionalParams}}
|
||||||
@ -243,8 +243,12 @@ func (a *{{{classname}}}Service) {{{nickname}}}(ctx context.Context{{#hasParams}
|
|||||||
} else {
|
} else {
|
||||||
key = auth.Key
|
key = auth.Key
|
||||||
}
|
}
|
||||||
{{#isKeyInHeader}}localVarHeaderParams["{{keyParamName}}"] = key{{/isKeyInHeader}}
|
{{#isKeyInHeader}}
|
||||||
{{#isKeyInQuery}}localVarQueryParams.Add("{{keyParamName}}", key){{/isKeyInQuery}}
|
localVarHeaderParams["{{keyParamName}}"] = key
|
||||||
|
{{/isKeyInHeader}}
|
||||||
|
{{#isKeyInQuery}}
|
||||||
|
localVarQueryParams.Add("{{keyParamName}}", key)
|
||||||
|
{{/isKeyInQuery}}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -270,7 +274,7 @@ func (a *{{{classname}}}Service) {{{nickname}}}(ctx context.Context{{#hasParams}
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return {{#returnType}}localVarReturnValue, {{/returnType}}localVarHttpResponse, err
|
return {{#returnType}}localVarReturnValue, {{/returnType}}localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -272,43 +272,6 @@ paths:
|
|||||||
- petstore_auth:
|
- petstore_auth:
|
||||||
- 'write:pets'
|
- 'write:pets'
|
||||||
- 'read: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:
|
/store/inventory:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@ -984,6 +947,43 @@ paths:
|
|||||||
description: successful operation
|
description: successful operation
|
||||||
schema:
|
schema:
|
||||||
$ref: '#/definitions/Client'
|
$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:
|
securityDefinitions:
|
||||||
petstore_auth:
|
petstore_auth:
|
||||||
type: oauth2
|
type: oauth2
|
||||||
|
@ -67,6 +67,7 @@ paths:
|
|||||||
description: Status values that need to be considered for filter
|
description: Status values that need to be considered for filter
|
||||||
required: true
|
required: true
|
||||||
style: form
|
style: form
|
||||||
|
explode: false
|
||||||
schema:
|
schema:
|
||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
@ -111,6 +112,7 @@ paths:
|
|||||||
description: Tags to filter by
|
description: Tags to filter by
|
||||||
required: true
|
required: true
|
||||||
style: form
|
style: form
|
||||||
|
explode: false
|
||||||
schema:
|
schema:
|
||||||
type: array
|
type: array
|
||||||
items:
|
items:
|
||||||
@ -265,47 +267,6 @@ paths:
|
|||||||
description: file to upload
|
description: file to upload
|
||||||
type: string
|
type: string
|
||||||
format: binary
|
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:
|
/store/inventory:
|
||||||
get:
|
get:
|
||||||
tags:
|
tags:
|
||||||
@ -612,6 +573,7 @@ paths:
|
|||||||
parameters:
|
parameters:
|
||||||
- name: enum_header_string_array
|
- name: enum_header_string_array
|
||||||
in: header
|
in: header
|
||||||
|
explode: true
|
||||||
description: Header parameter enum test (string array)
|
description: Header parameter enum test (string array)
|
||||||
schema:
|
schema:
|
||||||
type: array
|
type: array
|
||||||
@ -950,6 +912,47 @@ paths:
|
|||||||
$ref: '#/components/schemas/Client'
|
$ref: '#/components/schemas/Client'
|
||||||
requestBody:
|
requestBody:
|
||||||
$ref: '#/components/requestBodies/Client'
|
$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:
|
components:
|
||||||
requestBodies:
|
requestBodies:
|
||||||
UserArray:
|
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* | [**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* | [**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* | [**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* | [**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* | [**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
|
*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)
|
- [ReadOnlyFirst](docs/ReadOnlyFirst.md)
|
||||||
- [Return](docs/Return.md)
|
- [Return](docs/Return.md)
|
||||||
- [SpecialModelName](docs/SpecialModelName.md)
|
- [SpecialModelName](docs/SpecialModelName.md)
|
||||||
|
- [StringBooleanMap](docs/StringBooleanMap.md)
|
||||||
- [Tag](docs/Tag.md)
|
- [Tag](docs/Tag.md)
|
||||||
- [User](docs/User.md)
|
- [User](docs/User.md)
|
||||||
|
|
||||||
|
@ -973,6 +973,46 @@ paths:
|
|||||||
summary: To test special tags
|
summary: To test special tags
|
||||||
tags:
|
tags:
|
||||||
- $another-fake?
|
- $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:
|
components:
|
||||||
schemas:
|
schemas:
|
||||||
Category:
|
Category:
|
||||||
@ -1276,14 +1316,18 @@ components:
|
|||||||
type: array
|
type: array
|
||||||
type: object
|
type: object
|
||||||
OuterComposite:
|
OuterComposite:
|
||||||
example: {}
|
example:
|
||||||
|
my_string: my_string
|
||||||
|
my_number: 0.80082819046101150206595775671303272247314453125
|
||||||
|
my_boolean: true
|
||||||
properties:
|
properties:
|
||||||
my_number:
|
my_number:
|
||||||
$ref: '#/components/schemas/OuterNumber'
|
type: number
|
||||||
my_string:
|
my_string:
|
||||||
$ref: '#/components/schemas/OuterString'
|
type: string
|
||||||
my_boolean:
|
my_boolean:
|
||||||
$ref: '#/components/schemas/OuterBoolean'
|
type: boolean
|
||||||
|
x-codegen-body-parameter-name: boolean_post_body
|
||||||
type: object
|
type: object
|
||||||
format_test:
|
format_test:
|
||||||
properties:
|
properties:
|
||||||
@ -1381,6 +1425,10 @@ components:
|
|||||||
required:
|
required:
|
||||||
- className
|
- className
|
||||||
type: object
|
type: object
|
||||||
|
StringBooleanMap:
|
||||||
|
additionalProperties:
|
||||||
|
type: boolean
|
||||||
|
type: object
|
||||||
Cat:
|
Cat:
|
||||||
allOf:
|
allOf:
|
||||||
- $ref: '#/components/schemas/Animal'
|
- $ref: '#/components/schemas/Animal'
|
||||||
@ -1403,6 +1451,12 @@ components:
|
|||||||
- lower
|
- lower
|
||||||
type: string
|
type: string
|
||||||
type: object
|
type: object
|
||||||
|
direct_map:
|
||||||
|
additionalProperties:
|
||||||
|
type: boolean
|
||||||
|
type: object
|
||||||
|
indirect_map:
|
||||||
|
$ref: '#/components/schemas/StringBooleanMap'
|
||||||
type: object
|
type: object
|
||||||
Tag:
|
Tag:
|
||||||
example:
|
example:
|
||||||
|
@ -24,7 +24,7 @@ var (
|
|||||||
|
|
||||||
type AnotherFakeApiService service
|
type AnotherFakeApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
AnotherFakeApiService To test special tags
|
AnotherFakeApiService To test special tags
|
||||||
To test special tags
|
To test special tags
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -85,7 +85,7 @@ func (a *AnotherFakeApiService) TestSpecialTags(ctx context.Context, client Clie
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,7 +26,7 @@ var (
|
|||||||
|
|
||||||
type FakeApiService service
|
type FakeApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of outer boolean types
|
Test serialization of outer boolean types
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -96,7 +96,7 @@ func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVar
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -122,7 +122,7 @@ func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVar
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of object with outer number type
|
Test serialization of object with outer number type
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -196,7 +196,7 @@ func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localV
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -222,7 +222,7 @@ func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localV
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of outer number types
|
Test serialization of outer number types
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -292,7 +292,7 @@ func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarO
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -318,7 +318,7 @@ func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarO
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of outer string types
|
Test serialization of outer string types
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -388,7 +388,7 @@ func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarO
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -414,7 +414,7 @@ func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarO
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param query
|
* @param query
|
||||||
@ -482,8 +482,8 @@ func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query stri
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService To test \"client\" model
|
FakeApiService To test \"client\" model
|
||||||
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 ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param client client model
|
* @param client client model
|
||||||
@ -543,7 +543,7 @@ func (a *FakeApiService) TestClientModel(ctx context.Context, client Client) (Cl
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -569,7 +569,7 @@ func (a *FakeApiService) TestClientModel(ctx context.Context, client Client) (Cl
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
FakeApiService Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||||
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -719,7 +719,7 @@ func (a *FakeApiService) TestEndpointParameters(ctx context.Context, number floa
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService To test enum parameters
|
FakeApiService To test enum parameters
|
||||||
To test enum parameters
|
To test enum parameters
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -828,7 +828,7 @@ func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptiona
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService test inline additionalProperties
|
FakeApiService test inline additionalProperties
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param requestBody request body
|
* @param requestBody request body
|
||||||
@ -894,7 +894,7 @@ func (a *FakeApiService) TestInlineAdditionalProperties(ctx context.Context, req
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService test json serialization of form data
|
FakeApiService test json serialization of form data
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param param field1
|
* @param param field1
|
||||||
|
@ -24,7 +24,7 @@ var (
|
|||||||
|
|
||||||
type FakeClassnameTags123ApiService service
|
type FakeClassnameTags123ApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeClassnameTags123ApiService To test class name in snake case
|
FakeClassnameTags123ApiService To test class name in snake case
|
||||||
To test class name in snake case
|
To test class name in snake case
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -75,7 +75,6 @@ func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, clie
|
|||||||
} else {
|
} else {
|
||||||
key = auth.Key
|
key = auth.Key
|
||||||
}
|
}
|
||||||
|
|
||||||
localVarQueryParams.Add("api_key_query", key)
|
localVarQueryParams.Add("api_key_query", key)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -99,7 +98,7 @@ func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, clie
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -27,7 +27,7 @@ var (
|
|||||||
|
|
||||||
type PetApiService service
|
type PetApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Add a new pet to the store
|
PetApiService Add a new pet to the store
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param pet Pet object that needs to be added to the store
|
* @param pet Pet object that needs to be added to the store
|
||||||
@ -93,7 +93,7 @@ func (a *PetApiService) AddPet(ctx context.Context, pet Pet) (*http.Response, er
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Deletes a pet
|
PetApiService Deletes a pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param petId Pet id to delete
|
* @param petId Pet id to delete
|
||||||
@ -168,7 +168,7 @@ func (a *PetApiService) DeletePet(ctx context.Context, petId int64, localVarOpti
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Finds Pets by status
|
PetApiService Finds Pets by status
|
||||||
Multiple status values can be provided with comma separated strings
|
Multiple status values can be provided with comma separated strings
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -228,7 +228,7 @@ func (a *PetApiService) FindPetsByStatus(ctx context.Context, status []string) (
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -254,7 +254,7 @@ func (a *PetApiService) FindPetsByStatus(ctx context.Context, status []string) (
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Finds Pets by tags
|
PetApiService Finds Pets by tags
|
||||||
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -314,7 +314,7 @@ func (a *PetApiService) FindPetsByTags(ctx context.Context, tags []string) ([]Pe
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -340,7 +340,7 @@ func (a *PetApiService) FindPetsByTags(ctx context.Context, tags []string) ([]Pe
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Find pet by ID
|
PetApiService Find pet by ID
|
||||||
Returns a single pet
|
Returns a single pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -391,7 +391,6 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
|||||||
key = auth.Key
|
key = auth.Key
|
||||||
}
|
}
|
||||||
localVarHeaderParams["api_key"] = key
|
localVarHeaderParams["api_key"] = key
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -414,7 +413,7 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -440,7 +439,7 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Update an existing pet
|
PetApiService Update an existing pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param pet Pet object that needs to be added to the store
|
* @param pet Pet object that needs to be added to the store
|
||||||
@ -506,7 +505,7 @@ func (a *PetApiService) UpdatePet(ctx context.Context, pet Pet) (*http.Response,
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Updates a pet in the store with form data
|
PetApiService Updates a pet in the store with form data
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param petId ID of pet that needs to be updated
|
* @param petId ID of pet that needs to be updated
|
||||||
@ -586,7 +585,7 @@ func (a *PetApiService) UpdatePetWithForm(ctx context.Context, petId int64, loca
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService uploads an image
|
PetApiService uploads an image
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @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 petId ID of pet to update
|
||||||
@ -671,7 +670,110 @@ func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOpt
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
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
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
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
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ var (
|
|||||||
|
|
||||||
type StoreApiService service
|
type StoreApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Delete purchase order by ID
|
StoreApiService Delete purchase order by ID
|
||||||
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
|
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -91,7 +91,7 @@ func (a *StoreApiService) DeleteOrder(ctx context.Context, orderId string) (*htt
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Returns pet inventories by status
|
StoreApiService Returns pet inventories by status
|
||||||
Returns a map of status codes to quantities
|
Returns a map of status codes to quantities
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -140,7 +140,6 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
|||||||
key = auth.Key
|
key = auth.Key
|
||||||
}
|
}
|
||||||
localVarHeaderParams["api_key"] = key
|
localVarHeaderParams["api_key"] = key
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -163,7 +162,7 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -189,7 +188,7 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Find purchase order by ID
|
StoreApiService Find purchase order by ID
|
||||||
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
|
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -255,7 +254,7 @@ func (a *StoreApiService) GetOrderById(ctx context.Context, orderId int64) (Orde
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -281,7 +280,7 @@ func (a *StoreApiService) GetOrderById(ctx context.Context, orderId int64) (Orde
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Place an order for a pet
|
StoreApiService Place an order for a pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param order order placed for purchasing the pet
|
* @param order order placed for purchasing the pet
|
||||||
@ -341,7 +340,7 @@ func (a *StoreApiService) PlaceOrder(ctx context.Context, order Order) (Order, *
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ var (
|
|||||||
|
|
||||||
type UserApiService service
|
type UserApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Create user
|
UserApiService Create user
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -92,7 +92,7 @@ func (a *UserApiService) CreateUser(ctx context.Context, user User) (*http.Respo
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Creates list of users with given input array
|
UserApiService Creates list of users with given input array
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param user List of user object
|
* @param user List of user object
|
||||||
@ -158,7 +158,7 @@ func (a *UserApiService) CreateUsersWithArrayInput(ctx context.Context, user []U
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Creates list of users with given input array
|
UserApiService Creates list of users with given input array
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param user List of user object
|
* @param user List of user object
|
||||||
@ -224,7 +224,7 @@ func (a *UserApiService) CreateUsersWithListInput(ctx context.Context, user []Us
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Delete user
|
UserApiService Delete user
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -290,7 +290,7 @@ func (a *UserApiService) DeleteUser(ctx context.Context, username string) (*http
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Get user by user name
|
UserApiService Get user by user name
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param username The name that needs to be fetched. Use user1 for testing.
|
* @param username The name that needs to be fetched. Use user1 for testing.
|
||||||
@ -349,7 +349,7 @@ func (a *UserApiService) GetUserByName(ctx context.Context, username string) (Us
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -375,7 +375,7 @@ func (a *UserApiService) GetUserByName(ctx context.Context, username string) (Us
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Logs user into the system
|
UserApiService Logs user into the system
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param username The user name for login
|
* @param username The user name for login
|
||||||
@ -436,7 +436,7 @@ func (a *UserApiService) LoginUser(ctx context.Context, username string, passwor
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -462,7 +462,7 @@ func (a *UserApiService) LoginUser(ctx context.Context, username string, passwor
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Logs out current logged in user session
|
UserApiService Logs out current logged in user session
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
*/
|
*/
|
||||||
@ -525,7 +525,7 @@ func (a *UserApiService) LogoutUser(ctx context.Context) (*http.Response, error)
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Updated user
|
UserApiService Updated user
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
|
@ -5,6 +5,8 @@ Name | Type | Description | Notes
|
|||||||
------------ | ------------- | ------------- | -------------
|
------------ | ------------- | ------------- | -------------
|
||||||
**MapMapOfString** | [**map[string]map[string]string**](map.md) | | [optional]
|
**MapMapOfString** | [**map[string]map[string]string**](map.md) | | [optional]
|
||||||
**MapOfEnumString** | **map[string]string** | | [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)
|
[[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
|
[**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
|
[**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
|
[**UploadFile**](PetApi.md#UploadFile) | **Post** /pet/{petId}/uploadImage | uploads an image
|
||||||
|
[**UploadFileWithRequiredFile**](PetApi.md#UploadFileWithRequiredFile) | **Post** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required)
|
||||||
|
|
||||||
|
|
||||||
# **AddPet**
|
# **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)
|
[[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 {
|
type MapTest struct {
|
||||||
MapMapOfString map[string]map[string]string `json:"map_map_of_string,omitempty" xml:"map_map_of_string"`
|
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"`
|
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* | [**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* | [**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* | [**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* | [**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* | [**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
|
*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
|
summary: uploads an image
|
||||||
tags:
|
tags:
|
||||||
- pet
|
- 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:
|
/store/inventory:
|
||||||
get:
|
get:
|
||||||
description: Returns a map of status codes to quantities
|
description: Returns a map of status codes to quantities
|
||||||
@ -1013,6 +973,46 @@ paths:
|
|||||||
summary: To test special tags
|
summary: To test special tags
|
||||||
tags:
|
tags:
|
||||||
- $another-fake?
|
- $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:
|
components:
|
||||||
schemas:
|
schemas:
|
||||||
Category:
|
Category:
|
||||||
|
@ -24,7 +24,7 @@ var (
|
|||||||
|
|
||||||
type AnotherFakeApiService service
|
type AnotherFakeApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
AnotherFakeApiService To test special tags
|
AnotherFakeApiService To test special tags
|
||||||
To test special tags
|
To test special tags
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -85,7 +85,7 @@ func (a *AnotherFakeApiService) TestSpecialTags(ctx context.Context, client Clie
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -26,7 +26,7 @@ var (
|
|||||||
|
|
||||||
type FakeApiService service
|
type FakeApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of outer boolean types
|
Test serialization of outer boolean types
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -96,7 +96,7 @@ func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVar
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -122,7 +122,7 @@ func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVar
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of object with outer number type
|
Test serialization of object with outer number type
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -196,7 +196,7 @@ func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localV
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -222,7 +222,7 @@ func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localV
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of outer number types
|
Test serialization of outer number types
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -292,7 +292,7 @@ func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarO
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -318,7 +318,7 @@ func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarO
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
Test serialization of outer string types
|
Test serialization of outer string types
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -388,7 +388,7 @@ func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarO
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -414,7 +414,7 @@ func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarO
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService
|
FakeApiService
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param query
|
* @param query
|
||||||
@ -482,8 +482,8 @@ func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query stri
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService To test \"client\" model
|
FakeApiService To test \"client\" model
|
||||||
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 ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param client client model
|
* @param client client model
|
||||||
@ -543,7 +543,7 @@ func (a *FakeApiService) TestClientModel(ctx context.Context, client Client) (Cl
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -569,7 +569,7 @@ func (a *FakeApiService) TestClientModel(ctx context.Context, client Client) (Cl
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
FakeApiService Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||||
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -719,7 +719,7 @@ func (a *FakeApiService) TestEndpointParameters(ctx context.Context, number floa
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService To test enum parameters
|
FakeApiService To test enum parameters
|
||||||
To test enum parameters
|
To test enum parameters
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -828,7 +828,7 @@ func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptiona
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService test inline additionalProperties
|
FakeApiService test inline additionalProperties
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param requestBody request body
|
* @param requestBody request body
|
||||||
@ -894,7 +894,7 @@ func (a *FakeApiService) TestInlineAdditionalProperties(ctx context.Context, req
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeApiService test json serialization of form data
|
FakeApiService test json serialization of form data
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param param field1
|
* @param param field1
|
||||||
|
@ -24,7 +24,7 @@ var (
|
|||||||
|
|
||||||
type FakeClassnameTags123ApiService service
|
type FakeClassnameTags123ApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
FakeClassnameTags123ApiService To test class name in snake case
|
FakeClassnameTags123ApiService To test class name in snake case
|
||||||
To test class name in snake case
|
To test class name in snake case
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -75,7 +75,6 @@ func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, clie
|
|||||||
} else {
|
} else {
|
||||||
key = auth.Key
|
key = auth.Key
|
||||||
}
|
}
|
||||||
|
|
||||||
localVarQueryParams.Add("api_key_query", key)
|
localVarQueryParams.Add("api_key_query", key)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -99,7 +98,7 @@ func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, clie
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -27,7 +27,7 @@ var (
|
|||||||
|
|
||||||
type PetApiService service
|
type PetApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Add a new pet to the store
|
PetApiService Add a new pet to the store
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param pet Pet object that needs to be added to the store
|
* @param pet Pet object that needs to be added to the store
|
||||||
@ -93,7 +93,7 @@ func (a *PetApiService) AddPet(ctx context.Context, pet Pet) (*http.Response, er
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Deletes a pet
|
PetApiService Deletes a pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param petId Pet id to delete
|
* @param petId Pet id to delete
|
||||||
@ -168,7 +168,7 @@ func (a *PetApiService) DeletePet(ctx context.Context, petId int64, localVarOpti
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Finds Pets by status
|
PetApiService Finds Pets by status
|
||||||
Multiple status values can be provided with comma separated strings
|
Multiple status values can be provided with comma separated strings
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -228,7 +228,7 @@ func (a *PetApiService) FindPetsByStatus(ctx context.Context, status []string) (
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -254,7 +254,7 @@ func (a *PetApiService) FindPetsByStatus(ctx context.Context, status []string) (
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Finds Pets by tags
|
PetApiService Finds Pets by tags
|
||||||
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -314,7 +314,7 @@ func (a *PetApiService) FindPetsByTags(ctx context.Context, tags []string) ([]Pe
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -340,7 +340,7 @@ func (a *PetApiService) FindPetsByTags(ctx context.Context, tags []string) ([]Pe
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Find pet by ID
|
PetApiService Find pet by ID
|
||||||
Returns a single pet
|
Returns a single pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -391,7 +391,6 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
|||||||
key = auth.Key
|
key = auth.Key
|
||||||
}
|
}
|
||||||
localVarHeaderParams["api_key"] = key
|
localVarHeaderParams["api_key"] = key
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -414,7 +413,7 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -440,7 +439,7 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Update an existing pet
|
PetApiService Update an existing pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param pet Pet object that needs to be added to the store
|
* @param pet Pet object that needs to be added to the store
|
||||||
@ -506,7 +505,7 @@ func (a *PetApiService) UpdatePet(ctx context.Context, pet Pet) (*http.Response,
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService Updates a pet in the store with form data
|
PetApiService Updates a pet in the store with form data
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param petId ID of pet that needs to be updated
|
* @param petId ID of pet that needs to be updated
|
||||||
@ -586,7 +585,7 @@ func (a *PetApiService) UpdatePetWithForm(ctx context.Context, petId int64, loca
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
PetApiService uploads an image
|
PetApiService uploads an image
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @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 petId ID of pet to update
|
||||||
@ -671,7 +670,7 @@ func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOpt
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -697,8 +696,8 @@ func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOpt
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
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 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 petId ID of pet to update
|
||||||
* @param file file to upload
|
* @param file file to upload
|
||||||
@ -721,7 +720,7 @@ func (a *PetApiService) UploadFileWithRequiredFile(ctx context.Context, petId in
|
|||||||
)
|
)
|
||||||
|
|
||||||
// create path and map variables
|
// 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)
|
localVarPath = strings.Replace(localVarPath, "{"+"petId"+"}", fmt.Sprintf("%v", petId), -1)
|
||||||
|
|
||||||
localVarHeaderParams := make(map[string]string)
|
localVarHeaderParams := make(map[string]string)
|
||||||
@ -774,7 +773,7 @@ func (a *PetApiService) UploadFileWithRequiredFile(ctx context.Context, petId in
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ var (
|
|||||||
|
|
||||||
type StoreApiService service
|
type StoreApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Delete purchase order by ID
|
StoreApiService Delete purchase order by ID
|
||||||
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
|
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -91,7 +91,7 @@ func (a *StoreApiService) DeleteOrder(ctx context.Context, orderId string) (*htt
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Returns pet inventories by status
|
StoreApiService Returns pet inventories by status
|
||||||
Returns a map of status codes to quantities
|
Returns a map of status codes to quantities
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -140,7 +140,6 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
|||||||
key = auth.Key
|
key = auth.Key
|
||||||
}
|
}
|
||||||
localVarHeaderParams["api_key"] = key
|
localVarHeaderParams["api_key"] = key
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -163,7 +162,7 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -189,7 +188,7 @@ func (a *StoreApiService) GetInventory(ctx context.Context) (map[string]int32, *
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Find purchase order by ID
|
StoreApiService Find purchase order by ID
|
||||||
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
|
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -255,7 +254,7 @@ func (a *StoreApiService) GetOrderById(ctx context.Context, orderId int64) (Orde
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -281,7 +280,7 @@ func (a *StoreApiService) GetOrderById(ctx context.Context, orderId int64) (Orde
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
StoreApiService Place an order for a pet
|
StoreApiService Place an order for a pet
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param order order placed for purchasing the pet
|
* @param order order placed for purchasing the pet
|
||||||
@ -341,7 +340,7 @@ func (a *StoreApiService) PlaceOrder(ctx context.Context, order Order) (Order, *
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ var (
|
|||||||
|
|
||||||
type UserApiService service
|
type UserApiService service
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Create user
|
UserApiService Create user
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -92,7 +92,7 @@ func (a *UserApiService) CreateUser(ctx context.Context, user User) (*http.Respo
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Creates list of users with given input array
|
UserApiService Creates list of users with given input array
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param user List of user object
|
* @param user List of user object
|
||||||
@ -158,7 +158,7 @@ func (a *UserApiService) CreateUsersWithArrayInput(ctx context.Context, user []U
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Creates list of users with given input array
|
UserApiService Creates list of users with given input array
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param user List of user object
|
* @param user List of user object
|
||||||
@ -224,7 +224,7 @@ func (a *UserApiService) CreateUsersWithListInput(ctx context.Context, user []Us
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Delete user
|
UserApiService Delete user
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
@ -290,7 +290,7 @@ func (a *UserApiService) DeleteUser(ctx context.Context, username string) (*http
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Get user by user name
|
UserApiService Get user by user name
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param username The name that needs to be fetched. Use user1 for testing.
|
* @param username The name that needs to be fetched. Use user1 for testing.
|
||||||
@ -349,7 +349,7 @@ func (a *UserApiService) GetUserByName(ctx context.Context, username string) (Us
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -375,7 +375,7 @@ func (a *UserApiService) GetUserByName(ctx context.Context, username string) (Us
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Logs user into the system
|
UserApiService Logs user into the system
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
* @param username The user name for login
|
* @param username The user name for login
|
||||||
@ -436,7 +436,7 @@ func (a *UserApiService) LoginUser(ctx context.Context, username string, passwor
|
|||||||
if localVarHttpResponse.StatusCode < 300 {
|
if localVarHttpResponse.StatusCode < 300 {
|
||||||
// If we succeed, return the data, otherwise pass on to decode error.
|
// If we succeed, return the data, otherwise pass on to decode error.
|
||||||
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type"));
|
||||||
if err == nil {
|
if err == nil {
|
||||||
return localVarReturnValue, localVarHttpResponse, err
|
return localVarReturnValue, localVarHttpResponse, err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -462,7 +462,7 @@ func (a *UserApiService) LoginUser(ctx context.Context, username string, passwor
|
|||||||
return localVarReturnValue, localVarHttpResponse, nil
|
return localVarReturnValue, localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Logs out current logged in user session
|
UserApiService Logs out current logged in user session
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
*/
|
*/
|
||||||
@ -525,7 +525,7 @@ func (a *UserApiService) LogoutUser(ctx context.Context) (*http.Response, error)
|
|||||||
return localVarHttpResponse, nil
|
return localVarHttpResponse, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
UserApiService Updated user
|
UserApiService Updated user
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
* @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
|
||||||
|
@ -6,7 +6,7 @@ Name | Type | Description | Notes
|
|||||||
**MapMapOfString** | [**map[string]map[string]string**](map.md) | | [optional]
|
**MapMapOfString** | [**map[string]map[string]string**](map.md) | | [optional]
|
||||||
**MapOfEnumString** | **map[string]string** | | [optional]
|
**MapOfEnumString** | **map[string]string** | | [optional]
|
||||||
**DirectMap** | **map[string]bool** | | [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)
|
[[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
|
[**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
|
[**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
|
[**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**
|
# **AddPet**
|
||||||
@ -260,7 +260,7 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
# **UploadFileWithRequiredFile**
|
# **UploadFileWithRequiredFile**
|
||||||
> ApiResponse UploadFileWithRequiredFile(ctx, petId, file, optional)
|
> ApiResponse UploadFileWithRequiredFile(ctx, petId, file, optional)
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
|
@ -13,5 +13,5 @@ type MapTest struct {
|
|||||||
MapMapOfString map[string]map[string]string `json:"map_map_of_string,omitempty"`
|
MapMapOfString map[string]map[string]string `json:"map_map_of_string,omitempty"`
|
||||||
MapOfEnumString map[string]string `json:"map_of_enum_string,omitempty"`
|
MapOfEnumString map[string]string `json:"map_of_enum_string,omitempty"`
|
||||||
DirectMap map[string]bool `json:"direct_map,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);
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
* @param additionalMetadata Additional data to pass to server (optional, default to null)
|
* @param additionalMetadata Additional data to pass to server (optional, default to null)
|
||||||
* @return ModelApiResponse
|
* @return ModelApiResponse
|
||||||
*/
|
*/
|
||||||
@RequestLine("POST /pet/{petId}/uploadImageWithRequiredFile")
|
@RequestLine("POST /fake/{petId}/uploadImageWithRequiredFile")
|
||||||
@Headers({
|
@Headers({
|
||||||
"Content-Type: multipart/form-data",
|
"Content-Type: multipart/form-data",
|
||||||
"Accept: application/json",
|
"Accept: application/json",
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -716,7 +716,7 @@ public class PetApi {
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
* <p><b>200</b> - successful operation
|
* <p><b>200</b> - successful operation
|
||||||
* @param petId ID of pet to update
|
* @param petId ID of pet to update
|
||||||
* @param file file to upload
|
* @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
|
* <p><b>200</b> - successful operation
|
||||||
* @param petId ID of pet to update
|
* @param petId ID of pet to update
|
||||||
* @param file file to upload
|
* @param file file to upload
|
||||||
@ -756,7 +756,7 @@ public class PetApi {
|
|||||||
// create a map of path variables
|
// create a map of path variables
|
||||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||||
uriVariables.put("petId", petId);
|
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();
|
String url = uriBuilder.buildFromMap(uriVariables).toString();
|
||||||
GenericUrl genericUrl = new GenericUrl(url);
|
GenericUrl genericUrl = new GenericUrl(url);
|
||||||
@ -776,7 +776,7 @@ public class PetApi {
|
|||||||
// create a map of path variables
|
// create a map of path variables
|
||||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||||
uriVariables.put("petId", petId);
|
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
|
// 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);
|
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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -406,7 +406,7 @@ if (file != null)
|
|||||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -428,7 +428,7 @@ if (file != null)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// create path and map variables
|
// create path and map variables
|
||||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||||
|
|
||||||
// query params
|
// query params
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -480,7 +480,7 @@ if (file != null)
|
|||||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -515,7 +515,7 @@ if (file != null)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// create path and map variables
|
// create path and map variables
|
||||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||||
|
|
||||||
// query params
|
// query params
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -480,7 +480,7 @@ if (file != null)
|
|||||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -515,7 +515,7 @@ if (file != null)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// create path and map variables
|
// create path and map variables
|
||||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||||
|
|
||||||
// query params
|
// query params
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -480,7 +480,7 @@ if (file != null)
|
|||||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -515,7 +515,7 @@ if (file != null)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// create path and map variables
|
// create path and map variables
|
||||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||||
|
|
||||||
// query params
|
// query params
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -1077,7 +1077,7 @@ public class PetApi {
|
|||||||
Object localVarPostBody = new Object();
|
Object localVarPostBody = new Object();
|
||||||
|
|
||||||
// create path and map variables
|
// create path and map variables
|
||||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||||
|
|
||||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -1077,7 +1077,7 @@ public class PetApi {
|
|||||||
Object localVarPostBody = new Object();
|
Object localVarPostBody = new Object();
|
||||||
|
|
||||||
// create path and map variables
|
// create path and map variables
|
||||||
String localVarPath = "/pet/{petId}/uploadImageWithRequiredFile"
|
String localVarPath = "/fake/{petId}/uploadImageWithRequiredFile"
|
||||||
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||||
|
|
||||||
List<Pair> localVarQueryParams = new ArrayList<Pair>();
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -350,7 +350,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -743,7 +743,7 @@ public class PetApi {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @see #petIdPath ID of pet to update (required)
|
* @see #petIdPath ID of pet to update (required)
|
||||||
@ -753,7 +753,7 @@ public class PetApi {
|
|||||||
*/
|
*/
|
||||||
public class UploadFileWithRequiredFileOper {
|
public class UploadFileWithRequiredFileOper {
|
||||||
|
|
||||||
public static final String REQ_URI = "/pet/{petId}/uploadImageWithRequiredFile";
|
public static final String REQ_URI = "/fake/{petId}/uploadImageWithRequiredFile";
|
||||||
|
|
||||||
private RequestSpecBuilder reqSpec;
|
private RequestSpecBuilder reqSpec;
|
||||||
|
|
||||||
@ -774,7 +774,7 @@ public class PetApi {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* POST /pet/{petId}/uploadImageWithRequiredFile
|
* POST /fake/{petId}/uploadImageWithRequiredFile
|
||||||
* @param handler handler
|
* @param handler handler
|
||||||
* @param <T> type
|
* @param <T> type
|
||||||
* @return type
|
* @return type
|
||||||
@ -784,7 +784,7 @@ public class PetApi {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* POST /pet/{petId}/uploadImageWithRequiredFile
|
* POST /fake/{petId}/uploadImageWithRequiredFile
|
||||||
* @param handler handler
|
* @param handler handler
|
||||||
* @return ModelApiResponse
|
* @return ModelApiResponse
|
||||||
*/
|
*/
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -384,7 +384,7 @@ if (file != null)
|
|||||||
return apiClient.invokeAPI(localVarPath, "POST", localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAccept, localVarContentType, localVarAuthNames, localVarReturnType);
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -406,7 +406,7 @@ if (file != null)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// create path and map variables
|
// 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()));
|
.replaceAll("\\{" + "petId" + "\\}", apiClient.escapeString(petId.toString()));
|
||||||
|
|
||||||
// query params
|
// query params
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -356,7 +356,7 @@ public class PetApi {
|
|||||||
return apiClient.invokeAPI(path, HttpMethod.POST, queryParams, postBody, headerParams, formParams, accept, contentType, authNames, returnType);
|
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
|
* <p><b>200</b> - successful operation
|
||||||
* @param petId ID of pet to update
|
* @param petId ID of pet to update
|
||||||
@ -381,7 +381,7 @@ public class PetApi {
|
|||||||
// create path and map variables
|
// create path and map variables
|
||||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||||
uriVariables.put("petId", petId);
|
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 MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||||
final HttpHeaders headerParams = new HttpHeaders();
|
final HttpHeaders headerParams = new HttpHeaders();
|
||||||
|
@ -12,7 +12,7 @@ Method | HTTP request | Description
|
|||||||
[**updatePet**](PetApi.md#updatePet) | **PUT** /pet | Update an existing pet
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -356,7 +356,7 @@ public class PetApi {
|
|||||||
return apiClient.invokeAPI(path, HttpMethod.POST, queryParams, postBody, headerParams, formParams, accept, contentType, authNames, returnType);
|
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
|
* <p><b>200</b> - successful operation
|
||||||
* @param petId ID of pet to update
|
* @param petId ID of pet to update
|
||||||
@ -381,7 +381,7 @@ public class PetApi {
|
|||||||
// create path and map variables
|
// create path and map variables
|
||||||
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
final Map<String, Object> uriVariables = new HashMap<String, Object>();
|
||||||
uriVariables.put("petId", petId);
|
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 MultiValueMap<String, String> queryParams = new LinkedMultiValueMap<String, String>();
|
||||||
final HttpHeaders headerParams = new HttpHeaders();
|
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
|
@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
|
* Sync method
|
||||||
*
|
*
|
||||||
* @param petId ID of pet to update (required)
|
* @param petId ID of pet to update (required)
|
||||||
@ -233,13 +233,13 @@ public interface PetApi {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
@retrofit.http.Multipart
|
@retrofit.http.Multipart
|
||||||
@POST("/pet/{petId}/uploadImageWithRequiredFile")
|
@POST("/fake/{petId}/uploadImageWithRequiredFile")
|
||||||
ModelApiResponse uploadFileWithRequiredFile(
|
ModelApiResponse uploadFileWithRequiredFile(
|
||||||
@retrofit.http.Path("petId") Long petId, @retrofit.http.Part("file") TypedFile file, @retrofit.http.Part("additionalMetadata") String additionalMetadata
|
@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
|
* Async method
|
||||||
* @param petId ID of pet to update (required)
|
* @param petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -248,7 +248,7 @@ public interface PetApi {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
@retrofit.http.Multipart
|
@retrofit.http.Multipart
|
||||||
@POST("/pet/{petId}/uploadImageWithRequiredFile")
|
@POST("/fake/{petId}/uploadImageWithRequiredFile")
|
||||||
void uploadFileWithRequiredFile(
|
void uploadFileWithRequiredFile(
|
||||||
@retrofit.http.Path("petId") Long petId, @retrofit.http.Part("file") TypedFile file, @retrofit.http.Part("additionalMetadata") String additionalMetadata, Callback<ModelApiResponse> cb
|
@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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -126,7 +126,7 @@ public interface PetApi {
|
|||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param petId ID of pet to update (required)
|
* @param petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -134,7 +134,7 @@ public interface PetApi {
|
|||||||
* @return Call<ModelApiResponse>
|
* @return Call<ModelApiResponse>
|
||||||
*/
|
*/
|
||||||
@retrofit2.http.Multipart
|
@retrofit2.http.Multipart
|
||||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||||
F.Promise<Response<ModelApiResponse>> uploadFileWithRequiredFile(
|
F.Promise<Response<ModelApiResponse>> uploadFileWithRequiredFile(
|
||||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
@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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -126,7 +126,7 @@ public interface PetApi {
|
|||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param petId ID of pet to update (required)
|
* @param petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -134,7 +134,7 @@ public interface PetApi {
|
|||||||
* @return Call<ModelApiResponse>
|
* @return Call<ModelApiResponse>
|
||||||
*/
|
*/
|
||||||
@retrofit2.http.Multipart
|
@retrofit2.http.Multipart
|
||||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||||
CompletionStage<Response<ModelApiResponse>> uploadFileWithRequiredFile(
|
CompletionStage<Response<ModelApiResponse>> uploadFileWithRequiredFile(
|
||||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
@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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -123,7 +123,7 @@ public interface PetApi {
|
|||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param petId ID of pet to update (required)
|
* @param petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -131,7 +131,7 @@ public interface PetApi {
|
|||||||
* @return Call<ModelApiResponse>
|
* @return Call<ModelApiResponse>
|
||||||
*/
|
*/
|
||||||
@retrofit2.http.Multipart
|
@retrofit2.http.Multipart
|
||||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||||
Call<ModelApiResponse> uploadFileWithRequiredFile(
|
Call<ModelApiResponse> uploadFileWithRequiredFile(
|
||||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
@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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -123,7 +123,7 @@ public interface PetApi {
|
|||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param petId ID of pet to update (required)
|
* @param petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -131,7 +131,7 @@ public interface PetApi {
|
|||||||
* @return Observable<ModelApiResponse>
|
* @return Observable<ModelApiResponse>
|
||||||
*/
|
*/
|
||||||
@retrofit2.http.Multipart
|
@retrofit2.http.Multipart
|
||||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||||
Observable<ModelApiResponse> uploadFileWithRequiredFile(
|
Observable<ModelApiResponse> uploadFileWithRequiredFile(
|
||||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
@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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```java
|
||||||
|
@ -124,7 +124,7 @@ public interface PetApi {
|
|||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param petId ID of pet to update (required)
|
* @param petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -132,7 +132,7 @@ public interface PetApi {
|
|||||||
* @return Observable<ModelApiResponse>
|
* @return Observable<ModelApiResponse>
|
||||||
*/
|
*/
|
||||||
@retrofit2.http.Multipart
|
@retrofit2.http.Multipart
|
||||||
@POST("pet/{petId}/uploadImageWithRequiredFile")
|
@POST("fake/{petId}/uploadImageWithRequiredFile")
|
||||||
Observable<ModelApiResponse> uploadFileWithRequiredFile(
|
Observable<ModelApiResponse> uploadFileWithRequiredFile(
|
||||||
@retrofit2.http.Path("petId") Long petId, @retrofit2.http.Part("file") MultipartBody.Part file, @retrofit2.http.Part("additionalMetadata") String additionalMetadata
|
@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
|
[**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
|
[**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
|
[**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>
|
<a name="addPet"></a>
|
||||||
@ -441,7 +441,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
> ModelApiResponse uploadFileWithRequiredFile(petId, file, additionalMetadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```java
|
```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);
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (required)
|
* @param file file to upload (required)
|
||||||
@ -348,7 +348,7 @@ if (file != null) localVarFormParams.put("file", file);
|
|||||||
}
|
}
|
||||||
|
|
||||||
// create path and map variables
|
// 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
|
// query params
|
||||||
List<Pair> localVarQueryParams = new ArrayList<>();
|
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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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 petId ID of pet to update (required)
|
||||||
* @param file file to upload (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* | [**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* | [**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* | [**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* | [**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* | [**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
|
*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
|
[**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
|
[**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
|
[**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**
|
# **addPet**
|
||||||
@ -440,7 +440,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> \OpenAPI\Client\Model\ApiResponse uploadFileWithRequiredFile($pet_id, $file, $additional_metadata)
|
> \OpenAPI\Client\Model\ApiResponse uploadFileWithRequiredFile($pet_id, $file, $additional_metadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```php
|
```php
|
||||||
|
@ -2177,7 +2177,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFile
|
* Operation uploadFileWithRequiredFile
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2196,7 +2196,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFileWithHttpInfo
|
* Operation uploadFileWithRequiredFileWithHttpInfo
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2292,7 +2292,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFileAsync
|
* Operation uploadFileWithRequiredFileAsync
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2314,7 +2314,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFileAsyncWithHttpInfo
|
* Operation uploadFileWithRequiredFileAsyncWithHttpInfo
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2390,7 +2390,7 @@ class PetApi
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
$resourcePath = '/pet/{petId}/uploadImageWithRequiredFile';
|
$resourcePath = '/fake/{petId}/uploadImageWithRequiredFile';
|
||||||
$formParams = [];
|
$formParams = [];
|
||||||
$queryParams = [];
|
$queryParams = [];
|
||||||
$headerParams = [];
|
$headerParams = [];
|
||||||
|
@ -154,7 +154,7 @@ class PetApiTest extends \PHPUnit_Framework_TestCase
|
|||||||
/**
|
/**
|
||||||
* Test case for uploadFileWithRequiredFile
|
* Test case for uploadFileWithRequiredFile
|
||||||
*
|
*
|
||||||
* uploads an image.
|
* uploads an image (required).
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public function testUploadFileWithRequiredFile()
|
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**](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* | [**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**](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* | [**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_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
|
*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**](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
|
[**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**](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**
|
# **add_pet**
|
||||||
@ -422,7 +422,7 @@ Name | Type | Description | Notes
|
|||||||
# **upload_file_with_required_file**
|
# **upload_file_with_required_file**
|
||||||
> ApiResponse upload_file_with_required_file(pet_id, file, opts)
|
> ApiResponse upload_file_with_required_file(pet_id, file, opts)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```ruby
|
```ruby
|
||||||
@ -442,7 +442,7 @@ opts = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
begin
|
begin
|
||||||
#uploads an image
|
#uploads an image (required)
|
||||||
result = api_instance.upload_file_with_required_file(pet_id, file, opts)
|
result = api_instance.upload_file_with_required_file(pet_id, file, opts)
|
||||||
p result
|
p result
|
||||||
rescue Petstore::ApiError => e
|
rescue Petstore::ApiError => e
|
||||||
|
@ -438,7 +438,7 @@ module Petstore
|
|||||||
end
|
end
|
||||||
return data, status_code, headers
|
return data, status_code, headers
|
||||||
end
|
end
|
||||||
# uploads an image
|
# uploads an image (required)
|
||||||
# @param pet_id ID of pet to update
|
# @param pet_id ID of pet to update
|
||||||
# @param file file to upload
|
# @param file file to upload
|
||||||
# @param [Hash] opts the optional parameters
|
# @param [Hash] opts the optional parameters
|
||||||
@ -449,7 +449,7 @@ module Petstore
|
|||||||
data
|
data
|
||||||
end
|
end
|
||||||
|
|
||||||
# uploads an image
|
# uploads an image (required)
|
||||||
# @param pet_id ID of pet to update
|
# @param pet_id ID of pet to update
|
||||||
# @param file file to upload
|
# @param file file to upload
|
||||||
# @param [Hash] opts the optional parameters
|
# @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"
|
fail ArgumentError, "Missing the required parameter 'file' when calling PetApi.upload_file_with_required_file"
|
||||||
end
|
end
|
||||||
# resource path
|
# 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 parameters
|
||||||
query_params = {}
|
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* | [**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* | [**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* | [**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* | [**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* | [**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
|
*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
|
[**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
|
[**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
|
[**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**
|
# **addPet**
|
||||||
@ -440,7 +440,7 @@ Name | Type | Description | Notes
|
|||||||
# **uploadFileWithRequiredFile**
|
# **uploadFileWithRequiredFile**
|
||||||
> \OpenAPI\Client\Model\ApiResponse uploadFileWithRequiredFile($pet_id, $file, $additional_metadata)
|
> \OpenAPI\Client\Model\ApiResponse uploadFileWithRequiredFile($pet_id, $file, $additional_metadata)
|
||||||
|
|
||||||
uploads an image
|
uploads an image (required)
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
```php
|
```php
|
||||||
|
@ -756,7 +756,7 @@ class PetApi
|
|||||||
|
|
||||||
// query params
|
// query params
|
||||||
if (is_array($status)) {
|
if (is_array($status)) {
|
||||||
$status = ObjectSerializer::serializeCollection($status, 'multi', true);
|
$status = ObjectSerializer::serializeCollection($status, 'csv', true);
|
||||||
}
|
}
|
||||||
if ($status !== null) {
|
if ($status !== null) {
|
||||||
$queryParams['status'] = ObjectSerializer::toQueryValue($status);
|
$queryParams['status'] = ObjectSerializer::toQueryValue($status);
|
||||||
@ -1040,7 +1040,7 @@ class PetApi
|
|||||||
|
|
||||||
// query params
|
// query params
|
||||||
if (is_array($tags)) {
|
if (is_array($tags)) {
|
||||||
$tags = ObjectSerializer::serializeCollection($tags, 'multi', true);
|
$tags = ObjectSerializer::serializeCollection($tags, 'csv', true);
|
||||||
}
|
}
|
||||||
if ($tags !== null) {
|
if ($tags !== null) {
|
||||||
$queryParams['tags'] = ObjectSerializer::toQueryValue($tags);
|
$queryParams['tags'] = ObjectSerializer::toQueryValue($tags);
|
||||||
@ -2177,7 +2177,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFile
|
* Operation uploadFileWithRequiredFile
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2196,7 +2196,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFileWithHttpInfo
|
* Operation uploadFileWithRequiredFileWithHttpInfo
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2292,7 +2292,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFileAsync
|
* Operation uploadFileWithRequiredFileAsync
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2314,7 +2314,7 @@ class PetApi
|
|||||||
/**
|
/**
|
||||||
* Operation uploadFileWithRequiredFileAsyncWithHttpInfo
|
* Operation uploadFileWithRequiredFileAsyncWithHttpInfo
|
||||||
*
|
*
|
||||||
* uploads an image
|
* uploads an image (required)
|
||||||
*
|
*
|
||||||
* @param int $pet_id ID of pet to update (required)
|
* @param int $pet_id ID of pet to update (required)
|
||||||
* @param \SplFileObject $file file to upload (required)
|
* @param \SplFileObject $file file to upload (required)
|
||||||
@ -2390,7 +2390,7 @@ class PetApi
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
$resourcePath = '/pet/{petId}/uploadImageWithRequiredFile';
|
$resourcePath = '/fake/{petId}/uploadImageWithRequiredFile';
|
||||||
$formParams = [];
|
$formParams = [];
|
||||||
$queryParams = [];
|
$queryParams = [];
|
||||||
$headerParams = [];
|
$headerParams = [];
|
||||||
|
@ -154,7 +154,7 @@ class PetApiTest extends \PHPUnit_Framework_TestCase
|
|||||||
/**
|
/**
|
||||||
* Test case for uploadFileWithRequiredFile
|
* Test case for uploadFileWithRequiredFile
|
||||||
*
|
*
|
||||||
* uploads an image.
|
* uploads an image (required).
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public function testUploadFileWithRequiredFile()
|
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);
|
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
|
@POST
|
||||||
@Path("/pet/{petId}/uploadImageWithRequiredFile")
|
@Path("/fake/{petId}/uploadImageWithRequiredFile")
|
||||||
@Consumes({ "multipart/form-data" })
|
@Consumes({ "multipart/form-data" })
|
||||||
@Produces({ "application/json" })
|
@Produces({ "application/json" })
|
||||||
@ApiOperation(value = "uploads an image", tags={ "pet" })
|
@ApiOperation(value = "uploads an image (required)", tags={ "pet" })
|
||||||
@ApiResponses(value = {
|
@ApiResponses(value = {
|
||||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
@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);
|
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.io.File;
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import java.time.OffsetDateTime;
|
import java.time.OffsetDateTime;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
@ -211,4 +212,25 @@ public class FakeApi {
|
|||||||
throws NotFoundException {
|
throws NotFoundException {
|
||||||
return delegate.testJsonFormData(param,param2,securityContext);
|
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.io.File;
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import java.time.OffsetDateTime;
|
import java.time.OffsetDateTime;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
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 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 testInlineAdditionalProperties(Map<String, String> requestBody,SecurityContext securityContext) throws NotFoundException;
|
||||||
public abstract Response testJsonFormData(String param,String param2,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 {
|
throws NotFoundException {
|
||||||
return delegate.uploadFile(petId,additionalMetadata,fileInputStream, fileDetail,securityContext);
|
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 updatePet(Pet pet,SecurityContext securityContext) throws NotFoundException;
|
||||||
public abstract Response updatePetWithForm(Long petId,String name,String status,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 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.io.File;
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import java.time.OffsetDateTime;
|
import java.time.OffsetDateTime;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
@ -74,4 +75,9 @@ public class FakeApiServiceImpl extends FakeApiService {
|
|||||||
// do some magic!
|
// do some magic!
|
||||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
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!
|
// do some magic!
|
||||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
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 java.io.File;
|
||||||
import org.joda.time.LocalDate;
|
import org.joda.time.LocalDate;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
|
|
||||||
@ -101,8 +102,23 @@ public interface FakeApi {
|
|||||||
@GET
|
@GET
|
||||||
@Path("/jsonFormData")
|
@Path("/jsonFormData")
|
||||||
@Consumes({ "application/x-www-form-urlencoded" })
|
@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 = {
|
@ApiResponses(value = {
|
||||||
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
|
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
|
||||||
void testJsonFormData(@FormParam(value = "param") String param,@FormParam(value = "param2") String param2);
|
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 = "write:pets", description = "modify pets in your account"),
|
||||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||||
})
|
})
|
||||||
}, tags={ "pet", })
|
}, tags={ "pet" })
|
||||||
@ApiResponses(value = {
|
@ApiResponses(value = {
|
||||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
@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,
|
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);
|
@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
|
- pet
|
||||||
x-tags:
|
x-tags:
|
||||||
- tag: pet
|
- 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:
|
/store/inventory:
|
||||||
get:
|
get:
|
||||||
description: Returns a map of status codes to quantities
|
description: Returns a map of status codes to quantities
|
||||||
@ -1079,6 +1037,48 @@ paths:
|
|||||||
- $another-fake?
|
- $another-fake?
|
||||||
x-tags:
|
x-tags:
|
||||||
- tag: $another-fake?
|
- 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:
|
components:
|
||||||
schemas:
|
schemas:
|
||||||
Category:
|
Category:
|
||||||
|
@ -6,6 +6,7 @@ import java.util.Date;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import org.joda.time.LocalDate;
|
import org.joda.time.LocalDate;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
|
|
||||||
@ -128,11 +129,29 @@ public class FakeApi {
|
|||||||
@GET
|
@GET
|
||||||
@Path("/jsonFormData")
|
@Path("/jsonFormData")
|
||||||
@Consumes({ "application/x-www-form-urlencoded" })
|
@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 = {
|
@ApiResponses(value = {
|
||||||
@ApiResponse(code = 200, message = "successful operation", response = Void.class)
|
@ApiResponse(code = 200, message = "successful operation", response = Void.class)
|
||||||
})
|
})
|
||||||
public Response testJsonFormData(@FormParam(value = "param") String param,@FormParam(value = "param2") String param2) {
|
public Response testJsonFormData(@FormParam(value = "param") String param,@FormParam(value = "param2") String param2) {
|
||||||
return Response.ok().entity("magic!").build();
|
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 = "write:pets", description = "modify pets in your account"),
|
||||||
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
@AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||||
})
|
})
|
||||||
}, tags={ "pet", })
|
}, tags={ "pet" })
|
||||||
@ApiResponses(value = {
|
@ApiResponses(value = {
|
||||||
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class)
|
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class)
|
||||||
})
|
})
|
||||||
@ -147,22 +147,4 @@ public class PetApi {
|
|||||||
@FormParam(value = "file") Attachment fileDetail) {
|
@FormParam(value = "file") Attachment fileDetail) {
|
||||||
return Response.ok().entity("magic!").build();
|
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
|
- pet
|
||||||
x-tags:
|
x-tags:
|
||||||
- tag: pet
|
- 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:
|
/store/inventory:
|
||||||
get:
|
get:
|
||||||
description: Returns a map of status codes to quantities
|
description: Returns a map of status codes to quantities
|
||||||
@ -1079,6 +1037,48 @@ paths:
|
|||||||
- $another-fake?
|
- $another-fake?
|
||||||
x-tags:
|
x-tags:
|
||||||
- tag: $another-fake?
|
- 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:
|
components:
|
||||||
schemas:
|
schemas:
|
||||||
Category:
|
Category:
|
||||||
|
@ -193,7 +193,7 @@ public class PetApi {
|
|||||||
@Path("/{petId}/uploadImageWithRequiredFile")
|
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||||
@Consumes({ "multipart/form-data" })
|
@Consumes({ "multipart/form-data" })
|
||||||
@Produces({ "application/json" })
|
@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.Authorization(value = "petstore_auth", scopes = {
|
||||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
@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.util.Date;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
|
|
||||||
@ -187,7 +188,7 @@ public class FakeApi {
|
|||||||
@Path("/jsonFormData")
|
@Path("/jsonFormData")
|
||||||
@Consumes({ "application/x-www-form-urlencoded" })
|
@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.ApiResponses(value = {
|
||||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = Void.class) })
|
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = Void.class) })
|
||||||
public Response testJsonFormData(
|
public Response testJsonFormData(
|
||||||
@ -197,4 +198,25 @@ public class FakeApi {
|
|||||||
throws NotFoundException {
|
throws NotFoundException {
|
||||||
return delegate.testJsonFormData(param,param2,securityContext);
|
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.util.Date;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
|
|
||||||
@ -46,4 +47,6 @@ public abstract class FakeApiService {
|
|||||||
throws NotFoundException;
|
throws NotFoundException;
|
||||||
public abstract Response testJsonFormData(String param,String param2,SecurityContext securityContext)
|
public abstract Response testJsonFormData(String param,String param2,SecurityContext securityContext)
|
||||||
throws NotFoundException;
|
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 = "write:pets", description = "modify pets in your account"),
|
||||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
||||||
})
|
})
|
||||||
}, tags={ "pet", })
|
}, tags={ "pet" })
|
||||||
@io.swagger.annotations.ApiResponses(value = {
|
@io.swagger.annotations.ApiResponses(value = {
|
||||||
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
@io.swagger.annotations.ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
|
||||||
public Response uploadFile(
|
public Response uploadFile(
|
||||||
@ -189,25 +189,4 @@ public class PetApi {
|
|||||||
throws NotFoundException {
|
throws NotFoundException {
|
||||||
return delegate.uploadFile(petId,additionalMetadata,inputStream, fileDetail,securityContext);
|
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;
|
throws NotFoundException;
|
||||||
public abstract Response uploadFile(Long petId,String additionalMetadata,InputStream fileInputStream, FormDataContentDisposition fileDetail,SecurityContext securityContext)
|
public abstract Response uploadFile(Long petId,String additionalMetadata,InputStream fileInputStream, FormDataContentDisposition fileDetail,SecurityContext securityContext)
|
||||||
throws NotFoundException;
|
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.util.Date;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
|
|
||||||
@ -86,4 +87,10 @@ public class FakeApiServiceImpl extends FakeApiService {
|
|||||||
// do some magic!
|
// do some magic!
|
||||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
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!
|
// do some magic!
|
||||||
return Response.ok().entity(new ApiResponseMessage(ApiResponseMessage.OK, "magic!")).build();
|
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")
|
@Path("/{petId}/uploadImageWithRequiredFile")
|
||||||
@Consumes({ "multipart/form-data" })
|
@Consumes({ "multipart/form-data" })
|
||||||
@Produces({ "application/json" })
|
@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.Authorization(value = "petstore_auth", scopes = {
|
||||||
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
@io.swagger.annotations.AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
|
||||||
@io.swagger.annotations.AuthorizationScope(scope = "read:pets", description = "read your pets")
|
@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.util.Date;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
import org.openapitools.model.User;
|
||||||
|
|
||||||
@ -210,4 +211,25 @@ public class FakeApi {
|
|||||||
throws NotFoundException {
|
throws NotFoundException {
|
||||||
return delegate.testJsonFormData(param,param2,securityContext);
|
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.util.Date;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import org.openapitools.model.ModelApiResponse;
|
||||||
import org.openapitools.model.OuterComposite;
|
import org.openapitools.model.OuterComposite;
|
||||||
import org.openapitools.model.User;
|
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 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 testInlineAdditionalProperties(Map<String, String> requestBody,SecurityContext securityContext) throws NotFoundException;
|
||||||
public abstract Response testJsonFormData(String param,String param2,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;
|
||||||
}
|
}
|
||||||
|
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