mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-06-06 08:50:52 +00:00
restore go client from codgen2x
This commit is contained in:
parent
69133d3677
commit
1577e5d89f
@ -7,7 +7,7 @@ This API client was generated by the [swagger-codegen](https://github.com/swagge
|
|||||||
|
|
||||||
- API version: 1.0.0
|
- API version: 1.0.0
|
||||||
- Package version: 1.0.0
|
- Package version: 1.0.0
|
||||||
- Build package: org.openapitools.codegen.languages.GoClientCodegen
|
- Build package: io.swagger.codegen.languages.GoClientCodegen
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
Put the package under your project folder and add the following in import:
|
Put the package under your project folder and add the following in import:
|
||||||
@ -64,11 +64,9 @@ Class | Method | HTTP request | Description
|
|||||||
- [ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md)
|
- [ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md)
|
||||||
- [ArrayTest](docs/ArrayTest.md)
|
- [ArrayTest](docs/ArrayTest.md)
|
||||||
- [Capitalization](docs/Capitalization.md)
|
- [Capitalization](docs/Capitalization.md)
|
||||||
- [Cat](docs/Cat.md)
|
|
||||||
- [Category](docs/Category.md)
|
- [Category](docs/Category.md)
|
||||||
- [ClassModel](docs/ClassModel.md)
|
- [ClassModel](docs/ClassModel.md)
|
||||||
- [Client](docs/Client.md)
|
- [Client](docs/Client.md)
|
||||||
- [Dog](docs/Dog.md)
|
|
||||||
- [EnumArrays](docs/EnumArrays.md)
|
- [EnumArrays](docs/EnumArrays.md)
|
||||||
- [EnumClass](docs/EnumClass.md)
|
- [EnumClass](docs/EnumClass.md)
|
||||||
- [EnumTest](docs/EnumTest.md)
|
- [EnumTest](docs/EnumTest.md)
|
||||||
@ -93,6 +91,8 @@ Class | Method | HTTP request | Description
|
|||||||
- [SpecialModelName](docs/SpecialModelName.md)
|
- [SpecialModelName](docs/SpecialModelName.md)
|
||||||
- [Tag](docs/Tag.md)
|
- [Tag](docs/Tag.md)
|
||||||
- [User](docs/User.md)
|
- [User](docs/User.md)
|
||||||
|
- [Cat](docs/Cat.md)
|
||||||
|
- [Dog](docs/Dog.md)
|
||||||
|
|
||||||
|
|
||||||
## Documentation For Authorization
|
## Documentation For Authorization
|
||||||
|
@ -107,11 +107,11 @@ paths:
|
|||||||
type: "array"
|
type: "array"
|
||||||
items:
|
items:
|
||||||
type: "string"
|
type: "string"
|
||||||
|
default: "available"
|
||||||
enum:
|
enum:
|
||||||
- "available"
|
- "available"
|
||||||
- "pending"
|
- "pending"
|
||||||
- "sold"
|
- "sold"
|
||||||
default: "available"
|
|
||||||
collectionFormat: "csv"
|
collectionFormat: "csv"
|
||||||
x-exportParamName: "Status"
|
x-exportParamName: "Status"
|
||||||
responses:
|
responses:
|
||||||
@ -216,12 +216,14 @@ paths:
|
|||||||
required: false
|
required: false
|
||||||
type: "string"
|
type: "string"
|
||||||
x-exportParamName: "Name"
|
x-exportParamName: "Name"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "status"
|
- name: "status"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "Updated status of the pet"
|
description: "Updated status of the pet"
|
||||||
required: false
|
required: false
|
||||||
type: "string"
|
type: "string"
|
||||||
x-exportParamName: "Status"
|
x-exportParamName: "Status"
|
||||||
|
x-optionalDataType: "String"
|
||||||
responses:
|
responses:
|
||||||
405:
|
405:
|
||||||
description: "Invalid input"
|
description: "Invalid input"
|
||||||
@ -244,6 +246,7 @@ paths:
|
|||||||
required: false
|
required: false
|
||||||
type: "string"
|
type: "string"
|
||||||
x-exportParamName: "ApiKey"
|
x-exportParamName: "ApiKey"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "petId"
|
- name: "petId"
|
||||||
in: "path"
|
in: "path"
|
||||||
description: "Pet id to delete"
|
description: "Pet id to delete"
|
||||||
@ -283,6 +286,7 @@ paths:
|
|||||||
required: false
|
required: false
|
||||||
type: "string"
|
type: "string"
|
||||||
x-exportParamName: "AdditionalMetadata"
|
x-exportParamName: "AdditionalMetadata"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "file"
|
- name: "file"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "file to upload"
|
description: "file to upload"
|
||||||
@ -498,7 +502,7 @@ paths:
|
|||||||
X-Expires-After:
|
X-Expires-After:
|
||||||
type: "string"
|
type: "string"
|
||||||
format: "date-time"
|
format: "date-time"
|
||||||
description: "date in UTC when toekn expires"
|
description: "date in UTC when token expires"
|
||||||
400:
|
400:
|
||||||
description: "Invalid username/password supplied"
|
description: "Invalid username/password supplied"
|
||||||
/user/logout:
|
/user/logout:
|
||||||
@ -528,7 +532,7 @@ paths:
|
|||||||
parameters:
|
parameters:
|
||||||
- name: "username"
|
- name: "username"
|
||||||
in: "path"
|
in: "path"
|
||||||
description: "The name that needs to be fetched. Use user1 for testing. "
|
description: "The name that needs to be fetched. Use user1 for testing."
|
||||||
required: true
|
required: true
|
||||||
type: "string"
|
type: "string"
|
||||||
x-exportParamName: "Username"
|
x-exportParamName: "Username"
|
||||||
@ -595,6 +599,7 @@ paths:
|
|||||||
tags:
|
tags:
|
||||||
- "fake_classname_tags 123#$%^"
|
- "fake_classname_tags 123#$%^"
|
||||||
summary: "To test class name in snake case"
|
summary: "To test class name in snake case"
|
||||||
|
description: "To test class name in snake case"
|
||||||
operationId: "testClassname"
|
operationId: "testClassname"
|
||||||
consumes:
|
consumes:
|
||||||
- "application/json"
|
- "application/json"
|
||||||
@ -634,10 +639,10 @@ paths:
|
|||||||
type: "array"
|
type: "array"
|
||||||
items:
|
items:
|
||||||
type: "string"
|
type: "string"
|
||||||
|
default: "$"
|
||||||
enum:
|
enum:
|
||||||
- ">"
|
- ">"
|
||||||
- "$"
|
- "$"
|
||||||
default: "$"
|
|
||||||
x-exportParamName: "EnumFormStringArray"
|
x-exportParamName: "EnumFormStringArray"
|
||||||
- name: "enum_form_string"
|
- name: "enum_form_string"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
@ -650,6 +655,7 @@ paths:
|
|||||||
- "-efg"
|
- "-efg"
|
||||||
- "(xyz)"
|
- "(xyz)"
|
||||||
x-exportParamName: "EnumFormString"
|
x-exportParamName: "EnumFormString"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "enum_header_string_array"
|
- name: "enum_header_string_array"
|
||||||
in: "header"
|
in: "header"
|
||||||
description: "Header parameter enum test (string array)"
|
description: "Header parameter enum test (string array)"
|
||||||
@ -657,10 +663,10 @@ paths:
|
|||||||
type: "array"
|
type: "array"
|
||||||
items:
|
items:
|
||||||
type: "string"
|
type: "string"
|
||||||
|
default: "$"
|
||||||
enum:
|
enum:
|
||||||
- ">"
|
- ">"
|
||||||
- "$"
|
- "$"
|
||||||
default: "$"
|
|
||||||
x-exportParamName: "EnumHeaderStringArray"
|
x-exportParamName: "EnumHeaderStringArray"
|
||||||
- name: "enum_header_string"
|
- name: "enum_header_string"
|
||||||
in: "header"
|
in: "header"
|
||||||
@ -673,6 +679,7 @@ paths:
|
|||||||
- "-efg"
|
- "-efg"
|
||||||
- "(xyz)"
|
- "(xyz)"
|
||||||
x-exportParamName: "EnumHeaderString"
|
x-exportParamName: "EnumHeaderString"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "enum_query_string_array"
|
- name: "enum_query_string_array"
|
||||||
in: "query"
|
in: "query"
|
||||||
description: "Query parameter enum test (string array)"
|
description: "Query parameter enum test (string array)"
|
||||||
@ -680,10 +687,10 @@ paths:
|
|||||||
type: "array"
|
type: "array"
|
||||||
items:
|
items:
|
||||||
type: "string"
|
type: "string"
|
||||||
|
default: "$"
|
||||||
enum:
|
enum:
|
||||||
- ">"
|
- ">"
|
||||||
- "$"
|
- "$"
|
||||||
default: "$"
|
|
||||||
x-exportParamName: "EnumQueryStringArray"
|
x-exportParamName: "EnumQueryStringArray"
|
||||||
- name: "enum_query_string"
|
- name: "enum_query_string"
|
||||||
in: "query"
|
in: "query"
|
||||||
@ -696,6 +703,7 @@ paths:
|
|||||||
- "-efg"
|
- "-efg"
|
||||||
- "(xyz)"
|
- "(xyz)"
|
||||||
x-exportParamName: "EnumQueryString"
|
x-exportParamName: "EnumQueryString"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "enum_query_integer"
|
- name: "enum_query_integer"
|
||||||
in: "query"
|
in: "query"
|
||||||
description: "Query parameter enum test (double)"
|
description: "Query parameter enum test (double)"
|
||||||
@ -706,6 +714,7 @@ paths:
|
|||||||
- 1
|
- 1
|
||||||
- -2
|
- -2
|
||||||
x-exportParamName: "EnumQueryInteger"
|
x-exportParamName: "EnumQueryInteger"
|
||||||
|
x-optionalDataType: "Int32"
|
||||||
- name: "enum_query_double"
|
- name: "enum_query_double"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "Query parameter enum test (double)"
|
description: "Query parameter enum test (double)"
|
||||||
@ -716,6 +725,7 @@ paths:
|
|||||||
- 1.1
|
- 1.1
|
||||||
- -1.2
|
- -1.2
|
||||||
x-exportParamName: "EnumQueryDouble"
|
x-exportParamName: "EnumQueryDouble"
|
||||||
|
x-optionalDataType: "Float64"
|
||||||
responses:
|
responses:
|
||||||
400:
|
400:
|
||||||
description: "Invalid request"
|
description: "Invalid request"
|
||||||
@ -744,6 +754,7 @@ paths:
|
|||||||
maximum: 100
|
maximum: 100
|
||||||
minimum: 10
|
minimum: 10
|
||||||
x-exportParamName: "Integer"
|
x-exportParamName: "Integer"
|
||||||
|
x-optionalDataType: "Int32"
|
||||||
- name: "int32"
|
- name: "int32"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -753,6 +764,7 @@ paths:
|
|||||||
minimum: 20
|
minimum: 20
|
||||||
format: "int32"
|
format: "int32"
|
||||||
x-exportParamName: "Int32_"
|
x-exportParamName: "Int32_"
|
||||||
|
x-optionalDataType: "Int32"
|
||||||
- name: "int64"
|
- name: "int64"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -760,6 +772,7 @@ paths:
|
|||||||
type: "integer"
|
type: "integer"
|
||||||
format: "int64"
|
format: "int64"
|
||||||
x-exportParamName: "Int64_"
|
x-exportParamName: "Int64_"
|
||||||
|
x-optionalDataType: "Int64"
|
||||||
- name: "number"
|
- name: "number"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -776,6 +789,7 @@ paths:
|
|||||||
maximum: 987.6
|
maximum: 987.6
|
||||||
format: "float"
|
format: "float"
|
||||||
x-exportParamName: "Float"
|
x-exportParamName: "Float"
|
||||||
|
x-optionalDataType: "Float32"
|
||||||
- name: "double"
|
- name: "double"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -792,6 +806,7 @@ paths:
|
|||||||
type: "string"
|
type: "string"
|
||||||
pattern: "/[a-z]/i"
|
pattern: "/[a-z]/i"
|
||||||
x-exportParamName: "String_"
|
x-exportParamName: "String_"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "pattern_without_delimiter"
|
- name: "pattern_without_delimiter"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -813,6 +828,7 @@ paths:
|
|||||||
type: "string"
|
type: "string"
|
||||||
format: "binary"
|
format: "binary"
|
||||||
x-exportParamName: "Binary"
|
x-exportParamName: "Binary"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "date"
|
- name: "date"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -820,6 +836,7 @@ paths:
|
|||||||
type: "string"
|
type: "string"
|
||||||
format: "date"
|
format: "date"
|
||||||
x-exportParamName: "Date"
|
x-exportParamName: "Date"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "dateTime"
|
- name: "dateTime"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -827,6 +844,7 @@ paths:
|
|||||||
type: "string"
|
type: "string"
|
||||||
format: "date-time"
|
format: "date-time"
|
||||||
x-exportParamName: "DateTime"
|
x-exportParamName: "DateTime"
|
||||||
|
x-optionalDataType: "Time"
|
||||||
- name: "password"
|
- name: "password"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
@ -836,12 +854,14 @@ paths:
|
|||||||
minLength: 10
|
minLength: 10
|
||||||
format: "password"
|
format: "password"
|
||||||
x-exportParamName: "Password"
|
x-exportParamName: "Password"
|
||||||
|
x-optionalDataType: "String"
|
||||||
- name: "callback"
|
- name: "callback"
|
||||||
in: "formData"
|
in: "formData"
|
||||||
description: "None"
|
description: "None"
|
||||||
required: false
|
required: false
|
||||||
type: "string"
|
type: "string"
|
||||||
x-exportParamName: "Callback"
|
x-exportParamName: "Callback"
|
||||||
|
x-optionalDataType: "String"
|
||||||
responses:
|
responses:
|
||||||
400:
|
400:
|
||||||
description: "Invalid username supplied"
|
description: "Invalid username supplied"
|
||||||
@ -995,6 +1015,28 @@ paths:
|
|||||||
responses:
|
responses:
|
||||||
200:
|
200:
|
||||||
description: "successful operation"
|
description: "successful operation"
|
||||||
|
/fake/body-with-query-params:
|
||||||
|
put:
|
||||||
|
tags:
|
||||||
|
- "fake"
|
||||||
|
operationId: "testBodyWithQueryParams"
|
||||||
|
consumes:
|
||||||
|
- "application/json"
|
||||||
|
parameters:
|
||||||
|
- in: "body"
|
||||||
|
name: "body"
|
||||||
|
required: true
|
||||||
|
schema:
|
||||||
|
$ref: "#/definitions/User"
|
||||||
|
x-exportParamName: "Body"
|
||||||
|
- name: "query"
|
||||||
|
in: "query"
|
||||||
|
required: true
|
||||||
|
type: "string"
|
||||||
|
x-exportParamName: "Query"
|
||||||
|
responses:
|
||||||
|
200:
|
||||||
|
description: "Success"
|
||||||
/another-fake/dummy:
|
/another-fake/dummy:
|
||||||
patch:
|
patch:
|
||||||
tags:
|
tags:
|
||||||
@ -1344,6 +1386,8 @@ definitions:
|
|||||||
default: "-efg"
|
default: "-efg"
|
||||||
Enum_Test:
|
Enum_Test:
|
||||||
type: "object"
|
type: "object"
|
||||||
|
required:
|
||||||
|
- "enum_string_required"
|
||||||
properties:
|
properties:
|
||||||
enum_string:
|
enum_string:
|
||||||
type: "string"
|
type: "string"
|
||||||
@ -1351,6 +1395,12 @@ definitions:
|
|||||||
- "UPPER"
|
- "UPPER"
|
||||||
- "lower"
|
- "lower"
|
||||||
- ""
|
- ""
|
||||||
|
enum_string_required:
|
||||||
|
type: "string"
|
||||||
|
enum:
|
||||||
|
- "UPPER"
|
||||||
|
- "lower"
|
||||||
|
- ""
|
||||||
enum_integer:
|
enum_integer:
|
||||||
type: "integer"
|
type: "integer"
|
||||||
format: "int32"
|
format: "int32"
|
||||||
|
@ -29,11 +29,11 @@ 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().
|
||||||
* @param client client model
|
* @param body client model
|
||||||
|
|
||||||
@return Client
|
@return Client
|
||||||
*/
|
*/
|
||||||
func (a *AnotherFakeApiService) TestSpecialTags(ctx context.Context, client Client) (Client, *http.Response, error) {
|
func (a *AnotherFakeApiService) TestSpecialTags(ctx context.Context, body Client) (Client, *http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Patch")
|
localVarHttpMethod = strings.ToUpper("Patch")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -67,7 +67,7 @@ func (a *AnotherFakeApiService) TestSpecialTags(ctx context.Context, client Clie
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &client
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return localVarReturnValue, nil, err
|
return localVarReturnValue, nil, err
|
||||||
|
@ -17,7 +17,6 @@ import (
|
|||||||
"strings"
|
"strings"
|
||||||
"context"
|
"context"
|
||||||
"github.com/antihax/optional"
|
"github.com/antihax/optional"
|
||||||
"os"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// Linger please
|
// Linger please
|
||||||
@ -32,13 +31,13 @@ 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().
|
||||||
* @param optional nil or *FakeOuterBooleanSerializeOpts - Optional Parameters:
|
* @param optional nil or *FakeOuterBooleanSerializeOpts - Optional Parameters:
|
||||||
* @param "" (optional.Bool) - Input boolean as post body
|
* @param "Body" (optional.Interface of OuterBoolean) - Input boolean as post body
|
||||||
|
|
||||||
@return OuterBoolean
|
@return OuterBoolean
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type FakeOuterBooleanSerializeOpts struct {
|
type FakeOuterBooleanSerializeOpts struct {
|
||||||
optional.Bool
|
Body optional.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVarOptionals *FakeOuterBooleanSerializeOpts) (OuterBoolean, *http.Response, error) {
|
func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVarOptionals *FakeOuterBooleanSerializeOpts) (OuterBoolean, *http.Response, error) {
|
||||||
@ -67,7 +66,7 @@ func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVar
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{"*/*"}
|
localVarHttpHeaderAccepts := []string{}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -75,9 +74,13 @@ func (a *FakeApiService) FakeOuterBooleanSerialize(ctx context.Context, localVar
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Body.IsSet() {
|
||||||
localVarPostBody = &localVarOptionals..Value()
|
|
||||||
|
|
||||||
|
localVarOptionalBody, localVarOptionalBodyok := localVarOptionals.Body.Value().(OuterBoolean)
|
||||||
|
if !localVarOptionalBodyok {
|
||||||
|
return localVarReturnValue, nil, reportError("body should be OuterBoolean")
|
||||||
|
}
|
||||||
|
localVarPostBody = &localVarOptionalBody
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -131,13 +134,13 @@ 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().
|
||||||
* @param optional nil or *FakeOuterCompositeSerializeOpts - Optional Parameters:
|
* @param optional nil or *FakeOuterCompositeSerializeOpts - Optional Parameters:
|
||||||
* @param "" (optional.Interface of OuterComposite) - Input composite as post body
|
* @param "Body" (optional.Interface of OuterComposite) - Input composite as post body
|
||||||
|
|
||||||
@return OuterComposite
|
@return OuterComposite
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type FakeOuterCompositeSerializeOpts struct {
|
type FakeOuterCompositeSerializeOpts struct {
|
||||||
optional.Interface
|
Body optional.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localVarOptionals *FakeOuterCompositeSerializeOpts) (OuterComposite, *http.Response, error) {
|
func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localVarOptionals *FakeOuterCompositeSerializeOpts) (OuterComposite, *http.Response, error) {
|
||||||
@ -166,7 +169,7 @@ func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localV
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{"*/*"}
|
localVarHttpHeaderAccepts := []string{}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -174,13 +177,13 @@ func (a *FakeApiService) FakeOuterCompositeSerialize(ctx context.Context, localV
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Body.IsSet() {
|
||||||
|
|
||||||
localVarOptional, localVarOptionalok := localVarOptionals..Value().(OuterComposite)
|
localVarOptionalBody, localVarOptionalBodyok := localVarOptionals.Body.Value().(OuterComposite)
|
||||||
if !localVarOptionalok {
|
if !localVarOptionalBodyok {
|
||||||
return localVarReturnValue, nil, reportError("outerComposite should be OuterComposite")
|
return localVarReturnValue, nil, reportError("body should be OuterComposite")
|
||||||
}
|
}
|
||||||
localVarPostBody = &localVarOptional
|
localVarPostBody = &localVarOptionalBody
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -234,13 +237,13 @@ 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().
|
||||||
* @param optional nil or *FakeOuterNumberSerializeOpts - Optional Parameters:
|
* @param optional nil or *FakeOuterNumberSerializeOpts - Optional Parameters:
|
||||||
* @param "" (optional.Float32) - Input number as post body
|
* @param "Body" (optional.Interface of OuterNumber) - Input number as post body
|
||||||
|
|
||||||
@return OuterNumber
|
@return OuterNumber
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type FakeOuterNumberSerializeOpts struct {
|
type FakeOuterNumberSerializeOpts struct {
|
||||||
optional.Float32
|
Body optional.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarOptionals *FakeOuterNumberSerializeOpts) (OuterNumber, *http.Response, error) {
|
func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarOptionals *FakeOuterNumberSerializeOpts) (OuterNumber, *http.Response, error) {
|
||||||
@ -269,7 +272,7 @@ func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarO
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{"*/*"}
|
localVarHttpHeaderAccepts := []string{}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -277,9 +280,13 @@ func (a *FakeApiService) FakeOuterNumberSerialize(ctx context.Context, localVarO
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Body.IsSet() {
|
||||||
localVarPostBody = &localVarOptionals..Value()
|
|
||||||
|
|
||||||
|
localVarOptionalBody, localVarOptionalBodyok := localVarOptionals.Body.Value().(OuterNumber)
|
||||||
|
if !localVarOptionalBodyok {
|
||||||
|
return localVarReturnValue, nil, reportError("body should be OuterNumber")
|
||||||
|
}
|
||||||
|
localVarPostBody = &localVarOptionalBody
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -333,13 +340,13 @@ 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().
|
||||||
* @param optional nil or *FakeOuterStringSerializeOpts - Optional Parameters:
|
* @param optional nil or *FakeOuterStringSerializeOpts - Optional Parameters:
|
||||||
* @param "" (optional.String) - Input string as post body
|
* @param "Body" (optional.Interface of OuterString) - Input string as post body
|
||||||
|
|
||||||
@return OuterString
|
@return OuterString
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type FakeOuterStringSerializeOpts struct {
|
type FakeOuterStringSerializeOpts struct {
|
||||||
optional.String
|
Body optional.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarOptionals *FakeOuterStringSerializeOpts) (OuterString, *http.Response, error) {
|
func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarOptionals *FakeOuterStringSerializeOpts) (OuterString, *http.Response, error) {
|
||||||
@ -368,7 +375,7 @@ func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarO
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{"*/*"}
|
localVarHttpHeaderAccepts := []string{}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -376,9 +383,13 @@ func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarO
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Body.IsSet() {
|
||||||
localVarPostBody = &localVarOptionals..Value()
|
|
||||||
|
|
||||||
|
localVarOptionalBody, localVarOptionalBodyok := localVarOptionals.Body.Value().(OuterString)
|
||||||
|
if !localVarOptionalBodyok {
|
||||||
|
return localVarReturnValue, nil, reportError("body should be OuterString")
|
||||||
|
}
|
||||||
|
localVarPostBody = &localVarOptionalBody
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -430,12 +441,12 @@ func (a *FakeApiService) FakeOuterStringSerialize(ctx context.Context, localVarO
|
|||||||
/*
|
/*
|
||||||
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 body
|
||||||
* @param query
|
* @param query
|
||||||
* @param user
|
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query string, user User) (*http.Response, error) {
|
func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, body User, query string) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Put")
|
localVarHttpMethod = strings.ToUpper("Put")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -451,7 +462,7 @@ func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query stri
|
|||||||
localVarQueryParams := url.Values{}
|
localVarQueryParams := url.Values{}
|
||||||
localVarFormParams := url.Values{}
|
localVarFormParams := url.Values{}
|
||||||
|
|
||||||
localVarQueryParams.Add("query", parameterToString(query, "csv"))
|
localVarQueryParams.Add("query", parameterToString(query, ""))
|
||||||
// to determine the Content-Type header
|
// to determine the Content-Type header
|
||||||
localVarHttpContentTypes := []string{"application/json"}
|
localVarHttpContentTypes := []string{"application/json"}
|
||||||
|
|
||||||
@ -470,7 +481,7 @@ func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query stri
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &user
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -504,11 +515,11 @@ func (a *FakeApiService) TestBodyWithQueryParams(ctx context.Context, query stri
|
|||||||
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 body client model
|
||||||
|
|
||||||
@return Client
|
@return Client
|
||||||
*/
|
*/
|
||||||
func (a *FakeApiService) TestClientModel(ctx context.Context, client Client) (Client, *http.Response, error) {
|
func (a *FakeApiService) TestClientModel(ctx context.Context, body Client) (Client, *http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Patch")
|
localVarHttpMethod = strings.ToUpper("Patch")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -542,7 +553,7 @@ func (a *FakeApiService) TestClientModel(ctx context.Context, client Client) (Cl
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &client
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return localVarReturnValue, nil, err
|
return localVarReturnValue, nil, err
|
||||||
@ -597,36 +608,36 @@ Fake endpoint for testing various parameters 假端點 偽のエンドポイン
|
|||||||
* @param number None
|
* @param number None
|
||||||
* @param double None
|
* @param double None
|
||||||
* @param patternWithoutDelimiter None
|
* @param patternWithoutDelimiter None
|
||||||
* @param byte None
|
* @param byte_ None
|
||||||
* @param optional nil or *TestEndpointParametersOpts - Optional Parameters:
|
* @param optional nil or *TestEndpointParametersOpts - Optional Parameters:
|
||||||
* @param "" (optional.Int32) - None
|
* @param "Integer" (optional.Int32) - None
|
||||||
* @param "" (optional.Int32) - None
|
* @param "Int32_" (optional.Int32) - None
|
||||||
* @param "" (optional.Int64) - None
|
* @param "Int64_" (optional.Int64) - None
|
||||||
* @param "" (optional.Float32) - None
|
* @param "Float" (optional.Float32) - None
|
||||||
* @param "" (optional.String) - None
|
* @param "String_" (optional.String) - None
|
||||||
* @param "" (optional.*os.File) - None
|
* @param "Binary" (optional.String) - None
|
||||||
* @param "" (optional.String) - None
|
* @param "Date" (optional.String) - None
|
||||||
* @param "" (optional.Time) - None
|
* @param "DateTime" (optional.Time) - None
|
||||||
* @param "" (optional.String) - None
|
* @param "Password" (optional.String) - None
|
||||||
* @param "" (optional.String) - None
|
* @param "Callback" (optional.String) - None
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type TestEndpointParametersOpts struct {
|
type TestEndpointParametersOpts struct {
|
||||||
optional.Int32
|
Integer optional.Int32
|
||||||
optional.Int32
|
Int32_ optional.Int32
|
||||||
optional.Int64
|
Int64_ optional.Int64
|
||||||
optional.Float32
|
Float optional.Float32
|
||||||
optional.String
|
String_ optional.String
|
||||||
optional.*os.File
|
Binary optional.String
|
||||||
optional.String
|
Date optional.String
|
||||||
optional.Time
|
DateTime optional.Time
|
||||||
optional.String
|
Password optional.String
|
||||||
optional.String
|
Callback optional.String
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *FakeApiService) TestEndpointParameters(ctx context.Context, number float32, double float64, patternWithoutDelimiter string, byte string, localVarOptionals *TestEndpointParametersOpts) (*http.Response, error) {
|
func (a *FakeApiService) TestEndpointParameters(ctx context.Context, number float32, double float64, patternWithoutDelimiter string, byte_ string, localVarOptionals *TestEndpointParametersOpts) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Post")
|
localVarHttpMethod = strings.ToUpper("Post")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -655,7 +666,7 @@ func (a *FakeApiService) TestEndpointParameters(ctx context.Context, number floa
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Content-Type header
|
// to determine the Content-Type header
|
||||||
localVarHttpContentTypes := []string{"application/x-www-form-urlencoded"}
|
localVarHttpContentTypes := []string{"application/xml; charset=utf-8", "application/json; charset=utf-8"}
|
||||||
|
|
||||||
// set Content-Type header
|
// set Content-Type header
|
||||||
localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
|
localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
|
||||||
@ -664,57 +675,46 @@ func (a *FakeApiService) TestEndpointParameters(ctx context.Context, number floa
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml; charset=utf-8", "application/json; charset=utf-8"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
if localVarHttpHeaderAccept != "" {
|
if localVarHttpHeaderAccept != "" {
|
||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Integer.IsSet() {
|
||||||
localVarFormParams.Add("integer", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("integer", parameterToString(localVarOptionals.Integer.Value(), ""))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Int32_.IsSet() {
|
||||||
localVarFormParams.Add("int32", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("int32", parameterToString(localVarOptionals.Int32_.Value(), ""))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Int64_.IsSet() {
|
||||||
localVarFormParams.Add("int64", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("int64", parameterToString(localVarOptionals.Int64_.Value(), ""))
|
||||||
}
|
}
|
||||||
localVarFormParams.Add("number", parameterToString(number, ""))
|
localVarFormParams.Add("number", parameterToString(number, ""))
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Float.IsSet() {
|
||||||
localVarFormParams.Add("float", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("float", parameterToString(localVarOptionals.Float.Value(), ""))
|
||||||
}
|
}
|
||||||
localVarFormParams.Add("double", parameterToString(double, ""))
|
localVarFormParams.Add("double", parameterToString(double, ""))
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.String_.IsSet() {
|
||||||
localVarFormParams.Add("string", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("string", parameterToString(localVarOptionals.String_.Value(), ""))
|
||||||
}
|
}
|
||||||
localVarFormParams.Add("pattern_without_delimiter", parameterToString(patternWithoutDelimiter, ""))
|
localVarFormParams.Add("pattern_without_delimiter", parameterToString(patternWithoutDelimiter, ""))
|
||||||
localVarFormParams.Add("byte", parameterToString(byte, ""))
|
localVarFormParams.Add("byte", parameterToString(byte_, ""))
|
||||||
var localVarFile *os.File
|
if localVarOptionals != nil && localVarOptionals.Binary.IsSet() {
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
localVarFormParams.Add("binary", parameterToString(localVarOptionals.Binary.Value(), ""))
|
||||||
localVarFileOk := false
|
|
||||||
localVarFile, localVarFileOk = localVarOptionals..Value().(*os.File)
|
|
||||||
if !localVarFileOk {
|
|
||||||
return nil, reportError("binary should be *os.File")
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if localVarFile != nil {
|
if localVarOptionals != nil && localVarOptionals.Date.IsSet() {
|
||||||
fbs, _ := ioutil.ReadAll(localVarFile)
|
localVarFormParams.Add("date", parameterToString(localVarOptionals.Date.Value(), ""))
|
||||||
localVarFileBytes = fbs
|
|
||||||
localVarFileName = localVarFile.Name()
|
|
||||||
localVarFile.Close()
|
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.DateTime.IsSet() {
|
||||||
localVarFormParams.Add("date", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("dateTime", parameterToString(localVarOptionals.DateTime.Value(), ""))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Password.IsSet() {
|
||||||
localVarFormParams.Add("dateTime", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("password", parameterToString(localVarOptionals.Password.Value(), ""))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Callback.IsSet() {
|
||||||
localVarFormParams.Add("password", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("callback", parameterToString(localVarOptionals.Callback.Value(), ""))
|
||||||
}
|
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
|
||||||
localVarFormParams.Add("callback", parameterToString(localVarOptionals..Value(), ""))
|
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -750,27 +750,27 @@ 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().
|
||||||
* @param optional nil or *TestEnumParametersOpts - Optional Parameters:
|
* @param optional nil or *TestEnumParametersOpts - Optional Parameters:
|
||||||
|
* @param "EnumFormStringArray" (optional.Interface of []string) - Form parameter enum test (string array)
|
||||||
|
* @param "EnumFormString" (optional.String) - Form parameter enum test (string)
|
||||||
* @param "EnumHeaderStringArray" (optional.Interface of []string) - Header parameter enum test (string array)
|
* @param "EnumHeaderStringArray" (optional.Interface of []string) - Header parameter enum test (string array)
|
||||||
* @param "EnumHeaderString" (optional.String) - Header parameter enum test (string)
|
* @param "EnumHeaderString" (optional.String) - Header parameter enum test (string)
|
||||||
* @param "EnumQueryStringArray" (optional.Interface of []string) - Query parameter enum test (string array)
|
* @param "EnumQueryStringArray" (optional.Interface of []string) - Query parameter enum test (string array)
|
||||||
* @param "EnumQueryString" (optional.String) - Query parameter enum test (string)
|
* @param "EnumQueryString" (optional.String) - Query parameter enum test (string)
|
||||||
* @param "EnumQueryInteger" (optional.Int32) - Query parameter enum test (double)
|
* @param "EnumQueryInteger" (optional.Int32) - Query parameter enum test (double)
|
||||||
* @param "EnumQueryDouble" (optional.Float64) - Query parameter enum test (double)
|
* @param "EnumQueryDouble" (optional.Float64) - Query parameter enum test (double)
|
||||||
* @param "" (optional.Interface of []string) - Form parameter enum test (string array)
|
|
||||||
* @param "" (optional.String) - Form parameter enum test (string)
|
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type TestEnumParametersOpts struct {
|
type TestEnumParametersOpts struct {
|
||||||
|
EnumFormStringArray optional.Interface
|
||||||
|
EnumFormString optional.String
|
||||||
EnumHeaderStringArray optional.Interface
|
EnumHeaderStringArray optional.Interface
|
||||||
EnumHeaderString optional.String
|
EnumHeaderString optional.String
|
||||||
EnumQueryStringArray optional.Interface
|
EnumQueryStringArray optional.Interface
|
||||||
EnumQueryString optional.String
|
EnumQueryString optional.String
|
||||||
EnumQueryInteger optional.Int32
|
EnumQueryInteger optional.Int32
|
||||||
EnumQueryDouble optional.Float64
|
EnumQueryDouble optional.Float64
|
||||||
optional.Interface
|
|
||||||
optional.String
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptionals *TestEnumParametersOpts) (*http.Response, error) {
|
func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptionals *TestEnumParametersOpts) (*http.Response, error) {
|
||||||
@ -793,16 +793,13 @@ func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptiona
|
|||||||
localVarQueryParams.Add("enum_query_string_array", parameterToString(localVarOptionals.EnumQueryStringArray.Value(), "csv"))
|
localVarQueryParams.Add("enum_query_string_array", parameterToString(localVarOptionals.EnumQueryStringArray.Value(), "csv"))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals.EnumQueryString.IsSet() {
|
if localVarOptionals != nil && localVarOptionals.EnumQueryString.IsSet() {
|
||||||
localVarQueryParams.Add("enum_query_string", parameterToString(localVarOptionals.EnumQueryString.Value(), "csv"))
|
localVarQueryParams.Add("enum_query_string", parameterToString(localVarOptionals.EnumQueryString.Value(), ""))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals.EnumQueryInteger.IsSet() {
|
if localVarOptionals != nil && localVarOptionals.EnumQueryInteger.IsSet() {
|
||||||
localVarQueryParams.Add("enum_query_integer", parameterToString(localVarOptionals.EnumQueryInteger.Value(), "csv"))
|
localVarQueryParams.Add("enum_query_integer", parameterToString(localVarOptionals.EnumQueryInteger.Value(), ""))
|
||||||
}
|
|
||||||
if localVarOptionals != nil && localVarOptionals.EnumQueryDouble.IsSet() {
|
|
||||||
localVarQueryParams.Add("enum_query_double", parameterToString(localVarOptionals.EnumQueryDouble.Value(), "csv"))
|
|
||||||
}
|
}
|
||||||
// to determine the Content-Type header
|
// to determine the Content-Type header
|
||||||
localVarHttpContentTypes := []string{"application/x-www-form-urlencoded"}
|
localVarHttpContentTypes := []string{"*/*"}
|
||||||
|
|
||||||
// set Content-Type header
|
// set Content-Type header
|
||||||
localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
|
localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
|
||||||
@ -811,7 +808,7 @@ func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptiona
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"*/*"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -822,13 +819,16 @@ func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptiona
|
|||||||
localVarHeaderParams["enum_header_string_array"] = parameterToString(localVarOptionals.EnumHeaderStringArray.Value(), "csv")
|
localVarHeaderParams["enum_header_string_array"] = parameterToString(localVarOptionals.EnumHeaderStringArray.Value(), "csv")
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals.EnumHeaderString.IsSet() {
|
if localVarOptionals != nil && localVarOptionals.EnumHeaderString.IsSet() {
|
||||||
localVarHeaderParams["enum_header_string"] = parameterToString(localVarOptionals.EnumHeaderString.Value(), "csv")
|
localVarHeaderParams["enum_header_string"] = parameterToString(localVarOptionals.EnumHeaderString.Value(), "")
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.EnumFormStringArray.IsSet() {
|
||||||
localVarFormParams.Add("enum_form_string_array", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("enum_form_string_array", parameterToString(localVarOptionals.EnumFormStringArray.Value(), "csv"))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.EnumFormString.IsSet() {
|
||||||
localVarFormParams.Add("enum_form_string", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("enum_form_string", parameterToString(localVarOptionals.EnumFormString.Value(), ""))
|
||||||
|
}
|
||||||
|
if localVarOptionals != nil && localVarOptionals.EnumQueryDouble.IsSet() {
|
||||||
|
localVarFormParams.Add("enum_query_double", parameterToString(localVarOptionals.EnumQueryDouble.Value(), ""))
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -861,12 +861,13 @@ func (a *FakeApiService) TestEnumParameters(ctx context.Context, localVarOptiona
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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 param request body
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *FakeApiService) TestInlineAdditionalProperties(ctx context.Context, requestBody string) (*http.Response, error) {
|
func (a *FakeApiService) TestInlineAdditionalProperties(ctx context.Context, param interface{}) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Post")
|
localVarHttpMethod = strings.ToUpper("Post")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -900,7 +901,7 @@ func (a *FakeApiService) TestInlineAdditionalProperties(ctx context.Context, req
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &requestBody
|
localVarPostBody = ¶m
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -932,6 +933,7 @@ func (a *FakeApiService) TestInlineAdditionalProperties(ctx context.Context, req
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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
|
||||||
* @param param2 field2
|
* @param param2 field2
|
||||||
@ -955,7 +957,7 @@ func (a *FakeApiService) TestJsonFormData(ctx context.Context, param string, par
|
|||||||
localVarFormParams := url.Values{}
|
localVarFormParams := url.Values{}
|
||||||
|
|
||||||
// to determine the Content-Type header
|
// to determine the Content-Type header
|
||||||
localVarHttpContentTypes := []string{"application/x-www-form-urlencoded"}
|
localVarHttpContentTypes := []string{"application/json"}
|
||||||
|
|
||||||
// set Content-Type header
|
// set Content-Type header
|
||||||
localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
|
localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes)
|
||||||
|
@ -29,11 +29,11 @@ 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().
|
||||||
* @param client client model
|
* @param body client model
|
||||||
|
|
||||||
@return Client
|
@return Client
|
||||||
*/
|
*/
|
||||||
func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, client Client) (Client, *http.Response, error) {
|
func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, body Client) (Client, *http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Patch")
|
localVarHttpMethod = strings.ToUpper("Patch")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -67,7 +67,7 @@ func (a *FakeClassnameTags123ApiService) TestClassname(ctx context.Context, clie
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &client
|
localVarPostBody = &body
|
||||||
if ctx != nil {
|
if ctx != nil {
|
||||||
// API Key Authentication
|
// API Key Authentication
|
||||||
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
|
if auth, ok := ctx.Value(ContextAPIKey).(APIKey); ok {
|
||||||
|
@ -30,12 +30,13 @@ 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 body Pet object that needs to be added to the store
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *PetApiService) AddPet(ctx context.Context, pet Pet) (*http.Response, error) {
|
func (a *PetApiService) AddPet(ctx context.Context, body Pet) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Post")
|
localVarHttpMethod = strings.ToUpper("Post")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -61,7 +62,7 @@ func (a *PetApiService) AddPet(ctx context.Context, pet Pet) (*http.Response, er
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -69,7 +70,7 @@ func (a *PetApiService) AddPet(ctx context.Context, pet Pet) (*http.Response, er
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &pet
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -101,6 +102,7 @@ func (a *PetApiService) AddPet(ctx context.Context, pet Pet) (*http.Response, er
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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
|
||||||
* @param optional nil or *DeletePetOpts - Optional Parameters:
|
* @param optional nil or *DeletePetOpts - Optional Parameters:
|
||||||
@ -140,7 +142,7 @@ func (a *PetApiService) DeletePet(ctx context.Context, petId int64, localVarOpti
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -148,7 +150,7 @@ func (a *PetApiService) DeletePet(ctx context.Context, petId int64, localVarOpti
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals.ApiKey.IsSet() {
|
if localVarOptionals != nil && localVarOptionals.ApiKey.IsSet() {
|
||||||
localVarHeaderParams["api_key"] = parameterToString(localVarOptionals.ApiKey.Value(), "csv")
|
localVarHeaderParams["api_key"] = parameterToString(localVarOptionals.ApiKey.Value(), "")
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -461,12 +463,13 @@ func (a *PetApiService) GetPetById(ctx context.Context, petId int64) (Pet, *http
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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 body Pet object that needs to be added to the store
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *PetApiService) UpdatePet(ctx context.Context, pet Pet) (*http.Response, error) {
|
func (a *PetApiService) UpdatePet(ctx context.Context, body Pet) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Put")
|
localVarHttpMethod = strings.ToUpper("Put")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -492,7 +495,7 @@ func (a *PetApiService) UpdatePet(ctx context.Context, pet Pet) (*http.Response,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -500,7 +503,7 @@ func (a *PetApiService) UpdatePet(ctx context.Context, pet Pet) (*http.Response,
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &pet
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -532,18 +535,19 @@ func (a *PetApiService) UpdatePet(ctx context.Context, pet Pet) (*http.Response,
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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
|
||||||
* @param optional nil or *UpdatePetWithFormOpts - Optional Parameters:
|
* @param optional nil or *UpdatePetWithFormOpts - Optional Parameters:
|
||||||
* @param "" (optional.String) - Updated name of the pet
|
* @param "Name" (optional.String) - Updated name of the pet
|
||||||
* @param "" (optional.String) - Updated status of the pet
|
* @param "Status" (optional.String) - Updated status of the pet
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type UpdatePetWithFormOpts struct {
|
type UpdatePetWithFormOpts struct {
|
||||||
optional.String
|
Name optional.String
|
||||||
optional.String
|
Status optional.String
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *PetApiService) UpdatePetWithForm(ctx context.Context, petId int64, localVarOptionals *UpdatePetWithFormOpts) (*http.Response, error) {
|
func (a *PetApiService) UpdatePetWithForm(ctx context.Context, petId int64, localVarOptionals *UpdatePetWithFormOpts) (*http.Response, error) {
|
||||||
@ -573,18 +577,18 @@ func (a *PetApiService) UpdatePetWithForm(ctx context.Context, petId int64, loca
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
if localVarHttpHeaderAccept != "" {
|
if localVarHttpHeaderAccept != "" {
|
||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Name.IsSet() {
|
||||||
localVarFormParams.Add("name", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("name", parameterToString(localVarOptionals.Name.Value(), ""))
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.Status.IsSet() {
|
||||||
localVarFormParams.Add("status", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("status", parameterToString(localVarOptionals.Status.Value(), ""))
|
||||||
}
|
}
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@ -617,18 +621,19 @@ func (a *PetApiService) UpdatePetWithForm(ctx context.Context, petId int64, loca
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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
|
||||||
* @param optional nil or *UploadFileOpts - Optional Parameters:
|
* @param optional nil or *UploadFileOpts - Optional Parameters:
|
||||||
* @param "" (optional.String) - Additional data to pass to server
|
* @param "AdditionalMetadata" (optional.String) - Additional data to pass to server
|
||||||
* @param "" (optional.*os.File) - file to upload
|
* @param "File" (optional.Interface of *os.File) - file to upload
|
||||||
|
|
||||||
@return ModelApiResponse
|
@return ModelApiResponse
|
||||||
*/
|
*/
|
||||||
|
|
||||||
type UploadFileOpts struct {
|
type UploadFileOpts struct {
|
||||||
optional.String
|
AdditionalMetadata optional.String
|
||||||
optional.*os.File
|
File optional.Interface
|
||||||
}
|
}
|
||||||
|
|
||||||
func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOptionals *UploadFileOpts) (ModelApiResponse, *http.Response, error) {
|
func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOptionals *UploadFileOpts) (ModelApiResponse, *http.Response, error) {
|
||||||
@ -665,13 +670,13 @@ func (a *PetApiService) UploadFile(ctx context.Context, petId int64, localVarOpt
|
|||||||
if localVarHttpHeaderAccept != "" {
|
if localVarHttpHeaderAccept != "" {
|
||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.AdditionalMetadata.IsSet() {
|
||||||
localVarFormParams.Add("additionalMetadata", parameterToString(localVarOptionals..Value(), ""))
|
localVarFormParams.Add("additionalMetadata", parameterToString(localVarOptionals.AdditionalMetadata.Value(), ""))
|
||||||
}
|
}
|
||||||
var localVarFile *os.File
|
var localVarFile *os.File
|
||||||
if localVarOptionals != nil && localVarOptionals..IsSet() {
|
if localVarOptionals != nil && localVarOptionals.File.IsSet() {
|
||||||
localVarFileOk := false
|
localVarFileOk := false
|
||||||
localVarFile, localVarFileOk = localVarOptionals..Value().(*os.File)
|
localVarFile, localVarFileOk = localVarOptionals.File.Value().(*os.File)
|
||||||
if !localVarFileOk {
|
if !localVarFileOk {
|
||||||
return localVarReturnValue, nil, reportError("file should be *os.File")
|
return localVarReturnValue, nil, reportError("file should be *os.File")
|
||||||
}
|
}
|
||||||
|
@ -61,7 +61,7 @@ func (a *StoreApiService) DeleteOrder(ctx context.Context, orderId string) (*htt
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -294,12 +294,13 @@ func (a *StoreApiService) GetOrderById(ctx context.Context, orderId int64) (Orde
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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 body order placed for purchasing the pet
|
||||||
|
|
||||||
@return Order
|
@return Order
|
||||||
*/
|
*/
|
||||||
func (a *StoreApiService) PlaceOrder(ctx context.Context, order Order) (Order, *http.Response, error) {
|
func (a *StoreApiService) PlaceOrder(ctx context.Context, body Order) (Order, *http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Post")
|
localVarHttpMethod = strings.ToUpper("Post")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -333,7 +334,7 @@ func (a *StoreApiService) PlaceOrder(ctx context.Context, order Order) (Order, *
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &order
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return localVarReturnValue, nil, err
|
return localVarReturnValue, nil, err
|
||||||
|
@ -30,11 +30,11 @@ 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().
|
||||||
* @param user Created user object
|
* @param body Created user object
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *UserApiService) CreateUser(ctx context.Context, user User) (*http.Response, error) {
|
func (a *UserApiService) CreateUser(ctx context.Context, body User) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Post")
|
localVarHttpMethod = strings.ToUpper("Post")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -60,7 +60,7 @@ func (a *UserApiService) CreateUser(ctx context.Context, user User) (*http.Respo
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -68,7 +68,7 @@ func (a *UserApiService) CreateUser(ctx context.Context, user User) (*http.Respo
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &user
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -100,12 +100,13 @@ func (a *UserApiService) CreateUser(ctx context.Context, user User) (*http.Respo
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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 body List of user object
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *UserApiService) CreateUsersWithArrayInput(ctx context.Context, user []User) (*http.Response, error) {
|
func (a *UserApiService) CreateUsersWithArrayInput(ctx context.Context, body []User) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Post")
|
localVarHttpMethod = strings.ToUpper("Post")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -131,7 +132,7 @@ func (a *UserApiService) CreateUsersWithArrayInput(ctx context.Context, user []U
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -139,7 +140,7 @@ func (a *UserApiService) CreateUsersWithArrayInput(ctx context.Context, user []U
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &user
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -171,12 +172,13 @@ func (a *UserApiService) CreateUsersWithArrayInput(ctx context.Context, user []U
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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 body List of user object
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *UserApiService) CreateUsersWithListInput(ctx context.Context, user []User) (*http.Response, error) {
|
func (a *UserApiService) CreateUsersWithListInput(ctx context.Context, body []User) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Post")
|
localVarHttpMethod = strings.ToUpper("Post")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -202,7 +204,7 @@ func (a *UserApiService) CreateUsersWithListInput(ctx context.Context, user []Us
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -210,7 +212,7 @@ func (a *UserApiService) CreateUsersWithListInput(ctx context.Context, user []Us
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &user
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -275,7 +277,7 @@ func (a *UserApiService) DeleteUser(ctx context.Context, username string) (*http
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -313,6 +315,7 @@ func (a *UserApiService) DeleteUser(ctx context.Context, username string) (*http
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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.
|
||||||
|
|
||||||
@ -401,6 +404,7 @@ func (a *UserApiService) GetUserByName(ctx context.Context, username string) (Us
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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
|
||||||
* @param password The password for login in clear text
|
* @param password The password for login in clear text
|
||||||
@ -423,8 +427,8 @@ func (a *UserApiService) LoginUser(ctx context.Context, username string, passwor
|
|||||||
localVarQueryParams := url.Values{}
|
localVarQueryParams := url.Values{}
|
||||||
localVarFormParams := url.Values{}
|
localVarFormParams := url.Values{}
|
||||||
|
|
||||||
localVarQueryParams.Add("username", parameterToString(username, "csv"))
|
localVarQueryParams.Add("username", parameterToString(username, ""))
|
||||||
localVarQueryParams.Add("password", parameterToString(password, "csv"))
|
localVarQueryParams.Add("password", parameterToString(password, ""))
|
||||||
// to determine the Content-Type header
|
// to determine the Content-Type header
|
||||||
localVarHttpContentTypes := []string{}
|
localVarHttpContentTypes := []string{}
|
||||||
|
|
||||||
@ -491,6 +495,7 @@ func (a *UserApiService) LoginUser(ctx context.Context, username string, passwor
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
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().
|
||||||
|
|
||||||
|
|
||||||
@ -521,7 +526,7 @@ func (a *UserApiService) LogoutUser(ctx context.Context) (*http.Response, error)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -562,11 +567,11 @@ 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().
|
||||||
* @param username name that need to be deleted
|
* @param username name that need to be deleted
|
||||||
* @param user Updated user object
|
* @param body Updated user object
|
||||||
|
|
||||||
|
|
||||||
*/
|
*/
|
||||||
func (a *UserApiService) UpdateUser(ctx context.Context, username string, user User) (*http.Response, error) {
|
func (a *UserApiService) UpdateUser(ctx context.Context, username string, body User) (*http.Response, error) {
|
||||||
var (
|
var (
|
||||||
localVarHttpMethod = strings.ToUpper("Put")
|
localVarHttpMethod = strings.ToUpper("Put")
|
||||||
localVarPostBody interface{}
|
localVarPostBody interface{}
|
||||||
@ -593,7 +598,7 @@ func (a *UserApiService) UpdateUser(ctx context.Context, username string, user U
|
|||||||
}
|
}
|
||||||
|
|
||||||
// to determine the Accept header
|
// to determine the Accept header
|
||||||
localVarHttpHeaderAccepts := []string{}
|
localVarHttpHeaderAccepts := []string{"application/xml", "application/json"}
|
||||||
|
|
||||||
// set Accept header
|
// set Accept header
|
||||||
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts)
|
||||||
@ -601,7 +606,7 @@ func (a *UserApiService) UpdateUser(ctx context.Context, username string, user U
|
|||||||
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
localVarHeaderParams["Accept"] = localVarHttpHeaderAccept
|
||||||
}
|
}
|
||||||
// body params
|
// body params
|
||||||
localVarPostBody = &user
|
localVarPostBody = &body
|
||||||
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
@ -8,7 +8,7 @@ Method | HTTP request | Description
|
|||||||
|
|
||||||
|
|
||||||
# **TestSpecialTags**
|
# **TestSpecialTags**
|
||||||
> Client TestSpecialTags(ctx, client)
|
> Client TestSpecialTags(ctx, body)
|
||||||
To test special tags
|
To test special tags
|
||||||
|
|
||||||
To test special tags
|
To test special tags
|
||||||
@ -18,7 +18,7 @@ To test special tags
|
|||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**client** | [**Client**](Client.md)| client model |
|
**body** | [**Client**](Client.md)| client model |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
|
@ -34,7 +34,7 @@ Optional parameters are passed through a pointer to a FakeOuterBooleanSerializeO
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**booleanPostBody** | **optional.Bool**| Input boolean as post body |
|
**body** | [**optional.Interface of OuterBoolean**](OuterBoolean.md)| Input boolean as post body |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -47,7 +47,7 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: */*
|
- **Accept**: Not defined
|
||||||
|
|
||||||
[[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)
|
||||||
|
|
||||||
@ -69,7 +69,7 @@ Optional parameters are passed through a pointer to a FakeOuterCompositeSerializ
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**outerComposite** | [**optional.Interface of OuterComposite**](OuterComposite.md)| Input composite as post body |
|
**body** | [**optional.Interface of OuterComposite**](OuterComposite.md)| Input composite as post body |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -82,7 +82,7 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: */*
|
- **Accept**: Not defined
|
||||||
|
|
||||||
[[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)
|
||||||
|
|
||||||
@ -104,7 +104,7 @@ Optional parameters are passed through a pointer to a FakeOuterNumberSerializeOp
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | **optional.Float32**| Input number as post body |
|
**body** | [**optional.Interface of OuterNumber**](OuterNumber.md)| Input number as post body |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -117,7 +117,7 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: */*
|
- **Accept**: Not defined
|
||||||
|
|
||||||
[[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)
|
||||||
|
|
||||||
@ -139,7 +139,7 @@ Optional parameters are passed through a pointer to a FakeOuterStringSerializeOp
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**body** | **optional.String**| Input string as post body |
|
**body** | [**optional.Interface of OuterString**](OuterString.md)| Input string as post body |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -152,12 +152,12 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: */*
|
- **Accept**: Not defined
|
||||||
|
|
||||||
[[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)
|
||||||
|
|
||||||
# **TestBodyWithQueryParams**
|
# **TestBodyWithQueryParams**
|
||||||
> TestBodyWithQueryParams(ctx, query, user)
|
> TestBodyWithQueryParams(ctx, body, query)
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
@ -165,8 +165,8 @@ No authorization required
|
|||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
|
**body** | [**User**](User.md)| |
|
||||||
**query** | **string**| |
|
**query** | **string**| |
|
||||||
**user** | [**User**](User.md)| |
|
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -184,7 +184,7 @@ No authorization required
|
|||||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
[[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)
|
||||||
|
|
||||||
# **TestClientModel**
|
# **TestClientModel**
|
||||||
> Client TestClientModel(ctx, client)
|
> Client TestClientModel(ctx, body)
|
||||||
To test \"client\" model
|
To test \"client\" model
|
||||||
|
|
||||||
To test \"client\" model
|
To test \"client\" model
|
||||||
@ -194,7 +194,7 @@ To test \"client\" model
|
|||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**client** | [**Client**](Client.md)| client model |
|
**body** | [**Client**](Client.md)| client model |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -212,7 +212,7 @@ No authorization required
|
|||||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
[[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)
|
||||||
|
|
||||||
# **TestEndpointParameters**
|
# **TestEndpointParameters**
|
||||||
> TestEndpointParameters(ctx, number, double, patternWithoutDelimiter, byte, optional)
|
> TestEndpointParameters(ctx, number, double, patternWithoutDelimiter, byte_, optional)
|
||||||
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||||
|
|
||||||
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||||
@ -225,7 +225,7 @@ Name | Type | Description | Notes
|
|||||||
**number** | **float32**| None |
|
**number** | **float32**| None |
|
||||||
**double** | **float64**| None |
|
**double** | **float64**| None |
|
||||||
**patternWithoutDelimiter** | **string**| None |
|
**patternWithoutDelimiter** | **string**| None |
|
||||||
**byte** | **string**| None |
|
**byte_** | **string**| None |
|
||||||
**optional** | ***TestEndpointParametersOpts** | optional parameters | nil if no parameters
|
**optional** | ***TestEndpointParametersOpts** | optional parameters | nil if no parameters
|
||||||
|
|
||||||
### Optional Parameters
|
### Optional Parameters
|
||||||
@ -238,11 +238,11 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
|
|
||||||
**integer** | **optional.Int32**| None |
|
**integer** | **optional.Int32**| None |
|
||||||
**int32** | **optional.Int32**| None |
|
**int32_** | **optional.Int32**| None |
|
||||||
**int64** | **optional.Int64**| None |
|
**int64_** | **optional.Int64**| None |
|
||||||
**float** | **optional.Float32**| None |
|
**float** | **optional.Float32**| None |
|
||||||
**string** | **optional.String**| None |
|
**string_** | **optional.String**| None |
|
||||||
**binary** | **optional.Interface of *os.File****optional.*os.File**| None |
|
**binary** | **optional.String**| None |
|
||||||
**date** | **optional.String**| None |
|
**date** | **optional.String**| None |
|
||||||
**dateTime** | **optional.Time**| None |
|
**dateTime** | **optional.Time**| None |
|
||||||
**password** | **optional.String**| None |
|
**password** | **optional.String**| None |
|
||||||
@ -258,8 +258,8 @@ Name | Type | Description | Notes
|
|||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/x-www-form-urlencoded
|
- **Content-Type**: application/xml; charset=utf-8, application/json; charset=utf-8
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml; charset=utf-8, application/json; charset=utf-8
|
||||||
|
|
||||||
[[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)
|
||||||
|
|
||||||
@ -281,14 +281,14 @@ Optional parameters are passed through a pointer to a TestEnumParametersOpts str
|
|||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
|
**enumFormStringArray** | [**optional.Interface of []string**](string.md)| Form parameter enum test (string array) |
|
||||||
|
**enumFormString** | **optional.String**| Form parameter enum test (string) | [default to -efg]
|
||||||
**enumHeaderStringArray** | [**optional.Interface of []string**](string.md)| Header parameter enum test (string array) |
|
**enumHeaderStringArray** | [**optional.Interface of []string**](string.md)| Header parameter enum test (string array) |
|
||||||
**enumHeaderString** | **optional.String**| Header parameter enum test (string) | [default to -efg]
|
**enumHeaderString** | **optional.String**| Header parameter enum test (string) | [default to -efg]
|
||||||
**enumQueryStringArray** | [**optional.Interface of []string**](string.md)| Query parameter enum test (string array) |
|
**enumQueryStringArray** | [**optional.Interface of []string**](string.md)| Query parameter enum test (string array) |
|
||||||
**enumQueryString** | **optional.String**| Query parameter enum test (string) | [default to -efg]
|
**enumQueryString** | **optional.String**| Query parameter enum test (string) | [default to -efg]
|
||||||
**enumQueryInteger** | **optional.Int32**| Query parameter enum test (double) |
|
**enumQueryInteger** | **optional.Int32**| Query parameter enum test (double) |
|
||||||
**enumQueryDouble** | **optional.Float64**| Query parameter enum test (double) |
|
**enumQueryDouble** | **optional.Float64**| Query parameter enum test (double) |
|
||||||
**enumFormStringArray** | [**optional.Interface of []string**](array.md)| Form parameter enum test (string array) |
|
|
||||||
**enumFormString** | **optional.String**| Form parameter enum test (string) |
|
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -300,21 +300,23 @@ No authorization required
|
|||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/x-www-form-urlencoded
|
- **Content-Type**: */*
|
||||||
- **Accept**: Not defined
|
- **Accept**: */*
|
||||||
|
|
||||||
[[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)
|
||||||
|
|
||||||
# **TestInlineAdditionalProperties**
|
# **TestInlineAdditionalProperties**
|
||||||
> TestInlineAdditionalProperties(ctx, requestBody)
|
> TestInlineAdditionalProperties(ctx, param)
|
||||||
test inline additionalProperties
|
test inline additionalProperties
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**requestBody** | [**string**](string.md)| request body |
|
**param** | [**interface{}**](interface{}.md)| request body |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -335,6 +337,8 @@ No authorization required
|
|||||||
> TestJsonFormData(ctx, param, param2)
|
> TestJsonFormData(ctx, param, param2)
|
||||||
test json serialization of form data
|
test json serialization of form data
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
@ -353,7 +357,7 @@ No authorization required
|
|||||||
|
|
||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/x-www-form-urlencoded
|
- **Content-Type**: application/json
|
||||||
- **Accept**: Not defined
|
- **Accept**: Not defined
|
||||||
|
|
||||||
[[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)
|
||||||
|
@ -8,7 +8,7 @@ Method | HTTP request | Description
|
|||||||
|
|
||||||
|
|
||||||
# **TestClassname**
|
# **TestClassname**
|
||||||
> Client TestClassname(ctx, client)
|
> Client TestClassname(ctx, body)
|
||||||
To test class name in snake case
|
To test class name in snake case
|
||||||
|
|
||||||
To test class name in snake case
|
To test class name in snake case
|
||||||
@ -18,7 +18,7 @@ To test class name in snake case
|
|||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**client** | [**Client**](Client.md)| client model |
|
**body** | [**Client**](Client.md)| client model |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ Name | Type | Description | Notes
|
|||||||
**Double** | **float64** | | [optional] [default to null]
|
**Double** | **float64** | | [optional] [default to null]
|
||||||
**String_** | **string** | | [optional] [default to null]
|
**String_** | **string** | | [optional] [default to null]
|
||||||
**Byte_** | **string** | | [default to null]
|
**Byte_** | **string** | | [default to null]
|
||||||
**Binary** | [****os.File**](*os.File.md) | | [optional] [default to null]
|
**Binary** | **string** | | [optional] [default to null]
|
||||||
**Date** | **string** | | [default to null]
|
**Date** | **string** | | [default to null]
|
||||||
**DateTime** | [**time.Time**](time.Time.md) | | [optional] [default to null]
|
**DateTime** | [**time.Time**](time.Time.md) | | [optional] [default to null]
|
||||||
**Uuid** | **string** | | [optional] [default to null]
|
**Uuid** | **string** | | [optional] [default to null]
|
||||||
|
@ -15,15 +15,17 @@ Method | HTTP request | Description
|
|||||||
|
|
||||||
|
|
||||||
# **AddPet**
|
# **AddPet**
|
||||||
> AddPet(ctx, pet)
|
> AddPet(ctx, body)
|
||||||
Add a new pet to the store
|
Add a new pet to the store
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -36,7 +38,7 @@ Name | Type | Description | Notes
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json, application/xml
|
- **Content-Type**: application/json, application/xml
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
@ -44,6 +46,8 @@ Name | Type | Description | Notes
|
|||||||
> DeletePet(ctx, petId, optional)
|
> DeletePet(ctx, petId, optional)
|
||||||
Deletes a pet
|
Deletes a pet
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
@ -71,7 +75,7 @@ Name | Type | Description | Notes
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
@ -160,15 +164,17 @@ 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)
|
||||||
|
|
||||||
# **UpdatePet**
|
# **UpdatePet**
|
||||||
> UpdatePet(ctx, pet)
|
> UpdatePet(ctx, body)
|
||||||
Update an existing pet
|
Update an existing pet
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -181,7 +187,7 @@ Name | Type | Description | Notes
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/json, application/xml
|
- **Content-Type**: application/json, application/xml
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
@ -189,6 +195,8 @@ Name | Type | Description | Notes
|
|||||||
> UpdatePetWithForm(ctx, petId, optional)
|
> UpdatePetWithForm(ctx, petId, optional)
|
||||||
Updates a pet in the store with form data
|
Updates a pet in the store with form data
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
@ -217,7 +225,7 @@ Name | Type | Description | Notes
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: application/x-www-form-urlencoded
|
- **Content-Type**: application/x-www-form-urlencoded
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
@ -225,6 +233,8 @@ Name | Type | Description | Notes
|
|||||||
> ModelApiResponse UploadFile(ctx, petId, optional)
|
> ModelApiResponse UploadFile(ctx, petId, optional)
|
||||||
uploads an image
|
uploads an image
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
@ -240,7 +250,7 @@ Name | Type | Description | Notes
|
|||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
|
|
||||||
**additionalMetadata** | **optional.String**| Additional data to pass to server |
|
**additionalMetadata** | **optional.String**| Additional data to pass to server |
|
||||||
**file** | **optional.Interface of *os.File****optional.*os.File**| file to upload |
|
**file** | **optional.Interface of *os.File**| file to upload |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
|
@ -34,7 +34,7 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
@ -91,15 +91,17 @@ No authorization required
|
|||||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
[[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)
|
||||||
|
|
||||||
# **PlaceOrder**
|
# **PlaceOrder**
|
||||||
> Order PlaceOrder(ctx, order)
|
> Order PlaceOrder(ctx, body)
|
||||||
Place an order for a pet
|
Place an order for a pet
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**order** | [**Order**](Order.md)| order placed for purchasing the pet |
|
**body** | [**Order**](Order.md)| order placed for purchasing the pet |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
|
@ -15,7 +15,7 @@ Method | HTTP request | Description
|
|||||||
|
|
||||||
|
|
||||||
# **CreateUser**
|
# **CreateUser**
|
||||||
> CreateUser(ctx, user)
|
> CreateUser(ctx, body)
|
||||||
Create user
|
Create user
|
||||||
|
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
@ -25,7 +25,7 @@ This can only be done by the logged in user.
|
|||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**user** | [**User**](User.md)| Created user object |
|
**body** | [**User**](User.md)| Created user object |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -38,20 +38,22 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
# **CreateUsersWithArrayInput**
|
# **CreateUsersWithArrayInput**
|
||||||
> CreateUsersWithArrayInput(ctx, user)
|
> CreateUsersWithArrayInput(ctx, body)
|
||||||
Creates list of users with given input array
|
Creates list of users with given input array
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**user** | [**[]User**](array.md)| List of user object |
|
**body** | [**[]User**](User.md)| List of user object |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -64,20 +66,22 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
# **CreateUsersWithListInput**
|
# **CreateUsersWithListInput**
|
||||||
> CreateUsersWithListInput(ctx, user)
|
> CreateUsersWithListInput(ctx, body)
|
||||||
Creates list of users with given input array
|
Creates list of users with given input array
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**user** | [**[]User**](array.md)| List of user object |
|
**body** | [**[]User**](User.md)| List of user object |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -90,7 +94,7 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
@ -118,7 +122,7 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
@ -126,6 +130,8 @@ No authorization required
|
|||||||
> User GetUserByName(ctx, username)
|
> User GetUserByName(ctx, username)
|
||||||
Get user by user name
|
Get user by user name
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
@ -152,6 +158,8 @@ No authorization required
|
|||||||
> string LoginUser(ctx, username, password)
|
> string LoginUser(ctx, username, password)
|
||||||
Logs user into the system
|
Logs user into the system
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
|
|
||||||
Name | Type | Description | Notes
|
Name | Type | Description | Notes
|
||||||
@ -179,6 +187,8 @@ No authorization required
|
|||||||
> LogoutUser(ctx, )
|
> LogoutUser(ctx, )
|
||||||
Logs out current logged in user session
|
Logs out current logged in user session
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Required Parameters
|
### Required Parameters
|
||||||
This endpoint does not need any parameter.
|
This endpoint does not need any parameter.
|
||||||
|
|
||||||
@ -193,12 +203,12 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
# **UpdateUser**
|
# **UpdateUser**
|
||||||
> UpdateUser(ctx, username, user)
|
> UpdateUser(ctx, username, body)
|
||||||
Updated user
|
Updated user
|
||||||
|
|
||||||
This can only be done by the logged in user.
|
This can only be done by the logged in user.
|
||||||
@ -209,7 +219,7 @@ Name | Type | Description | Notes
|
|||||||
------------- | ------------- | ------------- | -------------
|
------------- | ------------- | ------------- | -------------
|
||||||
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
**ctx** | **context.Context** | context for authentication, logging, cancellation, deadlines, tracing, etc.
|
||||||
**username** | **string**| name that need to be deleted |
|
**username** | **string**| name that need to be deleted |
|
||||||
**user** | [**User**](User.md)| Updated user object |
|
**body** | [**User**](User.md)| Updated user object |
|
||||||
|
|
||||||
### Return type
|
### Return type
|
||||||
|
|
||||||
@ -222,7 +232,7 @@ No authorization required
|
|||||||
### HTTP request headers
|
### HTTP request headers
|
||||||
|
|
||||||
- **Content-Type**: Not defined
|
- **Content-Type**: Not defined
|
||||||
- **Accept**: Not defined
|
- **Accept**: application/xml, 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)
|
[[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)
|
||||||
|
|
||||||
|
@ -11,13 +11,9 @@
|
|||||||
package petstore
|
package petstore
|
||||||
|
|
||||||
import (
|
import (
|
||||||
import (
|
|
||||||
"os"
|
|
||||||
"time"
|
"time"
|
||||||
)
|
)
|
||||||
|
|
||||||
)
|
|
||||||
|
|
||||||
type FormatTest struct {
|
type FormatTest struct {
|
||||||
Integer int32 `json:"integer,omitempty"`
|
Integer int32 `json:"integer,omitempty"`
|
||||||
Int32_ int32 `json:"int32,omitempty"`
|
Int32_ int32 `json:"int32,omitempty"`
|
||||||
@ -27,7 +23,7 @@ type FormatTest struct {
|
|||||||
Double float64 `json:"double,omitempty"`
|
Double float64 `json:"double,omitempty"`
|
||||||
String_ string `json:"string,omitempty"`
|
String_ string `json:"string,omitempty"`
|
||||||
Byte_ string `json:"byte"`
|
Byte_ string `json:"byte"`
|
||||||
Binary **os.File `json:"binary,omitempty"`
|
Binary string `json:"binary,omitempty"`
|
||||||
Date string `json:"date"`
|
Date string `json:"date"`
|
||||||
DateTime time.Time `json:"dateTime,omitempty"`
|
DateTime time.Time `json:"dateTime,omitempty"`
|
||||||
Uuid string `json:"uuid,omitempty"`
|
Uuid string `json:"uuid,omitempty"`
|
||||||
|
Loading…
x
Reference in New Issue
Block a user