# coding: utf-8

"""
    Acre Platform User API

    # CORS CORS is implemented by all Acre API endpoints and only certain hostnames are allowed for each deployment of the API. If your use case requires calling the Acre User API from a browser, please contact Acre to arrange the appropriate configuration. # API Authentication The primary method of authentication for users of the Acre API is with the use of JSON Web Tokens (JWTs), which are suplemented by an application specific API Key. The API key must be provided through the `X-API-KEY` HTTP header and will be provided by your Acre Customer Success Manager. The JWT must be provided through a cookie with key of `authorization`. The JWT must be generated and signed as per the following section. # Generating JWTs JWT must either be generated by a third-party such as Azure ADB2C that has been configured for the appropriate service and/or user account, or alternatively can be generated locally and signed by an private key for which the public key has been made available to Acre via a JWKS URL. In addition to being signed by your private key, the JWT will also need to contain at a minimum:  * An issuer `iss`, which must be a valid URI previously agreed with Acre.  * A subject `sub`, which must be a unique identifier for the user and/or service account previously agreed with Acre.  * An expiry time `exp` which must not be more than four hours in the future.  * A not before time `nbf` which must be in the past, but not greater than six hours in the past.  The JWT should be signed using RS256.

    The version of the OpenAPI document: 1.0
    Generated by OpenAPI Generator (https://openapi-generator.tech)

    Do not edit the class manually.
"""  # noqa: E501

import warnings
from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
from typing import Any, Dict, List, Optional, Tuple, Union
from typing_extensions import Annotated

from pydantic import Field, StrictBool, StrictInt, StrictStr, field_validator
from typing import List, Optional
from typing_extensions import Annotated
from acre_api.models.acre_processor_add_case_protection_product_body import AcreProcessorAddCaseProtectionProductBody
from acre_api.models.cdm_add_case_protection_product_response import CdmAddCaseProtectionProductResponse
from acre_api.models.cdm_create_protection_product_request import CdmCreateProtectionProductRequest
from acre_api.models.cdm_create_protection_product_response import CdmCreateProtectionProductResponse
from acre_api.models.cdm_create_protection_product_version_response import CdmCreateProtectionProductVersionResponse
from acre_api.models.cdm_delete_case_protection_product_response import CdmDeleteCaseProtectionProductResponse
from acre_api.models.cdm_get_protection_product_response import CdmGetProtectionProductResponse
from acre_api.models.cdm_get_protection_product_version_response import CdmGetProtectionProductVersionResponse
from acre_api.models.cdm_save_protection_solution_to_case_request import CdmSaveProtectionSolutionToCaseRequest
from acre_api.models.cdm_save_protection_solution_to_case_response import CdmSaveProtectionSolutionToCaseResponse
from acre_api.models.cdm_update_protection_product_response import CdmUpdateProtectionProductResponse
from acre_api.models.partial_details_of_the_protection_product_to_be_updated_required import PartialDetailsOfTheProtectionProductToBeUpdatedRequired

from acre_api.api_client import ApiClient, RequestSerialized
from acre_api.api_response import ApiResponse
from acre_api.rest import RESTResponseType


class ProtectionProductApi:
    """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) -> None:
        if api_client is None:
            api_client = ApiClient.get_default()
        self.api_client = api_client


    @validate_call
    def add_case_protection_product(
        self,
        protection_id: Annotated[StrictStr, Field(description="ID of the protection product to be added to the case. Required.")],
        body: AcreProcessorAddCaseProtectionProductBody,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmAddCaseProtectionProductResponse:
        """Add a protection product to an existing case.


        :param protection_id: ID of the protection product to be added to the case. Required. (required)
        :type protection_id: str
        :param body: (required)
        :type body: AcreProcessorAddCaseProtectionProductBody
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._add_case_protection_product_serialize(
            protection_id=protection_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmAddCaseProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def add_case_protection_product_with_http_info(
        self,
        protection_id: Annotated[StrictStr, Field(description="ID of the protection product to be added to the case. Required.")],
        body: AcreProcessorAddCaseProtectionProductBody,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmAddCaseProtectionProductResponse]:
        """Add a protection product to an existing case.


        :param protection_id: ID of the protection product to be added to the case. Required. (required)
        :type protection_id: str
        :param body: (required)
        :type body: AcreProcessorAddCaseProtectionProductBody
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._add_case_protection_product_serialize(
            protection_id=protection_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmAddCaseProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def add_case_protection_product_without_preload_content(
        self,
        protection_id: Annotated[StrictStr, Field(description="ID of the protection product to be added to the case. Required.")],
        body: AcreProcessorAddCaseProtectionProductBody,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Add a protection product to an existing case.


        :param protection_id: ID of the protection product to be added to the case. Required. (required)
        :type protection_id: str
        :param body: (required)
        :type body: AcreProcessorAddCaseProtectionProductBody
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._add_case_protection_product_serialize(
            protection_id=protection_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmAddCaseProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _add_case_protection_product_serialize(
        self,
        protection_id,
        body,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        if protection_id is not None:
            _path_params['protection_id'] = protection_id
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter
        if body is not None:
            _body_params = body


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )

        # set the HTTP header `Content-Type`
        if _content_type:
            _header_params['Content-Type'] = _content_type
        else:
            _default_content_type = (
                self.api_client.select_header_content_type(
                    [
                        'application/json'
                    ]
                )
            )
            if _default_content_type is not None:
                _header_params['Content-Type'] = _default_content_type

        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v1/acre/protection_product/{protection_id}/case',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )




    @validate_call
    def create_protection_product(
        self,
        body: Annotated[CdmCreateProtectionProductRequest, Field(description="Create protection product request.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmCreateProtectionProductResponse:
        """Create a protection product.


        :param body: Create protection product request. (required)
        :type body: CdmCreateProtectionProductRequest
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._create_protection_product_serialize(
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmCreateProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def create_protection_product_with_http_info(
        self,
        body: Annotated[CdmCreateProtectionProductRequest, Field(description="Create protection product request.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmCreateProtectionProductResponse]:
        """Create a protection product.


        :param body: Create protection product request. (required)
        :type body: CdmCreateProtectionProductRequest
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._create_protection_product_serialize(
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmCreateProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def create_protection_product_without_preload_content(
        self,
        body: Annotated[CdmCreateProtectionProductRequest, Field(description="Create protection product request.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Create a protection product.


        :param body: Create protection product request. (required)
        :type body: CdmCreateProtectionProductRequest
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._create_protection_product_serialize(
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmCreateProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _create_protection_product_serialize(
        self,
        body,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter
        if body is not None:
            _body_params = body


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )

        # set the HTTP header `Content-Type`
        if _content_type:
            _header_params['Content-Type'] = _content_type
        else:
            _default_content_type = (
                self.api_client.select_header_content_type(
                    [
                        'application/json'
                    ]
                )
            )
            if _default_content_type is not None:
                _header_params['Content-Type'] = _default_content_type

        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v1/acre/protection_product',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )




    @validate_call
    def create_protection_product_version(
        self,
        protection_id: Annotated[StrictStr, Field(description="Protection product ID. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmCreateProtectionProductVersionResponse:
        """Create a protection product version.


        :param protection_id: Protection product ID. Required. (required)
        :type protection_id: str
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._create_protection_product_version_serialize(
            protection_id=protection_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmCreateProtectionProductVersionResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def create_protection_product_version_with_http_info(
        self,
        protection_id: Annotated[StrictStr, Field(description="Protection product ID. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmCreateProtectionProductVersionResponse]:
        """Create a protection product version.


        :param protection_id: Protection product ID. Required. (required)
        :type protection_id: str
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._create_protection_product_version_serialize(
            protection_id=protection_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmCreateProtectionProductVersionResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def create_protection_product_version_without_preload_content(
        self,
        protection_id: Annotated[StrictStr, Field(description="Protection product ID. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Create a protection product version.


        :param protection_id: Protection product ID. Required. (required)
        :type protection_id: str
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._create_protection_product_version_serialize(
            protection_id=protection_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmCreateProtectionProductVersionResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _create_protection_product_version_serialize(
        self,
        protection_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        if protection_id is not None:
            _path_params['protection_id'] = protection_id
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )


        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v1/acre/protection_product/{protection_id}/version',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )




    @validate_call
    def delete_case_protection_product(
        self,
        protection_id: Annotated[StrictStr, Field(description="ID of the product to remove. Required.")],
        case_id: Annotated[StrictStr, Field(description="Case to remove the product. Required.")],
        force: Annotated[Optional[StrictBool], Field(description="If true, it'll force the unlink of the product from the case and clients, even if it fails to find the product. This was added as a workaround for an index issue.")] = None,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmDeleteCaseProtectionProductResponse:
        """Delete (DELETE) case from a protection product.


        :param protection_id: ID of the product to remove. Required. (required)
        :type protection_id: str
        :param case_id: Case to remove the product. Required. (required)
        :type case_id: str
        :param force: If true, it'll force the unlink of the product from the case and clients, even if it fails to find the product. This was added as a workaround for an index issue.
        :type force: bool
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._delete_case_protection_product_serialize(
            protection_id=protection_id,
            case_id=case_id,
            force=force,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmDeleteCaseProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def delete_case_protection_product_with_http_info(
        self,
        protection_id: Annotated[StrictStr, Field(description="ID of the product to remove. Required.")],
        case_id: Annotated[StrictStr, Field(description="Case to remove the product. Required.")],
        force: Annotated[Optional[StrictBool], Field(description="If true, it'll force the unlink of the product from the case and clients, even if it fails to find the product. This was added as a workaround for an index issue.")] = None,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmDeleteCaseProtectionProductResponse]:
        """Delete (DELETE) case from a protection product.


        :param protection_id: ID of the product to remove. Required. (required)
        :type protection_id: str
        :param case_id: Case to remove the product. Required. (required)
        :type case_id: str
        :param force: If true, it'll force the unlink of the product from the case and clients, even if it fails to find the product. This was added as a workaround for an index issue.
        :type force: bool
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._delete_case_protection_product_serialize(
            protection_id=protection_id,
            case_id=case_id,
            force=force,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmDeleteCaseProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def delete_case_protection_product_without_preload_content(
        self,
        protection_id: Annotated[StrictStr, Field(description="ID of the product to remove. Required.")],
        case_id: Annotated[StrictStr, Field(description="Case to remove the product. Required.")],
        force: Annotated[Optional[StrictBool], Field(description="If true, it'll force the unlink of the product from the case and clients, even if it fails to find the product. This was added as a workaround for an index issue.")] = None,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Delete (DELETE) case from a protection product.


        :param protection_id: ID of the product to remove. Required. (required)
        :type protection_id: str
        :param case_id: Case to remove the product. Required. (required)
        :type case_id: str
        :param force: If true, it'll force the unlink of the product from the case and clients, even if it fails to find the product. This was added as a workaround for an index issue.
        :type force: bool
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._delete_case_protection_product_serialize(
            protection_id=protection_id,
            case_id=case_id,
            force=force,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmDeleteCaseProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _delete_case_protection_product_serialize(
        self,
        protection_id,
        case_id,
        force,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        if protection_id is not None:
            _path_params['protection_id'] = protection_id
        if case_id is not None:
            _path_params['case_id'] = case_id
        # process the query parameters
        if force is not None:
            
            _query_params.append(('force', force))
            
        # process the header parameters
        # process the form parameters
        # process the body parameter


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )


        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='DELETE',
            resource_path='/v1/acre/protection_product/{protection_id}/case/{case_id}',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )




    @validate_call
    def get_protection_product(
        self,
        protection_product_details: Annotated[Optional[StrictBool], Field(description="Return the entire protection product details. By default this value is false and ProtectionProductDetails are returned as null.")] = None,
        protection_ids: Annotated[Optional[List[StrictStr]], Field(description="Protection product IDs (optional, default wildcard for all protection products that the user can access).")] = None,
        filter_client_ids: Annotated[Optional[List[StrictStr]], Field(description="Filter by client IDs. Intersection/AND/conjunction filter; only return protection products which are linked to all clients provided. Cannot be used with protection_ids.")] = None,
        filter_case_ids: Annotated[Optional[List[StrictStr]], Field(description="Filter by case IDs. **IMPORTANT:** misleading plural naming, only a single case_id filter value is accepted. Cannot be used with protection_ids.")] = None,
        bookmark: Annotated[Optional[StrictStr], Field(description="Opaque pagination bookmark. Set to the empty string (or omit) to begin.")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="Specify a limit on the number of items returned in a page. Values that are too large will be rejected. All requests are subject to the page size, which is 100 if not specified and can be specified up to 200.")] = None,
        filter_ext_ids: Annotated[Optional[List[StrictStr]], Field(description="Only include protection products with the specified external IDs. This filter must be used in conjunction with filter_ext_source. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.")] = None,
        filter_ext_source: Annotated[Optional[StrictStr], Field(description="Filtering by external source. This filter must be used in conjunction with filter_ext_ids. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.   - ONFIDO: Onfido (https://onfido.com/).")] = None,
        skip_source_response: Annotated[Optional[StrictBool], Field(description="Option to indicate if you wan to avoid returning the source response for the protection products. It will be returned by default.")] = None,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmGetProtectionProductResponse:
        """Get protection product details.


        :param protection_product_details: Return the entire protection product details. By default this value is false and ProtectionProductDetails are returned as null.
        :type protection_product_details: bool
        :param protection_ids: Protection product IDs (optional, default wildcard for all protection products that the user can access).
        :type protection_ids: List[str]
        :param filter_client_ids: Filter by client IDs. Intersection/AND/conjunction filter; only return protection products which are linked to all clients provided. Cannot be used with protection_ids.
        :type filter_client_ids: List[str]
        :param filter_case_ids: Filter by case IDs. **IMPORTANT:** misleading plural naming, only a single case_id filter value is accepted. Cannot be used with protection_ids.
        :type filter_case_ids: List[str]
        :param bookmark: Opaque pagination bookmark. Set to the empty string (or omit) to begin.
        :type bookmark: str
        :param page_size: Specify a limit on the number of items returned in a page. Values that are too large will be rejected. All requests are subject to the page size, which is 100 if not specified and can be specified up to 200.
        :type page_size: int
        :param filter_ext_ids: Only include protection products with the specified external IDs. This filter must be used in conjunction with filter_ext_source. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.
        :type filter_ext_ids: List[str]
        :param filter_ext_source: Filtering by external source. This filter must be used in conjunction with filter_ext_ids. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.   - ONFIDO: Onfido (https://onfido.com/).
        :type filter_ext_source: str
        :param skip_source_response: Option to indicate if you wan to avoid returning the source response for the protection products. It will be returned by default.
        :type skip_source_response: bool
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._get_protection_product_serialize(
            protection_product_details=protection_product_details,
            protection_ids=protection_ids,
            filter_client_ids=filter_client_ids,
            filter_case_ids=filter_case_ids,
            bookmark=bookmark,
            page_size=page_size,
            filter_ext_ids=filter_ext_ids,
            filter_ext_source=filter_ext_source,
            skip_source_response=skip_source_response,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmGetProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def get_protection_product_with_http_info(
        self,
        protection_product_details: Annotated[Optional[StrictBool], Field(description="Return the entire protection product details. By default this value is false and ProtectionProductDetails are returned as null.")] = None,
        protection_ids: Annotated[Optional[List[StrictStr]], Field(description="Protection product IDs (optional, default wildcard for all protection products that the user can access).")] = None,
        filter_client_ids: Annotated[Optional[List[StrictStr]], Field(description="Filter by client IDs. Intersection/AND/conjunction filter; only return protection products which are linked to all clients provided. Cannot be used with protection_ids.")] = None,
        filter_case_ids: Annotated[Optional[List[StrictStr]], Field(description="Filter by case IDs. **IMPORTANT:** misleading plural naming, only a single case_id filter value is accepted. Cannot be used with protection_ids.")] = None,
        bookmark: Annotated[Optional[StrictStr], Field(description="Opaque pagination bookmark. Set to the empty string (or omit) to begin.")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="Specify a limit on the number of items returned in a page. Values that are too large will be rejected. All requests are subject to the page size, which is 100 if not specified and can be specified up to 200.")] = None,
        filter_ext_ids: Annotated[Optional[List[StrictStr]], Field(description="Only include protection products with the specified external IDs. This filter must be used in conjunction with filter_ext_source. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.")] = None,
        filter_ext_source: Annotated[Optional[StrictStr], Field(description="Filtering by external source. This filter must be used in conjunction with filter_ext_ids. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.   - ONFIDO: Onfido (https://onfido.com/).")] = None,
        skip_source_response: Annotated[Optional[StrictBool], Field(description="Option to indicate if you wan to avoid returning the source response for the protection products. It will be returned by default.")] = None,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmGetProtectionProductResponse]:
        """Get protection product details.


        :param protection_product_details: Return the entire protection product details. By default this value is false and ProtectionProductDetails are returned as null.
        :type protection_product_details: bool
        :param protection_ids: Protection product IDs (optional, default wildcard for all protection products that the user can access).
        :type protection_ids: List[str]
        :param filter_client_ids: Filter by client IDs. Intersection/AND/conjunction filter; only return protection products which are linked to all clients provided. Cannot be used with protection_ids.
        :type filter_client_ids: List[str]
        :param filter_case_ids: Filter by case IDs. **IMPORTANT:** misleading plural naming, only a single case_id filter value is accepted. Cannot be used with protection_ids.
        :type filter_case_ids: List[str]
        :param bookmark: Opaque pagination bookmark. Set to the empty string (or omit) to begin.
        :type bookmark: str
        :param page_size: Specify a limit on the number of items returned in a page. Values that are too large will be rejected. All requests are subject to the page size, which is 100 if not specified and can be specified up to 200.
        :type page_size: int
        :param filter_ext_ids: Only include protection products with the specified external IDs. This filter must be used in conjunction with filter_ext_source. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.
        :type filter_ext_ids: List[str]
        :param filter_ext_source: Filtering by external source. This filter must be used in conjunction with filter_ext_ids. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.   - ONFIDO: Onfido (https://onfido.com/).
        :type filter_ext_source: str
        :param skip_source_response: Option to indicate if you wan to avoid returning the source response for the protection products. It will be returned by default.
        :type skip_source_response: bool
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._get_protection_product_serialize(
            protection_product_details=protection_product_details,
            protection_ids=protection_ids,
            filter_client_ids=filter_client_ids,
            filter_case_ids=filter_case_ids,
            bookmark=bookmark,
            page_size=page_size,
            filter_ext_ids=filter_ext_ids,
            filter_ext_source=filter_ext_source,
            skip_source_response=skip_source_response,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmGetProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def get_protection_product_without_preload_content(
        self,
        protection_product_details: Annotated[Optional[StrictBool], Field(description="Return the entire protection product details. By default this value is false and ProtectionProductDetails are returned as null.")] = None,
        protection_ids: Annotated[Optional[List[StrictStr]], Field(description="Protection product IDs (optional, default wildcard for all protection products that the user can access).")] = None,
        filter_client_ids: Annotated[Optional[List[StrictStr]], Field(description="Filter by client IDs. Intersection/AND/conjunction filter; only return protection products which are linked to all clients provided. Cannot be used with protection_ids.")] = None,
        filter_case_ids: Annotated[Optional[List[StrictStr]], Field(description="Filter by case IDs. **IMPORTANT:** misleading plural naming, only a single case_id filter value is accepted. Cannot be used with protection_ids.")] = None,
        bookmark: Annotated[Optional[StrictStr], Field(description="Opaque pagination bookmark. Set to the empty string (or omit) to begin.")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="Specify a limit on the number of items returned in a page. Values that are too large will be rejected. All requests are subject to the page size, which is 100 if not specified and can be specified up to 200.")] = None,
        filter_ext_ids: Annotated[Optional[List[StrictStr]], Field(description="Only include protection products with the specified external IDs. This filter must be used in conjunction with filter_ext_source. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.")] = None,
        filter_ext_source: Annotated[Optional[StrictStr], Field(description="Filtering by external source. This filter must be used in conjunction with filter_ext_ids. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.   - ONFIDO: Onfido (https://onfido.com/).")] = None,
        skip_source_response: Annotated[Optional[StrictBool], Field(description="Option to indicate if you wan to avoid returning the source response for the protection products. It will be returned by default.")] = None,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Get protection product details.


        :param protection_product_details: Return the entire protection product details. By default this value is false and ProtectionProductDetails are returned as null.
        :type protection_product_details: bool
        :param protection_ids: Protection product IDs (optional, default wildcard for all protection products that the user can access).
        :type protection_ids: List[str]
        :param filter_client_ids: Filter by client IDs. Intersection/AND/conjunction filter; only return protection products which are linked to all clients provided. Cannot be used with protection_ids.
        :type filter_client_ids: List[str]
        :param filter_case_ids: Filter by case IDs. **IMPORTANT:** misleading plural naming, only a single case_id filter value is accepted. Cannot be used with protection_ids.
        :type filter_case_ids: List[str]
        :param bookmark: Opaque pagination bookmark. Set to the empty string (or omit) to begin.
        :type bookmark: str
        :param page_size: Specify a limit on the number of items returned in a page. Values that are too large will be rejected. All requests are subject to the page size, which is 100 if not specified and can be specified up to 200.
        :type page_size: int
        :param filter_ext_ids: Only include protection products with the specified external IDs. This filter must be used in conjunction with filter_ext_source. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.
        :type filter_ext_ids: List[str]
        :param filter_ext_source: Filtering by external source. This filter must be used in conjunction with filter_ext_ids. Cannot be used with protection_ids. When multiple filters are specified, they all apply to return only results that match all the criteria.   - ONFIDO: Onfido (https://onfido.com/).
        :type filter_ext_source: str
        :param skip_source_response: Option to indicate if you wan to avoid returning the source response for the protection products. It will be returned by default.
        :type skip_source_response: bool
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._get_protection_product_serialize(
            protection_product_details=protection_product_details,
            protection_ids=protection_ids,
            filter_client_ids=filter_client_ids,
            filter_case_ids=filter_case_ids,
            bookmark=bookmark,
            page_size=page_size,
            filter_ext_ids=filter_ext_ids,
            filter_ext_source=filter_ext_source,
            skip_source_response=skip_source_response,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmGetProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _get_protection_product_serialize(
        self,
        protection_product_details,
        protection_ids,
        filter_client_ids,
        filter_case_ids,
        bookmark,
        page_size,
        filter_ext_ids,
        filter_ext_source,
        skip_source_response,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
            'protection_ids': 'multi',
            'filter_client_ids': 'multi',
            'filter_case_ids': 'multi',
            'filter_ext_ids': 'multi',
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        # process the query parameters
        if protection_product_details is not None:
            
            _query_params.append(('protection_product_details', protection_product_details))
            
        if protection_ids is not None:
            
            _query_params.append(('protection_ids', protection_ids))
            
        if filter_client_ids is not None:
            
            _query_params.append(('filter_client_ids', filter_client_ids))
            
        if filter_case_ids is not None:
            
            _query_params.append(('filter_case_ids', filter_case_ids))
            
        if bookmark is not None:
            
            _query_params.append(('bookmark', bookmark))
            
        if page_size is not None:
            
            _query_params.append(('page_size', page_size))
            
        if filter_ext_ids is not None:
            
            _query_params.append(('filter_ext_ids', filter_ext_ids))
            
        if filter_ext_source is not None:
            
            _query_params.append(('filter_ext_source', filter_ext_source))
            
        if skip_source_response is not None:
            
            _query_params.append(('skip_source_response', skip_source_response))
            
        # process the header parameters
        # process the form parameters
        # process the body parameter


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )


        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v1/acre/protection_product',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )




    @validate_call
    def get_protection_product_version(
        self,
        protection_id: Annotated[StrictStr, Field(description="Protection product ID. Required.")],
        version: Annotated[StrictInt, Field(description="If zero, returns the latest (i.e., mutable) version. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmGetProtectionProductVersionResponse:
        """Get a protection product, specifying a version (use zero for latest).


        :param protection_id: Protection product ID. Required. (required)
        :type protection_id: str
        :param version: If zero, returns the latest (i.e., mutable) version. Required. (required)
        :type version: int
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._get_protection_product_version_serialize(
            protection_id=protection_id,
            version=version,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmGetProtectionProductVersionResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def get_protection_product_version_with_http_info(
        self,
        protection_id: Annotated[StrictStr, Field(description="Protection product ID. Required.")],
        version: Annotated[StrictInt, Field(description="If zero, returns the latest (i.e., mutable) version. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmGetProtectionProductVersionResponse]:
        """Get a protection product, specifying a version (use zero for latest).


        :param protection_id: Protection product ID. Required. (required)
        :type protection_id: str
        :param version: If zero, returns the latest (i.e., mutable) version. Required. (required)
        :type version: int
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._get_protection_product_version_serialize(
            protection_id=protection_id,
            version=version,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmGetProtectionProductVersionResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def get_protection_product_version_without_preload_content(
        self,
        protection_id: Annotated[StrictStr, Field(description="Protection product ID. Required.")],
        version: Annotated[StrictInt, Field(description="If zero, returns the latest (i.e., mutable) version. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Get a protection product, specifying a version (use zero for latest).


        :param protection_id: Protection product ID. Required. (required)
        :type protection_id: str
        :param version: If zero, returns the latest (i.e., mutable) version. Required. (required)
        :type version: int
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._get_protection_product_version_serialize(
            protection_id=protection_id,
            version=version,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmGetProtectionProductVersionResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _get_protection_product_version_serialize(
        self,
        protection_id,
        version,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        if protection_id is not None:
            _path_params['protection_id'] = protection_id
        if version is not None:
            _path_params['version'] = version
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )


        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v1/acre/protection_product/{protection_id}/version/{version}',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )




    @validate_call
    def save_protection_solution_to_case(
        self,
        body: CdmSaveProtectionSolutionToCaseRequest,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmSaveProtectionSolutionToCaseResponse:
        """Create protection products which belong to a single solution and add to case.


        :param body: (required)
        :type body: CdmSaveProtectionSolutionToCaseRequest
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._save_protection_solution_to_case_serialize(
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmSaveProtectionSolutionToCaseResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def save_protection_solution_to_case_with_http_info(
        self,
        body: CdmSaveProtectionSolutionToCaseRequest,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmSaveProtectionSolutionToCaseResponse]:
        """Create protection products which belong to a single solution and add to case.


        :param body: (required)
        :type body: CdmSaveProtectionSolutionToCaseRequest
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._save_protection_solution_to_case_serialize(
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmSaveProtectionSolutionToCaseResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def save_protection_solution_to_case_without_preload_content(
        self,
        body: CdmSaveProtectionSolutionToCaseRequest,
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Create protection products which belong to a single solution and add to case.


        :param body: (required)
        :type body: CdmSaveProtectionSolutionToCaseRequest
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._save_protection_solution_to_case_serialize(
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmSaveProtectionSolutionToCaseResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _save_protection_solution_to_case_serialize(
        self,
        body,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter
        if body is not None:
            _body_params = body


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )

        # set the HTTP header `Content-Type`
        if _content_type:
            _header_params['Content-Type'] = _content_type
        else:
            _default_content_type = (
                self.api_client.select_header_content_type(
                    [
                        'application/json'
                    ]
                )
            )
            if _default_content_type is not None:
                _header_params['Content-Type'] = _default_content_type

        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v1/acre/protection_solution',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )




    @validate_call
    def update_protection_product(
        self,
        protection_product_protection_id: Annotated[StrictStr, Field(description="Property reference. Populated automatically; cannot be set.")],
        protection_product: Annotated[PartialDetailsOfTheProtectionProductToBeUpdatedRequired, Field(description="Partial details of the protection product to be updated. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> CdmUpdateProtectionProductResponse:
        """Update (PATCH) an existing protection product.


        :param protection_product_protection_id: Property reference. Populated automatically; cannot be set. (required)
        :type protection_product_protection_id: str
        :param protection_product: Partial details of the protection product to be updated. Required. (required)
        :type protection_product: PartialDetailsOfTheProtectionProductToBeUpdatedRequired
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._update_protection_product_serialize(
            protection_product_protection_id=protection_product_protection_id,
            protection_product=protection_product,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmUpdateProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def update_protection_product_with_http_info(
        self,
        protection_product_protection_id: Annotated[StrictStr, Field(description="Property reference. Populated automatically; cannot be set.")],
        protection_product: Annotated[PartialDetailsOfTheProtectionProductToBeUpdatedRequired, Field(description="Partial details of the protection product to be updated. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> ApiResponse[CdmUpdateProtectionProductResponse]:
        """Update (PATCH) an existing protection product.


        :param protection_product_protection_id: Property reference. Populated automatically; cannot be set. (required)
        :type protection_product_protection_id: str
        :param protection_product: Partial details of the protection product to be updated. Required. (required)
        :type protection_product: PartialDetailsOfTheProtectionProductToBeUpdatedRequired
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._update_protection_product_serialize(
            protection_product_protection_id=protection_product_protection_id,
            protection_product=protection_product,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmUpdateProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def update_protection_product_without_preload_content(
        self,
        protection_product_protection_id: Annotated[StrictStr, Field(description="Property reference. Populated automatically; cannot be set.")],
        protection_product: Annotated[PartialDetailsOfTheProtectionProductToBeUpdatedRequired, Field(description="Partial details of the protection product to be updated. Required.")],
        _request_timeout: Union[
            None,
            Annotated[StrictFloat, Field(gt=0)],
            Tuple[
                Annotated[StrictFloat, Field(gt=0)],
                Annotated[StrictFloat, Field(gt=0)]
            ]
        ] = None,
        _request_auth: Optional[Dict[StrictStr, Any]] = None,
        _content_type: Optional[StrictStr] = None,
        _headers: Optional[Dict[StrictStr, Any]] = None,
        _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
    ) -> RESTResponseType:
        """Update (PATCH) an existing protection product.


        :param protection_product_protection_id: Property reference. Populated automatically; cannot be set. (required)
        :type protection_product_protection_id: str
        :param protection_product: Partial details of the protection product to be updated. Required. (required)
        :type protection_product: PartialDetailsOfTheProtectionProductToBeUpdatedRequired
        :param _request_timeout: 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.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._update_protection_product_serialize(
            protection_product_protection_id=protection_product_protection_id,
            protection_product=protection_product,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CdmUpdateProtectionProductResponse",
            '400': "V1ExceptionResponse",
            '401': "V1ExceptionResponse",
            '403': "V1ExceptionResponse",
            '404': "V1ExceptionResponse",
            '405': "str",
            '500': "V1ExceptionResponse",
            '503': "V1ExceptionResponse",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _update_protection_product_serialize(
        self,
        protection_product_protection_id,
        protection_product,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = None

        _collection_formats: Dict[str, str] = {
        }

        _path_params: Dict[str, str] = {}
        _query_params: List[Tuple[str, str]] = []
        _header_params: Dict[str, Optional[str]] = _headers or {}
        _form_params: List[Tuple[str, str]] = []
        _files: Dict[
            str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
        ] = {}
        _body_params: Optional[bytes] = None

        # process the path parameters
        if protection_product_protection_id is not None:
            _path_params['protection_product.protection_id'] = protection_product_protection_id
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter
        if protection_product is not None:
            _body_params = protection_product


        # set the HTTP header `Accept`
        if 'Accept' not in _header_params:
            _header_params['Accept'] = self.api_client.select_header_accept(
                [
                    'application/json'
                ]
            )

        # set the HTTP header `Content-Type`
        if _content_type:
            _header_params['Content-Type'] = _content_type
        else:
            _default_content_type = (
                self.api_client.select_header_content_type(
                    [
                        'application/json'
                    ]
                )
            )
            if _default_content_type is not None:
                _header_params['Content-Type'] = _default_content_type

        # authentication setting
        _auth_settings: List[str] = [
        ]

        return self.api_client.param_serialize(
            method='PATCH',
            resource_path='/v1/acre/protection_product/{protection_product.protection_id}',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


