mirror of
https://github.com/valitydev/openapi-generator.git
synced 2024-11-06 10:35:25 +00:00
* Updates ap.mustache for python-experimental, adds test test_test_endpoint_enums_length_one * Removes sortParamsByRequiredFlag from python-experimental * Removes duplicate params from docstring
This commit is contained in:
parent
3922607858
commit
a51d02ac61
@ -12,7 +12,6 @@ sidebar_label: python-experimental
|
||||
|packageUrl|python package URL.| |null|
|
||||
|packageVersion|python package version.| |1.0.0|
|
||||
|projectName|python project name in setup.py (e.g. petstore-api).| |null|
|
||||
|sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true|
|
||||
|useNose|use the nose test framework| |false|
|
||||
|
||||
## IMPORT MAPPING
|
||||
|
@ -97,6 +97,13 @@ public class PythonClientExperimentalCodegen extends PythonClientCodegen {
|
||||
modelTestTemplateFiles.remove("model_test.mustache", ".py");
|
||||
modelTestTemplateFiles.put("python-experimental/model_test.mustache", ".py");
|
||||
|
||||
// this generator does not use SORT_PARAMS_BY_REQUIRED_FLAG
|
||||
// this generator uses the following order for endpoint paramters and model properties
|
||||
// required params/props with no enum of length one
|
||||
// required params/props with enum of length one (which is used to set a default value as a python named arg value)
|
||||
// optional params/props with **kwargs in python
|
||||
cliOptions.remove(4);
|
||||
|
||||
generatorMetadata = GeneratorMetadata.newBuilder(generatorMetadata)
|
||||
.stability(Stability.EXPERIMENTAL)
|
||||
.build();
|
||||
|
@ -45,7 +45,20 @@ class {{classname}}(object):
|
||||
self.api_client = api_client
|
||||
{{#operation}}
|
||||
|
||||
def __{{operationId}}(self, {{#sortParamsByRequiredFlag}}{{#allParams}}{{#required}}{{paramName}}, {{/required}}{{/allParams}}{{/sortParamsByRequiredFlag}}**kwargs): # noqa: E501
|
||||
def __{{operationId}}(
|
||||
self,
|
||||
{{#requiredParams}}
|
||||
{{^defaultValue}}
|
||||
{{paramName}},
|
||||
{{/defaultValue}}
|
||||
{{/requiredParams}}
|
||||
{{#requiredParams}}
|
||||
{{#defaultValue}}
|
||||
{{paramName}}={{{defaultValue}}},
|
||||
{{/defaultValue}}
|
||||
{{/requiredParams}}
|
||||
**kwargs
|
||||
):
|
||||
"""{{#summary}}{{{.}}}{{/summary}}{{^summary}}{{operationId}}{{/summary}} # noqa: E501
|
||||
|
||||
{{#notes}}
|
||||
@ -53,40 +66,51 @@ class {{classname}}(object):
|
||||
{{/notes}}
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
asynchronous HTTP request, please pass async_req=True
|
||||
{{#sortParamsByRequiredFlag}}
|
||||
>>> thread = api.{{operationId}}({{#allParams}}{{#required}}{{paramName}}, {{/required}}{{/allParams}}async_req=True)
|
||||
{{/sortParamsByRequiredFlag}}
|
||||
{{^sortParamsByRequiredFlag}}
|
||||
>>> thread = api.{{operationId}}({{#allParams}}{{#required}}{{paramName}}={{paramName}}_value, {{/required}}{{/allParams}}async_req=True)
|
||||
{{/sortParamsByRequiredFlag}}
|
||||
>>> thread = api.{{operationId}}({{#requiredParams}}{{^defaultValue}}{{paramName}}, {{/defaultValue}}{{/requiredParams}}{{#requiredParams}}{{#defaultValue}}{{paramName}}={{{defaultValue}}}, {{/defaultValue}}{{/requiredParams}}async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
{{#allParams}}
|
||||
:param {{dataType}} {{paramName}}:{{#description}} {{{description}}}{{/description}}{{#required}} (required){{/required}}{{#optional}}(optional){{/optional}}
|
||||
{{/allParams}}
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: {{#returnType}}{{returnType}}{{/returnType}}{{^returnType}}None{{/returnType}}
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
{{#requiredParams}}
|
||||
{{^hasMore}}
|
||||
Args:
|
||||
{{/hasMore}}
|
||||
{{/requiredParams}}
|
||||
{{#requiredParams}}
|
||||
{{^defaultValue}}
|
||||
{{paramName}} ({{dataType}}):{{#description}} {{description}}{{/description}}
|
||||
{{/defaultValue}}
|
||||
{{/requiredParams}}
|
||||
{{#requiredParams}}
|
||||
{{#defaultValue}}
|
||||
{{paramName}} ({{dataType}}):{{#description}} {{description}}.{{/description}} defaults to {{{defaultValue}}}, must be one of [{{{defaultValue}}}]
|
||||
{{/defaultValue}}
|
||||
{{/requiredParams}}
|
||||
|
||||
Keyword Args:{{#optionalParams}}
|
||||
{{paramName}} ({{dataType}}):{{#description}} {{description}}.{{/description}} [optional]{{#defaultValue}} if omitted the server will use the default value of {{{defaultValue}}}{{/defaultValue}}{{/optionalParams}}
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
{{#returnType}}{{returnType}}{{/returnType}}{{^returnType}}None{{/returnType}}
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -49,7 +49,11 @@ class AnotherFakeApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __call_123_test_special_tags(self, body, **kwargs): # noqa: E501
|
||||
def __call_123_test_special_tags(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""To test special tags # noqa: E501
|
||||
|
||||
To test special tags and operation ID starting with number # noqa: E501
|
||||
@ -58,30 +62,34 @@ class AnotherFakeApi(object):
|
||||
>>> thread = api.call_123_test_special_tags(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param client.Client body: client model (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body (client.Client): client model
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -49,7 +49,11 @@ class FakeClassnameTags123Api(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __test_classname(self, body, **kwargs): # noqa: E501
|
||||
def __test_classname(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""To test class name in snake case # noqa: E501
|
||||
|
||||
To test class name in snake case # noqa: E501
|
||||
@ -58,30 +62,34 @@ class FakeClassnameTags123Api(object):
|
||||
>>> thread = api.test_classname(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param client.Client body: client model (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body (client.Client): client model
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -50,7 +50,11 @@ class PetApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __add_pet(self, body, **kwargs): # noqa: E501
|
||||
def __add_pet(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""Add a new pet to the store # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -58,30 +62,34 @@ class PetApi(object):
|
||||
>>> thread = api.add_pet(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param pet.Pet body: Pet object that needs to be added to the store (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body (pet.Pet): Pet object that needs to be added to the store
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -159,7 +167,11 @@ class PetApi(object):
|
||||
callable=__add_pet
|
||||
)
|
||||
|
||||
def __delete_pet(self, pet_id, **kwargs): # noqa: E501
|
||||
def __delete_pet(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Deletes a pet # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -167,31 +179,35 @@ class PetApi(object):
|
||||
>>> thread = api.delete_pet(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: Pet id to delete (required)
|
||||
:param str api_key:
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): Pet id to delete
|
||||
|
||||
Keyword Args:
|
||||
api_key (str): [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -272,7 +288,11 @@ class PetApi(object):
|
||||
callable=__delete_pet
|
||||
)
|
||||
|
||||
def __find_pets_by_status(self, status, **kwargs): # noqa: E501
|
||||
def __find_pets_by_status(
|
||||
self,
|
||||
status,
|
||||
**kwargs
|
||||
):
|
||||
"""Finds Pets by status # noqa: E501
|
||||
|
||||
Multiple status values can be provided with comma separated strings # noqa: E501
|
||||
@ -281,30 +301,34 @@ class PetApi(object):
|
||||
>>> thread = api.find_pets_by_status(status, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [str] status: Status values that need to be considered for filter (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: [pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
status ([str]): Status values that need to be considered for filter
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
[pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -391,7 +415,11 @@ class PetApi(object):
|
||||
callable=__find_pets_by_status
|
||||
)
|
||||
|
||||
def __find_pets_by_tags(self, tags, **kwargs): # noqa: E501
|
||||
def __find_pets_by_tags(
|
||||
self,
|
||||
tags,
|
||||
**kwargs
|
||||
):
|
||||
"""Finds Pets by tags # noqa: E501
|
||||
|
||||
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. # noqa: E501
|
||||
@ -400,30 +428,34 @@ class PetApi(object):
|
||||
>>> thread = api.find_pets_by_tags(tags, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [str] tags: Tags to filter by (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: [pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
tags ([str]): Tags to filter by
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
[pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -503,7 +535,11 @@ class PetApi(object):
|
||||
callable=__find_pets_by_tags
|
||||
)
|
||||
|
||||
def __get_pet_by_id(self, pet_id, **kwargs): # noqa: E501
|
||||
def __get_pet_by_id(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Find pet by ID # noqa: E501
|
||||
|
||||
Returns a single pet # noqa: E501
|
||||
@ -512,30 +548,34 @@ class PetApi(object):
|
||||
>>> thread = api.get_pet_by_id(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet to return (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: pet.Pet
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet to return
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
pet.Pet
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -614,7 +654,11 @@ class PetApi(object):
|
||||
callable=__get_pet_by_id
|
||||
)
|
||||
|
||||
def __update_pet(self, body, **kwargs): # noqa: E501
|
||||
def __update_pet(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""Update an existing pet # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -622,30 +666,34 @@ class PetApi(object):
|
||||
>>> thread = api.update_pet(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param pet.Pet body: Pet object that needs to be added to the store (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body (pet.Pet): Pet object that needs to be added to the store
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -723,7 +771,11 @@ class PetApi(object):
|
||||
callable=__update_pet
|
||||
)
|
||||
|
||||
def __update_pet_with_form(self, pet_id, **kwargs): # noqa: E501
|
||||
def __update_pet_with_form(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Updates a pet in the store with form data # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -731,32 +783,36 @@ class PetApi(object):
|
||||
>>> thread = api.update_pet_with_form(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet that needs to be updated (required)
|
||||
:param str name: Updated name of the pet
|
||||
:param str status: Updated status of the pet
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet that needs to be updated
|
||||
|
||||
Keyword Args:
|
||||
name (str): Updated name of the pet. [optional]
|
||||
status (str): Updated status of the pet. [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -844,7 +900,11 @@ class PetApi(object):
|
||||
callable=__update_pet_with_form
|
||||
)
|
||||
|
||||
def __upload_file(self, pet_id, **kwargs): # noqa: E501
|
||||
def __upload_file(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""uploads an image # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -852,33 +912,37 @@ class PetApi(object):
|
||||
>>> thread = api.upload_file(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet to update (required)
|
||||
:param str additional_metadata: Additional data to pass to server
|
||||
:param file_type file: file to upload
|
||||
:param [file_type] files: files to upload
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet to update
|
||||
|
||||
Keyword Args:
|
||||
additional_metadata (str): Additional data to pass to server. [optional]
|
||||
file (file_type): file to upload. [optional]
|
||||
files ([file_type]): files to upload. [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -974,7 +1038,12 @@ class PetApi(object):
|
||||
callable=__upload_file
|
||||
)
|
||||
|
||||
def __upload_file_with_required_file(self, pet_id, required_file, **kwargs): # noqa: E501
|
||||
def __upload_file_with_required_file(
|
||||
self,
|
||||
pet_id,
|
||||
required_file,
|
||||
**kwargs
|
||||
):
|
||||
"""uploads an image (required) # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -982,32 +1051,36 @@ class PetApi(object):
|
||||
>>> thread = api.upload_file_with_required_file(pet_id, required_file, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet to update (required)
|
||||
:param file_type required_file: file to upload (required)
|
||||
:param str additional_metadata: Additional data to pass to server
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet to update
|
||||
required_file (file_type): file to upload
|
||||
|
||||
Keyword Args:
|
||||
additional_metadata (str): Additional data to pass to server. [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -49,7 +49,11 @@ class StoreApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __delete_order(self, order_id, **kwargs): # noqa: E501
|
||||
def __delete_order(
|
||||
self,
|
||||
order_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Delete purchase order by ID # noqa: E501
|
||||
|
||||
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors # noqa: E501
|
||||
@ -58,30 +62,34 @@ class StoreApi(object):
|
||||
>>> thread = api.delete_order(order_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str order_id: ID of the order that needs to be deleted (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
order_id (str): ID of the order that needs to be deleted
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -155,7 +163,10 @@ class StoreApi(object):
|
||||
callable=__delete_order
|
||||
)
|
||||
|
||||
def __get_inventory(self, **kwargs): # noqa: E501
|
||||
def __get_inventory(
|
||||
self,
|
||||
**kwargs
|
||||
):
|
||||
"""Returns pet inventories by status # noqa: E501
|
||||
|
||||
Returns a map of status codes to quantities # noqa: E501
|
||||
@ -164,29 +175,32 @@ class StoreApi(object):
|
||||
>>> thread = api.get_inventory(async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: {str: (int,)}
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
{str: (int,)}
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -255,7 +269,11 @@ class StoreApi(object):
|
||||
callable=__get_inventory
|
||||
)
|
||||
|
||||
def __get_order_by_id(self, order_id, **kwargs): # noqa: E501
|
||||
def __get_order_by_id(
|
||||
self,
|
||||
order_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Find purchase order by ID # noqa: E501
|
||||
|
||||
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions # noqa: E501
|
||||
@ -264,30 +282,34 @@ class StoreApi(object):
|
||||
>>> thread = api.get_order_by_id(order_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int order_id: ID of pet that needs to be fetched (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
order_id (int): ID of pet that needs to be fetched
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -370,7 +392,11 @@ class StoreApi(object):
|
||||
callable=__get_order_by_id
|
||||
)
|
||||
|
||||
def __place_order(self, body, **kwargs): # noqa: E501
|
||||
def __place_order(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""Place an order for a pet # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -378,30 +404,34 @@ class StoreApi(object):
|
||||
>>> thread = api.place_order(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param order.Order body: order placed for purchasing the pet (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body (order.Order): order placed for purchasing the pet
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -49,7 +49,11 @@ class UserApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __create_user(self, body, **kwargs): # noqa: E501
|
||||
def __create_user(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""Create user # noqa: E501
|
||||
|
||||
This can only be done by the logged in user. # noqa: E501
|
||||
@ -58,30 +62,34 @@ class UserApi(object):
|
||||
>>> thread = api.create_user(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param user.User body: Created user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body (user.User): Created user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -154,7 +162,11 @@ class UserApi(object):
|
||||
callable=__create_user
|
||||
)
|
||||
|
||||
def __create_users_with_array_input(self, body, **kwargs): # noqa: E501
|
||||
def __create_users_with_array_input(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""Creates list of users with given input array # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -162,30 +174,34 @@ class UserApi(object):
|
||||
>>> thread = api.create_users_with_array_input(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [user.User] body: List of user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body ([user.User]): List of user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -258,7 +274,11 @@ class UserApi(object):
|
||||
callable=__create_users_with_array_input
|
||||
)
|
||||
|
||||
def __create_users_with_list_input(self, body, **kwargs): # noqa: E501
|
||||
def __create_users_with_list_input(
|
||||
self,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""Creates list of users with given input array # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -266,30 +286,34 @@ class UserApi(object):
|
||||
>>> thread = api.create_users_with_list_input(body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [user.User] body: List of user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
body ([user.User]): List of user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -362,7 +386,11 @@ class UserApi(object):
|
||||
callable=__create_users_with_list_input
|
||||
)
|
||||
|
||||
def __delete_user(self, username, **kwargs): # noqa: E501
|
||||
def __delete_user(
|
||||
self,
|
||||
username,
|
||||
**kwargs
|
||||
):
|
||||
"""Delete user # noqa: E501
|
||||
|
||||
This can only be done by the logged in user. # noqa: E501
|
||||
@ -371,30 +399,34 @@ class UserApi(object):
|
||||
>>> thread = api.delete_user(username, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: The name that needs to be deleted (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): The name that needs to be deleted
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -468,7 +500,11 @@ class UserApi(object):
|
||||
callable=__delete_user
|
||||
)
|
||||
|
||||
def __get_user_by_name(self, username, **kwargs): # noqa: E501
|
||||
def __get_user_by_name(
|
||||
self,
|
||||
username,
|
||||
**kwargs
|
||||
):
|
||||
"""Get user by user name # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -476,30 +512,34 @@ class UserApi(object):
|
||||
>>> thread = api.get_user_by_name(username, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: The name that needs to be fetched. Use user1 for testing. (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: user.User
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): The name that needs to be fetched. Use user1 for testing.
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
user.User
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -576,7 +616,12 @@ class UserApi(object):
|
||||
callable=__get_user_by_name
|
||||
)
|
||||
|
||||
def __login_user(self, username, password, **kwargs): # noqa: E501
|
||||
def __login_user(
|
||||
self,
|
||||
username,
|
||||
password,
|
||||
**kwargs
|
||||
):
|
||||
"""Logs user into the system # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -584,31 +629,35 @@ class UserApi(object):
|
||||
>>> thread = api.login_user(username, password, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: The user name for login (required)
|
||||
:param str password: The password for login in clear text (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: str
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): The user name for login
|
||||
password (str): The password for login in clear text
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
str
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -693,7 +742,10 @@ class UserApi(object):
|
||||
callable=__login_user
|
||||
)
|
||||
|
||||
def __logout_user(self, **kwargs): # noqa: E501
|
||||
def __logout_user(
|
||||
self,
|
||||
**kwargs
|
||||
):
|
||||
"""Logs out current logged in user session # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -701,29 +753,32 @@ class UserApi(object):
|
||||
>>> thread = api.logout_user(async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -788,7 +843,12 @@ class UserApi(object):
|
||||
callable=__logout_user
|
||||
)
|
||||
|
||||
def __update_user(self, username, body, **kwargs): # noqa: E501
|
||||
def __update_user(
|
||||
self,
|
||||
username,
|
||||
body,
|
||||
**kwargs
|
||||
):
|
||||
"""Updated user # noqa: E501
|
||||
|
||||
This can only be done by the logged in user. # noqa: E501
|
||||
@ -797,31 +857,35 @@ class UserApi(object):
|
||||
>>> thread = api.update_user(username, body, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: name that need to be deleted (required)
|
||||
:param user.User body: Updated user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): name that need to be deleted
|
||||
body (user.User): Updated user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -5,14 +5,19 @@
|
||||
|
||||
This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ # noqa: E501
|
||||
|
||||
OpenAPI spec version: 1.0.0
|
||||
The version of the OpenAPI document: 1.0.0
|
||||
Generated by: https://openapi-generator.tech
|
||||
"""
|
||||
|
||||
|
||||
from __future__ import absolute_import
|
||||
import six
|
||||
|
||||
import unittest
|
||||
if six.PY3:
|
||||
from unittest.mock import patch
|
||||
else:
|
||||
from mock import patch
|
||||
|
||||
import petstore_api
|
||||
from petstore_api.api.fake_api import FakeApi # noqa: E501
|
||||
@ -28,6 +33,13 @@ class TestFakeApi(unittest.TestCase):
|
||||
def tearDown(self):
|
||||
pass
|
||||
|
||||
def test_create_xml_item(self):
|
||||
"""Test case for create_xml_item
|
||||
|
||||
creates an XmlItem # noqa: E501
|
||||
"""
|
||||
pass
|
||||
|
||||
def test_fake_outer_boolean_serialize(self):
|
||||
"""Test case for fake_outer_boolean_serialize
|
||||
|
||||
@ -64,6 +76,12 @@ class TestFakeApi(unittest.TestCase):
|
||||
"""
|
||||
pass
|
||||
|
||||
def test_test_body_with_file_schema(self):
|
||||
"""Test case for test_body_with_file_schema
|
||||
|
||||
"""
|
||||
pass
|
||||
|
||||
def test_test_body_with_query_params(self):
|
||||
"""Test case for test_body_with_query_params
|
||||
|
||||
@ -77,6 +95,29 @@ class TestFakeApi(unittest.TestCase):
|
||||
"""
|
||||
pass
|
||||
|
||||
def test_test_endpoint_enums_length_one(self):
|
||||
"""Test case for test_endpoint_enums_length_one
|
||||
|
||||
"""
|
||||
# when we omit the required enums of length one, they are still set
|
||||
endpoint = self.api.test_endpoint_enums_length_one
|
||||
with patch.object(endpoint, 'call_with_http_info') as call_with_http_info:
|
||||
endpoint()
|
||||
call_with_http_info.assert_called_with(
|
||||
_check_input_type=True,
|
||||
_check_return_type=True,
|
||||
_host_index=0,
|
||||
_preload_content=True,
|
||||
_request_timeout=None,
|
||||
_return_http_data_only=True,
|
||||
async_req=False,
|
||||
header_number=1.234,
|
||||
path_integer=34,
|
||||
path_string='hello',
|
||||
query_integer=3,
|
||||
query_string='brillig'
|
||||
)
|
||||
|
||||
def test_test_endpoint_parameters(self):
|
||||
"""Test case for test_endpoint_parameters
|
||||
|
||||
@ -115,6 +156,13 @@ class TestFakeApi(unittest.TestCase):
|
||||
with self.assertRaises(petstore_api.ApiValueError):
|
||||
self.api.test_enum_parameters(**keyword_args)
|
||||
|
||||
def test_test_group_parameters(self):
|
||||
"""Test case for test_group_parameters
|
||||
|
||||
Fake endpoint to test group parameters (optional) # noqa: E501
|
||||
"""
|
||||
pass
|
||||
|
||||
def test_test_inline_additional_properties(self):
|
||||
"""Test case for test_inline_additional_properties
|
||||
|
||||
|
@ -49,7 +49,11 @@ class AnotherFakeApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __call_123_test_special_tags(self, client_client, **kwargs): # noqa: E501
|
||||
def __call_123_test_special_tags(
|
||||
self,
|
||||
client_client,
|
||||
**kwargs
|
||||
):
|
||||
"""To test special tags # noqa: E501
|
||||
|
||||
To test special tags and operation ID starting with number # noqa: E501
|
||||
@ -58,30 +62,34 @@ class AnotherFakeApi(object):
|
||||
>>> thread = api.call_123_test_special_tags(client_client, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param client.Client client_client: client model (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
client_client (client.Client): client model
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -49,7 +49,10 @@ class DefaultApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __foo_get(self, **kwargs): # noqa: E501
|
||||
def __foo_get(
|
||||
self,
|
||||
**kwargs
|
||||
):
|
||||
"""foo_get # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -57,29 +60,32 @@ class DefaultApi(object):
|
||||
>>> thread = api.foo_get(async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: inline_response_default.InlineResponseDefault
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
inline_response_default.InlineResponseDefault
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -49,7 +49,11 @@ class FakeClassnameTags123Api(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __test_classname(self, client_client, **kwargs): # noqa: E501
|
||||
def __test_classname(
|
||||
self,
|
||||
client_client,
|
||||
**kwargs
|
||||
):
|
||||
"""To test class name in snake case # noqa: E501
|
||||
|
||||
To test class name in snake case # noqa: E501
|
||||
@ -58,30 +62,34 @@ class FakeClassnameTags123Api(object):
|
||||
>>> thread = api.test_classname(client_client, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param client.Client client_client: client model (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
client_client (client.Client): client model
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
client.Client
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -50,7 +50,11 @@ class PetApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __add_pet(self, pet_pet, **kwargs): # noqa: E501
|
||||
def __add_pet(
|
||||
self,
|
||||
pet_pet,
|
||||
**kwargs
|
||||
):
|
||||
"""Add a new pet to the store # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -58,30 +62,34 @@ class PetApi(object):
|
||||
>>> thread = api.add_pet(pet_pet, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param pet.Pet pet_pet: Pet object that needs to be added to the store (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_pet (pet.Pet): Pet object that needs to be added to the store
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -163,7 +171,11 @@ class PetApi(object):
|
||||
callable=__add_pet
|
||||
)
|
||||
|
||||
def __delete_pet(self, pet_id, **kwargs): # noqa: E501
|
||||
def __delete_pet(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Deletes a pet # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -171,31 +183,35 @@ class PetApi(object):
|
||||
>>> thread = api.delete_pet(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: Pet id to delete (required)
|
||||
:param str api_key:
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): Pet id to delete
|
||||
|
||||
Keyword Args:
|
||||
api_key (str): [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -276,7 +292,11 @@ class PetApi(object):
|
||||
callable=__delete_pet
|
||||
)
|
||||
|
||||
def __find_pets_by_status(self, status, **kwargs): # noqa: E501
|
||||
def __find_pets_by_status(
|
||||
self,
|
||||
status,
|
||||
**kwargs
|
||||
):
|
||||
"""Finds Pets by status # noqa: E501
|
||||
|
||||
Multiple status values can be provided with comma separated strings # noqa: E501
|
||||
@ -285,30 +305,34 @@ class PetApi(object):
|
||||
>>> thread = api.find_pets_by_status(status, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [str] status: Status values that need to be considered for filter (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: [pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
status ([str]): Status values that need to be considered for filter
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
[pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -396,7 +420,11 @@ class PetApi(object):
|
||||
callable=__find_pets_by_status
|
||||
)
|
||||
|
||||
def __find_pets_by_tags(self, tags, **kwargs): # noqa: E501
|
||||
def __find_pets_by_tags(
|
||||
self,
|
||||
tags,
|
||||
**kwargs
|
||||
):
|
||||
"""Finds Pets by tags # noqa: E501
|
||||
|
||||
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. # noqa: E501
|
||||
@ -405,30 +433,34 @@ class PetApi(object):
|
||||
>>> thread = api.find_pets_by_tags(tags, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [str] tags: Tags to filter by (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: [pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
tags ([str]): Tags to filter by
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
[pet.Pet]
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -509,7 +541,11 @@ class PetApi(object):
|
||||
callable=__find_pets_by_tags
|
||||
)
|
||||
|
||||
def __get_pet_by_id(self, pet_id, **kwargs): # noqa: E501
|
||||
def __get_pet_by_id(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Find pet by ID # noqa: E501
|
||||
|
||||
Returns a single pet # noqa: E501
|
||||
@ -518,30 +554,34 @@ class PetApi(object):
|
||||
>>> thread = api.get_pet_by_id(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet to return (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: pet.Pet
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet to return
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
pet.Pet
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -620,7 +660,11 @@ class PetApi(object):
|
||||
callable=__get_pet_by_id
|
||||
)
|
||||
|
||||
def __update_pet(self, pet_pet, **kwargs): # noqa: E501
|
||||
def __update_pet(
|
||||
self,
|
||||
pet_pet,
|
||||
**kwargs
|
||||
):
|
||||
"""Update an existing pet # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -628,30 +672,34 @@ class PetApi(object):
|
||||
>>> thread = api.update_pet(pet_pet, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param pet.Pet pet_pet: Pet object that needs to be added to the store (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_pet (pet.Pet): Pet object that needs to be added to the store
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -733,7 +781,11 @@ class PetApi(object):
|
||||
callable=__update_pet
|
||||
)
|
||||
|
||||
def __update_pet_with_form(self, pet_id, **kwargs): # noqa: E501
|
||||
def __update_pet_with_form(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Updates a pet in the store with form data # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -741,32 +793,36 @@ class PetApi(object):
|
||||
>>> thread = api.update_pet_with_form(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet that needs to be updated (required)
|
||||
:param str name: Updated name of the pet
|
||||
:param str status: Updated status of the pet
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet that needs to be updated
|
||||
|
||||
Keyword Args:
|
||||
name (str): Updated name of the pet. [optional]
|
||||
status (str): Updated status of the pet. [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -854,7 +910,11 @@ class PetApi(object):
|
||||
callable=__update_pet_with_form
|
||||
)
|
||||
|
||||
def __upload_file(self, pet_id, **kwargs): # noqa: E501
|
||||
def __upload_file(
|
||||
self,
|
||||
pet_id,
|
||||
**kwargs
|
||||
):
|
||||
"""uploads an image # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -862,32 +922,36 @@ class PetApi(object):
|
||||
>>> thread = api.upload_file(pet_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet to update (required)
|
||||
:param str additional_metadata: Additional data to pass to server
|
||||
:param file_type file: file to upload
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet to update
|
||||
|
||||
Keyword Args:
|
||||
additional_metadata (str): Additional data to pass to server. [optional]
|
||||
file (file_type): file to upload. [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -977,7 +1041,12 @@ class PetApi(object):
|
||||
callable=__upload_file
|
||||
)
|
||||
|
||||
def __upload_file_with_required_file(self, pet_id, required_file, **kwargs): # noqa: E501
|
||||
def __upload_file_with_required_file(
|
||||
self,
|
||||
pet_id,
|
||||
required_file,
|
||||
**kwargs
|
||||
):
|
||||
"""uploads an image (required) # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -985,32 +1054,36 @@ class PetApi(object):
|
||||
>>> thread = api.upload_file_with_required_file(pet_id, required_file, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int pet_id: ID of pet to update (required)
|
||||
:param file_type required_file: file to upload (required)
|
||||
:param str additional_metadata: Additional data to pass to server
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
pet_id (int): ID of pet to update
|
||||
required_file (file_type): file to upload
|
||||
|
||||
Keyword Args:
|
||||
additional_metadata (str): Additional data to pass to server. [optional]
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
api_response.ApiResponse
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -49,7 +49,11 @@ class StoreApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __delete_order(self, order_id, **kwargs): # noqa: E501
|
||||
def __delete_order(
|
||||
self,
|
||||
order_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Delete purchase order by ID # noqa: E501
|
||||
|
||||
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors # noqa: E501
|
||||
@ -58,30 +62,34 @@ class StoreApi(object):
|
||||
>>> thread = api.delete_order(order_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str order_id: ID of the order that needs to be deleted (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
order_id (str): ID of the order that needs to be deleted
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -155,7 +163,10 @@ class StoreApi(object):
|
||||
callable=__delete_order
|
||||
)
|
||||
|
||||
def __get_inventory(self, **kwargs): # noqa: E501
|
||||
def __get_inventory(
|
||||
self,
|
||||
**kwargs
|
||||
):
|
||||
"""Returns pet inventories by status # noqa: E501
|
||||
|
||||
Returns a map of status codes to quantities # noqa: E501
|
||||
@ -164,29 +175,32 @@ class StoreApi(object):
|
||||
>>> thread = api.get_inventory(async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: {str: (int,)}
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
{str: (int,)}
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -255,7 +269,11 @@ class StoreApi(object):
|
||||
callable=__get_inventory
|
||||
)
|
||||
|
||||
def __get_order_by_id(self, order_id, **kwargs): # noqa: E501
|
||||
def __get_order_by_id(
|
||||
self,
|
||||
order_id,
|
||||
**kwargs
|
||||
):
|
||||
"""Find purchase order by ID # noqa: E501
|
||||
|
||||
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions # noqa: E501
|
||||
@ -264,30 +282,34 @@ class StoreApi(object):
|
||||
>>> thread = api.get_order_by_id(order_id, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param int order_id: ID of pet that needs to be fetched (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
order_id (int): ID of pet that needs to be fetched
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -370,7 +392,11 @@ class StoreApi(object):
|
||||
callable=__get_order_by_id
|
||||
)
|
||||
|
||||
def __place_order(self, order_order, **kwargs): # noqa: E501
|
||||
def __place_order(
|
||||
self,
|
||||
order_order,
|
||||
**kwargs
|
||||
):
|
||||
"""Place an order for a pet # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -378,30 +404,34 @@ class StoreApi(object):
|
||||
>>> thread = api.place_order(order_order, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param order.Order order_order: order placed for purchasing the pet (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
order_order (order.Order): order placed for purchasing the pet
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
order.Order
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
@ -49,7 +49,11 @@ class UserApi(object):
|
||||
api_client = ApiClient()
|
||||
self.api_client = api_client
|
||||
|
||||
def __create_user(self, user_user, **kwargs): # noqa: E501
|
||||
def __create_user(
|
||||
self,
|
||||
user_user,
|
||||
**kwargs
|
||||
):
|
||||
"""Create user # noqa: E501
|
||||
|
||||
This can only be done by the logged in user. # noqa: E501
|
||||
@ -58,30 +62,34 @@ class UserApi(object):
|
||||
>>> thread = api.create_user(user_user, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param user.User user_user: Created user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
user_user (user.User): Created user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -156,7 +164,11 @@ class UserApi(object):
|
||||
callable=__create_user
|
||||
)
|
||||
|
||||
def __create_users_with_array_input(self, user_user, **kwargs): # noqa: E501
|
||||
def __create_users_with_array_input(
|
||||
self,
|
||||
user_user,
|
||||
**kwargs
|
||||
):
|
||||
"""Creates list of users with given input array # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -164,30 +176,34 @@ class UserApi(object):
|
||||
>>> thread = api.create_users_with_array_input(user_user, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [user.User] user_user: List of user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
user_user ([user.User]): List of user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -262,7 +278,11 @@ class UserApi(object):
|
||||
callable=__create_users_with_array_input
|
||||
)
|
||||
|
||||
def __create_users_with_list_input(self, user_user, **kwargs): # noqa: E501
|
||||
def __create_users_with_list_input(
|
||||
self,
|
||||
user_user,
|
||||
**kwargs
|
||||
):
|
||||
"""Creates list of users with given input array # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -270,30 +290,34 @@ class UserApi(object):
|
||||
>>> thread = api.create_users_with_list_input(user_user, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param [user.User] user_user: List of user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
user_user ([user.User]): List of user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -368,7 +392,11 @@ class UserApi(object):
|
||||
callable=__create_users_with_list_input
|
||||
)
|
||||
|
||||
def __delete_user(self, username, **kwargs): # noqa: E501
|
||||
def __delete_user(
|
||||
self,
|
||||
username,
|
||||
**kwargs
|
||||
):
|
||||
"""Delete user # noqa: E501
|
||||
|
||||
This can only be done by the logged in user. # noqa: E501
|
||||
@ -377,30 +405,34 @@ class UserApi(object):
|
||||
>>> thread = api.delete_user(username, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: The name that needs to be deleted (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): The name that needs to be deleted
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -474,7 +506,11 @@ class UserApi(object):
|
||||
callable=__delete_user
|
||||
)
|
||||
|
||||
def __get_user_by_name(self, username, **kwargs): # noqa: E501
|
||||
def __get_user_by_name(
|
||||
self,
|
||||
username,
|
||||
**kwargs
|
||||
):
|
||||
"""Get user by user name # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -482,30 +518,34 @@ class UserApi(object):
|
||||
>>> thread = api.get_user_by_name(username, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: The name that needs to be fetched. Use user1 for testing. (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: user.User
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): The name that needs to be fetched. Use user1 for testing.
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
user.User
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -582,7 +622,12 @@ class UserApi(object):
|
||||
callable=__get_user_by_name
|
||||
)
|
||||
|
||||
def __login_user(self, username, password, **kwargs): # noqa: E501
|
||||
def __login_user(
|
||||
self,
|
||||
username,
|
||||
password,
|
||||
**kwargs
|
||||
):
|
||||
"""Logs user into the system # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -590,31 +635,35 @@ class UserApi(object):
|
||||
>>> thread = api.login_user(username, password, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: The user name for login (required)
|
||||
:param str password: The password for login in clear text (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: str
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): The user name for login
|
||||
password (str): The password for login in clear text
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
str
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -699,7 +748,10 @@ class UserApi(object):
|
||||
callable=__login_user
|
||||
)
|
||||
|
||||
def __logout_user(self, **kwargs): # noqa: E501
|
||||
def __logout_user(
|
||||
self,
|
||||
**kwargs
|
||||
):
|
||||
"""Logs out current logged in user session # noqa: E501
|
||||
|
||||
This method makes a synchronous HTTP request by default. To make an
|
||||
@ -707,29 +759,32 @@ class UserApi(object):
|
||||
>>> thread = api.logout_user(async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
@ -794,7 +849,12 @@ class UserApi(object):
|
||||
callable=__logout_user
|
||||
)
|
||||
|
||||
def __update_user(self, username, user_user, **kwargs): # noqa: E501
|
||||
def __update_user(
|
||||
self,
|
||||
username,
|
||||
user_user,
|
||||
**kwargs
|
||||
):
|
||||
"""Updated user # noqa: E501
|
||||
|
||||
This can only be done by the logged in user. # noqa: E501
|
||||
@ -803,31 +863,35 @@ class UserApi(object):
|
||||
>>> thread = api.update_user(username, user_user, async_req=True)
|
||||
>>> result = thread.get()
|
||||
|
||||
:param async_req bool: execute request asynchronously
|
||||
Default is False.
|
||||
:param str username: name that need to be deleted (required)
|
||||
:param user.User user_user: Updated user object (required)
|
||||
:param _return_http_data_only: response data without head status
|
||||
code and headers. Default is True.
|
||||
:param _preload_content: if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
:param _request_timeout: timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
:param _check_input_type: boolean specifying if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
:param _check_return_type: boolean specifying if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
:param _host_index: integer specifying the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
:return: None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
Args:
|
||||
username (str): name that need to be deleted
|
||||
user_user (user.User): Updated user object
|
||||
|
||||
Keyword Args:
|
||||
_return_http_data_only (bool): response data without head status
|
||||
code and headers. Default is True.
|
||||
_preload_content (bool): if False, the urllib3.HTTPResponse object
|
||||
will be returned without reading/decoding response data.
|
||||
Default is True.
|
||||
_request_timeout (float/tuple): timeout setting for this request. If one
|
||||
number provided, it will be total request timeout. It can also
|
||||
be a pair (tuple) of (connection, read) timeouts.
|
||||
Default is None.
|
||||
_check_input_type (bool): specifies if type checking
|
||||
should be done one the data sent to the server.
|
||||
Default is True.
|
||||
_check_return_type (bool): specifies if type checking
|
||||
should be done one the data received from the server.
|
||||
Default is True.
|
||||
_host_index (int): specifies the index of the server
|
||||
that we want to use.
|
||||
Default is 0.
|
||||
async_req (bool): execute request asynchronously
|
||||
|
||||
Returns:
|
||||
None
|
||||
If the method is called asynchronously, returns the request
|
||||
thread.
|
||||
"""
|
||||
kwargs['async_req'] = kwargs.get(
|
||||
'async_req', False
|
||||
|
Loading…
Reference in New Issue
Block a user