"""
    SmartyMeet Dev03 API REST

    No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)

    The version of the OpenAPI document: 1.0.1
    Contact: developer@smartymeet.com
    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 datetime import datetime
from pydantic import Field, StrictStr, field_validator
from typing import Any, Optional
from typing_extensions import Annotated
from smartytalent_client.models.create_finder_request_body import CreateFinderRequestBody
from smartytalent_client.models.finder_schema import FinderSchema
from smartytalent_client.models.finders_schema import FindersSchema
from smartytalent_client.models.update_finder_request_body import UpdateFinderRequestBody

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


class FindersApi:
    """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 create_finder(
        self,
        create_finder_request_body: Annotated[CreateFinderRequestBody, Field(description="A JSON object containing Finder information")],
        _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,
    ) -> FinderSchema:
        """Create Finder

        Creates a new finder search in your account.  ### Finder's Attributes  Here is a table that describes the attributes of the finder object:  | Attribute | Type | Required | Description | |-----------|------|----------|-------------| | `name` | string | Yes | The name of the finder search (1-256 characters) | | `type` | string | Yes | The type of search: talents, candidates, jobs, emails, users, reports | | `query` | object | No | The search query parameters sent to OpenSearch (e.g. `{ \"type\": \"talents\", \"jobId\": \"...\" }`) | | `results` | object | No | The search results (auto-populated after OpenSearch query execution) | | `status` | string | No | The current status: active (default), pending, completed, failed, archived | | `languageCode` | string | No | Language code for the finder (default: `en`) | | `settings` | object | No | Additional configuration settings | | `source` | string | No | Source of the finder creation (nullable) | | `ttl` | string | No | Time-to-live expiration timestamp in ISO 8601 format (nullable) | | `timestamps.created` | string | No | The date and time when the finder was created (ISO 8601 format) | | `timestamps.modified` | string | No | The date and time when the finder was last modified (ISO 8601 format) |  ### Relationships  | Relationship | Type | Description | |-------------|------|-------------| | `jobs` | array | Associated job resources | | `users` | array | Associated user resources | | `talents` | array | Associated talent resources | | `candidates` | array | Associated candidate resources |  ### Behavior  When a `query` is provided, OpenSearch is queried immediately. The `results` field is populated with matching documents and `status` is set to `completed` or `failed`.

        :param create_finder_request_body: A JSON object containing Finder information (required)
        :type create_finder_request_body: CreateFinderRequestBody
        :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_finder_serialize(
            create_finder_request_body=create_finder_request_body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        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_finder_with_http_info(
        self,
        create_finder_request_body: Annotated[CreateFinderRequestBody, Field(description="A JSON object containing Finder information")],
        _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[FinderSchema]:
        """Create Finder

        Creates a new finder search in your account.  ### Finder's Attributes  Here is a table that describes the attributes of the finder object:  | Attribute | Type | Required | Description | |-----------|------|----------|-------------| | `name` | string | Yes | The name of the finder search (1-256 characters) | | `type` | string | Yes | The type of search: talents, candidates, jobs, emails, users, reports | | `query` | object | No | The search query parameters sent to OpenSearch (e.g. `{ \"type\": \"talents\", \"jobId\": \"...\" }`) | | `results` | object | No | The search results (auto-populated after OpenSearch query execution) | | `status` | string | No | The current status: active (default), pending, completed, failed, archived | | `languageCode` | string | No | Language code for the finder (default: `en`) | | `settings` | object | No | Additional configuration settings | | `source` | string | No | Source of the finder creation (nullable) | | `ttl` | string | No | Time-to-live expiration timestamp in ISO 8601 format (nullable) | | `timestamps.created` | string | No | The date and time when the finder was created (ISO 8601 format) | | `timestamps.modified` | string | No | The date and time when the finder was last modified (ISO 8601 format) |  ### Relationships  | Relationship | Type | Description | |-------------|------|-------------| | `jobs` | array | Associated job resources | | `users` | array | Associated user resources | | `talents` | array | Associated talent resources | | `candidates` | array | Associated candidate resources |  ### Behavior  When a `query` is provided, OpenSearch is queried immediately. The `results` field is populated with matching documents and `status` is set to `completed` or `failed`.

        :param create_finder_request_body: A JSON object containing Finder information (required)
        :type create_finder_request_body: CreateFinderRequestBody
        :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_finder_serialize(
            create_finder_request_body=create_finder_request_body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        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_finder_without_preload_content(
        self,
        create_finder_request_body: Annotated[CreateFinderRequestBody, Field(description="A JSON object containing Finder information")],
        _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 Finder

        Creates a new finder search in your account.  ### Finder's Attributes  Here is a table that describes the attributes of the finder object:  | Attribute | Type | Required | Description | |-----------|------|----------|-------------| | `name` | string | Yes | The name of the finder search (1-256 characters) | | `type` | string | Yes | The type of search: talents, candidates, jobs, emails, users, reports | | `query` | object | No | The search query parameters sent to OpenSearch (e.g. `{ \"type\": \"talents\", \"jobId\": \"...\" }`) | | `results` | object | No | The search results (auto-populated after OpenSearch query execution) | | `status` | string | No | The current status: active (default), pending, completed, failed, archived | | `languageCode` | string | No | Language code for the finder (default: `en`) | | `settings` | object | No | Additional configuration settings | | `source` | string | No | Source of the finder creation (nullable) | | `ttl` | string | No | Time-to-live expiration timestamp in ISO 8601 format (nullable) | | `timestamps.created` | string | No | The date and time when the finder was created (ISO 8601 format) | | `timestamps.modified` | string | No | The date and time when the finder was last modified (ISO 8601 format) |  ### Relationships  | Relationship | Type | Description | |-------------|------|-------------| | `jobs` | array | Associated job resources | | `users` | array | Associated user resources | | `talents` | array | Associated talent resources | | `candidates` | array | Associated candidate resources |  ### Behavior  When a `query` is provided, OpenSearch is queried immediately. The `results` field is populated with matching documents and `status` is set to `completed` or `failed`.

        :param create_finder_request_body: A JSON object containing Finder information (required)
        :type create_finder_request_body: CreateFinderRequestBody
        :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_finder_serialize(
            create_finder_request_body=create_finder_request_body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _create_finder_serialize(
        self,
        create_finder_request_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 create_finder_request_body is not None:
            _body_params = create_finder_request_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] = [
            'ApiKeyAuth', 
            'OAuth2Auth'
        ]

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v1/finders',
            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_finder(
        self,
        finder_id: StrictStr,
        _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,
    ) -> None:
        """Delete Finder

        This endpoint allows you to delete a specific finder from your account. Once deleted, the finder's information will be permanently removed and cannot be recovered.

        :param finder_id: (required)
        :type finder_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._delete_finder_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '400': "ErrorSchema",
        }
        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_finder_with_http_info(
        self,
        finder_id: StrictStr,
        _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[None]:
        """Delete Finder

        This endpoint allows you to delete a specific finder from your account. Once deleted, the finder's information will be permanently removed and cannot be recovered.

        :param finder_id: (required)
        :type finder_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._delete_finder_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '400': "ErrorSchema",
        }
        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_finder_without_preload_content(
        self,
        finder_id: StrictStr,
        _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 Finder

        This endpoint allows you to delete a specific finder from your account. Once deleted, the finder's information will be permanently removed and cannot be recovered.

        :param finder_id: (required)
        :type finder_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._delete_finder_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '400': "ErrorSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _delete_finder_serialize(
        self,
        finder_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 finder_id is not None:
            _path_params['finderId'] = finder_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] = [
            'ApiKeyAuth', 
            'OAuth2Auth'
        ]

        return self.api_client.param_serialize(
            method='DELETE',
            resource_path='/v1/finders/{finderId}',
            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 finder_options(
        self,
        finder_id: StrictStr,
        _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,
    ) -> None:
        """Finder Options

        Enable CORS by returning correct headers

        :param finder_id: (required)
        :type finder_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._finder_options_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': None,
        }
        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 finder_options_with_http_info(
        self,
        finder_id: StrictStr,
        _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[None]:
        """Finder Options

        Enable CORS by returning correct headers

        :param finder_id: (required)
        :type finder_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._finder_options_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': None,
        }
        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 finder_options_without_preload_content(
        self,
        finder_id: StrictStr,
        _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:
        """Finder Options

        Enable CORS by returning correct headers

        :param finder_id: (required)
        :type finder_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._finder_options_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': None,
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _finder_options_serialize(
        self,
        finder_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 finder_id is not None:
            _path_params['finderId'] = finder_id
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter




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

        return self.api_client.param_serialize(
            method='OPTIONS',
            resource_path='/v1/finders/{finderId}',
            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 finders_options(
        self,
        _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,
    ) -> None:
        """Finders Options

        Enable CORS by returning correct headers

        :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._finders_options_serialize(
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': None,
        }
        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 finders_options_with_http_info(
        self,
        _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[None]:
        """Finders Options

        Enable CORS by returning correct headers

        :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._finders_options_serialize(
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': None,
        }
        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 finders_options_without_preload_content(
        self,
        _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:
        """Finders Options

        Enable CORS by returning correct headers

        :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._finders_options_serialize(
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': None,
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _finders_options_serialize(
        self,
        _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




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

        return self.api_client.param_serialize(
            method='OPTIONS',
            resource_path='/v1/finders',
            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 list_finders(
        self,
        filter_status: Annotated[Optional[StrictStr], Field(description="Returns finders with the current status (active, pending, completed, failed, archived). If not provided, the default value will be set to 'active'.")] = None,
        filter_type: Annotated[Optional[StrictStr], Field(description="Returns finders with the specified type (talents, candidates, jobs, emails, users, reports).")] = None,
        filter_created_from: Annotated[Optional[datetime], Field(description="Filters results to include only those created from the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_created_to: Annotated[Optional[datetime], Field(description="Filters results to include only those created up to the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_modified_from: Annotated[Optional[datetime], Field(description="Filters results to include only those modified from the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_modified_to: Annotated[Optional[datetime], Field(description="Filters results to include only those modified up to the specified date and time. The value must be in ISO 8601 format.")] = None,
        page_size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Specifies the number of items to retrieve per page. The maximum value is 100.")] = None,
        page_number: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Specifies the page number to retrieve. Used for traditional pagination.")] = None,
        page_after: Annotated[Optional[Any], Field(description="Returns the data encoded in Base64 format, used for cursor-based pagination")] = None,
        page_before: Annotated[Optional[StrictStr], Field(description="Returns the data encoded in Base64 format, used for cursor-based pagination")] = 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,
    ) -> FindersSchema:
        """List Finders

        Returns a collection of your account finders  ## Overview  Returns a collection of your account finders, sorted by the time they were inserted into the system in ascending order.  ### Finders Endpoints Pagination  The finders endpoints support two versions of pagination: traditional and cursor-based. Note that the parameters for these pagination methods cannot coexist; using them together will result in a bad request error.  :::tip Pagination tip  Ensure that when using traditional pagination, you use `pageNumber`, and when using cursor-based pagination, you use either `pageAfter` or `pageBefore`, but not both together.  :::  #### More information For more information, see the [pagination documentation](/docs/pagination).

        :param filter_status: Returns finders with the current status (active, pending, completed, failed, archived). If not provided, the default value will be set to 'active'.
        :type filter_status: str
        :param filter_type: Returns finders with the specified type (talents, candidates, jobs, emails, users, reports).
        :type filter_type: str
        :param filter_created_from: Filters results to include only those created from the specified date and time. The value must be in ISO 8601 format.
        :type filter_created_from: datetime
        :param filter_created_to: Filters results to include only those created up to the specified date and time. The value must be in ISO 8601 format.
        :type filter_created_to: datetime
        :param filter_modified_from: Filters results to include only those modified from the specified date and time. The value must be in ISO 8601 format.
        :type filter_modified_from: datetime
        :param filter_modified_to: Filters results to include only those modified up to the specified date and time. The value must be in ISO 8601 format.
        :type filter_modified_to: datetime
        :param page_size: Specifies the number of items to retrieve per page. The maximum value is 100.
        :type page_size: int
        :param page_number: Specifies the page number to retrieve. Used for traditional pagination.
        :type page_number: int
        :param page_after: Returns the data encoded in Base64 format, used for cursor-based pagination
        :type page_after: object
        :param page_before: Returns the data encoded in Base64 format, used for cursor-based pagination
        :type page_before: 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._list_finders_serialize(
            filter_status=filter_status,
            filter_type=filter_type,
            filter_created_from=filter_created_from,
            filter_created_to=filter_created_to,
            filter_modified_from=filter_modified_from,
            filter_modified_to=filter_modified_to,
            page_size=page_size,
            page_number=page_number,
            page_after=page_after,
            page_before=page_before,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FindersSchema",
            '400': "ErrorSchema",
            '401': "ErrorSchema",
            '404': "ErrorSchema",
            '500': "ErrorSchema",
        }
        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 list_finders_with_http_info(
        self,
        filter_status: Annotated[Optional[StrictStr], Field(description="Returns finders with the current status (active, pending, completed, failed, archived). If not provided, the default value will be set to 'active'.")] = None,
        filter_type: Annotated[Optional[StrictStr], Field(description="Returns finders with the specified type (talents, candidates, jobs, emails, users, reports).")] = None,
        filter_created_from: Annotated[Optional[datetime], Field(description="Filters results to include only those created from the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_created_to: Annotated[Optional[datetime], Field(description="Filters results to include only those created up to the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_modified_from: Annotated[Optional[datetime], Field(description="Filters results to include only those modified from the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_modified_to: Annotated[Optional[datetime], Field(description="Filters results to include only those modified up to the specified date and time. The value must be in ISO 8601 format.")] = None,
        page_size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Specifies the number of items to retrieve per page. The maximum value is 100.")] = None,
        page_number: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Specifies the page number to retrieve. Used for traditional pagination.")] = None,
        page_after: Annotated[Optional[Any], Field(description="Returns the data encoded in Base64 format, used for cursor-based pagination")] = None,
        page_before: Annotated[Optional[StrictStr], Field(description="Returns the data encoded in Base64 format, used for cursor-based pagination")] = 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[FindersSchema]:
        """List Finders

        Returns a collection of your account finders  ## Overview  Returns a collection of your account finders, sorted by the time they were inserted into the system in ascending order.  ### Finders Endpoints Pagination  The finders endpoints support two versions of pagination: traditional and cursor-based. Note that the parameters for these pagination methods cannot coexist; using them together will result in a bad request error.  :::tip Pagination tip  Ensure that when using traditional pagination, you use `pageNumber`, and when using cursor-based pagination, you use either `pageAfter` or `pageBefore`, but not both together.  :::  #### More information For more information, see the [pagination documentation](/docs/pagination).

        :param filter_status: Returns finders with the current status (active, pending, completed, failed, archived). If not provided, the default value will be set to 'active'.
        :type filter_status: str
        :param filter_type: Returns finders with the specified type (talents, candidates, jobs, emails, users, reports).
        :type filter_type: str
        :param filter_created_from: Filters results to include only those created from the specified date and time. The value must be in ISO 8601 format.
        :type filter_created_from: datetime
        :param filter_created_to: Filters results to include only those created up to the specified date and time. The value must be in ISO 8601 format.
        :type filter_created_to: datetime
        :param filter_modified_from: Filters results to include only those modified from the specified date and time. The value must be in ISO 8601 format.
        :type filter_modified_from: datetime
        :param filter_modified_to: Filters results to include only those modified up to the specified date and time. The value must be in ISO 8601 format.
        :type filter_modified_to: datetime
        :param page_size: Specifies the number of items to retrieve per page. The maximum value is 100.
        :type page_size: int
        :param page_number: Specifies the page number to retrieve. Used for traditional pagination.
        :type page_number: int
        :param page_after: Returns the data encoded in Base64 format, used for cursor-based pagination
        :type page_after: object
        :param page_before: Returns the data encoded in Base64 format, used for cursor-based pagination
        :type page_before: 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._list_finders_serialize(
            filter_status=filter_status,
            filter_type=filter_type,
            filter_created_from=filter_created_from,
            filter_created_to=filter_created_to,
            filter_modified_from=filter_modified_from,
            filter_modified_to=filter_modified_to,
            page_size=page_size,
            page_number=page_number,
            page_after=page_after,
            page_before=page_before,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FindersSchema",
            '400': "ErrorSchema",
            '401': "ErrorSchema",
            '404': "ErrorSchema",
            '500': "ErrorSchema",
        }
        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 list_finders_without_preload_content(
        self,
        filter_status: Annotated[Optional[StrictStr], Field(description="Returns finders with the current status (active, pending, completed, failed, archived). If not provided, the default value will be set to 'active'.")] = None,
        filter_type: Annotated[Optional[StrictStr], Field(description="Returns finders with the specified type (talents, candidates, jobs, emails, users, reports).")] = None,
        filter_created_from: Annotated[Optional[datetime], Field(description="Filters results to include only those created from the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_created_to: Annotated[Optional[datetime], Field(description="Filters results to include only those created up to the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_modified_from: Annotated[Optional[datetime], Field(description="Filters results to include only those modified from the specified date and time. The value must be in ISO 8601 format.")] = None,
        filter_modified_to: Annotated[Optional[datetime], Field(description="Filters results to include only those modified up to the specified date and time. The value must be in ISO 8601 format.")] = None,
        page_size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Specifies the number of items to retrieve per page. The maximum value is 100.")] = None,
        page_number: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Specifies the page number to retrieve. Used for traditional pagination.")] = None,
        page_after: Annotated[Optional[Any], Field(description="Returns the data encoded in Base64 format, used for cursor-based pagination")] = None,
        page_before: Annotated[Optional[StrictStr], Field(description="Returns the data encoded in Base64 format, used for cursor-based pagination")] = 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:
        """List Finders

        Returns a collection of your account finders  ## Overview  Returns a collection of your account finders, sorted by the time they were inserted into the system in ascending order.  ### Finders Endpoints Pagination  The finders endpoints support two versions of pagination: traditional and cursor-based. Note that the parameters for these pagination methods cannot coexist; using them together will result in a bad request error.  :::tip Pagination tip  Ensure that when using traditional pagination, you use `pageNumber`, and when using cursor-based pagination, you use either `pageAfter` or `pageBefore`, but not both together.  :::  #### More information For more information, see the [pagination documentation](/docs/pagination).

        :param filter_status: Returns finders with the current status (active, pending, completed, failed, archived). If not provided, the default value will be set to 'active'.
        :type filter_status: str
        :param filter_type: Returns finders with the specified type (talents, candidates, jobs, emails, users, reports).
        :type filter_type: str
        :param filter_created_from: Filters results to include only those created from the specified date and time. The value must be in ISO 8601 format.
        :type filter_created_from: datetime
        :param filter_created_to: Filters results to include only those created up to the specified date and time. The value must be in ISO 8601 format.
        :type filter_created_to: datetime
        :param filter_modified_from: Filters results to include only those modified from the specified date and time. The value must be in ISO 8601 format.
        :type filter_modified_from: datetime
        :param filter_modified_to: Filters results to include only those modified up to the specified date and time. The value must be in ISO 8601 format.
        :type filter_modified_to: datetime
        :param page_size: Specifies the number of items to retrieve per page. The maximum value is 100.
        :type page_size: int
        :param page_number: Specifies the page number to retrieve. Used for traditional pagination.
        :type page_number: int
        :param page_after: Returns the data encoded in Base64 format, used for cursor-based pagination
        :type page_after: object
        :param page_before: Returns the data encoded in Base64 format, used for cursor-based pagination
        :type page_before: 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._list_finders_serialize(
            filter_status=filter_status,
            filter_type=filter_type,
            filter_created_from=filter_created_from,
            filter_created_to=filter_created_to,
            filter_modified_from=filter_modified_from,
            filter_modified_to=filter_modified_to,
            page_size=page_size,
            page_number=page_number,
            page_after=page_after,
            page_before=page_before,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

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


    def _list_finders_serialize(
        self,
        filter_status,
        filter_type,
        filter_created_from,
        filter_created_to,
        filter_modified_from,
        filter_modified_to,
        page_size,
        page_number,
        page_after,
        page_before,
        _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
        if filter_status is not None:
            
            _query_params.append(('filterStatus', filter_status))
            
        if filter_type is not None:
            
            _query_params.append(('filterType', filter_type))
            
        if filter_created_from is not None:
            if isinstance(filter_created_from, datetime):
                _query_params.append(
                    (
                        'filterCreatedFrom',
                        filter_created_from.strftime(
                            self.api_client.configuration.datetime_format
                        )
                    )
                )
            else:
                _query_params.append(('filterCreatedFrom', filter_created_from))
            
        if filter_created_to is not None:
            if isinstance(filter_created_to, datetime):
                _query_params.append(
                    (
                        'filterCreatedTo',
                        filter_created_to.strftime(
                            self.api_client.configuration.datetime_format
                        )
                    )
                )
            else:
                _query_params.append(('filterCreatedTo', filter_created_to))
            
        if filter_modified_from is not None:
            if isinstance(filter_modified_from, datetime):
                _query_params.append(
                    (
                        'filterModifiedFrom',
                        filter_modified_from.strftime(
                            self.api_client.configuration.datetime_format
                        )
                    )
                )
            else:
                _query_params.append(('filterModifiedFrom', filter_modified_from))
            
        if filter_modified_to is not None:
            if isinstance(filter_modified_to, datetime):
                _query_params.append(
                    (
                        'filterModifiedTo',
                        filter_modified_to.strftime(
                            self.api_client.configuration.datetime_format
                        )
                    )
                )
            else:
                _query_params.append(('filterModifiedTo', filter_modified_to))
            
        if page_size is not None:
            
            _query_params.append(('pageSize', page_size))
            
        if page_number is not None:
            
            _query_params.append(('pageNumber', page_number))
            
        if page_after is not None:
            
            _query_params.append(('pageAfter', page_after))
            
        if page_before is not None:
            
            _query_params.append(('pageBefore', page_before))
            
        # 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] = [
            'ApiKeyAuth', 
            'OAuth2Auth'
        ]

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v1/finders',
            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 show_finder(
        self,
        finder_id: StrictStr,
        _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,
    ) -> FinderSchema:
        """Show Finder

        This endpoint retrieves details of a specific finder from your account. You can view information such as name, type, query, results, status, settings, and other relevant attributes of the finder.

        :param finder_id: (required)
        :type finder_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._show_finder_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        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 show_finder_with_http_info(
        self,
        finder_id: StrictStr,
        _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[FinderSchema]:
        """Show Finder

        This endpoint retrieves details of a specific finder from your account. You can view information such as name, type, query, results, status, settings, and other relevant attributes of the finder.

        :param finder_id: (required)
        :type finder_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._show_finder_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        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 show_finder_without_preload_content(
        self,
        finder_id: StrictStr,
        _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:
        """Show Finder

        This endpoint retrieves details of a specific finder from your account. You can view information such as name, type, query, results, status, settings, and other relevant attributes of the finder.

        :param finder_id: (required)
        :type finder_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._show_finder_serialize(
            finder_id=finder_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _show_finder_serialize(
        self,
        finder_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 finder_id is not None:
            _path_params['finderId'] = finder_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] = [
            'ApiKeyAuth', 
            'OAuth2Auth'
        ]

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v1/finders/{finderId}',
            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_finder(
        self,
        finder_id: StrictStr,
        update_finder_request_body: Annotated[UpdateFinderRequestBody, Field(description="A JSON object containing Finder information")],
        _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,
    ) -> FinderSchema:
        """Update Finder

        This endpoint allows you to update details of a specific finder in your account. You can modify information such as name, query, status, settings, and other relevant attributes of the finder. Only the fields provided in the request will be updated.

        :param finder_id: (required)
        :type finder_id: str
        :param update_finder_request_body: A JSON object containing Finder information (required)
        :type update_finder_request_body: UpdateFinderRequestBody
        :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_finder_serialize(
            finder_id=finder_id,
            update_finder_request_body=update_finder_request_body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        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_finder_with_http_info(
        self,
        finder_id: StrictStr,
        update_finder_request_body: Annotated[UpdateFinderRequestBody, Field(description="A JSON object containing Finder information")],
        _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[FinderSchema]:
        """Update Finder

        This endpoint allows you to update details of a specific finder in your account. You can modify information such as name, query, status, settings, and other relevant attributes of the finder. Only the fields provided in the request will be updated.

        :param finder_id: (required)
        :type finder_id: str
        :param update_finder_request_body: A JSON object containing Finder information (required)
        :type update_finder_request_body: UpdateFinderRequestBody
        :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_finder_serialize(
            finder_id=finder_id,
            update_finder_request_body=update_finder_request_body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        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_finder_without_preload_content(
        self,
        finder_id: StrictStr,
        update_finder_request_body: Annotated[UpdateFinderRequestBody, Field(description="A JSON object containing Finder information")],
        _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 Finder

        This endpoint allows you to update details of a specific finder in your account. You can modify information such as name, query, status, settings, and other relevant attributes of the finder. Only the fields provided in the request will be updated.

        :param finder_id: (required)
        :type finder_id: str
        :param update_finder_request_body: A JSON object containing Finder information (required)
        :type update_finder_request_body: UpdateFinderRequestBody
        :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_finder_serialize(
            finder_id=finder_id,
            update_finder_request_body=update_finder_request_body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "FinderSchema",
            '400': "ErrorSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            _request_timeout=_request_timeout
        )
        return response_data.response


    def _update_finder_serialize(
        self,
        finder_id,
        update_finder_request_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 finder_id is not None:
            _path_params['finderId'] = finder_id
        # process the query parameters
        # process the header parameters
        # process the form parameters
        # process the body parameter
        if update_finder_request_body is not None:
            _body_params = update_finder_request_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] = [
            'ApiKeyAuth', 
            'OAuth2Auth'
        ]

        return self.api_client.param_serialize(
            method='PATCH',
            resource_path='/v1/finders/{finderId}',
            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
        )


