You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1283 lines
54 KiB
Python

# Copyright (C) 2022 CVAT.ai Corporation
#
# SPDX-License-Identifier: MIT
# CVAT REST API
#
# REST API for Computer Vision Annotation Tool (CVAT) # noqa: E501
#
# The version of the OpenAPI document: alpha (2.0)
# Contact: support@cvat.ai
# Generated by: https://openapi-generator.tech
from __future__ import annotations
import re # noqa: F401
import typing
from typing import TYPE_CHECKING
import urllib3
from cvat_sdk.api_client import ApiClient
from cvat_sdk.api_client import Endpoint as _Endpoint
from cvat_sdk.model.cloud_storage_read import CloudStorageRead
from cvat_sdk.model.cloud_storage_write import CloudStorageWrite
from cvat_sdk.model.cloud_storage_write_request import CloudStorageWriteRequest
from cvat_sdk.model.paginated_cloud_storage_read_list import PaginatedCloudStorageReadList
from cvat_sdk.model.patched_cloud_storage_write_request import PatchedCloudStorageWriteRequest
from cvat_sdk.model_utils import date, datetime, file_type, none_type # noqa: F401
if TYPE_CHECKING:
# Enable introspection. Can't work normally due to cyclic imports
from cvat_sdk.apis import *
from cvat_sdk.models import *
class CloudStoragesApi(object):
"""NOTE: This class is auto generated by OpenAPI Generator
Ref: https://openapi-generator.tech
Do not edit the class manually.
"""
def __init__(self, api_client=None):
if api_client is None:
api_client = ApiClient()
self.api_client = api_client
self.cloudstorages_create_endpoint = _Endpoint(
settings={
"response_schema": (CloudStorageWrite,),
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages",
"operation_id": "cloudstorages_create",
"http_method": "POST",
"servers": None,
},
params_map={
"all": [
"cloud_storage_write_request",
"x_organization",
"org",
"org_id",
],
"required": [
"cloud_storage_write_request",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"cloud_storage_write_request": (CloudStorageWriteRequest,),
"x_organization": (str,),
"org": (str,),
"org_id": (int,),
},
"attribute_map": {
"x_organization": "X-Organization",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"cloud_storage_write_request": "body",
"x_organization": "header",
"org": "query",
"org_id": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": ["application/vnd.cvat+json"],
"content_type": [
"application/json",
"application/x-www-form-urlencoded",
"multipart/form-data",
"application/offset+octet-stream",
],
},
api_client=api_client,
)
self.cloudstorages_destroy_endpoint = _Endpoint(
settings={
"response_schema": None,
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages/{id}",
"operation_id": "cloudstorages_destroy",
"http_method": "DELETE",
"servers": None,
},
params_map={
"all": [
"id",
"x_organization",
"org",
"org_id",
],
"required": [
"id",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"id": (int,),
"x_organization": (str,),
"org": (str,),
"org_id": (int,),
},
"attribute_map": {
"id": "id",
"x_organization": "X-Organization",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"id": "path",
"x_organization": "header",
"org": "query",
"org_id": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": [],
"content_type": [],
},
api_client=api_client,
)
self.cloudstorages_list_endpoint = _Endpoint(
settings={
"response_schema": (PaginatedCloudStorageReadList,),
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages",
"operation_id": "cloudstorages_list",
"http_method": "GET",
"servers": None,
},
params_map={
"all": [
"x_organization",
"filter",
"org",
"org_id",
"page",
"page_size",
"search",
"sort",
],
"required": [],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"x_organization": (str,),
"filter": (str,),
"org": (str,),
"org_id": (int,),
"page": (int,),
"page_size": (int,),
"search": (str,),
"sort": (str,),
},
"attribute_map": {
"x_organization": "X-Organization",
"filter": "filter",
"org": "org",
"org_id": "org_id",
"page": "page",
"page_size": "page_size",
"search": "search",
"sort": "sort",
},
"location_map": {
"x_organization": "header",
"filter": "query",
"org": "query",
"org_id": "query",
"page": "query",
"page_size": "query",
"search": "query",
"sort": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": ["application/vnd.cvat+json"],
"content_type": [],
},
api_client=api_client,
)
self.cloudstorages_partial_update_endpoint = _Endpoint(
settings={
"response_schema": (CloudStorageWrite,),
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages/{id}",
"operation_id": "cloudstorages_partial_update",
"http_method": "PATCH",
"servers": None,
},
params_map={
"all": [
"id",
"x_organization",
"org",
"org_id",
"patched_cloud_storage_write_request",
],
"required": [
"id",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"id": (int,),
"x_organization": (str,),
"org": (str,),
"org_id": (int,),
"patched_cloud_storage_write_request": (PatchedCloudStorageWriteRequest,),
},
"attribute_map": {
"id": "id",
"x_organization": "X-Organization",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"id": "path",
"x_organization": "header",
"org": "query",
"org_id": "query",
"patched_cloud_storage_write_request": "body",
},
"collection_format_map": {},
},
headers_map={
"accept": ["application/vnd.cvat+json"],
"content_type": [
"application/json",
"application/x-www-form-urlencoded",
"multipart/form-data",
"application/offset+octet-stream",
],
},
api_client=api_client,
)
self.cloudstorages_retrieve_endpoint = _Endpoint(
settings={
"response_schema": (CloudStorageRead,),
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages/{id}",
"operation_id": "cloudstorages_retrieve",
"http_method": "GET",
"servers": None,
},
params_map={
"all": [
"id",
"x_organization",
"org",
"org_id",
],
"required": [
"id",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"id": (int,),
"x_organization": (str,),
"org": (str,),
"org_id": (int,),
},
"attribute_map": {
"id": "id",
"x_organization": "X-Organization",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"id": "path",
"x_organization": "header",
"org": "query",
"org_id": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": ["application/vnd.cvat+json"],
"content_type": [],
},
api_client=api_client,
)
self.cloudstorages_retrieve_actions_endpoint = _Endpoint(
settings={
"response_schema": (str,),
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages/{id}/actions",
"operation_id": "cloudstorages_retrieve_actions",
"http_method": "GET",
"servers": None,
},
params_map={
"all": [
"id",
"x_organization",
"org",
"org_id",
],
"required": [
"id",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"id": (int,),
"x_organization": (str,),
"org": (str,),
"org_id": (int,),
},
"attribute_map": {
"id": "id",
"x_organization": "X-Organization",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"id": "path",
"x_organization": "header",
"org": "query",
"org_id": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": ["application/vnd.cvat+json"],
"content_type": [],
},
api_client=api_client,
)
self.cloudstorages_retrieve_content_endpoint = _Endpoint(
settings={
"response_schema": (
{str: (bool, date, datetime, dict, float, int, list, str, none_type)},
),
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages/{id}/content",
"operation_id": "cloudstorages_retrieve_content",
"http_method": "GET",
"servers": None,
},
params_map={
"all": [
"id",
"x_organization",
"manifest_path",
"org",
"org_id",
],
"required": [
"id",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"id": (int,),
"x_organization": (str,),
"manifest_path": (str,),
"org": (str,),
"org_id": (int,),
},
"attribute_map": {
"id": "id",
"x_organization": "X-Organization",
"manifest_path": "manifest_path",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"id": "path",
"x_organization": "header",
"manifest_path": "query",
"org": "query",
"org_id": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": ["application/vnd.cvat+json"],
"content_type": [],
},
api_client=api_client,
)
self.cloudstorages_retrieve_preview_endpoint = _Endpoint(
settings={
"response_schema": None,
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages/{id}/preview",
"operation_id": "cloudstorages_retrieve_preview",
"http_method": "GET",
"servers": None,
},
params_map={
"all": [
"id",
"x_organization",
"org",
"org_id",
],
"required": [
"id",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"id": (int,),
"x_organization": (str,),
"org": (str,),
"org_id": (int,),
},
"attribute_map": {
"id": "id",
"x_organization": "X-Organization",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"id": "path",
"x_organization": "header",
"org": "query",
"org_id": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": [],
"content_type": [],
},
api_client=api_client,
)
self.cloudstorages_retrieve_status_endpoint = _Endpoint(
settings={
"response_schema": (str,),
"auth": ["SignatureAuthentication", "basicAuth", "cookieAuth", "tokenAuth"],
"endpoint_path": "/api/cloudstorages/{id}/status",
"operation_id": "cloudstorages_retrieve_status",
"http_method": "GET",
"servers": None,
},
params_map={
"all": [
"id",
"x_organization",
"org",
"org_id",
],
"required": [
"id",
],
"nullable": [],
"enum": [],
"validation": [],
},
root_map={
"validations": {},
"allowed_values": {},
"openapi_types": {
"id": (int,),
"x_organization": (str,),
"org": (str,),
"org_id": (int,),
},
"attribute_map": {
"id": "id",
"x_organization": "X-Organization",
"org": "org",
"org_id": "org_id",
},
"location_map": {
"id": "path",
"x_organization": "header",
"org": "query",
"org_id": "query",
},
"collection_format_map": {},
},
headers_map={
"accept": ["application/vnd.cvat+json"],
"content_type": [],
},
api_client=api_client,
)
def cloudstorages_create(
self,
cloud_storage_write_request: CloudStorageWriteRequest,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[CloudStorageWrite], urllib3.HTTPResponse]:
"""Method creates a cloud storage with a specified characteristics # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_create(cloud_storage_write_request, _async_call=True)
>>> result = thread.get()
Args:
cloud_storage_write_request (CloudStorageWriteRequest):
Keyword Args:
x_organization (str): [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(CloudStorageWrite, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["cloud_storage_write_request"] = cloud_storage_write_request
return self.cloudstorages_create_endpoint.call_with_http_info(**kwargs)
def cloudstorages_destroy(
self,
id: int,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[None], urllib3.HTTPResponse]:
"""Method deletes a specific cloud storage # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_destroy(id, _async_call=True)
>>> result = thread.get()
Args:
id (int): A unique integer value identifying this cloud storage.
Keyword Args:
x_organization (str): [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(None, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["id"] = id
return self.cloudstorages_destroy_endpoint.call_with_http_info(**kwargs)
def cloudstorages_list(
self,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[PaginatedCloudStorageReadList], urllib3.HTTPResponse]:
"""Returns a paginated list of storages according to query parameters # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_list(_async_call=True)
>>> result = thread.get()
Keyword Args:
x_organization (str): [optional]
filter (str): A filter term. Avaliable filter_fields: ['provider_type', 'display_name', 'resource', 'credentials_type', 'owner', 'description', 'id']. [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
page (int): A page number within the paginated result set.. [optional]
page_size (int): Number of results to return per page.. [optional]
search (str): A search term. Avaliable search_fields: ('provider_type', 'display_name', 'resource', 'credentials_type', 'owner', 'description'). [optional]
sort (str): Which field to use when ordering the results. Avaliable ordering_fields: ['provider_type', 'display_name', 'resource', 'credentials_type', 'owner', 'description', 'id']. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(PaginatedCloudStorageReadList, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
return self.cloudstorages_list_endpoint.call_with_http_info(**kwargs)
def cloudstorages_partial_update(
self,
id: int,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[CloudStorageWrite], urllib3.HTTPResponse]:
"""Methods does a partial update of chosen fields in a cloud storage instance # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_partial_update(id, _async_call=True)
>>> result = thread.get()
Args:
id (int): A unique integer value identifying this cloud storage.
Keyword Args:
x_organization (str): [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
patched_cloud_storage_write_request (PatchedCloudStorageWriteRequest): [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(CloudStorageWrite, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["id"] = id
return self.cloudstorages_partial_update_endpoint.call_with_http_info(**kwargs)
def cloudstorages_retrieve(
self,
id: int,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[CloudStorageRead], urllib3.HTTPResponse]:
"""Method returns details of a specific cloud storage # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_retrieve(id, _async_call=True)
>>> result = thread.get()
Args:
id (int): A unique integer value identifying this cloud storage.
Keyword Args:
x_organization (str): [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(CloudStorageRead, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["id"] = id
return self.cloudstorages_retrieve_endpoint.call_with_http_info(**kwargs)
def cloudstorages_retrieve_actions(
self,
id: int,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[str], urllib3.HTTPResponse]:
"""Method returns allowed actions for the cloud storage # noqa: E501
Method return allowed actions for cloud storage. It's required for reading/writing # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_retrieve_actions(id, _async_call=True)
>>> result = thread.get()
Args:
id (int): A unique integer value identifying this cloud storage.
Keyword Args:
x_organization (str): [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(str, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["id"] = id
return self.cloudstorages_retrieve_actions_endpoint.call_with_http_info(**kwargs)
def cloudstorages_retrieve_content(
self,
id: int,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[
typing.Optional[typing.Dict[str, typing.Union[typing.Any, none_type]]], urllib3.HTTPResponse
]:
"""Method returns a manifest content # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_retrieve_content(id, _async_call=True)
>>> result = thread.get()
Args:
id (int): A unique integer value identifying this cloud storage.
Keyword Args:
x_organization (str): [optional]
manifest_path (str): Path to the manifest file in a cloud storage. [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
({str: (bool, date, datetime, dict, float, int, list, str, none_type)}, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["id"] = id
return self.cloudstorages_retrieve_content_endpoint.call_with_http_info(**kwargs)
def cloudstorages_retrieve_preview(
self,
id: int,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[None], urllib3.HTTPResponse]:
"""Method returns a preview image from a cloud storage # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_retrieve_preview(id, _async_call=True)
>>> result = thread.get()
Args:
id (int): A unique integer value identifying this cloud storage.
Keyword Args:
x_organization (str): [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(None, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["id"] = id
return self.cloudstorages_retrieve_preview_endpoint.call_with_http_info(**kwargs)
def cloudstorages_retrieve_status(
self,
id: int,
*,
_parse_response: bool = True,
_request_timeout: typing.Union[int, float, tuple] = None,
_validate_inputs: bool = True,
_validate_outputs: bool = True,
_check_status: bool = True,
_spec_property_naming: bool = False,
_content_type: typing.Optional[str] = None,
_host_index: typing.Optional[int] = None,
_request_auths: typing.Optional[typing.List] = None,
_async_call: bool = False,
**kwargs,
) -> typing.Tuple[typing.Optional[str], urllib3.HTTPResponse]:
"""Method returns a cloud storage status # noqa: E501
This method makes a synchronous HTTP request by default. To make an
asynchronous HTTP request, please pass _async_call=True
>>> thread = api.cloudstorages_retrieve_status(id, _async_call=True)
>>> result = thread.get()
Args:
id (int): A unique integer value identifying this cloud storage.
Keyword Args:
x_organization (str): [optional]
org (str): Organization unique slug. [optional]
org_id (int): Organization identifier. [optional]
_parse_response (bool): if False, the response data will not be parsed,
None is returned for data.
Default is True.
_request_timeout (int/float/tuple): timeout setting for this request. If
one number provided, it will be total request timeout. It can also
be a pair (tuple) of (connection, read) timeouts.
Default is None.
_validate_inputs (bool): specifies if type checking
should be done one the data sent to the server.
Default is True.
_validate_outputs (bool): specifies if type checking
should be done one the data received from the server.
Default is True.
_check_status (bool): whether to check response status
for being positive or not.
Default is True
_spec_property_naming (bool): True if the variable names in the input data
are serialized names, as specified in the OpenAPI document.
False if the variable names in the input data
are pythonic names, e.g. snake case (default)
_content_type (str/None): force body content-type.
Default is None and content-type will be predicted by allowed
content-types and body.
_host_index (int/None): specifies the index of the server
that we want to use.
Default is read from the configuration.
_request_auths (list): set to override the auth_settings for an a single
request; this effectively ignores the authentication
in the spec for a single request.
Default is None
_async_call (bool): execute request asynchronously
Returns:
(str, HTTPResponse)
If the method is called asynchronously, returns the request
thread.
"""
kwargs["_async_call"] = _async_call
kwargs["_parse_response"] = _parse_response
kwargs["_request_timeout"] = _request_timeout
kwargs["_validate_inputs"] = _validate_inputs
kwargs["_validate_outputs"] = _validate_outputs
kwargs["_check_status"] = _check_status
kwargs["_spec_property_naming"] = _spec_property_naming
kwargs["_content_type"] = _content_type
kwargs["_host_index"] = _host_index
kwargs["_request_auths"] = _request_auths
kwargs["id"] = id
return self.cloudstorages_retrieve_status_endpoint.call_with_http_info(**kwargs)