mirror of
https://github.com/valitydev/openapi-generator.git
synced 2024-11-08 03:18:53 +00:00
Update required packages to latest stable version
This commit is contained in:
parent
25ccb250cc
commit
79bbab04ec
@ -15,7 +15,7 @@ VERSION = "{{packageVersion}}"
|
||||
# prerequisite: setuptools
|
||||
# http://pypi.python.org/pypi/setuptools
|
||||
|
||||
REQUIRES = ["urllib3 >= 1.10", "six >= 1.9", "certifi", "python-dateutil"]
|
||||
REQUIRES = ["urllib3 >= 1.15", "six >= 1.10", "certifi", "python-dateutil"]
|
||||
|
||||
setup(
|
||||
name=NAME,
|
||||
|
@ -5,7 +5,7 @@ This Python package is automatically generated by the [Swagger Codegen](https://
|
||||
|
||||
- API version: 1.0.0
|
||||
- Package version: 1.0.0
|
||||
- Build date: 2016-04-14T17:57:34.564+08:00
|
||||
- Build date: 2016-04-19T21:05:59.494+01:00
|
||||
- Build package: class io.swagger.codegen.languages.PythonClientCodegen
|
||||
|
||||
## Requirements.
|
||||
|
@ -5,20 +5,17 @@ All URIs are relative to *http://petstore.swagger.io/v2*
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**add_pet**](PetApi.md#add_pet) | **POST** /pet | Add a new pet to the store
|
||||
[**add_pet_using_byte_array**](PetApi.md#add_pet_using_byte_array) | **POST** /pet?testing_byte_array=true | Fake endpoint to test byte array in body parameter for adding 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
|
||||
[**get_pet_by_id_in_object**](PetApi.md#get_pet_by_id_in_object) | **GET** /pet/{petId}?response=inline_arbitrary_object | Fake endpoint to test inline arbitrary object return by 'Find pet by ID'
|
||||
[**pet_pet_idtesting_byte_arraytrue_get**](PetApi.md#pet_pet_idtesting_byte_arraytrue_get) | **GET** /pet/{petId}?testing_byte_array=true | Fake endpoint to test byte array return by '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=body)
|
||||
> add_pet(body)
|
||||
|
||||
Add a new pet to the store
|
||||
|
||||
@ -36,11 +33,11 @@ swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
body = swagger_client.Pet() # Pet | Pet object that needs to be added to the store (optional)
|
||||
body = swagger_client.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=body)
|
||||
api_instance.add_pet(body)
|
||||
except ApiException as e:
|
||||
print "Exception when calling PetApi->add_pet: %s\n" % e
|
||||
```
|
||||
@ -49,7 +46,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | [optional]
|
||||
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -62,56 +59,7 @@ void (empty response body)
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json, application/xml
|
||||
- **Accept**: application/json, application/xml
|
||||
|
||||
[[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)
|
||||
|
||||
# **add_pet_using_byte_array**
|
||||
> add_pet_using_byte_array(body=body)
|
||||
|
||||
Fake endpoint to test byte array in body parameter for adding a new pet to the store
|
||||
|
||||
|
||||
|
||||
### Example
|
||||
```python
|
||||
import time
|
||||
import swagger_client
|
||||
from swagger_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
body = 'B' # str | Pet object in the form of byte array (optional)
|
||||
|
||||
try:
|
||||
# Fake endpoint to test byte array in body parameter for adding a new pet to the store
|
||||
api_instance.add_pet_using_byte_array(body=body)
|
||||
except ApiException as e:
|
||||
print "Exception when calling PetApi->add_pet_using_byte_array: %s\n" % e
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | **str**| Pet object in the form of byte array | [optional]
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
|
||||
### Authorization
|
||||
|
||||
[petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json, application/xml
|
||||
- **Accept**: 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)
|
||||
|
||||
@ -162,12 +110,12 @@ void (empty response body)
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
# **find_pets_by_status**
|
||||
> list[Pet] find_pets_by_status(status=status)
|
||||
> list[Pet] find_pets_by_status(status)
|
||||
|
||||
Finds Pets by status
|
||||
|
||||
@ -185,11 +133,11 @@ swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
status = ['available'] # list[str] | Status values that need to be considered for query (optional) (default to available)
|
||||
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=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
|
||||
@ -199,7 +147,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**status** | [**list[str]**](str.md)| Status values that need to be considered for query | [optional] [default to available]
|
||||
**status** | [**list[str]**](str.md)| Status values that need to be considered for filter |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -212,16 +160,16 @@ Name | Type | Description | Notes
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
# **find_pets_by_tags**
|
||||
> list[Pet] find_pets_by_tags(tags=tags)
|
||||
> list[Pet] find_pets_by_tags(tags)
|
||||
|
||||
Finds Pets by tags
|
||||
|
||||
Muliple tags can be provided with comma seperated strings. Use tag1, tag2, tag3 for testing.
|
||||
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
|
||||
|
||||
### Example
|
||||
```python
|
||||
@ -235,11 +183,11 @@ swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
tags = ['tags_example'] # list[str] | Tags to filter by (optional)
|
||||
tags = ['tags_example'] # list[str] | Tags to filter by
|
||||
|
||||
try:
|
||||
# Finds Pets by tags
|
||||
api_response = api_instance.find_pets_by_tags(tags=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
|
||||
@ -249,7 +197,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**tags** | [**list[str]**](str.md)| Tags to filter by | [optional]
|
||||
**tags** | [**list[str]**](str.md)| Tags to filter by |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -262,7 +210,7 @@ Name | Type | Description | Notes
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
@ -271,7 +219,7 @@ Name | Type | Description | Notes
|
||||
|
||||
Find pet by ID
|
||||
|
||||
Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions
|
||||
Returns a single pet
|
||||
|
||||
### Example
|
||||
```python
|
||||
@ -284,12 +232,10 @@ from pprint import pprint
|
||||
swagger_client.configuration.api_key['api_key'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['api_key'] = 'BEARER'
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
pet_id = 789 # int | ID of pet that needs to be fetched
|
||||
pet_id = 789 # int | ID of pet to return
|
||||
|
||||
try:
|
||||
# Find pet by ID
|
||||
@ -303,7 +249,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **int**| ID of pet that needs to be fetched |
|
||||
**pet_id** | **int**| ID of pet to return |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -311,125 +257,17 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[api_key](../README.md#api_key), [petstore_auth](../README.md#petstore_auth)
|
||||
[api_key](../README.md#api_key)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json, application/xml
|
||||
|
||||
[[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_in_object**
|
||||
> InlineResponse200 get_pet_by_id_in_object(pet_id)
|
||||
|
||||
Fake endpoint to test inline arbitrary object return by 'Find pet by ID'
|
||||
|
||||
Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions
|
||||
|
||||
### Example
|
||||
```python
|
||||
import time
|
||||
import swagger_client
|
||||
from swagger_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
swagger_client.configuration.api_key['api_key'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['api_key'] = 'BEARER'
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
pet_id = 789 # int | ID of pet that needs to be fetched
|
||||
|
||||
try:
|
||||
# Fake endpoint to test inline arbitrary object return by 'Find pet by ID'
|
||||
api_response = api_instance.get_pet_by_id_in_object(pet_id)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print "Exception when calling PetApi->get_pet_by_id_in_object: %s\n" % e
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **int**| ID of pet that needs to be fetched |
|
||||
|
||||
### Return type
|
||||
|
||||
[**InlineResponse200**](InlineResponse200.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[api_key](../README.md#api_key), [petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json, application/xml
|
||||
|
||||
[[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)
|
||||
|
||||
# **pet_pet_idtesting_byte_arraytrue_get**
|
||||
> str pet_pet_idtesting_byte_arraytrue_get(pet_id)
|
||||
|
||||
Fake endpoint to test byte array return by 'Find pet by ID'
|
||||
|
||||
Returns a pet when ID < 10. ID > 10 or nonintegers will simulate API error conditions
|
||||
|
||||
### Example
|
||||
```python
|
||||
import time
|
||||
import swagger_client
|
||||
from swagger_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
swagger_client.configuration.api_key['api_key'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['api_key'] = 'BEARER'
|
||||
# Configure OAuth2 access token for authorization: petstore_auth
|
||||
swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
pet_id = 789 # int | ID of pet that needs to be fetched
|
||||
|
||||
try:
|
||||
# Fake endpoint to test byte array return by 'Find pet by ID'
|
||||
api_response = api_instance.pet_pet_idtesting_byte_arraytrue_get(pet_id)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print "Exception when calling PetApi->pet_pet_idtesting_byte_arraytrue_get: %s\n" % e
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **int**| ID of pet that needs to be fetched |
|
||||
|
||||
### Return type
|
||||
|
||||
**str**
|
||||
|
||||
### Authorization
|
||||
|
||||
[api_key](../README.md#api_key), [petstore_auth](../README.md#petstore_auth)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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**
|
||||
> update_pet(body=body)
|
||||
> update_pet(body)
|
||||
|
||||
Update an existing pet
|
||||
|
||||
@ -447,11 +285,11 @@ swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
body = swagger_client.Pet() # Pet | Pet object that needs to be added to the store (optional)
|
||||
body = swagger_client.Pet() # Pet | Pet object that needs to be added to the store
|
||||
|
||||
try:
|
||||
# Update an existing pet
|
||||
api_instance.update_pet(body=body)
|
||||
api_instance.update_pet(body)
|
||||
except ApiException as e:
|
||||
print "Exception when calling PetApi->update_pet: %s\n" % e
|
||||
```
|
||||
@ -460,7 +298,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | [optional]
|
||||
**body** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -473,7 +311,7 @@ void (empty response body)
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/json, application/xml
|
||||
- **Accept**: 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)
|
||||
|
||||
@ -496,7 +334,7 @@ swagger_client.configuration.access_token = 'YOUR_ACCESS_TOKEN'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.PetApi()
|
||||
pet_id = 'pet_id_example' # str | ID of pet that needs to be updated
|
||||
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)
|
||||
|
||||
@ -511,7 +349,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**pet_id** | **str**| ID of pet that needs to be updated |
|
||||
**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]
|
||||
|
||||
@ -526,12 +364,12 @@ void (empty response body)
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: application/x-www-form-urlencoded
|
||||
- **Accept**: 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)
|
||||
|
||||
# **upload_file**
|
||||
> upload_file(pet_id, additional_metadata=additional_metadata, file=file)
|
||||
> ApiResponse upload_file(pet_id, additional_metadata=additional_metadata, file=file)
|
||||
|
||||
uploads an image
|
||||
|
||||
@ -555,7 +393,8 @@ file = '/path/to/file.txt' # file | file to upload (optional)
|
||||
|
||||
try:
|
||||
# uploads an image
|
||||
api_instance.upload_file(pet_id, additional_metadata=additional_metadata, file=file)
|
||||
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
|
||||
```
|
||||
@ -570,7 +409,7 @@ Name | Type | Description | Notes
|
||||
|
||||
### Return type
|
||||
|
||||
void (empty response body)
|
||||
[**ApiResponse**](ApiResponse.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
@ -579,7 +418,7 @@ void (empty response body)
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: multipart/form-data
|
||||
- **Accept**: application/json, application/xml
|
||||
- **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)
|
||||
|
||||
|
@ -5,9 +5,7 @@ All URIs are relative to *http://petstore.swagger.io/v2*
|
||||
Method | HTTP request | Description
|
||||
------------- | ------------- | -------------
|
||||
[**delete_order**](StoreApi.md#delete_order) | **DELETE** /store/order/{orderId} | Delete purchase order by ID
|
||||
[**find_orders_by_status**](StoreApi.md#find_orders_by_status) | **GET** /store/findByStatus | Finds orders by status
|
||||
[**get_inventory**](StoreApi.md#get_inventory) | **GET** /store/inventory | Returns pet inventories by status
|
||||
[**get_inventory_in_object**](StoreApi.md#get_inventory_in_object) | **GET** /store/inventory?response=arbitrary_object | Fake endpoint to test arbitrary object return by 'Get inventory'
|
||||
[**get_order_by_id**](StoreApi.md#get_order_by_id) | **GET** /store/order/{orderId} | Find purchase order by ID
|
||||
[**place_order**](StoreApi.md#place_order) | **POST** /store/order | Place an order for a pet
|
||||
|
||||
@ -54,63 +52,7 @@ No authorization required
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json, application/xml
|
||||
|
||||
[[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_orders_by_status**
|
||||
> list[Order] find_orders_by_status(status=status)
|
||||
|
||||
Finds orders by status
|
||||
|
||||
A single status value can be provided as a string
|
||||
|
||||
### Example
|
||||
```python
|
||||
import time
|
||||
import swagger_client
|
||||
from swagger_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: test_api_client_id
|
||||
swagger_client.configuration.api_key['x-test_api_client_id'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['x-test_api_client_id'] = 'BEARER'
|
||||
# Configure API key authorization: test_api_client_secret
|
||||
swagger_client.configuration.api_key['x-test_api_client_secret'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['x-test_api_client_secret'] = 'BEARER'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.StoreApi()
|
||||
status = 'placed' # str | Status value that needs to be considered for query (optional) (default to placed)
|
||||
|
||||
try:
|
||||
# Finds orders by status
|
||||
api_response = api_instance.find_orders_by_status(status=status)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print "Exception when calling StoreApi->find_orders_by_status: %s\n" % e
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**status** | **str**| Status value that needs to be considered for query | [optional] [default to placed]
|
||||
|
||||
### Return type
|
||||
|
||||
[**list[Order]**](Order.md)
|
||||
|
||||
### Authorization
|
||||
|
||||
[test_api_client_id](../README.md#test_api_client_id), [test_api_client_secret](../README.md#test_api_client_secret)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
@ -158,55 +100,7 @@ This endpoint does not need any parameter.
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json, application/xml
|
||||
|
||||
[[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_in_object**
|
||||
> object get_inventory_in_object()
|
||||
|
||||
Fake endpoint to test arbitrary object return by 'Get inventory'
|
||||
|
||||
Returns an arbitrary object which is actually a map of status codes to quantities
|
||||
|
||||
### Example
|
||||
```python
|
||||
import time
|
||||
import swagger_client
|
||||
from swagger_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: api_key
|
||||
swagger_client.configuration.api_key['api_key'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['api_key'] = 'BEARER'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.StoreApi()
|
||||
|
||||
try:
|
||||
# Fake endpoint to test arbitrary object return by 'Get inventory'
|
||||
api_response = api_instance.get_inventory_in_object()
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print "Exception when calling StoreApi->get_inventory_in_object: %s\n" % e
|
||||
```
|
||||
|
||||
### Parameters
|
||||
This endpoint does not need any parameter.
|
||||
|
||||
### Return type
|
||||
|
||||
**object**
|
||||
|
||||
### Authorization
|
||||
|
||||
[api_key](../README.md#api_key)
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: application/json, application/xml
|
||||
- **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)
|
||||
|
||||
@ -224,18 +118,9 @@ import swagger_client
|
||||
from swagger_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: test_api_key_header
|
||||
swagger_client.configuration.api_key['test_api_key_header'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['test_api_key_header'] = 'BEARER'
|
||||
# Configure API key authorization: test_api_key_query
|
||||
swagger_client.configuration.api_key['test_api_key_query'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['test_api_key_query'] = 'BEARER'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.StoreApi()
|
||||
order_id = 'order_id_example' # str | ID of pet that needs to be fetched
|
||||
order_id = 789 # int | ID of pet that needs to be fetched
|
||||
|
||||
try:
|
||||
# Find purchase order by ID
|
||||
@ -249,7 +134,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**order_id** | **str**| ID of pet that needs to be fetched |
|
||||
**order_id** | **int**| ID of pet that needs to be fetched |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -257,17 +142,17 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[test_api_key_header](../README.md#test_api_key_header), [test_api_key_query](../README.md#test_api_key_query)
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
# **place_order**
|
||||
> Order place_order(body=body)
|
||||
> Order place_order(body)
|
||||
|
||||
Place an order for a pet
|
||||
|
||||
@ -280,22 +165,13 @@ import swagger_client
|
||||
from swagger_client.rest import ApiException
|
||||
from pprint import pprint
|
||||
|
||||
# Configure API key authorization: test_api_client_id
|
||||
swagger_client.configuration.api_key['x-test_api_client_id'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['x-test_api_client_id'] = 'BEARER'
|
||||
# Configure API key authorization: test_api_client_secret
|
||||
swagger_client.configuration.api_key['x-test_api_client_secret'] = 'YOUR_API_KEY'
|
||||
# Uncomment below to setup prefix (e.g. BEARER) for API key, if needed
|
||||
# swagger_client.configuration.api_key_prefix['x-test_api_client_secret'] = 'BEARER'
|
||||
|
||||
# create an instance of the API class
|
||||
api_instance = swagger_client.StoreApi()
|
||||
body = swagger_client.Order() # Order | order placed for purchasing the pet (optional)
|
||||
body = swagger_client.Order() # Order | order placed for purchasing the pet
|
||||
|
||||
try:
|
||||
# Place an order for a pet
|
||||
api_response = api_instance.place_order(body=body)
|
||||
api_response = api_instance.place_order(body)
|
||||
pprint(api_response)
|
||||
except ApiException as e:
|
||||
print "Exception when calling StoreApi->place_order: %s\n" % e
|
||||
@ -305,7 +181,7 @@ except ApiException as e:
|
||||
|
||||
Name | Type | Description | Notes
|
||||
------------- | ------------- | ------------- | -------------
|
||||
**body** | [**Order**](Order.md)| order placed for purchasing the pet | [optional]
|
||||
**body** | [**Order**](Order.md)| order placed for purchasing the pet |
|
||||
|
||||
### Return type
|
||||
|
||||
@ -313,12 +189,12 @@ Name | Type | Description | Notes
|
||||
|
||||
### Authorization
|
||||
|
||||
[test_api_client_id](../README.md#test_api_client_id), [test_api_client_secret](../README.md#test_api_client_secret)
|
||||
No authorization required
|
||||
|
||||
### HTTP request headers
|
||||
|
||||
- **Content-Type**: Not defined
|
||||
- **Accept**: 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)
|
||||
|
||||
|
@ -15,7 +15,7 @@ VERSION = "1.0.0"
|
||||
# prerequisite: setuptools
|
||||
# http://pypi.python.org/pypi/setuptools
|
||||
|
||||
REQUIRES = ["urllib3 >= 1.10", "six >= 1.9", "certifi", "python-dateutil"]
|
||||
REQUIRES = ["urllib3 >= 1.15", "six >= 1.10", "certifi", "python-dateutil"]
|
||||
|
||||
setup(
|
||||
name=NAME,
|
||||
|
@ -1,4 +1,4 @@
|
||||
urllib3 >= 1.10
|
||||
six >= 1.9
|
||||
urllib3 >= 1.15
|
||||
six >= 1.10
|
||||
certifi
|
||||
python-dateutil
|
||||
|
Loading…
Reference in New Issue
Block a user