petstore_api.UserApi
All URIs are relative to http://petstore.swagger.io:80/v2
create_user
create_user(user)
Create user
This can only be done by the logged in user.
Example
Parameters
| Name |
Type |
Description |
Notes |
| body |
typing.Union[SchemaForRequestBodyApplicationJson] |
required |
|
| content_type |
str |
optional, default is 'application/json' |
Selects the schema and serialization of the request body |
| stream |
bool |
default is False |
if True then the response.content will be streamed and loaded from a file like object. When downloading a file, set this to True to force the code to deserialize the content to a FileSchema file |
| timeout |
typing.Optional[typing.Union[int, typing.Tuple]] |
default is None |
the timeout used by the rest client |
| skip_deserialization |
bool |
default is False |
when True, headers and body will be unset and an instance of api_client.ApiResponseWithoutDeserialization will be returned |
body
SchemaForRequestBodyApplicationJson
| Type |
Description |
Notes |
| User |
|
|
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| default |
ApiResponseForDefault |
successful operation |
ApiResponseForDefault
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
void (empty response body)
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]
create_users_with_array_input
create_users_with_array_input(user)
Creates list of users with given input array
Example
Parameters
| Name |
Type |
Description |
Notes |
| body |
typing.Union[SchemaForRequestBodyApplicationJson] |
required |
|
| content_type |
str |
optional, default is 'application/json' |
Selects the schema and serialization of the request body |
| stream |
bool |
default is False |
if True then the response.content will be streamed and loaded from a file like object. When downloading a file, set this to True to force the code to deserialize the content to a FileSchema file |
| timeout |
typing.Optional[typing.Union[int, typing.Tuple]] |
default is None |
the timeout used by the rest client |
| skip_deserialization |
bool |
default is False |
when True, headers and body will be unset and an instance of api_client.ApiResponseWithoutDeserialization will be returned |
body
SchemaForRequestBodyApplicationJson
| Type |
Description |
Notes |
| [User] |
|
|
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| default |
ApiResponseForDefault |
successful operation |
ApiResponseForDefault
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
void (empty response body)
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]
create_users_with_list_input
create_users_with_list_input(user)
Creates list of users with given input array
Example
Parameters
| Name |
Type |
Description |
Notes |
| body |
typing.Union[SchemaForRequestBodyApplicationJson] |
required |
|
| content_type |
str |
optional, default is 'application/json' |
Selects the schema and serialization of the request body |
| stream |
bool |
default is False |
if True then the response.content will be streamed and loaded from a file like object. When downloading a file, set this to True to force the code to deserialize the content to a FileSchema file |
| timeout |
typing.Optional[typing.Union[int, typing.Tuple]] |
default is None |
the timeout used by the rest client |
| skip_deserialization |
bool |
default is False |
when True, headers and body will be unset and an instance of api_client.ApiResponseWithoutDeserialization will be returned |
body
SchemaForRequestBodyApplicationJson
| Type |
Description |
Notes |
| [User] |
|
|
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| default |
ApiResponseForDefault |
successful operation |
ApiResponseForDefault
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
void (empty response body)
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]
delete_user
delete_user(username)
Delete user
This can only be done by the logged in user.
Example
Parameters
| Name |
Type |
Description |
Notes |
| path_params |
RequestPathParams |
|
|
| stream |
bool |
default is False |
if True then the response.content will be streamed and loaded from a file like object. When downloading a file, set this to True to force the code to deserialize the content to a FileSchema file |
| timeout |
typing.Optional[typing.Union[int, typing.Tuple]] |
default is None |
the timeout used by the rest client |
| skip_deserialization |
bool |
default is False |
when True, headers and body will be unset and an instance of api_client.ApiResponseWithoutDeserialization will be returned |
path_params
RequestPathParams
| Name |
Type |
Description |
Notes |
| username |
UsernameSchema |
|
|
UsernameSchema
| Type |
Description |
Notes |
| str |
|
|
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| 400 |
ApiResponseFor400 |
Invalid username supplied |
| 404 |
ApiResponseFor404 |
User not found |
ApiResponseFor400
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
ApiResponseFor404
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
void (empty response body)
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]
get_user_by_name
User get_user_by_name(username)
Get user by user name
Example
Parameters
| Name |
Type |
Description |
Notes |
| path_params |
RequestPathParams |
|
|
| accept_content_types |
typing.Tuple[str] |
default is ('application/xml', 'application/json', ) |
Tells the server the content type(s) that are accepted by the client |
| stream |
bool |
default is False |
if True then the response.content will be streamed and loaded from a file like object. When downloading a file, set this to True to force the code to deserialize the content to a FileSchema file |
| timeout |
typing.Optional[typing.Union[int, typing.Tuple]] |
default is None |
the timeout used by the rest client |
| skip_deserialization |
bool |
default is False |
when True, headers and body will be unset and an instance of api_client.ApiResponseWithoutDeserialization will be returned |
path_params
RequestPathParams
| Name |
Type |
Description |
Notes |
| username |
UsernameSchema |
|
|
UsernameSchema
| Type |
Description |
Notes |
| str |
|
|
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| 200 |
ApiResponseFor200 |
successful operation |
| 400 |
ApiResponseFor400 |
Invalid username supplied |
| 404 |
ApiResponseFor404 |
User not found |
ApiResponseFor200
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
typing.Union[SchemaFor200ResponseBodyApplicationXml, SchemaFor200ResponseBodyApplicationJson, ] |
|
|
| headers |
Unset |
headers were not defined |
|
SchemaFor200ResponseBodyApplicationXml
| Type |
Description |
Notes |
| User |
|
|
SchemaFor200ResponseBodyApplicationJson
| Type |
Description |
Notes |
| User |
|
|
ApiResponseFor400
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
ApiResponseFor404
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
User
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]
login_user
str login_user(usernamepassword)
Logs user into the system
Example
Parameters
| Name |
Type |
Description |
Notes |
| query_params |
RequestQueryParams |
|
|
| accept_content_types |
typing.Tuple[str] |
default is ('application/xml', 'application/json', ) |
Tells the server the content type(s) that are accepted by the client |
| stream |
bool |
default is False |
if True then the response.content will be streamed and loaded from a file like object. When downloading a file, set this to True to force the code to deserialize the content to a FileSchema file |
| timeout |
typing.Optional[typing.Union[int, typing.Tuple]] |
default is None |
the timeout used by the rest client |
| skip_deserialization |
bool |
default is False |
when True, headers and body will be unset and an instance of api_client.ApiResponseWithoutDeserialization will be returned |
query_params
RequestQueryParams
| Name |
Type |
Description |
Notes |
| username |
UsernameSchema |
|
|
| password |
PasswordSchema |
|
|
UsernameSchema
| Type |
Description |
Notes |
| str |
|
|
PasswordSchema
| Type |
Description |
Notes |
| str |
|
|
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| 200 |
ApiResponseFor200 |
successful operation |
| 400 |
ApiResponseFor400 |
Invalid username/password supplied |
ApiResponseFor200
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
typing.Union[SchemaFor200ResponseBodyApplicationXml, SchemaFor200ResponseBodyApplicationJson, ] |
|
|
| headers |
ResponseHeadersFor200 |
|
|
SchemaFor200ResponseBodyApplicationXml
| Type |
Description |
Notes |
| str |
|
|
SchemaFor200ResponseBodyApplicationJson
| Type |
Description |
Notes |
| str |
|
|
| Name |
Type |
Description |
Notes |
| X-Rate-Limit |
XRateLimitSchema |
|
optional |
| X-Expires-After |
XExpiresAfterSchema |
|
optional |
XRateLimitSchema
calls per hour allowed by the user
| Type |
Description |
Notes |
| int |
calls per hour allowed by the user |
|
XExpiresAfterSchema
date in UTC when token expires
| Type |
Description |
Notes |
| datetime |
date in UTC when token expires |
|
ApiResponseFor400
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
str
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]
logout_user
logout_user()
Logs out current logged in user session
Example
Parameters
This endpoint does not need any parameter.
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| default |
ApiResponseForDefault |
successful operation |
ApiResponseForDefault
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
void (empty response body)
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]
update_user
update_user(usernameuser)
Updated user
This can only be done by the logged in user.
Example
Parameters
| Name |
Type |
Description |
Notes |
| body |
typing.Union[SchemaForRequestBodyApplicationJson] |
required |
|
| path_params |
RequestPathParams |
|
|
| content_type |
str |
optional, default is 'application/json' |
Selects the schema and serialization of the request body |
| stream |
bool |
default is False |
if True then the response.content will be streamed and loaded from a file like object. When downloading a file, set this to True to force the code to deserialize the content to a FileSchema file |
| timeout |
typing.Optional[typing.Union[int, typing.Tuple]] |
default is None |
the timeout used by the rest client |
| skip_deserialization |
bool |
default is False |
when True, headers and body will be unset and an instance of api_client.ApiResponseWithoutDeserialization will be returned |
body
SchemaForRequestBodyApplicationJson
| Type |
Description |
Notes |
| User |
|
|
path_params
RequestPathParams
| Name |
Type |
Description |
Notes |
| username |
UsernameSchema |
|
|
UsernameSchema
| Type |
Description |
Notes |
| str |
|
|
Return Types, Responses
| Code |
Class |
Description |
| n/a |
api_client.ApiResponseWithoutDeserialization |
When skip_deserialization is True this response is returned |
| 400 |
ApiResponseFor400 |
Invalid user supplied |
| 404 |
ApiResponseFor404 |
User not found |
ApiResponseFor400
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
ApiResponseFor404
| Name |
Type |
Description |
Notes |
| response |
urllib3.HTTPResponse |
Raw response |
|
| body |
Unset |
body was not defined |
|
| headers |
Unset |
headers were not defined |
|
void (empty response body)
Authorization
No authorization required
[Back to top] [Back to API list] [Back to Model list] [Back to README]