mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-06 04:06:07 +00:00
[Python] Add configuration.{connection_pool_maxsize, assert_hostname} (#6508)
* Backport kubernetes client features: - assert_hostname - connection_pool_maxsize - cleanups * Update petstore sample
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
# AdditionalPropertiesClass
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**map_property** | **dict(str, str)** | | [optional]
|
||||
**map_of_map_property** | [**dict(str, dict(str, str))**](dict.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
11
samples/client/petstore/python-asyncio/docs/Animal.md
Normal file
11
samples/client/petstore/python-asyncio/docs/Animal.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# Animal
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**class_name** | **str** | |
|
||||
**color** | **str** | | [optional] [default to 'red']
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
# AnimalFarm
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,57 @@
|
||||
# petstore_api.AnotherFakeApi
|
||||
|
||||
All URIs are relative to *http://petstore.swagger.io:80/v2*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**test_special_tags**](AnotherFakeApi.md#test_special_tags) | **PATCH** /another-fake/dummy | To test special tags
|
||||
|
||||
|
||||
# **test_special_tags**
|
||||
> Client test_special_tags(body)
|
||||
|
||||
To test special tags
|
||||
|
||||
To test special tags
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.AnotherFakeApi()
|
||||
body = petstore_api.Client() # Client | client model
|
||||
|
||||
try:
|
||||
# To test special tags
|
||||
api_response = api_instance.test_special_tags(body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling AnotherFakeApi->test_special_tags: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Client**](Client.md)| client model |
|
||||
|
||||
### Return type
|
||||
|
||||
[**Client**](Client.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
12
samples/client/petstore/python-asyncio/docs/ApiResponse.md
Normal file
12
samples/client/petstore/python-asyncio/docs/ApiResponse.md
Normal file
@@ -0,0 +1,12 @@
|
||||
# ApiResponse
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**code** | **int** | | [optional]
|
||||
**type** | **str** | | [optional]
|
||||
**message** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
# ArrayOfArrayOfNumberOnly
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**array_array_number** | **list[list[float]]** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
# ArrayOfNumberOnly
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**array_number** | **list[float]** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
12
samples/client/petstore/python-asyncio/docs/ArrayTest.md
Normal file
12
samples/client/petstore/python-asyncio/docs/ArrayTest.md
Normal file
@@ -0,0 +1,12 @@
|
||||
# ArrayTest
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**array_of_string** | **list[str]** | | [optional]
|
||||
**array_array_of_integer** | **list[list[int]]** | | [optional]
|
||||
**array_array_of_model** | **list[list[ReadOnlyFirst]]** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
# Capitalization
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**small_camel** | **str** | | [optional]
|
||||
**capital_camel** | **str** | | [optional]
|
||||
**small_snake** | **str** | | [optional]
|
||||
**capital_snake** | **str** | | [optional]
|
||||
**sca_eth_flow_points** | **str** | | [optional]
|
||||
**att_name** | **str** | Name of the pet | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
10
samples/client/petstore/python-asyncio/docs/Cat.md
Normal file
10
samples/client/petstore/python-asyncio/docs/Cat.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# Cat
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**declawed** | **bool** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
11
samples/client/petstore/python-asyncio/docs/Category.md
Normal file
11
samples/client/petstore/python-asyncio/docs/Category.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# Category
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**id** | **int** | | [optional]
|
||||
**name** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
10
samples/client/petstore/python-asyncio/docs/ClassModel.md
Normal file
10
samples/client/petstore/python-asyncio/docs/ClassModel.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# ClassModel
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**_class** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
10
samples/client/petstore/python-asyncio/docs/Client.md
Normal file
10
samples/client/petstore/python-asyncio/docs/Client.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# Client
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**client** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
10
samples/client/petstore/python-asyncio/docs/Dog.md
Normal file
10
samples/client/petstore/python-asyncio/docs/Dog.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# Dog
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**breed** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
11
samples/client/petstore/python-asyncio/docs/EnumArrays.md
Normal file
11
samples/client/petstore/python-asyncio/docs/EnumArrays.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# EnumArrays
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**just_symbol** | **str** | | [optional]
|
||||
**array_enum** | **list[str]** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
9
samples/client/petstore/python-asyncio/docs/EnumClass.md
Normal file
9
samples/client/petstore/python-asyncio/docs/EnumClass.md
Normal file
@@ -0,0 +1,9 @@
|
||||
# EnumClass
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
13
samples/client/petstore/python-asyncio/docs/EnumTest.md
Normal file
13
samples/client/petstore/python-asyncio/docs/EnumTest.md
Normal file
@@ -0,0 +1,13 @@
|
||||
# EnumTest
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**enum_string** | **str** | | [optional]
|
||||
**enum_integer** | **int** | | [optional]
|
||||
**enum_number** | **float** | | [optional]
|
||||
**outer_enum** | [**OuterEnum**](OuterEnum.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
440
samples/client/petstore/python-asyncio/docs/FakeApi.md
Normal file
440
samples/client/petstore/python-asyncio/docs/FakeApi.md
Normal file
@@ -0,0 +1,440 @@
|
||||
# petstore_api.FakeApi
|
||||
|
||||
All URIs are relative to *http://petstore.swagger.io:80/v2*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**fake_outer_boolean_serialize**](FakeApi.md#fake_outer_boolean_serialize) | **POST** /fake/outer/boolean |
|
||||
[**fake_outer_composite_serialize**](FakeApi.md#fake_outer_composite_serialize) | **POST** /fake/outer/composite |
|
||||
[**fake_outer_number_serialize**](FakeApi.md#fake_outer_number_serialize) | **POST** /fake/outer/number |
|
||||
[**fake_outer_string_serialize**](FakeApi.md#fake_outer_string_serialize) | **POST** /fake/outer/string |
|
||||
[**test_client_model**](FakeApi.md#test_client_model) | **PATCH** /fake | To test \"client\" model
|
||||
[**test_endpoint_parameters**](FakeApi.md#test_endpoint_parameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
[**test_enum_parameters**](FakeApi.md#test_enum_parameters) | **GET** /fake | To test enum parameters
|
||||
[**test_json_form_data**](FakeApi.md#test_json_form_data) | **GET** /fake/jsonFormData | test json serialization of form data
|
||||
|
||||
|
||||
# **fake_outer_boolean_serialize**
|
||||
> OuterBoolean fake_outer_boolean_serialize(body=body)
|
||||
|
||||
|
||||
|
||||
Test serialization of outer boolean types
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi()
|
||||
body = petstore_api.OuterBoolean() # OuterBoolean | Input boolean as post body (optional)
|
||||
|
||||
try:
|
||||
api_response = api_instance.fake_outer_boolean_serialize(body=body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->fake_outer_boolean_serialize: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**OuterBoolean**](OuterBoolean.md)| Input boolean as post body | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**OuterBoolean**](OuterBoolean.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: Not defined
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **fake_outer_composite_serialize**
|
||||
> OuterComposite fake_outer_composite_serialize(body=body)
|
||||
|
||||
|
||||
|
||||
Test serialization of object with outer number type
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi()
|
||||
body = petstore_api.OuterComposite() # OuterComposite | Input composite as post body (optional)
|
||||
|
||||
try:
|
||||
api_response = api_instance.fake_outer_composite_serialize(body=body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->fake_outer_composite_serialize: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**OuterComposite**](OuterComposite.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: Not defined
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **fake_outer_number_serialize**
|
||||
> OuterNumber fake_outer_number_serialize(body=body)
|
||||
|
||||
|
||||
|
||||
Test serialization of outer number types
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi()
|
||||
body = petstore_api.OuterNumber() # OuterNumber | Input number as post body (optional)
|
||||
|
||||
try:
|
||||
api_response = api_instance.fake_outer_number_serialize(body=body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->fake_outer_number_serialize: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**OuterNumber**](OuterNumber.md)| Input number as post body | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**OuterNumber**](OuterNumber.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: Not defined
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **fake_outer_string_serialize**
|
||||
> OuterString fake_outer_string_serialize(body=body)
|
||||
|
||||
|
||||
|
||||
Test serialization of outer string types
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi()
|
||||
body = petstore_api.OuterString() # OuterString | Input string as post body (optional)
|
||||
|
||||
try:
|
||||
api_response = api_instance.fake_outer_string_serialize(body=body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->fake_outer_string_serialize: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**OuterString**](OuterString.md)| Input string as post body | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**OuterString**](OuterString.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: Not defined
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **test_client_model**
|
||||
> Client test_client_model(body)
|
||||
|
||||
To test \"client\" model
|
||||
|
||||
To test \"client\" model
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi()
|
||||
body = petstore_api.Client() # Client | client model
|
||||
|
||||
try:
|
||||
# To test \"client\" model
|
||||
api_response = api_instance.test_client_model(body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->test_client_model: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Client**](Client.md)| client model |
|
||||
|
||||
### Return type
|
||||
|
||||
[**Client**](Client.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **test_endpoint_parameters**
|
||||
> test_endpoint_parameters(number, double, pattern_without_delimiter, byte, integer=integer, int32=int32, int64=int64, float=float, string=string, binary=binary, date=date, date_time=date_time, password=password, param_callback=param_callback)
|
||||
|
||||
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
|
||||
Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure HTTP basic authorization: http_basic_test
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.username = 'YOUR_USERNAME'
|
||||
configuration.password = 'YOUR_PASSWORD'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi(petstore_api.ApiClient(configuration))
|
||||
number = 3.4 # float | None
|
||||
double = 1.2 # float | None
|
||||
pattern_without_delimiter = 'pattern_without_delimiter_example' # str | None
|
||||
byte = 'byte_example' # str | None
|
||||
integer = 56 # int | None (optional)
|
||||
int32 = 56 # int | None (optional)
|
||||
int64 = 789 # int | None (optional)
|
||||
float = 3.4 # float | None (optional)
|
||||
string = 'string_example' # str | None (optional)
|
||||
binary = 'B' # str | None (optional)
|
||||
date = '2013-10-20' # date | None (optional)
|
||||
date_time = '2013-10-20T19:20:30+01:00' # datetime | None (optional)
|
||||
password = 'password_example' # str | None (optional)
|
||||
param_callback = 'param_callback_example' # str | None (optional)
|
||||
|
||||
try:
|
||||
# Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
api_instance.test_endpoint_parameters(number, double, pattern_without_delimiter, byte, integer=integer, int32=int32, int64=int64, float=float, string=string, binary=binary, date=date, date_time=date_time, password=password, param_callback=param_callback)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->test_endpoint_parameters: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**number** | **float**| None |
|
||||
**double** | **float**| None |
|
||||
**pattern_without_delimiter** | **str**| None |
|
||||
**byte** | **str**| None |
|
||||
**integer** | **int**| None | [optional]
|
||||
**int32** | **int**| None | [optional]
|
||||
**int64** | **int**| None | [optional]
|
||||
**float** | **float**| None | [optional]
|
||||
**string** | **str**| None | [optional]
|
||||
**binary** | **str**| None | [optional]
|
||||
**date** | **date**| None | [optional]
|
||||
**date_time** | **datetime**| None | [optional]
|
||||
**password** | **str**| None | [optional]
|
||||
**param_callback** | **str**| None | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[http_basic_test](../README.md#http_basic_test)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/xml; charset=utf-8, application/json; charset=utf-8
|
||||
- **Accept**: application/xml; charset=utf-8, application/json; charset=utf-8
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **test_enum_parameters**
|
||||
> test_enum_parameters(enum_form_string_array=enum_form_string_array, enum_form_string=enum_form_string, enum_header_string_array=enum_header_string_array, enum_header_string=enum_header_string, enum_query_string_array=enum_query_string_array, enum_query_string=enum_query_string, enum_query_integer=enum_query_integer, enum_query_double=enum_query_double)
|
||||
|
||||
To test enum parameters
|
||||
|
||||
To test enum parameters
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi()
|
||||
enum_form_string_array = ['enum_form_string_array_example'] # list[str] | Form parameter enum test (string array) (optional)
|
||||
enum_form_string = '-efg' # str | Form parameter enum test (string) (optional) (default to -efg)
|
||||
enum_header_string_array = ['enum_header_string_array_example'] # list[str] | Header parameter enum test (string array) (optional)
|
||||
enum_header_string = '-efg' # str | Header parameter enum test (string) (optional) (default to -efg)
|
||||
enum_query_string_array = ['enum_query_string_array_example'] # list[str] | Query parameter enum test (string array) (optional)
|
||||
enum_query_string = '-efg' # str | Query parameter enum test (string) (optional) (default to -efg)
|
||||
enum_query_integer = 56 # int | Query parameter enum test (double) (optional)
|
||||
enum_query_double = 1.2 # float | Query parameter enum test (double) (optional)
|
||||
|
||||
try:
|
||||
# To test enum parameters
|
||||
api_instance.test_enum_parameters(enum_form_string_array=enum_form_string_array, enum_form_string=enum_form_string, enum_header_string_array=enum_header_string_array, enum_header_string=enum_header_string, enum_query_string_array=enum_query_string_array, enum_query_string=enum_query_string, enum_query_integer=enum_query_integer, enum_query_double=enum_query_double)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->test_enum_parameters: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**enum_form_string_array** | [**list[str]**](str.md)| Form parameter enum test (string array) | [optional]
|
||||
**enum_form_string** | **str**| Form parameter enum test (string) | [optional] [default to -efg]
|
||||
**enum_header_string_array** | [**list[str]**](str.md)| Header parameter enum test (string array) | [optional]
|
||||
**enum_header_string** | **str**| Header parameter enum test (string) | [optional] [default to -efg]
|
||||
**enum_query_string_array** | [**list[str]**](str.md)| Query parameter enum test (string array) | [optional]
|
||||
**enum_query_string** | **str**| Query parameter enum test (string) | [optional] [default to -efg]
|
||||
**enum_query_integer** | **int**| Query parameter enum test (double) | [optional]
|
||||
**enum_query_double** | **float**| Query parameter enum test (double) | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: */*
|
||||
- **Accept**: */*
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **test_json_form_data**
|
||||
> test_json_form_data(param, param2)
|
||||
|
||||
test json serialization of form data
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeApi()
|
||||
param = 'param_example' # str | field1
|
||||
param2 = 'param2_example' # str | field2
|
||||
|
||||
try:
|
||||
# test json serialization of form data
|
||||
api_instance.test_json_form_data(param, param2)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeApi->test_json_form_data: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**param** | **str**| field1 |
|
||||
**param2** | **str**| field2 |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: Not defined
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
@@ -0,0 +1,61 @@
|
||||
# petstore_api.FakeClassnameTags123Api
|
||||
|
||||
All URIs are relative to *http://petstore.swagger.io:80/v2*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**test_classname**](FakeClassnameTags123Api.md#test_classname) | **PATCH** /fake_classname_test | To test class name in snake case
|
||||
|
||||
|
||||
# **test_classname**
|
||||
> Client test_classname(body)
|
||||
|
||||
To test class name in snake case
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: api_key_query
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.api_key['api_key_query'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key_query'] = 'Bearer'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.FakeClassnameTags123Api(petstore_api.ApiClient(configuration))
|
||||
body = petstore_api.Client() # Client | client model
|
||||
|
||||
try:
|
||||
# To test class name in snake case
|
||||
api_response = api_instance.test_classname(body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling FakeClassnameTags123Api->test_classname: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Client**](Client.md)| client model |
|
||||
|
||||
### Return type
|
||||
|
||||
[**Client**](Client.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[api_key_query](../README.md#api_key_query)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json
|
||||
- **Accept**: application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
22
samples/client/petstore/python-asyncio/docs/FormatTest.md
Normal file
22
samples/client/petstore/python-asyncio/docs/FormatTest.md
Normal file
@@ -0,0 +1,22 @@
|
||||
# FormatTest
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**integer** | **int** | | [optional]
|
||||
**int32** | **int** | | [optional]
|
||||
**int64** | **int** | | [optional]
|
||||
**number** | **float** | |
|
||||
**float** | **float** | | [optional]
|
||||
**double** | **float** | | [optional]
|
||||
**string** | **str** | | [optional]
|
||||
**byte** | **str** | |
|
||||
**binary** | **str** | | [optional]
|
||||
**date** | **date** | |
|
||||
**date_time** | **datetime** | | [optional]
|
||||
**uuid** | **str** | | [optional]
|
||||
**password** | **str** | |
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
# HasOnlyReadOnly
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**bar** | **str** | | [optional]
|
||||
**foo** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
10
samples/client/petstore/python-asyncio/docs/List.md
Normal file
10
samples/client/petstore/python-asyncio/docs/List.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# List
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**_123_list** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
11
samples/client/petstore/python-asyncio/docs/MapTest.md
Normal file
11
samples/client/petstore/python-asyncio/docs/MapTest.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# MapTest
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**map_map_of_string** | [**dict(str, dict(str, str))**](dict.md) | | [optional]
|
||||
**map_of_enum_string** | **dict(str, str)** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
# MixedPropertiesAndAdditionalPropertiesClass
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**uuid** | **str** | | [optional]
|
||||
**date_time** | **datetime** | | [optional]
|
||||
**map** | [**dict(str, Animal)**](Animal.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
# Model200Response
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**name** | **int** | | [optional]
|
||||
**_class** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
10
samples/client/petstore/python-asyncio/docs/ModelReturn.md
Normal file
10
samples/client/petstore/python-asyncio/docs/ModelReturn.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# ModelReturn
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**_return** | **int** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
13
samples/client/petstore/python-asyncio/docs/Name.md
Normal file
13
samples/client/petstore/python-asyncio/docs/Name.md
Normal file
@@ -0,0 +1,13 @@
|
||||
# Name
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**name** | **int** | |
|
||||
**snake_case** | **int** | | [optional]
|
||||
**_property** | **str** | | [optional]
|
||||
**_123_number** | **int** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
10
samples/client/petstore/python-asyncio/docs/NumberOnly.md
Normal file
10
samples/client/petstore/python-asyncio/docs/NumberOnly.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# NumberOnly
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**just_number** | **float** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
15
samples/client/petstore/python-asyncio/docs/Order.md
Normal file
15
samples/client/petstore/python-asyncio/docs/Order.md
Normal file
@@ -0,0 +1,15 @@
|
||||
# Order
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**id** | **int** | | [optional]
|
||||
**pet_id** | **int** | | [optional]
|
||||
**quantity** | **int** | | [optional]
|
||||
**ship_date** | **datetime** | | [optional]
|
||||
**status** | **str** | Order Status | [optional]
|
||||
**complete** | **bool** | | [optional] [default to False]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
# OuterBoolean
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
# OuterComposite
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**my_number** | [**OuterNumber**](OuterNumber.md) | | [optional]
|
||||
**my_string** | [**OuterString**](OuterString.md) | | [optional]
|
||||
**my_boolean** | [**OuterBoolean**](OuterBoolean.md) | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
9
samples/client/petstore/python-asyncio/docs/OuterEnum.md
Normal file
9
samples/client/petstore/python-asyncio/docs/OuterEnum.md
Normal file
@@ -0,0 +1,9 @@
|
||||
# OuterEnum
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
# OuterNumber
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
# OuterString
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
15
samples/client/petstore/python-asyncio/docs/Pet.md
Normal file
15
samples/client/petstore/python-asyncio/docs/Pet.md
Normal file
@@ -0,0 +1,15 @@
|
||||
# Pet
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**id** | **int** | | [optional]
|
||||
**category** | [**Category**](Category.md) | | [optional]
|
||||
**name** | **str** | |
|
||||
**photo_urls** | **list[str]** | |
|
||||
**tags** | [**list[Tag]**](Tag.md) | | [optional]
|
||||
**status** | **str** | pet status in the store | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
440
samples/client/petstore/python-asyncio/docs/PetApi.md
Normal file
440
samples/client/petstore/python-asyncio/docs/PetApi.md
Normal file
@@ -0,0 +1,440 @@
|
||||
# petstore_api.PetApi
|
||||
|
||||
All URIs are relative to *http://petstore.swagger.io:80/v2*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**add_pet**](PetApi.md#add_pet) | **POST** /pet | Add a new pet to the store
|
||||
[**delete_pet**](PetApi.md#delete_pet) | **DELETE** /pet/{petId} | Deletes a pet
|
||||
[**find_pets_by_status**](PetApi.md#find_pets_by_status) | **GET** /pet/findByStatus | Finds Pets by status
|
||||
[**find_pets_by_tags**](PetApi.md#find_pets_by_tags) | **GET** /pet/findByTags | Finds Pets by tags
|
||||
[**get_pet_by_id**](PetApi.md#get_pet_by_id) | **GET** /pet/{petId} | Find pet by ID
|
||||
[**update_pet**](PetApi.md#update_pet) | **PUT** /pet | Update an existing pet
|
||||
[**update_pet_with_form**](PetApi.md#update_pet_with_form) | **POST** /pet/{petId} | Updates a pet in the store with form data
|
||||
[**upload_file**](PetApi.md#upload_file) | **POST** /pet/{petId}/uploadImage | uploads an image
|
||||
|
||||
|
||||
# **add_pet**
|
||||
> add_pet(body)
|
||||
|
||||
Add a new pet to the store
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
body = petstore_api.Pet() # Pet | Pet object that needs to be added to the store
|
||||
|
||||
try:
|
||||
# Add a new pet to the store
|
||||
api_instance.add_pet(body)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->add_pet: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json, application/xml
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **delete_pet**
|
||||
> delete_pet(pet_id, api_key=api_key)
|
||||
|
||||
Deletes a pet
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
pet_id = 789 # int | Pet id to delete
|
||||
api_key = 'api_key_example' # str | (optional)
|
||||
|
||||
try:
|
||||
# Deletes a pet
|
||||
api_instance.delete_pet(pet_id, api_key=api_key)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->delete_pet: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **int**| Pet id to delete |
|
||||
**api_key** | **str**| | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **find_pets_by_status**
|
||||
> list[Pet] find_pets_by_status(status)
|
||||
|
||||
Finds Pets by status
|
||||
|
||||
Multiple status values can be provided with comma separated strings
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
status = ['status_example'] # list[str] | Status values that need to be considered for filter
|
||||
|
||||
try:
|
||||
# Finds Pets by status
|
||||
api_response = api_instance.find_pets_by_status(status)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->find_pets_by_status: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
|
||||
|
||||
### Return type
|
||||
|
||||
[**list[Pet]**](Pet.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **find_pets_by_tags**
|
||||
> list[Pet] find_pets_by_tags(tags)
|
||||
|
||||
Finds Pets by tags
|
||||
|
||||
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
tags = ['tags_example'] # list[str] | Tags to filter by
|
||||
|
||||
try:
|
||||
# Finds Pets by tags
|
||||
api_response = api_instance.find_pets_by_tags(tags)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->find_pets_by_tags: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**tags** | [**list[str]**](str.md)| Tags to filter by |
|
||||
|
||||
### Return type
|
||||
|
||||
[**list[Pet]**](Pet.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **get_pet_by_id**
|
||||
> Pet get_pet_by_id(pet_id)
|
||||
|
||||
Find pet by ID
|
||||
|
||||
Returns a single pet
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.api_key['api_key'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
pet_id = 789 # int | ID of pet to return
|
||||
|
||||
try:
|
||||
# Find pet by ID
|
||||
api_response = api_instance.get_pet_by_id(pet_id)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->get_pet_by_id: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **int**| ID of pet to return |
|
||||
|
||||
### Return type
|
||||
|
||||
[**Pet**](Pet.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[api_key](../README.md#api_key)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **update_pet**
|
||||
> update_pet(body)
|
||||
|
||||
Update an existing pet
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
body = petstore_api.Pet() # Pet | Pet object that needs to be added to the store
|
||||
|
||||
try:
|
||||
# Update an existing pet
|
||||
api_instance.update_pet(body)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->update_pet: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json, application/xml
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **update_pet_with_form**
|
||||
> update_pet_with_form(pet_id, name=name, status=status)
|
||||
|
||||
Updates a pet in the store with form data
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
pet_id = 789 # int | ID of pet that needs to be updated
|
||||
name = 'name_example' # str | Updated name of the pet (optional)
|
||||
status = 'status_example' # str | Updated status of the pet (optional)
|
||||
|
||||
try:
|
||||
# Updates a pet in the store with form data
|
||||
api_instance.update_pet_with_form(pet_id, name=name, status=status)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->update_pet_with_form: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **int**| ID of pet that needs to be updated |
|
||||
**name** | **str**| Updated name of the pet | [optional]
|
||||
**status** | **str**| Updated status of the pet | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/x-www-form-urlencoded
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **upload_file**
|
||||
> ApiResponse upload_file(pet_id, additional_metadata=additional_metadata, file=file)
|
||||
|
||||
uploads an image
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.PetApi(petstore_api.ApiClient(configuration))
|
||||
pet_id = 789 # int | ID of pet to update
|
||||
additional_metadata = 'additional_metadata_example' # str | Additional data to pass to server (optional)
|
||||
file = '/path/to/file.txt' # file | file to upload (optional)
|
||||
|
||||
try:
|
||||
# uploads an image
|
||||
api_response = api_instance.upload_file(pet_id, additional_metadata=additional_metadata, file=file)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling PetApi->upload_file: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **int**| ID of pet to update |
|
||||
**additional_metadata** | **str**| Additional data to pass to server | [optional]
|
||||
**file** | **file**| file to upload | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
[**ApiResponse**](ApiResponse.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: multipart/form-data
|
||||
- **Accept**: application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
11
samples/client/petstore/python-asyncio/docs/ReadOnlyFirst.md
Normal file
11
samples/client/petstore/python-asyncio/docs/ReadOnlyFirst.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# ReadOnlyFirst
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**bar** | **str** | | [optional]
|
||||
**baz** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
# SpecialModelName
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**special_property_name** | **int** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
205
samples/client/petstore/python-asyncio/docs/StoreApi.md
Normal file
205
samples/client/petstore/python-asyncio/docs/StoreApi.md
Normal file
@@ -0,0 +1,205 @@
|
||||
# petstore_api.StoreApi
|
||||
|
||||
All URIs are relative to *http://petstore.swagger.io:80/v2*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**delete_order**](StoreApi.md#delete_order) | **DELETE** /store/order/{order_id} | Delete purchase order by ID
|
||||
[**get_inventory**](StoreApi.md#get_inventory) | **GET** /store/inventory | Returns pet inventories by status
|
||||
[**get_order_by_id**](StoreApi.md#get_order_by_id) | **GET** /store/order/{order_id} | Find purchase order by ID
|
||||
[**place_order**](StoreApi.md#place_order) | **POST** /store/order | Place an order for a pet
|
||||
|
||||
|
||||
# **delete_order**
|
||||
> delete_order(order_id)
|
||||
|
||||
Delete purchase order by ID
|
||||
|
||||
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.StoreApi()
|
||||
order_id = 'order_id_example' # str | ID of the order that needs to be deleted
|
||||
|
||||
try:
|
||||
# Delete purchase order by ID
|
||||
api_instance.delete_order(order_id)
|
||||
except ApiException as e:
|
||||
print("Exception when calling StoreApi->delete_order: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**order_id** | **str**| ID of the order that needs to be deleted |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **get_inventory**
|
||||
> dict(str, int) get_inventory()
|
||||
|
||||
Returns pet inventories by status
|
||||
|
||||
Returns a map of status codes to quantities
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
configuration = petstore_api.Configuration()
|
||||
configuration.api_key['api_key'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
|
||||
# configuration.api_key_prefix['api_key'] = 'Bearer'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.StoreApi(petstore_api.ApiClient(configuration))
|
||||
|
||||
try:
|
||||
# Returns pet inventories by status
|
||||
api_response = api_instance.get_inventory()
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling StoreApi->get_inventory: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
This endpoint does not need any parameter.
|
||||
|
||||
### Return type
|
||||
|
||||
**dict(str, int)**
|
||||
|
||||
### Authorization
|
||||
|
||||
[api_key](../README.md#api_key)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **get_order_by_id**
|
||||
> Order get_order_by_id(order_id)
|
||||
|
||||
Find purchase order by ID
|
||||
|
||||
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.StoreApi()
|
||||
order_id = 789 # int | ID of pet that needs to be fetched
|
||||
|
||||
try:
|
||||
# Find purchase order by ID
|
||||
api_response = api_instance.get_order_by_id(order_id)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling StoreApi->get_order_by_id: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**order_id** | **int**| ID of pet that needs to be fetched |
|
||||
|
||||
### Return type
|
||||
|
||||
[**Order**](Order.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **place_order**
|
||||
> Order place_order(body)
|
||||
|
||||
Place an order for a pet
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.StoreApi()
|
||||
body = petstore_api.Order() # Order | order placed for purchasing the pet
|
||||
|
||||
try:
|
||||
# Place an order for a pet
|
||||
api_response = api_instance.place_order(body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling StoreApi->place_order: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Order**](Order.md)| order placed for purchasing the pet |
|
||||
|
||||
### Return type
|
||||
|
||||
[**Order**](Order.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
11
samples/client/petstore/python-asyncio/docs/Tag.md
Normal file
11
samples/client/petstore/python-asyncio/docs/Tag.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# Tag
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**id** | **int** | | [optional]
|
||||
**name** | **str** | | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
17
samples/client/petstore/python-asyncio/docs/User.md
Normal file
17
samples/client/petstore/python-asyncio/docs/User.md
Normal file
@@ -0,0 +1,17 @@
|
||||
# User
|
||||
|
||||
## Properties
|
||||
Name | Type | Description | Notes
|
||||
------------ | ------------- | ------------- | -------------
|
||||
**id** | **int** | | [optional]
|
||||
**username** | **str** | | [optional]
|
||||
**first_name** | **str** | | [optional]
|
||||
**last_name** | **str** | | [optional]
|
||||
**email** | **str** | | [optional]
|
||||
**password** | **str** | | [optional]
|
||||
**phone** | **str** | | [optional]
|
||||
**user_status** | **int** | User Status | [optional]
|
||||
|
||||
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
||||
|
||||
|
||||
394
samples/client/petstore/python-asyncio/docs/UserApi.md
Normal file
394
samples/client/petstore/python-asyncio/docs/UserApi.md
Normal file
@@ -0,0 +1,394 @@
|
||||
# petstore_api.UserApi
|
||||
|
||||
All URIs are relative to *http://petstore.swagger.io:80/v2*
|
||||
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**create_user**](UserApi.md#create_user) | **POST** /user | Create user
|
||||
[**create_users_with_array_input**](UserApi.md#create_users_with_array_input) | **POST** /user/createWithArray | Creates list of users with given input array
|
||||
[**create_users_with_list_input**](UserApi.md#create_users_with_list_input) | **POST** /user/createWithList | Creates list of users with given input array
|
||||
[**delete_user**](UserApi.md#delete_user) | **DELETE** /user/{username} | Delete user
|
||||
[**get_user_by_name**](UserApi.md#get_user_by_name) | **GET** /user/{username} | Get user by user name
|
||||
[**login_user**](UserApi.md#login_user) | **GET** /user/login | Logs user into the system
|
||||
[**logout_user**](UserApi.md#logout_user) | **GET** /user/logout | Logs out current logged in user session
|
||||
[**update_user**](UserApi.md#update_user) | **PUT** /user/{username} | Updated user
|
||||
|
||||
|
||||
# **create_user**
|
||||
> create_user(body)
|
||||
|
||||
Create user
|
||||
|
||||
This can only be done by the logged in user.
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
body = petstore_api.User() # User | Created user object
|
||||
|
||||
try:
|
||||
# Create user
|
||||
api_instance.create_user(body)
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->create_user: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**User**](User.md)| Created user object |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **create_users_with_array_input**
|
||||
> create_users_with_array_input(body)
|
||||
|
||||
Creates list of users with given input array
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
body = [petstore_api.User()] # list[User] | List of user object
|
||||
|
||||
try:
|
||||
# Creates list of users with given input array
|
||||
api_instance.create_users_with_array_input(body)
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->create_users_with_array_input: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**list[User]**](User.md)| List of user object |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **create_users_with_list_input**
|
||||
> create_users_with_list_input(body)
|
||||
|
||||
Creates list of users with given input array
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
body = [petstore_api.User()] # list[User] | List of user object
|
||||
|
||||
try:
|
||||
# Creates list of users with given input array
|
||||
api_instance.create_users_with_list_input(body)
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->create_users_with_list_input: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**list[User]**](User.md)| List of user object |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **delete_user**
|
||||
> delete_user(username)
|
||||
|
||||
Delete user
|
||||
|
||||
This can only be done by the logged in user.
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
username = 'username_example' # str | The name that needs to be deleted
|
||||
|
||||
try:
|
||||
# Delete user
|
||||
api_instance.delete_user(username)
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->delete_user: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**username** | **str**| The name that needs to be deleted |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **get_user_by_name**
|
||||
> User get_user_by_name(username)
|
||||
|
||||
Get user by user name
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
username = 'username_example' # str | The name that needs to be fetched. Use user1 for testing.
|
||||
|
||||
try:
|
||||
# Get user by user name
|
||||
api_response = api_instance.get_user_by_name(username)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->get_user_by_name: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**username** | **str**| The name that needs to be fetched. Use user1 for testing. |
|
||||
|
||||
### Return type
|
||||
|
||||
[**User**](User.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **login_user**
|
||||
> str login_user(username, password)
|
||||
|
||||
Logs user into the system
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
username = 'username_example' # str | The user name for login
|
||||
password = 'password_example' # str | The password for login in clear text
|
||||
|
||||
try:
|
||||
# Logs user into the system
|
||||
api_response = api_instance.login_user(username, password)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->login_user: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**username** | **str**| The user name for login |
|
||||
**password** | **str**| The password for login in clear text |
|
||||
|
||||
### Return type
|
||||
|
||||
**str**
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **logout_user**
|
||||
> logout_user()
|
||||
|
||||
Logs out current logged in user session
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
|
||||
try:
|
||||
# Logs out current logged in user session
|
||||
api_instance.logout_user()
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->logout_user: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
This endpoint does not need any parameter.
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
# **update_user**
|
||||
> update_user(username, body)
|
||||
|
||||
Updated user
|
||||
|
||||
This can only be done by the logged in user.
|
||||
|
||||
### Example
|
||||
```python
|
||||
from __future__ import print_function
|
||||
import time
|
||||
import petstore_api
|
||||
from petstore_api.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = petstore_api.UserApi()
|
||||
username = 'username_example' # str | name that need to be deleted
|
||||
body = petstore_api.User() # User | Updated user object
|
||||
|
||||
try:
|
||||
# Updated user
|
||||
api_instance.update_user(username, body)
|
||||
except ApiException as e:
|
||||
print("Exception when calling UserApi->update_user: %s\n" % e)
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**username** | **str**| name that need to be deleted |
|
||||
**body** | [**User**](User.md)| Updated user object |
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/xml, application/json
|
||||
|
||||
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
||||
|
||||
Reference in New Issue
Block a user