fix key query params

This commit is contained in:
Quentin 2023-11-23 08:53:53 +01:00
parent e02326f5db
commit 8fa1cac54f
Signed by: quentin
GPG key ID: E9602264D639FF68
2 changed files with 28 additions and 28 deletions

View file

@ -95,7 +95,7 @@ Name | Type | Description | Notes
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
# **delete_key**
> delete_key(access_key)
> delete_key(id)
Delete a key
@ -130,12 +130,12 @@ configuration = garage_admin_sdk.Configuration(
with garage_admin_sdk.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = key_api.KeyApi(api_client)
access_key = "GK31c2f218a2e44f485b94239e" # str | The exact API access key generated by Garage
id = "GK31c2f218a2e44f485b94239e" # str | The exact API access key generated by Garage
# example passing only required values which don't have defaults set
try:
# Delete a key
api_instance.delete_key(access_key)
api_instance.delete_key(id)
except garage_admin_sdk.ApiException as e:
print("Exception when calling KeyApi->delete_key: %s\n" % e)
```
@ -145,7 +145,7 @@ with garage_admin_sdk.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**access_key** | **str**| The exact API access key generated by Garage |
**id** | **str**| The exact API access key generated by Garage |
### Return type
@ -412,7 +412,7 @@ This endpoint does not need any parameter.
[[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_key**
> KeyInfo update_key(access_key, update_key_request)
> KeyInfo update_key(id, update_key_request)
Update a key
@ -449,7 +449,7 @@ configuration = garage_admin_sdk.Configuration(
with garage_admin_sdk.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = key_api.KeyApi(api_client)
access_key = "GK31c2f218a2e44f485b94239e" # str | The exact API access key generated by Garage
id = "GK31c2f218a2e44f485b94239e" # str | The exact API access key generated by Garage
update_key_request = UpdateKeyRequest(
name="test-key",
allow=UpdateKeyRequestAllow(
@ -463,7 +463,7 @@ with garage_admin_sdk.ApiClient(configuration) as api_client:
# example passing only required values which don't have defaults set
try:
# Update a key
api_response = api_instance.update_key(access_key, update_key_request)
api_response = api_instance.update_key(id, update_key_request)
pprint(api_response)
except garage_admin_sdk.ApiException as e:
print("Exception when calling KeyApi->update_key: %s\n" % e)
@ -474,7 +474,7 @@ with garage_admin_sdk.ApiClient(configuration) as api_client:
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**access_key** | **str**| The exact API access key generated by Garage |
**id** | **str**| The exact API access key generated by Garage |
**update_key_request** | [**UpdateKeyRequest**](UpdateKeyRequest.md)| For a given key, provide a first set with the permissions to grant, and a second set with the permissions to remove |
### Return type

View file

@ -104,10 +104,10 @@ class KeyApi(object):
},
params_map={
'all': [
'access_key',
'id',
],
'required': [
'access_key',
'id',
],
'nullable': [
],
@ -122,14 +122,14 @@ class KeyApi(object):
'allowed_values': {
},
'openapi_types': {
'access_key':
'id':
(str,),
},
'attribute_map': {
'access_key': 'access_key',
'id': 'id',
},
'location_map': {
'access_key': 'path',
'id': 'query',
},
'collection_format_map': {
}
@ -314,11 +314,11 @@ class KeyApi(object):
},
params_map={
'all': [
'access_key',
'id',
'update_key_request',
],
'required': [
'access_key',
'id',
'update_key_request',
],
'nullable': [
@ -334,16 +334,16 @@ class KeyApi(object):
'allowed_values': {
},
'openapi_types': {
'access_key':
'id':
(str,),
'update_key_request':
(UpdateKeyRequest,),
},
'attribute_map': {
'access_key': 'access_key',
'id': 'id',
},
'location_map': {
'access_key': 'path',
'id': 'query',
'update_key_request': 'body',
},
'collection_format_map': {
@ -445,7 +445,7 @@ class KeyApi(object):
def delete_key(
self,
access_key,
id,
**kwargs
):
"""Delete a key # noqa: E501
@ -454,11 +454,11 @@ class KeyApi(object):
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.delete_key(access_key, async_req=True)
>>> thread = api.delete_key(id, async_req=True)
>>> result = thread.get()
Args:
access_key (str): The exact API access key generated by Garage
id (str): The exact API access key generated by Garage
Keyword Args:
_return_http_data_only (bool): response data without head status
@ -522,8 +522,8 @@ class KeyApi(object):
'_content_type')
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['_request_auths'] = kwargs.get('_request_auths', None)
kwargs['access_key'] = \
access_key
kwargs['id'] = \
id
return self.delete_key_endpoint.call_with_http_info(**kwargs)
def get_key(
@ -770,7 +770,7 @@ class KeyApi(object):
def update_key(
self,
access_key,
id,
update_key_request,
**kwargs
):
@ -780,11 +780,11 @@ class KeyApi(object):
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass async_req=True
>>> thread = api.update_key(access_key, update_key_request, async_req=True)
>>> thread = api.update_key(id, update_key_request, async_req=True)
>>> result = thread.get()
Args:
access_key (str): The exact API access key generated by Garage
id (str): The exact API access key generated by Garage
update_key_request (UpdateKeyRequest): For a given key, provide a first set with the permissions to grant, and a second set with the permissions to remove
Keyword Args:
@ -849,8 +849,8 @@ class KeyApi(object):
'_content_type')
kwargs['_host_index'] = kwargs.get('_host_index')
kwargs['_request_auths'] = kwargs.get('_request_auths', None)
kwargs['access_key'] = \
access_key
kwargs['id'] = \
id
kwargs['update_key_request'] = \
update_key_request
return self.update_key_endpoint.call_with_http_info(**kwargs)