# coding: utf-8

"""
    Teambition Open API

    Teambition Open API

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

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


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

from pydantic import Field, StrictInt, StrictStr
from typing import Any, Dict, Optional
from typing_extensions import Annotated
from teambition_oapi_sdk.model.archive_task_v3_response import ArchiveTaskV3Response
from teambition_oapi_sdk.model.check_user_visible_in_app_response import CheckUserVisibleInAppResponse
from teambition_oapi_sdk.model.create_task_comment_v3_request import CreateTaskCommentV3Request
from teambition_oapi_sdk.model.create_task_comment_v3_response import CreateTaskCommentV3Response
from teambition_oapi_sdk.model.create_task_dependency_v3_request import CreateTaskDependencyV3Request
from teambition_oapi_sdk.model.create_task_dependency_v3_response import CreateTaskDependencyV3Response
from teambition_oapi_sdk.model.create_task_link_v3_request import CreateTaskLinkV3Request
from teambition_oapi_sdk.model.create_task_link_v3_response import CreateTaskLinkV3Response
from teambition_oapi_sdk.model.create_task_trace_v3_request import CreateTaskTraceV3Request
from teambition_oapi_sdk.model.create_task_trace_v3_response import CreateTaskTraceV3Response
from teambition_oapi_sdk.model.create_task_v3_request import CreateTaskV3Request
from teambition_oapi_sdk.model.create_task_v3_response import CreateTaskV3Response
from teambition_oapi_sdk.model.delete_task_dependency_v3_response import DeleteTaskDependencyV3Response
from teambition_oapi_sdk.model.delete_task_link_v3_response import DeleteTaskLinkV3Response
from teambition_oapi_sdk.model.delete_task_v3_response import DeleteTaskV3Response
from teambition_oapi_sdk.model.get_project_table_custom_field_response import GetProjectTableCustomFieldResponse
from teambition_oapi_sdk.model.get_task_dependencies_v3_response import GetTaskDependenciesV3Response
from teambition_oapi_sdk.model.get_task_links_v3_response import GetTaskLinksV3Response
from teambition_oapi_sdk.model.get_task_traces_v3_response import GetTaskTracesV3Response
from teambition_oapi_sdk.model.get_template_v2_response import GetTemplateV2Response
from teambition_oapi_sdk.model.list_task_activities_v3_response import ListTaskActivitiesV3Response
from teambition_oapi_sdk.model.move_org_task_to_project_request import MoveOrgTaskToProjectRequest
from teambition_oapi_sdk.model.move_org_task_to_project_response import MoveOrgTaskToProjectResponse
from teambition_oapi_sdk.model.move_task_v3_request import MoveTaskV3Request
from teambition_oapi_sdk.model.move_task_v3_response import MoveTaskV3Response
from teambition_oapi_sdk.model.put_v3_task_node_complete_request import PutV3TaskNodeCompleteRequest
from teambition_oapi_sdk.model.put_v3_task_node_complete_response import PutV3TaskNodeCompleteResponse
from teambition_oapi_sdk.model.put_v3_task_node_list_response import PutV3TaskNodeListResponse
from teambition_oapi_sdk.model.put_v3_task_node_rollback_request import PutV3TaskNodeRollbackRequest
from teambition_oapi_sdk.model.put_v3_task_node_rollback_response import PutV3TaskNodeRollbackResponse
from teambition_oapi_sdk.model.put_v3_task_node_update_request import PutV3TaskNodeUpdateRequest
from teambition_oapi_sdk.model.put_v3_task_node_update_response import PutV3TaskNodeUpdateResponse
from teambition_oapi_sdk.model.query_task_v3_response import QueryTaskV3Response
from teambition_oapi_sdk.model.render_task_rtf_v3_response import RenderTaskRtfV3Response
from teambition_oapi_sdk.model.restore_task_v3_request import RestoreTaskV3Request
from teambition_oapi_sdk.model.search_tasks_by_tql_response import SearchTasksByTQLResponse
from teambition_oapi_sdk.model.search_user_tasks_v3_response import SearchUserTasksV3Response
from teambition_oapi_sdk.model.update_project_table_custom_field_response import UpdateProjectTableCustomFieldResponse
from teambition_oapi_sdk.model.update_task_content_v3_request import UpdateTaskContentV3Request
from teambition_oapi_sdk.model.update_task_content_v3_response import UpdateTaskContentV3Response
from teambition_oapi_sdk.model.update_task_cusom_field_by_instance_v3_request import UpdateTaskCusomFieldByInstanceV3Request
from teambition_oapi_sdk.model.update_task_cusom_field_by_instance_v3_response import UpdateTaskCusomFieldByInstanceV3Response
from teambition_oapi_sdk.model.update_task_cusom_field_v3_request import UpdateTaskCusomFieldV3Request
from teambition_oapi_sdk.model.update_task_custom_field_request import UpdateTaskCustomFieldRequest
from teambition_oapi_sdk.model.update_task_custom_field_response import UpdateTaskCustomFieldResponse
from teambition_oapi_sdk.model.update_task_custom_field_v2_request import UpdateTaskCustomFieldV2Request
from teambition_oapi_sdk.model.update_task_due_date_v3_request import UpdateTaskDueDateV3Request
from teambition_oapi_sdk.model.update_task_due_date_v3_response import UpdateTaskDueDateV3Response
from teambition_oapi_sdk.model.update_task_executor_v3_request import UpdateTaskExecutorV3Request
from teambition_oapi_sdk.model.update_task_executor_v3_response import UpdateTaskExecutorV3Response
from teambition_oapi_sdk.model.update_task_lock_v3_request import UpdateTaskLockV3Request
from teambition_oapi_sdk.model.update_task_members_v3_request import UpdateTaskMembersV3Request
from teambition_oapi_sdk.model.update_task_members_v3_response import UpdateTaskMembersV3Response
from teambition_oapi_sdk.model.update_task_note_v3_request import UpdateTaskNoteV3Request
from teambition_oapi_sdk.model.update_task_note_v3_response import UpdateTaskNoteV3Response
from teambition_oapi_sdk.model.update_task_parent_v3_request import UpdateTaskParentV3Request
from teambition_oapi_sdk.model.update_task_parent_v3_response import UpdateTaskParentV3Response
from teambition_oapi_sdk.model.update_task_priority_v3_request import UpdateTaskPriorityV3Request
from teambition_oapi_sdk.model.update_task_priority_v3_response import UpdateTaskPriorityV3Response
from teambition_oapi_sdk.model.update_task_progress_v3_request import UpdateTaskProgressV3Request
from teambition_oapi_sdk.model.update_task_progress_v3_response import UpdateTaskProgressV3Response
from teambition_oapi_sdk.model.update_task_sfc_v3_request import UpdateTaskSfcV3Request
from teambition_oapi_sdk.model.update_task_sfc_v3_response import UpdateTaskSfcV3Response
from teambition_oapi_sdk.model.update_task_sprint_v3_request import UpdateTaskSprintV3Request
from teambition_oapi_sdk.model.update_task_sprint_v3_response import UpdateTaskSprintV3Response
from teambition_oapi_sdk.model.update_task_stage_v3_request import UpdateTaskStageV3Request
from teambition_oapi_sdk.model.update_task_stage_v3_response import UpdateTaskStageV3Response
from teambition_oapi_sdk.model.update_task_start_date_v3_request import UpdateTaskStartDateV3Request
from teambition_oapi_sdk.model.update_task_start_date_v3_response import UpdateTaskStartDateV3Response
from teambition_oapi_sdk.model.update_task_status_v3_request import UpdateTaskStatusV3Request
from teambition_oapi_sdk.model.update_task_status_v3_response import UpdateTaskStatusV3Response
from teambition_oapi_sdk.model.update_task_story_point_v3_request import UpdateTaskStoryPointV3Request
from teambition_oapi_sdk.model.update_task_story_point_v3_response import UpdateTaskStoryPointV3Response
from teambition_oapi_sdk.model.update_task_table_custom_field_v3_request import UpdateTaskTableCustomFieldV3Request
from teambition_oapi_sdk.model.update_task_tags_v3_request import UpdateTaskTagsV3Request
from teambition_oapi_sdk.model.update_task_tags_v3_response import UpdateTaskTagsV3Response
from teambition_oapi_sdk.model.update_task_visibility_v3_request import UpdateTaskVisibilityV3Request
from teambition_oapi_sdk.model.update_task_visibility_v3_response import UpdateTaskVisibilityV3Response

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

class TaskApi:
    """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 archive_task_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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,
    ) -> ArchiveTaskV3Response:
        """归档任务(移入回收站)

        归档任务(移入回收站)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._archive_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ArchiveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 archive_task_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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[ArchiveTaskV3Response]:
        """归档任务(移入回收站)

        归档任务(移入回收站)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._archive_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ArchiveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 archive_task_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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:
        """归档任务(移入回收站)

        归档任务(移入回收站)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._archive_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ArchiveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _archive_task_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/archive"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/archive',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def create_task_comment_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="评论人ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_comment_v3_request: Optional[CreateTaskCommentV3Request] = 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,
    ) -> CreateTaskCommentV3Response:
        """评论任务

        评论任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 评论人ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_comment_v3_request: 
        :type create_task_comment_v3_request: CreateTaskCommentV3Request
        :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_task_comment_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_comment_v3_request=create_task_comment_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskCommentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_comment_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="评论人ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_comment_v3_request: Optional[CreateTaskCommentV3Request] = 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[CreateTaskCommentV3Response]:
        """评论任务

        评论任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 评论人ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_comment_v3_request: 
        :type create_task_comment_v3_request: CreateTaskCommentV3Request
        :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_task_comment_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_comment_v3_request=create_task_comment_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskCommentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_comment_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="评论人ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_comment_v3_request: Optional[CreateTaskCommentV3Request] = 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:
        """评论任务

        评论任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 评论人ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_comment_v3_request: 
        :type create_task_comment_v3_request: CreateTaskCommentV3Request
        :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_task_comment_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_comment_v3_request=create_task_comment_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskCommentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _create_task_comment_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        create_task_comment_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if create_task_comment_v3_request is not None:
            _body_params = create_task_comment_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/comment"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/comment',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def create_task_dependency_v3(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_dependency_v3_request: Optional[CreateTaskDependencyV3Request] = 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,
    ) -> CreateTaskDependencyV3Response:
        """创建任务依赖

        创建任务依赖

        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_dependency_v3_request: 
        :type create_task_dependency_v3_request: CreateTaskDependencyV3Request
        :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_task_dependency_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_dependency_v3_request=create_task_dependency_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskDependencyV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_dependency_v3_with_http_info(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_dependency_v3_request: Optional[CreateTaskDependencyV3Request] = 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[CreateTaskDependencyV3Response]:
        """创建任务依赖

        创建任务依赖

        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_dependency_v3_request: 
        :type create_task_dependency_v3_request: CreateTaskDependencyV3Request
        :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_task_dependency_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_dependency_v3_request=create_task_dependency_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskDependencyV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_dependency_v3_without_preload_content(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_dependency_v3_request: Optional[CreateTaskDependencyV3Request] = 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:
        """创建任务依赖

        创建任务依赖

        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_dependency_v3_request: 
        :type create_task_dependency_v3_request: CreateTaskDependencyV3Request
        :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_task_dependency_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_dependency_v3_request=create_task_dependency_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskDependencyV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _create_task_dependency_v3_serialize(
        self,
        x_operator_id,
        x_tenant_id,
        create_task_dependency_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if create_task_dependency_v3_request is not None:
            _body_params = create_task_dependency_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/dependency/create"

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


    @validate_call
    def create_task_link_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_link_v3_request: Optional[CreateTaskLinkV3Request] = 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,
    ) -> CreateTaskLinkV3Response:
        """创建任务关联

        创建任务关联

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_link_v3_request: 
        :type create_task_link_v3_request: CreateTaskLinkV3Request
        :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_task_link_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_link_v3_request=create_task_link_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskLinkV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_link_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_link_v3_request: Optional[CreateTaskLinkV3Request] = 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[CreateTaskLinkV3Response]:
        """创建任务关联

        创建任务关联

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_link_v3_request: 
        :type create_task_link_v3_request: CreateTaskLinkV3Request
        :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_task_link_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_link_v3_request=create_task_link_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskLinkV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_link_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_link_v3_request: Optional[CreateTaskLinkV3Request] = 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:
        """创建任务关联

        创建任务关联

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_link_v3_request: 
        :type create_task_link_v3_request: CreateTaskLinkV3Request
        :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_task_link_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_link_v3_request=create_task_link_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskLinkV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _create_task_link_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        create_task_link_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if create_task_link_v3_request is not None:
            _body_params = create_task_link_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/objectlinks"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/objectlinks',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def create_task_trace_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务 ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者 ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_trace_v3_request: Optional[CreateTaskTraceV3Request] = 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,
    ) -> CreateTaskTraceV3Response:
        """创建任务进展

        用来创建 / 更新 任务的最新进展

        :param task_id: 任务 ID (required)
        :type task_id: str
        :param x_operator_id: 操作者 ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_trace_v3_request: 
        :type create_task_trace_v3_request: CreateTaskTraceV3Request
        :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_task_trace_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_trace_v3_request=create_task_trace_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskTraceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_trace_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务 ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者 ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_trace_v3_request: Optional[CreateTaskTraceV3Request] = 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[CreateTaskTraceV3Response]:
        """创建任务进展

        用来创建 / 更新 任务的最新进展

        :param task_id: 任务 ID (required)
        :type task_id: str
        :param x_operator_id: 操作者 ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_trace_v3_request: 
        :type create_task_trace_v3_request: CreateTaskTraceV3Request
        :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_task_trace_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_trace_v3_request=create_task_trace_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskTraceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_trace_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务 ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者 ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_trace_v3_request: Optional[CreateTaskTraceV3Request] = 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:
        """创建任务进展

        用来创建 / 更新 任务的最新进展

        :param task_id: 任务 ID (required)
        :type task_id: str
        :param x_operator_id: 操作者 ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_trace_v3_request: 
        :type create_task_trace_v3_request: CreateTaskTraceV3Request
        :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_task_trace_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_trace_v3_request=create_task_trace_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskTraceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _create_task_trace_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        create_task_trace_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if create_task_trace_v3_request is not None:
            _body_params = create_task_trace_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/trace/create"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/trace/create',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def create_task_v3(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="任务创建人")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_v3_request: Optional[CreateTaskV3Request] = 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,
    ) -> CreateTaskV3Response:
        """创建任务

        创建任务

        :param x_operator_id: 任务创建人
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_v3_request: 
        :type create_task_v3_request: CreateTaskV3Request
        :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_task_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_v3_request=create_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_v3_with_http_info(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="任务创建人")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_v3_request: Optional[CreateTaskV3Request] = 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[CreateTaskV3Response]:
        """创建任务

        创建任务

        :param x_operator_id: 任务创建人
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_v3_request: 
        :type create_task_v3_request: CreateTaskV3Request
        :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_task_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_v3_request=create_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_v3_without_preload_content(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="任务创建人")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        create_task_v3_request: Optional[CreateTaskV3Request] = 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:
        """创建任务

        创建任务

        :param x_operator_id: 任务创建人
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param create_task_v3_request: 
        :type create_task_v3_request: CreateTaskV3Request
        :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_task_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            create_task_v3_request=create_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CreateTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _create_task_v3_serialize(
        self,
        x_operator_id,
        x_tenant_id,
        create_task_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if create_task_v3_request is not None:
            _body_params = create_task_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/create"

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/create',
            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_task_dependency_v3(
        self,
        dependency_id: Annotated[StrictStr, Field(description="依赖ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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,
    ) -> DeleteTaskDependencyV3Response:
        """删除任务依赖

        删除任务依赖

        :param dependency_id: 依赖ID (required)
        :type dependency_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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_task_dependency_v3_serialize(
            dependency_id=dependency_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskDependencyV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_dependency_v3_with_http_info(
        self,
        dependency_id: Annotated[StrictStr, Field(description="依赖ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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[DeleteTaskDependencyV3Response]:
        """删除任务依赖

        删除任务依赖

        :param dependency_id: 依赖ID (required)
        :type dependency_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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_task_dependency_v3_serialize(
            dependency_id=dependency_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskDependencyV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_dependency_v3_without_preload_content(
        self,
        dependency_id: Annotated[StrictStr, Field(description="依赖ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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:
        """删除任务依赖

        删除任务依赖

        :param dependency_id: 依赖ID (required)
        :type dependency_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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_task_dependency_v3_serialize(
            dependency_id=dependency_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskDependencyV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _delete_task_dependency_v3_serialize(
        self,
        dependency_id,
        x_operator_id,
        x_tenant_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 dependency_id is not None:
            _path_params['dependencyId'] = dependency_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/dependency/{dependencyId}/delete"
        url = url.replace('{' + 'dependencyId' + '}', str(dependency_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/dependency/{dependencyId}/delete',
            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_task_link_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        objectlink_id: Annotated[StrictStr, Field(description="关联ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        body: Optional[Dict[str, Any]] = 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,
    ) -> DeleteTaskLinkV3Response:
        """删除任务关联

        删除任务关联

        :param task_id: 任务ID (required)
        :type task_id: str
        :param objectlink_id: 关联ID (required)
        :type objectlink_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param body: 
        :type body: object
        :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_task_link_v3_serialize(
            task_id=task_id,
            objectlink_id=objectlink_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskLinkV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_link_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        objectlink_id: Annotated[StrictStr, Field(description="关联ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        body: Optional[Dict[str, Any]] = 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[DeleteTaskLinkV3Response]:
        """删除任务关联

        删除任务关联

        :param task_id: 任务ID (required)
        :type task_id: str
        :param objectlink_id: 关联ID (required)
        :type objectlink_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param body: 
        :type body: object
        :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_task_link_v3_serialize(
            task_id=task_id,
            objectlink_id=objectlink_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskLinkV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_link_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        objectlink_id: Annotated[StrictStr, Field(description="关联ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        body: Optional[Dict[str, Any]] = 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:
        """删除任务关联

        删除任务关联

        :param task_id: 任务ID (required)
        :type task_id: str
        :param objectlink_id: 关联ID (required)
        :type objectlink_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param body: 
        :type body: object
        :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_task_link_v3_serialize(
            task_id=task_id,
            objectlink_id=objectlink_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskLinkV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _delete_task_link_v3_serialize(
        self,
        task_id,
        objectlink_id,
        x_operator_id,
        x_tenant_id,
        body,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        if objectlink_id is not None:
            _path_params['objectlinkId'] = objectlink_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if body is not None:
            _body_params = body


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

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

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

        # Build the full URL
        url = _host + "/v3/task/{taskId}/objectlinks/{objectlinkId}"
        url = url.replace('{' + 'taskId' + '}', str(task_id))
        url = url.replace('{' + 'objectlinkId' + '}', str(objectlink_id))

        return self.api_client.param_serialize(
            method='DELETE',
            resource_path='/v3/task/{taskId}/objectlinks/{objectlinkId}',
            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_task_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        body: Optional[Dict[str, Any]] = 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,
    ) -> DeleteTaskV3Response:
        """删除任务

        删除任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param body: 
        :type body: object
        :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_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        body: Optional[Dict[str, Any]] = 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[DeleteTaskV3Response]:
        """删除任务

        删除任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param body: 
        :type body: object
        :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_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        body: Optional[Dict[str, Any]] = 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:
        """删除任务

        删除任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param body: 
        :type body: object
        :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_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            body=body,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "DeleteTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _delete_task_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        body,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if body is not None:
            _body_params = body


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

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

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

        # Build the full URL
        url = _host + "/v3/task/{taskId}/delete"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/delete',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def get_task_dependencies_v3(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        task_id: Annotated[Optional[StrictStr], Field(description="任务ID集合,使用逗号分隔")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="返回数量")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="pageToken")] = 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,
    ) -> GetTaskDependenciesV3Response:
        """获取任务依赖

        获取任务依赖

        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param task_id: 任务ID集合,使用逗号分隔
        :type task_id: str
        :param page_size: 返回数量
        :type page_size: int
        :param page_token: pageToken
        :type page_token: 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._get_task_dependencies_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            task_id=task_id,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskDependenciesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data

    @validate_call
    def get_task_dependencies_v3_with_http_info(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        task_id: Annotated[Optional[StrictStr], Field(description="任务ID集合,使用逗号分隔")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="返回数量")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="pageToken")] = 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[GetTaskDependenciesV3Response]:
        """获取任务依赖

        获取任务依赖

        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param task_id: 任务ID集合,使用逗号分隔
        :type task_id: str
        :param page_size: 返回数量
        :type page_size: int
        :param page_token: pageToken
        :type page_token: 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._get_task_dependencies_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            task_id=task_id,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskDependenciesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )

    @validate_call
    def get_task_dependencies_v3_without_preload_content(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        task_id: Annotated[Optional[StrictStr], Field(description="任务ID集合,使用逗号分隔")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="返回数量")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="pageToken")] = 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:
        """获取任务依赖

        获取任务依赖

        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param task_id: 任务ID集合,使用逗号分隔
        :type task_id: str
        :param page_size: 返回数量
        :type page_size: int
        :param page_token: pageToken
        :type page_token: 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._get_task_dependencies_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            task_id=task_id,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskDependenciesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _get_task_dependencies_v3_serialize(
        self,
        x_operator_id,
        x_tenant_id,
        task_id,
        page_size,
        page_token,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            
            _query_params.append(('taskId', task_id))
            
        if page_size is not None:
            
            _query_params.append(('pageSize', page_size))
            
        if page_token is not None:
            
            _query_params.append(('pageToken', page_token))
            
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/dependency"

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


    @validate_call
    def get_task_links_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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,
    ) -> GetTaskLinksV3Response:
        """获取任务关联列表

        获取任务关联列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._get_task_links_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskLinksV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data

    @validate_call
    def get_task_links_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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[GetTaskLinksV3Response]:
        """获取任务关联列表

        获取任务关联列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._get_task_links_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskLinksV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )

    @validate_call
    def get_task_links_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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:
        """获取任务关联列表

        获取任务关联列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._get_task_links_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskLinksV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _get_task_links_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/objectlinks"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/task/{taskId}/objectlinks',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def get_task_table_custom_field_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Optional[StrictStr] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        customfield_id: Optional[StrictStr] = 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,
    ) -> GetProjectTableCustomFieldResponse:
        """获取任务的表格自定义字段

        获取任务的表格自定义字段

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param customfield_id: 
        :type customfield_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._get_task_table_custom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            customfield_id=customfield_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetProjectTableCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data

    @validate_call
    def get_task_table_custom_field_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Optional[StrictStr] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        customfield_id: Optional[StrictStr] = 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[GetProjectTableCustomFieldResponse]:
        """获取任务的表格自定义字段

        获取任务的表格自定义字段

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param customfield_id: 
        :type customfield_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._get_task_table_custom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            customfield_id=customfield_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetProjectTableCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )

    @validate_call
    def get_task_table_custom_field_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Optional[StrictStr] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        customfield_id: Optional[StrictStr] = 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:
        """获取任务的表格自定义字段

        获取任务的表格自定义字段

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param customfield_id: 
        :type customfield_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._get_task_table_custom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            customfield_id=customfield_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetProjectTableCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _get_task_table_custom_field_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        customfield_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        if customfield_id is not None:
            
            _query_params.append(('customfieldId', customfield_id))
            
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/customfield/table"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/task/{taskId}/customfield/table',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def get_task_traces_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务 ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者 ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="每页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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,
    ) -> GetTaskTracesV3Response:
        """获取任务进展

        获取任务进展

        :param task_id: 任务 ID (required)
        :type task_id: str
        :param x_operator_id: 操作者 ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param page_size: 每页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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._get_task_traces_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskTracesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data

    @validate_call
    def get_task_traces_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务 ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者 ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="每页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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[GetTaskTracesV3Response]:
        """获取任务进展

        获取任务进展

        :param task_id: 任务 ID (required)
        :type task_id: str
        :param x_operator_id: 操作者 ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param page_size: 每页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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._get_task_traces_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskTracesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )

    @validate_call
    def get_task_traces_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务 ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者 ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="每页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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:
        """获取任务进展

        获取任务进展

        :param task_id: 任务 ID (required)
        :type task_id: str
        :param x_operator_id: 操作者 ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param page_size: 每页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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._get_task_traces_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTaskTracesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _get_task_traces_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        page_size,
        page_token,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        if page_size is not None:
            
            _query_params.append(('pageSize', page_size))
            
        if page_token is not None:
            
            _query_params.append(('pageToken', page_token))
            
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/traces"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/task/{taskId}/traces',
            path_params=_path_params,
            query_params=_query_params,
            header_params=_header_params,
            body=_body_params,
            post_params=_form_params,
            files=_files,
            auth_settings=_auth_settings,
            collection_formats=_collection_formats,
            _host=_host,
            _request_auth=_request_auth
        )


    @validate_call
    def get_template_v2(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        template_id: Annotated[Optional[StrictStr], Field(description="模板 ID")] = 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,
    ) -> GetTemplateV2Response:
        """根据ID获取任务类型信息V2

        根据ID获取任务类型信息V2

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param template_id: 模板 ID
        :type template_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._get_template_v2_serialize(
            x_tenant_id=x_tenant_id,
            template_id=template_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTemplateV2Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data

    @validate_call
    def get_template_v2_with_http_info(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        template_id: Annotated[Optional[StrictStr], Field(description="模板 ID")] = 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[GetTemplateV2Response]:
        """根据ID获取任务类型信息V2

        根据ID获取任务类型信息V2

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param template_id: 模板 ID
        :type template_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._get_template_v2_serialize(
            x_tenant_id=x_tenant_id,
            template_id=template_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTemplateV2Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )

    @validate_call
    def get_template_v2_without_preload_content(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        template_id: Annotated[Optional[StrictStr], Field(description="模板 ID")] = 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:
        """根据ID获取任务类型信息V2

        根据ID获取任务类型信息V2

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param template_id: 模板 ID
        :type template_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._get_template_v2_serialize(
            x_tenant_id=x_tenant_id,
            template_id=template_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "GetTemplateV2Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _get_template_v2_serialize(
        self,
        x_tenant_id,
        template_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 template_id is not None:
            
            _query_params.append(('templateId', template_id))
            
        # process the header parameters
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v2/template/info"

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v2/template/info',
            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_task_activities_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页大小")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = None,
        actions: Annotated[Optional[StrictStr], Field(description="过滤动态名称，用逗号「,」分隔")] = None,
        exclude_actions: Annotated[Optional[StrictStr], Field(description="排除动态名称，用逗号「,」分隔")] = None,
        creator_ids: Annotated[Optional[StrictStr], Field(description="需要过滤的动态创建人ID，用逗号分隔")] = None,
        language: Annotated[Optional[StrictStr], Field(description="支持语言参数，返回可读动态文本，可选值 zh_CN, zh_TW, en_US")] = None,
        order_by: Annotated[Optional[StrictStr], Field(description="排序方式，可选值 created, created_desc, updated, updated_desc")] = 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,
    ) -> ListTaskActivitiesV3Response:
        """列出任务动态

        列出任务动态

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param page_size: 分页大小
        :type page_size: int
        :param page_token: 分页标
        :type page_token: str
        :param actions: 过滤动态名称，用逗号「,」分隔
        :type actions: str
        :param exclude_actions: 排除动态名称，用逗号「,」分隔
        :type exclude_actions: str
        :param creator_ids: 需要过滤的动态创建人ID，用逗号分隔
        :type creator_ids: str
        :param language: 支持语言参数，返回可读动态文本，可选值 zh_CN, zh_TW, en_US
        :type language: str
        :param order_by: 排序方式，可选值 created, created_desc, updated, updated_desc
        :type order_by: 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_task_activities_v3_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            page_size=page_size,
            page_token=page_token,
            actions=actions,
            exclude_actions=exclude_actions,
            creator_ids=creator_ids,
            language=language,
            order_by=order_by,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ListTaskActivitiesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_activities_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页大小")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = None,
        actions: Annotated[Optional[StrictStr], Field(description="过滤动态名称，用逗号「,」分隔")] = None,
        exclude_actions: Annotated[Optional[StrictStr], Field(description="排除动态名称，用逗号「,」分隔")] = None,
        creator_ids: Annotated[Optional[StrictStr], Field(description="需要过滤的动态创建人ID，用逗号分隔")] = None,
        language: Annotated[Optional[StrictStr], Field(description="支持语言参数，返回可读动态文本，可选值 zh_CN, zh_TW, en_US")] = None,
        order_by: Annotated[Optional[StrictStr], Field(description="排序方式，可选值 created, created_desc, updated, updated_desc")] = 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[ListTaskActivitiesV3Response]:
        """列出任务动态

        列出任务动态

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param page_size: 分页大小
        :type page_size: int
        :param page_token: 分页标
        :type page_token: str
        :param actions: 过滤动态名称，用逗号「,」分隔
        :type actions: str
        :param exclude_actions: 排除动态名称，用逗号「,」分隔
        :type exclude_actions: str
        :param creator_ids: 需要过滤的动态创建人ID，用逗号分隔
        :type creator_ids: str
        :param language: 支持语言参数，返回可读动态文本，可选值 zh_CN, zh_TW, en_US
        :type language: str
        :param order_by: 排序方式，可选值 created, created_desc, updated, updated_desc
        :type order_by: 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_task_activities_v3_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            page_size=page_size,
            page_token=page_token,
            actions=actions,
            exclude_actions=exclude_actions,
            creator_ids=creator_ids,
            language=language,
            order_by=order_by,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ListTaskActivitiesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_activities_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页大小")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = None,
        actions: Annotated[Optional[StrictStr], Field(description="过滤动态名称，用逗号「,」分隔")] = None,
        exclude_actions: Annotated[Optional[StrictStr], Field(description="排除动态名称，用逗号「,」分隔")] = None,
        creator_ids: Annotated[Optional[StrictStr], Field(description="需要过滤的动态创建人ID，用逗号分隔")] = None,
        language: Annotated[Optional[StrictStr], Field(description="支持语言参数，返回可读动态文本，可选值 zh_CN, zh_TW, en_US")] = None,
        order_by: Annotated[Optional[StrictStr], Field(description="排序方式，可选值 created, created_desc, updated, updated_desc")] = 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:
        """列出任务动态

        列出任务动态

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param page_size: 分页大小
        :type page_size: int
        :param page_token: 分页标
        :type page_token: str
        :param actions: 过滤动态名称，用逗号「,」分隔
        :type actions: str
        :param exclude_actions: 排除动态名称，用逗号「,」分隔
        :type exclude_actions: str
        :param creator_ids: 需要过滤的动态创建人ID，用逗号分隔
        :type creator_ids: str
        :param language: 支持语言参数，返回可读动态文本，可选值 zh_CN, zh_TW, en_US
        :type language: str
        :param order_by: 排序方式，可选值 created, created_desc, updated, updated_desc
        :type order_by: 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_task_activities_v3_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            page_size=page_size,
            page_token=page_token,
            actions=actions,
            exclude_actions=exclude_actions,
            creator_ids=creator_ids,
            language=language,
            order_by=order_by,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ListTaskActivitiesV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _list_task_activities_v3_serialize(
        self,
        task_id,
        x_tenant_id,
        page_size,
        page_token,
        actions,
        exclude_actions,
        creator_ids,
        language,
        order_by,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        if page_size is not None:
            
            _query_params.append(('pageSize', page_size))
            
        if page_token is not None:
            
            _query_params.append(('pageToken', page_token))
            
        if actions is not None:
            
            _query_params.append(('actions', actions))
            
        if exclude_actions is not None:
            
            _query_params.append(('excludeActions', exclude_actions))
            
        if creator_ids is not None:
            
            _query_params.append(('creatorIds', creator_ids))
            
        if language is not None:
            
            _query_params.append(('language', language))
            
        if order_by is not None:
            
            _query_params.append(('orderBy', order_by))
            
        # process the header parameters
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/activity/list"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/task/{taskId}/activity/list',
            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 move_org_task_to_project(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        move_org_task_to_project_request: Optional[MoveOrgTaskToProjectRequest] = 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,
    ) -> MoveOrgTaskToProjectResponse:
        """轻任务移动到项目中

        轻任务移动到项目中

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param move_org_task_to_project_request: 
        :type move_org_task_to_project_request: MoveOrgTaskToProjectRequest
        :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._move_org_task_to_project_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            move_org_task_to_project_request=move_org_task_to_project_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "MoveOrgTaskToProjectResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 move_org_task_to_project_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        move_org_task_to_project_request: Optional[MoveOrgTaskToProjectRequest] = 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[MoveOrgTaskToProjectResponse]:
        """轻任务移动到项目中

        轻任务移动到项目中

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param move_org_task_to_project_request: 
        :type move_org_task_to_project_request: MoveOrgTaskToProjectRequest
        :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._move_org_task_to_project_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            move_org_task_to_project_request=move_org_task_to_project_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "MoveOrgTaskToProjectResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 move_org_task_to_project_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        move_org_task_to_project_request: Optional[MoveOrgTaskToProjectRequest] = 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:
        """轻任务移动到项目中

        轻任务移动到项目中

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param move_org_task_to_project_request: 
        :type move_org_task_to_project_request: MoveOrgTaskToProjectRequest
        :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._move_org_task_to_project_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            move_org_task_to_project_request=move_org_task_to_project_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "MoveOrgTaskToProjectResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _move_org_task_to_project_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        move_org_task_to_project_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if move_org_task_to_project_request is not None:
            _body_params = move_org_task_to_project_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/organization-task/{taskId}/move"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/organization-task/{taskId}/move',
            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 move_task_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        move_task_v3_request: Optional[MoveTaskV3Request] = 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,
    ) -> MoveTaskV3Response:
        """跨项目移动任务

        跨项目移动任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param move_task_v3_request: 
        :type move_task_v3_request: MoveTaskV3Request
        :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._move_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            move_task_v3_request=move_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "MoveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 move_task_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        move_task_v3_request: Optional[MoveTaskV3Request] = 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[MoveTaskV3Response]:
        """跨项目移动任务

        跨项目移动任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param move_task_v3_request: 
        :type move_task_v3_request: MoveTaskV3Request
        :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._move_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            move_task_v3_request=move_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "MoveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 move_task_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        move_task_v3_request: Optional[MoveTaskV3Request] = 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:
        """跨项目移动任务

        跨项目移动任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param move_task_v3_request: 
        :type move_task_v3_request: MoveTaskV3Request
        :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._move_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            move_task_v3_request=move_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "MoveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _move_task_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        move_task_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if move_task_v3_request is not None:
            _body_params = move_task_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/move"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/move',
            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 put_v3_task_node_complete(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID (ObjectId格式)")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_complete_request: Optional[PutV3TaskNodeCompleteRequest] = 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,
    ) -> PutV3TaskNodeCompleteResponse:
        """完成任务节点

        完成任务节点，仅能完成status=begin的“进行中”节点

        :param task_id: 任务ID (ObjectId格式) (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_complete_request: 
        :type put_v3_task_node_complete_request: PutV3TaskNodeCompleteRequest
        :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._put_v3_task_node_complete_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_complete_request=put_v3_task_node_complete_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeCompleteResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_complete_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID (ObjectId格式)")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_complete_request: Optional[PutV3TaskNodeCompleteRequest] = 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[PutV3TaskNodeCompleteResponse]:
        """完成任务节点

        完成任务节点，仅能完成status=begin的“进行中”节点

        :param task_id: 任务ID (ObjectId格式) (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_complete_request: 
        :type put_v3_task_node_complete_request: PutV3TaskNodeCompleteRequest
        :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._put_v3_task_node_complete_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_complete_request=put_v3_task_node_complete_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeCompleteResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_complete_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID (ObjectId格式)")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_complete_request: Optional[PutV3TaskNodeCompleteRequest] = 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:
        """完成任务节点

        完成任务节点，仅能完成status=begin的“进行中”节点

        :param task_id: 任务ID (ObjectId格式) (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_complete_request: 
        :type put_v3_task_node_complete_request: PutV3TaskNodeCompleteRequest
        :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._put_v3_task_node_complete_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_complete_request=put_v3_task_node_complete_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeCompleteResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _put_v3_task_node_complete_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        put_v3_task_node_complete_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if put_v3_task_node_complete_request is not None:
            _body_params = put_v3_task_node_complete_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/node/complete"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/node/complete',
            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 put_v3_task_node_list(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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,
    ) -> PutV3TaskNodeListResponse:
        """获取任务节点列表

        获取任务节点列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._put_v3_task_node_list_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeListResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_list_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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[PutV3TaskNodeListResponse]:
        """获取任务节点列表

        获取任务节点列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._put_v3_task_node_list_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeListResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_list_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = 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:
        """获取任务节点列表

        获取任务节点列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_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._put_v3_task_node_list_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeListResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _put_v3_task_node_list_serialize(
        self,
        task_id,
        x_tenant_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/node/list"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/task/{taskId}/node/list',
            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 put_v3_task_node_rollback(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_rollback_request: Optional[PutV3TaskNodeRollbackRequest] = 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,
    ) -> PutV3TaskNodeRollbackResponse:
        """回滚任务节点

        回滚任务节点，仅能回滚status=finish的“已完成”节点

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_rollback_request: 
        :type put_v3_task_node_rollback_request: PutV3TaskNodeRollbackRequest
        :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._put_v3_task_node_rollback_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_rollback_request=put_v3_task_node_rollback_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeRollbackResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_rollback_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_rollback_request: Optional[PutV3TaskNodeRollbackRequest] = 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[PutV3TaskNodeRollbackResponse]:
        """回滚任务节点

        回滚任务节点，仅能回滚status=finish的“已完成”节点

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_rollback_request: 
        :type put_v3_task_node_rollback_request: PutV3TaskNodeRollbackRequest
        :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._put_v3_task_node_rollback_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_rollback_request=put_v3_task_node_rollback_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeRollbackResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_rollback_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_rollback_request: Optional[PutV3TaskNodeRollbackRequest] = 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:
        """回滚任务节点

        回滚任务节点，仅能回滚status=finish的“已完成”节点

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_rollback_request: 
        :type put_v3_task_node_rollback_request: PutV3TaskNodeRollbackRequest
        :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._put_v3_task_node_rollback_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_rollback_request=put_v3_task_node_rollback_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeRollbackResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _put_v3_task_node_rollback_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        put_v3_task_node_rollback_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if put_v3_task_node_rollback_request is not None:
            _body_params = put_v3_task_node_rollback_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/node/rollback"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/node/rollback',
            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 put_v3_task_node_update(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_update_request: Optional[PutV3TaskNodeUpdateRequest] = 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,
    ) -> PutV3TaskNodeUpdateResponse:
        """更新任务节点

        更新任务节点

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_update_request: 
        :type put_v3_task_node_update_request: PutV3TaskNodeUpdateRequest
        :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._put_v3_task_node_update_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_update_request=put_v3_task_node_update_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeUpdateResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_update_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_update_request: Optional[PutV3TaskNodeUpdateRequest] = 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[PutV3TaskNodeUpdateResponse]:
        """更新任务节点

        更新任务节点

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_update_request: 
        :type put_v3_task_node_update_request: PutV3TaskNodeUpdateRequest
        :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._put_v3_task_node_update_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_update_request=put_v3_task_node_update_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeUpdateResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 put_v3_task_node_update_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        put_v3_task_node_update_request: Optional[PutV3TaskNodeUpdateRequest] = 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:
        """更新任务节点

        更新任务节点

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param put_v3_task_node_update_request: 
        :type put_v3_task_node_update_request: PutV3TaskNodeUpdateRequest
        :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._put_v3_task_node_update_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            put_v3_task_node_update_request=put_v3_task_node_update_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "PutV3TaskNodeUpdateResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _put_v3_task_node_update_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        put_v3_task_node_update_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if put_v3_task_node_update_request is not None:
            _body_params = put_v3_task_node_update_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/node/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/node/update',
            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 query_task_v3(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID, 如果存在会检查该成员可见的任务")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        task_id: Annotated[Optional[StrictStr], Field(description="任务ID集合,使用逗号分隔,和parentTaskId冲突(选其一)")] = None,
        short_ids: Annotated[Optional[StrictStr], Field(description="任务短ID集合,使用逗号分隔")] = None,
        parent_task_id: Annotated[Optional[StrictStr], Field(description="父任务ID,和taskId冲突(选其一)")] = 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,
    ) -> QueryTaskV3Response:
        """查询任务详情

        查询任务详情

        :param x_operator_id: 查询人ID, 如果存在会检查该成员可见的任务
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param task_id: 任务ID集合,使用逗号分隔,和parentTaskId冲突(选其一)
        :type task_id: str
        :param short_ids: 任务短ID集合,使用逗号分隔
        :type short_ids: str
        :param parent_task_id: 父任务ID,和taskId冲突(选其一)
        :type parent_task_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._query_task_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            task_id=task_id,
            short_ids=short_ids,
            parent_task_id=parent_task_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "QueryTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 query_task_v3_with_http_info(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID, 如果存在会检查该成员可见的任务")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        task_id: Annotated[Optional[StrictStr], Field(description="任务ID集合,使用逗号分隔,和parentTaskId冲突(选其一)")] = None,
        short_ids: Annotated[Optional[StrictStr], Field(description="任务短ID集合,使用逗号分隔")] = None,
        parent_task_id: Annotated[Optional[StrictStr], Field(description="父任务ID,和taskId冲突(选其一)")] = 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[QueryTaskV3Response]:
        """查询任务详情

        查询任务详情

        :param x_operator_id: 查询人ID, 如果存在会检查该成员可见的任务
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param task_id: 任务ID集合,使用逗号分隔,和parentTaskId冲突(选其一)
        :type task_id: str
        :param short_ids: 任务短ID集合,使用逗号分隔
        :type short_ids: str
        :param parent_task_id: 父任务ID,和taskId冲突(选其一)
        :type parent_task_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._query_task_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            task_id=task_id,
            short_ids=short_ids,
            parent_task_id=parent_task_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "QueryTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 query_task_v3_without_preload_content(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID, 如果存在会检查该成员可见的任务")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        task_id: Annotated[Optional[StrictStr], Field(description="任务ID集合,使用逗号分隔,和parentTaskId冲突(选其一)")] = None,
        short_ids: Annotated[Optional[StrictStr], Field(description="任务短ID集合,使用逗号分隔")] = None,
        parent_task_id: Annotated[Optional[StrictStr], Field(description="父任务ID,和taskId冲突(选其一)")] = 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:
        """查询任务详情

        查询任务详情

        :param x_operator_id: 查询人ID, 如果存在会检查该成员可见的任务
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param task_id: 任务ID集合,使用逗号分隔,和parentTaskId冲突(选其一)
        :type task_id: str
        :param short_ids: 任务短ID集合,使用逗号分隔
        :type short_ids: str
        :param parent_task_id: 父任务ID,和taskId冲突(选其一)
        :type parent_task_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._query_task_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            task_id=task_id,
            short_ids=short_ids,
            parent_task_id=parent_task_id,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "QueryTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _query_task_v3_serialize(
        self,
        x_operator_id,
        x_tenant_id,
        task_id,
        short_ids,
        parent_task_id,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            
            _query_params.append(('taskId', task_id))
            
        if short_ids is not None:
            
            _query_params.append(('shortIds', short_ids))
            
        if parent_task_id is not None:
            
            _query_params.append(('parentTaskId', parent_task_id))
            
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/query"

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/task/query',
            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 render_task_rtf_v3(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        rtf_fields: Annotated[Optional[StrictStr], Field(description="富文本字段标识，多个标识之间用逗号分割，最多支持 50 个 - 富文本字段：`任务ID:cf:字段ID` 如 `60471fc306c1e046e63759c4:cf:63d61d1cbde6c83a2ce729d6` - 富文本备注：`任务ID:note` 如 `60471fc306c1e046e63759c4:note` - 富文本进展：`任务ID:trace:进展ID` 如 `60471fc306c1e046e63759c4:trace:63d61d1cbde6c83a2ce729d6` ")] = None,
        html_expire_seconds: Annotated[Optional[StrictInt], Field(description="渲染html时内容过期时间，默认为 1800(秒)，最小为 600(秒)，最大为 3600(秒)")] = 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,
    ) -> RenderTaskRtfV3Response:
        """任务富文本内容渲染为 html

        任务富文本内容渲染为 html

        :param x_operator_id: 查询人ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param rtf_fields: 富文本字段标识，多个标识之间用逗号分割，最多支持 50 个 - 富文本字段：`任务ID:cf:字段ID` 如 `60471fc306c1e046e63759c4:cf:63d61d1cbde6c83a2ce729d6` - 富文本备注：`任务ID:note` 如 `60471fc306c1e046e63759c4:note` - 富文本进展：`任务ID:trace:进展ID` 如 `60471fc306c1e046e63759c4:trace:63d61d1cbde6c83a2ce729d6` 
        :type rtf_fields: str
        :param html_expire_seconds: 渲染html时内容过期时间，默认为 1800(秒)，最小为 600(秒)，最大为 3600(秒)
        :type html_expire_seconds: int
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._render_task_rtf_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            rtf_fields=rtf_fields,
            html_expire_seconds=html_expire_seconds,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "RenderTaskRtfV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 render_task_rtf_v3_with_http_info(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        rtf_fields: Annotated[Optional[StrictStr], Field(description="富文本字段标识，多个标识之间用逗号分割，最多支持 50 个 - 富文本字段：`任务ID:cf:字段ID` 如 `60471fc306c1e046e63759c4:cf:63d61d1cbde6c83a2ce729d6` - 富文本备注：`任务ID:note` 如 `60471fc306c1e046e63759c4:note` - 富文本进展：`任务ID:trace:进展ID` 如 `60471fc306c1e046e63759c4:trace:63d61d1cbde6c83a2ce729d6` ")] = None,
        html_expire_seconds: Annotated[Optional[StrictInt], Field(description="渲染html时内容过期时间，默认为 1800(秒)，最小为 600(秒)，最大为 3600(秒)")] = 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[RenderTaskRtfV3Response]:
        """任务富文本内容渲染为 html

        任务富文本内容渲染为 html

        :param x_operator_id: 查询人ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param rtf_fields: 富文本字段标识，多个标识之间用逗号分割，最多支持 50 个 - 富文本字段：`任务ID:cf:字段ID` 如 `60471fc306c1e046e63759c4:cf:63d61d1cbde6c83a2ce729d6` - 富文本备注：`任务ID:note` 如 `60471fc306c1e046e63759c4:note` - 富文本进展：`任务ID:trace:进展ID` 如 `60471fc306c1e046e63759c4:trace:63d61d1cbde6c83a2ce729d6` 
        :type rtf_fields: str
        :param html_expire_seconds: 渲染html时内容过期时间，默认为 1800(秒)，最小为 600(秒)，最大为 3600(秒)
        :type html_expire_seconds: int
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._render_task_rtf_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            rtf_fields=rtf_fields,
            html_expire_seconds=html_expire_seconds,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "RenderTaskRtfV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 render_task_rtf_v3_without_preload_content(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        rtf_fields: Annotated[Optional[StrictStr], Field(description="富文本字段标识，多个标识之间用逗号分割，最多支持 50 个 - 富文本字段：`任务ID:cf:字段ID` 如 `60471fc306c1e046e63759c4:cf:63d61d1cbde6c83a2ce729d6` - 富文本备注：`任务ID:note` 如 `60471fc306c1e046e63759c4:note` - 富文本进展：`任务ID:trace:进展ID` 如 `60471fc306c1e046e63759c4:trace:63d61d1cbde6c83a2ce729d6` ")] = None,
        html_expire_seconds: Annotated[Optional[StrictInt], Field(description="渲染html时内容过期时间，默认为 1800(秒)，最小为 600(秒)，最大为 3600(秒)")] = 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:
        """任务富文本内容渲染为 html

        任务富文本内容渲染为 html

        :param x_operator_id: 查询人ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param rtf_fields: 富文本字段标识，多个标识之间用逗号分割，最多支持 50 个 - 富文本字段：`任务ID:cf:字段ID` 如 `60471fc306c1e046e63759c4:cf:63d61d1cbde6c83a2ce729d6` - 富文本备注：`任务ID:note` 如 `60471fc306c1e046e63759c4:note` - 富文本进展：`任务ID:trace:进展ID` 如 `60471fc306c1e046e63759c4:trace:63d61d1cbde6c83a2ce729d6` 
        :type rtf_fields: str
        :param html_expire_seconds: 渲染html时内容过期时间，默认为 1800(秒)，最小为 600(秒)，最大为 3600(秒)
        :type html_expire_seconds: int
        :param _request_timeout: timeout setting for this request. If one
                                 number provided, it will be total request
                                 timeout. It can also be a pair (tuple) of
                                 (connection, read) timeouts.
        :type _request_timeout: int, tuple(int, int), optional
        :param _request_auth: set to override the auth_settings for an a single
                              request; this effectively ignores the
                              authentication in the spec for a single request.
        :type _request_auth: dict, optional
        :param _content_type: force content-type for the request.
        :type _content_type: str, Optional
        :param _headers: set to override the headers for a single
                         request; this effectively ignores the headers
                         in the spec for a single request.
        :type _headers: dict, optional
        :param _host_index: set to override the host_index for a single
                            request; this effectively ignores the host_index
                            in the spec for a single request.
        :type _host_index: int, optional
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._render_task_rtf_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            rtf_fields=rtf_fields,
            html_expire_seconds=html_expire_seconds,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "RenderTaskRtfV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _render_task_rtf_v3_serialize(
        self,
        x_operator_id,
        x_tenant_id,
        rtf_fields,
        html_expire_seconds,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 rtf_fields is not None:
            
            _query_params.append(('rtfFields', rtf_fields))
            
        if html_expire_seconds is not None:
            
            _query_params.append(('htmlExpireSeconds', html_expire_seconds))
            
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/rtf/render"

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/task/rtf/render',
            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 restore_task_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        restore_task_v3_request: Optional[RestoreTaskV3Request] = 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,
    ) -> ArchiveTaskV3Response:
        """恢复任务(移出回收站)

        恢复任务(移出回收站)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param restore_task_v3_request: 
        :type restore_task_v3_request: RestoreTaskV3Request
        :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._restore_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            restore_task_v3_request=restore_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ArchiveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 restore_task_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        restore_task_v3_request: Optional[RestoreTaskV3Request] = 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[ArchiveTaskV3Response]:
        """恢复任务(移出回收站)

        恢复任务(移出回收站)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param restore_task_v3_request: 
        :type restore_task_v3_request: RestoreTaskV3Request
        :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._restore_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            restore_task_v3_request=restore_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ArchiveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 restore_task_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        restore_task_v3_request: Optional[RestoreTaskV3Request] = 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:
        """恢复任务(移出回收站)

        恢复任务(移出回收站)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param restore_task_v3_request: 
        :type restore_task_v3_request: RestoreTaskV3Request
        :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._restore_task_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            restore_task_v3_request=restore_task_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "ArchiveTaskV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _restore_task_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        restore_task_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if restore_task_v3_request is not None:
            _body_params = restore_task_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/restore"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/restore',
            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 search_tasks_by_tql(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Optional[StrictStr] = None,
        tql: Annotated[Optional[StrictStr], Field(description="企业下任务搜索TQL语句")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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,
    ) -> SearchTasksByTQLResponse:
        """(Deprecated) 通过TQL搜索自由任务和项目任务ID

        通过TQL搜索自由任务和项目任务ID

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id:
        :type x_operator_id: str
        :param tql: 企业下任务搜索TQL语句
        :type tql: str
        :param page_size: 分页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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
        warnings.warn("GET /all-task/search is deprecated.", DeprecationWarning)

        _param = self._search_tasks_by_tql_serialize(
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            tql=tql,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchTasksByTQLResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 search_tasks_by_tql_with_http_info(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Optional[StrictStr] = None,
        tql: Annotated[Optional[StrictStr], Field(description="企业下任务搜索TQL语句")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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[SearchTasksByTQLResponse]:
        """(Deprecated) 通过TQL搜索自由任务和项目任务ID

        通过TQL搜索自由任务和项目任务ID

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id:
        :type x_operator_id: str
        :param tql: 企业下任务搜索TQL语句
        :type tql: str
        :param page_size: 分页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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
        warnings.warn("GET /all-task/search is deprecated.", DeprecationWarning)

        _param = self._search_tasks_by_tql_serialize(
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            tql=tql,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchTasksByTQLResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 search_tasks_by_tql_without_preload_content(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Optional[StrictStr] = None,
        tql: Annotated[Optional[StrictStr], Field(description="企业下任务搜索TQL语句")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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:
        """(Deprecated) 通过TQL搜索自由任务和项目任务ID

        通过TQL搜索自由任务和项目任务ID

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id:
        :type x_operator_id: str
        :param tql: 企业下任务搜索TQL语句
        :type tql: str
        :param page_size: 分页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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
        warnings.warn("GET /all-task/search is deprecated.", DeprecationWarning)

        _param = self._search_tasks_by_tql_serialize(
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            tql=tql,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchTasksByTQLResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _search_tasks_by_tql_serialize(
        self,
        x_tenant_id,
        x_operator_id,
        tql,
        page_size,
        page_token,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 tql is not None:
            
            _query_params.append(('tql', tql))
            
        if page_size is not None:
            
            _query_params.append(('pageSize', page_size))
            
        if page_token is not None:
            
            _query_params.append(('pageToken', page_token))
            
        # process the header parameters
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        if x_operator_id is not None:
            _header_params['X-Operator-Id'] = x_operator_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/all-task/search"

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/all-task/search',
            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 search_tasks_by_tqlv2(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID, 为空时查询全部")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        tql: Annotated[Optional[StrictStr], Field(description="企业下任务搜索TQL语句")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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,
    ) -> SearchTasksByTQLResponse:
        """通过TQL搜索自由任务和项目任务ID (V2)

        通过TQL搜索自由任务和项目任务ID

        :param x_operator_id: 操作者ID, 为空时查询全部
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param tql: 企业下任务搜索TQL语句
        :type tql: str
        :param page_size: 分页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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._search_tasks_by_tqlv2_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            tql=tql,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchTasksByTQLResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 search_tasks_by_tqlv2_with_http_info(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID, 为空时查询全部")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        tql: Annotated[Optional[StrictStr], Field(description="企业下任务搜索TQL语句")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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[SearchTasksByTQLResponse]:
        """通过TQL搜索自由任务和项目任务ID (V2)

        通过TQL搜索自由任务和项目任务ID

        :param x_operator_id: 操作者ID, 为空时查询全部
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param tql: 企业下任务搜索TQL语句
        :type tql: str
        :param page_size: 分页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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._search_tasks_by_tqlv2_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            tql=tql,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchTasksByTQLResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 search_tasks_by_tqlv2_without_preload_content(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID, 为空时查询全部")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        tql: Annotated[Optional[StrictStr], Field(description="企业下任务搜索TQL语句")] = None,
        page_size: Annotated[Optional[StrictInt], Field(description="分页长度")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="分页标")] = 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:
        """通过TQL搜索自由任务和项目任务ID (V2)

        通过TQL搜索自由任务和项目任务ID

        :param x_operator_id: 操作者ID, 为空时查询全部
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param tql: 企业下任务搜索TQL语句
        :type tql: str
        :param page_size: 分页长度
        :type page_size: int
        :param page_token: 分页标
        :type page_token: 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._search_tasks_by_tqlv2_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            tql=tql,
            page_size=page_size,
            page_token=page_token,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchTasksByTQLResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _search_tasks_by_tqlv2_serialize(
        self,
        x_operator_id,
        x_tenant_id,
        tql,
        page_size,
        page_token,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 tql is not None:
            
            _query_params.append(('tql', tql))
            
        if page_size is not None:
            
            _query_params.append(('pageSize', page_size))
            
        if page_token is not None:
            
            _query_params.append(('pageToken', page_token))
            
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v2/all-task/search"

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v2/all-task/search',
            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 search_user_tasks_v3(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID, 必传")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        role_types: Annotated[Optional[StrictStr], Field(description="用户的任务角色, creator,executor,involveMember 中的一个或多个,以 ','拼接。例如：creator,executor")] = None,
        tql: Annotated[Optional[StrictStr], Field(description="tql 参考企业下任务搜索TQL说明")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="下一页翻页token,从上一次请求结果中获得")] = None,
        page_size: Annotated[Optional[StrictStr], Field(description="分页大小,默认10")] = 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,
    ) -> SearchUserTasksV3Response:
        """搜索用户的任务

        搜索用户的任务，用户参与的/用户执行的/用户创建的

        :param x_operator_id: 查询人ID, 必传
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param role_types: 用户的任务角色, creator,executor,involveMember 中的一个或多个,以 ','拼接。例如：creator,executor
        :type role_types: str
        :param tql: tql 参考企业下任务搜索TQL说明
        :type tql: str
        :param page_token: 下一页翻页token,从上一次请求结果中获得
        :type page_token: str
        :param page_size: 分页大小,默认10
        :type page_size: 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._search_user_tasks_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            role_types=role_types,
            tql=tql,
            page_token=page_token,
            page_size=page_size,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchUserTasksV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 search_user_tasks_v3_with_http_info(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID, 必传")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        role_types: Annotated[Optional[StrictStr], Field(description="用户的任务角色, creator,executor,involveMember 中的一个或多个,以 ','拼接。例如：creator,executor")] = None,
        tql: Annotated[Optional[StrictStr], Field(description="tql 参考企业下任务搜索TQL说明")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="下一页翻页token,从上一次请求结果中获得")] = None,
        page_size: Annotated[Optional[StrictStr], Field(description="分页大小,默认10")] = 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[SearchUserTasksV3Response]:
        """搜索用户的任务

        搜索用户的任务，用户参与的/用户执行的/用户创建的

        :param x_operator_id: 查询人ID, 必传
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param role_types: 用户的任务角色, creator,executor,involveMember 中的一个或多个,以 ','拼接。例如：creator,executor
        :type role_types: str
        :param tql: tql 参考企业下任务搜索TQL说明
        :type tql: str
        :param page_token: 下一页翻页token,从上一次请求结果中获得
        :type page_token: str
        :param page_size: 分页大小,默认10
        :type page_size: 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._search_user_tasks_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            role_types=role_types,
            tql=tql,
            page_token=page_token,
            page_size=page_size,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchUserTasksV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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 search_user_tasks_v3_without_preload_content(
        self,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="查询人ID, 必传")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        role_types: Annotated[Optional[StrictStr], Field(description="用户的任务角色, creator,executor,involveMember 中的一个或多个,以 ','拼接。例如：creator,executor")] = None,
        tql: Annotated[Optional[StrictStr], Field(description="tql 参考企业下任务搜索TQL说明")] = None,
        page_token: Annotated[Optional[StrictStr], Field(description="下一页翻页token,从上一次请求结果中获得")] = None,
        page_size: Annotated[Optional[StrictStr], Field(description="分页大小,默认10")] = 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:
        """搜索用户的任务

        搜索用户的任务，用户参与的/用户执行的/用户创建的

        :param x_operator_id: 查询人ID, 必传
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param role_types: 用户的任务角色, creator,executor,involveMember 中的一个或多个,以 ','拼接。例如：creator,executor
        :type role_types: str
        :param tql: tql 参考企业下任务搜索TQL说明
        :type tql: str
        :param page_token: 下一页翻页token,从上一次请求结果中获得
        :type page_token: str
        :param page_size: 分页大小,默认10
        :type page_size: 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._search_user_tasks_v3_serialize(
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            role_types=role_types,
            tql=tql,
            page_token=page_token,
            page_size=page_size,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "SearchUserTasksV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _search_user_tasks_v3_serialize(
        self,
        x_operator_id,
        x_tenant_id,
        role_types,
        tql,
        page_token,
        page_size,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 role_types is not None:
            
            _query_params.append(('roleTypes', role_types))
            
        if tql is not None:
            
            _query_params.append(('tql', tql))
            
        if page_token is not None:
            
            _query_params.append(('pageToken', page_token))
            
        if page_size is not None:
            
            _query_params.append(('pageSize', page_size))
            
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/usertasks/search"

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/v3/usertasks/search',
            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_task_content_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_content_v3_request: Optional[UpdateTaskContentV3Request] = 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,
    ) -> UpdateTaskContentV3Response:
        """更新任务标题

        更新任务标题

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_content_v3_request: 
        :type update_task_content_v3_request: UpdateTaskContentV3Request
        :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_task_content_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_content_v3_request=update_task_content_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskContentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_content_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_content_v3_request: Optional[UpdateTaskContentV3Request] = 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[UpdateTaskContentV3Response]:
        """更新任务标题

        更新任务标题

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_content_v3_request: 
        :type update_task_content_v3_request: UpdateTaskContentV3Request
        :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_task_content_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_content_v3_request=update_task_content_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskContentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_content_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_content_v3_request: Optional[UpdateTaskContentV3Request] = 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:
        """更新任务标题

        更新任务标题

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_content_v3_request: 
        :type update_task_content_v3_request: UpdateTaskContentV3Request
        :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_task_content_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_content_v3_request=update_task_content_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskContentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_content_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_content_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_content_v3_request is not None:
            _body_params = update_task_content_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/content"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/content',
            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_task_cusom_field_by_instance_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        instance_id: Annotated[StrictStr, Field(description="字段InstanceId")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_cusom_field_by_instance_v3_request: Optional[UpdateTaskCusomFieldByInstanceV3Request] = 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,
    ) -> UpdateTaskCusomFieldByInstanceV3Response:
        """根据字段InstanceId更新任务自定义字段值(弃用)

        根据字段InstanceId更新任务自定义字段值(弃用)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param instance_id: 字段InstanceId (required)
        :type instance_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_cusom_field_by_instance_v3_request: 
        :type update_task_cusom_field_by_instance_v3_request: UpdateTaskCusomFieldByInstanceV3Request
        :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_task_cusom_field_by_instance_v3_serialize(
            task_id=task_id,
            instance_id=instance_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_cusom_field_by_instance_v3_request=update_task_cusom_field_by_instance_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_cusom_field_by_instance_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        instance_id: Annotated[StrictStr, Field(description="字段InstanceId")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_cusom_field_by_instance_v3_request: Optional[UpdateTaskCusomFieldByInstanceV3Request] = 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[UpdateTaskCusomFieldByInstanceV3Response]:
        """根据字段InstanceId更新任务自定义字段值(弃用)

        根据字段InstanceId更新任务自定义字段值(弃用)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param instance_id: 字段InstanceId (required)
        :type instance_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_cusom_field_by_instance_v3_request: 
        :type update_task_cusom_field_by_instance_v3_request: UpdateTaskCusomFieldByInstanceV3Request
        :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_task_cusom_field_by_instance_v3_serialize(
            task_id=task_id,
            instance_id=instance_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_cusom_field_by_instance_v3_request=update_task_cusom_field_by_instance_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_cusom_field_by_instance_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        instance_id: Annotated[StrictStr, Field(description="字段InstanceId")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_cusom_field_by_instance_v3_request: Optional[UpdateTaskCusomFieldByInstanceV3Request] = 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:
        """根据字段InstanceId更新任务自定义字段值(弃用)

        根据字段InstanceId更新任务自定义字段值(弃用)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param instance_id: 字段InstanceId (required)
        :type instance_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_cusom_field_by_instance_v3_request: 
        :type update_task_cusom_field_by_instance_v3_request: UpdateTaskCusomFieldByInstanceV3Request
        :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_task_cusom_field_by_instance_v3_serialize(
            task_id=task_id,
            instance_id=instance_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_cusom_field_by_instance_v3_request=update_task_cusom_field_by_instance_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_cusom_field_by_instance_v3_serialize(
        self,
        task_id,
        instance_id,
        x_operator_id,
        x_tenant_id,
        update_task_cusom_field_by_instance_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        if instance_id is not None:
            _path_params['instanceId'] = instance_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_cusom_field_by_instance_v3_request is not None:
            _body_params = update_task_cusom_field_by_instance_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/customfield-instance/{instanceId}/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))
        url = url.replace('{' + 'instanceId' + '}', str(instance_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/customfield-instance/{instanceId}/update',
            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_task_cusom_field_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_cusom_field_v3_request: Optional[UpdateTaskCusomFieldV3Request] = 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,
    ) -> UpdateTaskCusomFieldByInstanceV3Response:
        """更新任务自定义字段值

        更新任务自定义字段值

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_cusom_field_v3_request: 
        :type update_task_cusom_field_v3_request: UpdateTaskCusomFieldV3Request
        :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_task_cusom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_cusom_field_v3_request=update_task_cusom_field_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_cusom_field_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_cusom_field_v3_request: Optional[UpdateTaskCusomFieldV3Request] = 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[UpdateTaskCusomFieldByInstanceV3Response]:
        """更新任务自定义字段值

        更新任务自定义字段值

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_cusom_field_v3_request: 
        :type update_task_cusom_field_v3_request: UpdateTaskCusomFieldV3Request
        :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_task_cusom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_cusom_field_v3_request=update_task_cusom_field_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_cusom_field_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_cusom_field_v3_request: Optional[UpdateTaskCusomFieldV3Request] = 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:
        """更新任务自定义字段值

        更新任务自定义字段值

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_cusom_field_v3_request: 
        :type update_task_cusom_field_v3_request: UpdateTaskCusomFieldV3Request
        :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_task_cusom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_cusom_field_v3_request=update_task_cusom_field_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_cusom_field_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_cusom_field_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_cusom_field_v3_request is not None:
            _body_params = update_task_cusom_field_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/customfield/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/customfield/update',
            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_task_custom_field(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作人ID")] = None,
        task_id: Optional[StrictStr] = None,
        customfield_id: Optional[StrictStr] = None,
        update_task_custom_field_request: Optional[UpdateTaskCustomFieldRequest] = 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,
    ) -> UpdateTaskCustomFieldResponse:
        """更新任务字段信息

        更新任务字段信息

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id: 操作人ID
        :type x_operator_id: str
        :param task_id: 
        :type task_id: str
        :param customfield_id: 
        :type customfield_id: str
        :param update_task_custom_field_request: 
        :type update_task_custom_field_request: UpdateTaskCustomFieldRequest
        :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_task_custom_field_serialize(
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            task_id=task_id,
            customfield_id=customfield_id,
            update_task_custom_field_request=update_task_custom_field_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_custom_field_with_http_info(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作人ID")] = None,
        task_id: Optional[StrictStr] = None,
        customfield_id: Optional[StrictStr] = None,
        update_task_custom_field_request: Optional[UpdateTaskCustomFieldRequest] = 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[UpdateTaskCustomFieldResponse]:
        """更新任务字段信息

        更新任务字段信息

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id: 操作人ID
        :type x_operator_id: str
        :param task_id: 
        :type task_id: str
        :param customfield_id: 
        :type customfield_id: str
        :param update_task_custom_field_request: 
        :type update_task_custom_field_request: UpdateTaskCustomFieldRequest
        :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_task_custom_field_serialize(
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            task_id=task_id,
            customfield_id=customfield_id,
            update_task_custom_field_request=update_task_custom_field_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_custom_field_without_preload_content(
        self,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作人ID")] = None,
        task_id: Optional[StrictStr] = None,
        customfield_id: Optional[StrictStr] = None,
        update_task_custom_field_request: Optional[UpdateTaskCustomFieldRequest] = 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:
        """更新任务字段信息

        更新任务字段信息

        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id: 操作人ID
        :type x_operator_id: str
        :param task_id: 
        :type task_id: str
        :param customfield_id: 
        :type customfield_id: str
        :param update_task_custom_field_request: 
        :type update_task_custom_field_request: UpdateTaskCustomFieldRequest
        :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_task_custom_field_serialize(
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            task_id=task_id,
            customfield_id=customfield_id,
            update_task_custom_field_request=update_task_custom_field_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_custom_field_serialize(
        self,
        x_tenant_id,
        x_operator_id,
        task_id,
        customfield_id,
        update_task_custom_field_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        if customfield_id is not None:
            _path_params['customfieldId'] = customfield_id
        # process the query parameters
        # process the header parameters
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        if x_operator_id is not None:
            _header_params['X-Operator-Id'] = x_operator_id
        # process the form parameters
        # process the body parameter
        if update_task_custom_field_request is not None:
            _body_params = update_task_custom_field_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/task/customfield/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))
        url = url.replace('{' + 'customfieldId' + '}', str(customfield_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/task/customfield/update',
            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_task_custom_field_v2(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        customfield_id: Annotated[StrictStr, Field(description="字段ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_custom_field_v2_request: Optional[UpdateTaskCustomFieldV2Request] = 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,
    ) -> UpdateTaskCusomFieldByInstanceV3Response:
        """更新任务自定义字段值(弃用)

        更新任务自定义字段值(弃用)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param customfield_id: 字段ID (required)
        :type customfield_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_custom_field_v2_request: 
        :type update_task_custom_field_v2_request: UpdateTaskCustomFieldV2Request
        :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_task_custom_field_v2_serialize(
            task_id=task_id,
            customfield_id=customfield_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_custom_field_v2_request=update_task_custom_field_v2_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_custom_field_v2_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        customfield_id: Annotated[StrictStr, Field(description="字段ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_custom_field_v2_request: Optional[UpdateTaskCustomFieldV2Request] = 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[UpdateTaskCusomFieldByInstanceV3Response]:
        """更新任务自定义字段值(弃用)

        更新任务自定义字段值(弃用)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param customfield_id: 字段ID (required)
        :type customfield_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_custom_field_v2_request: 
        :type update_task_custom_field_v2_request: UpdateTaskCustomFieldV2Request
        :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_task_custom_field_v2_serialize(
            task_id=task_id,
            customfield_id=customfield_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_custom_field_v2_request=update_task_custom_field_v2_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_custom_field_v2_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        customfield_id: Annotated[StrictStr, Field(description="字段ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_custom_field_v2_request: Optional[UpdateTaskCustomFieldV2Request] = 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:
        """更新任务自定义字段值(弃用)

        更新任务自定义字段值(弃用)

        :param task_id: 任务ID (required)
        :type task_id: str
        :param customfield_id: 字段ID (required)
        :type customfield_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_custom_field_v2_request: 
        :type update_task_custom_field_v2_request: UpdateTaskCustomFieldV2Request
        :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_task_custom_field_v2_serialize(
            task_id=task_id,
            customfield_id=customfield_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_custom_field_v2_request=update_task_custom_field_v2_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskCusomFieldByInstanceV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_custom_field_v2_serialize(
        self,
        task_id,
        customfield_id,
        x_operator_id,
        x_tenant_id,
        update_task_custom_field_v2_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        if customfield_id is not None:
            _path_params['customfieldId'] = customfield_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_custom_field_v2_request is not None:
            _body_params = update_task_custom_field_v2_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/customfield/{customfieldId}/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))
        url = url.replace('{' + 'customfieldId' + '}', str(customfield_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/customfield/{customfieldId}/update',
            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_task_due_date_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_due_date_v3_request: Optional[UpdateTaskDueDateV3Request] = 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,
    ) -> UpdateTaskDueDateV3Response:
        """更新任务截止时间

        更新任务截止时间

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_due_date_v3_request: 
        :type update_task_due_date_v3_request: UpdateTaskDueDateV3Request
        :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_task_due_date_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_due_date_v3_request=update_task_due_date_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskDueDateV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_due_date_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_due_date_v3_request: Optional[UpdateTaskDueDateV3Request] = 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[UpdateTaskDueDateV3Response]:
        """更新任务截止时间

        更新任务截止时间

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_due_date_v3_request: 
        :type update_task_due_date_v3_request: UpdateTaskDueDateV3Request
        :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_task_due_date_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_due_date_v3_request=update_task_due_date_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskDueDateV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_due_date_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_due_date_v3_request: Optional[UpdateTaskDueDateV3Request] = 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:
        """更新任务截止时间

        更新任务截止时间

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_due_date_v3_request: 
        :type update_task_due_date_v3_request: UpdateTaskDueDateV3Request
        :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_task_due_date_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_due_date_v3_request=update_task_due_date_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskDueDateV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_due_date_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_due_date_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_due_date_v3_request is not None:
            _body_params = update_task_due_date_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/dueDate"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/dueDate',
            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_task_executor_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者用户ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_executor_v3_request: Optional[UpdateTaskExecutorV3Request] = 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,
    ) -> UpdateTaskExecutorV3Response:
        """更新任务执行者

        更新任务执行者

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者用户ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_executor_v3_request: 
        :type update_task_executor_v3_request: UpdateTaskExecutorV3Request
        :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_task_executor_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_executor_v3_request=update_task_executor_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskExecutorV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_executor_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者用户ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_executor_v3_request: Optional[UpdateTaskExecutorV3Request] = 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[UpdateTaskExecutorV3Response]:
        """更新任务执行者

        更新任务执行者

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者用户ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_executor_v3_request: 
        :type update_task_executor_v3_request: UpdateTaskExecutorV3Request
        :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_task_executor_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_executor_v3_request=update_task_executor_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskExecutorV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_executor_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者用户ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_executor_v3_request: Optional[UpdateTaskExecutorV3Request] = 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:
        """更新任务执行者

        更新任务执行者

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者用户ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_executor_v3_request: 
        :type update_task_executor_v3_request: UpdateTaskExecutorV3Request
        :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_task_executor_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_executor_v3_request=update_task_executor_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskExecutorV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_executor_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_executor_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_executor_v3_request is not None:
            _body_params = update_task_executor_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/executor"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/executor',
            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_task_lock_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_lock_v3_request: Optional[UpdateTaskLockV3Request] = 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,
    ) -> CheckUserVisibleInAppResponse:
        """更新任务加锁/解锁动作

        更新任务加锁/解锁动作

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_lock_v3_request: 
        :type update_task_lock_v3_request: UpdateTaskLockV3Request
        :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_task_lock_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_lock_v3_request=update_task_lock_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CheckUserVisibleInAppResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_lock_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_lock_v3_request: Optional[UpdateTaskLockV3Request] = 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[CheckUserVisibleInAppResponse]:
        """更新任务加锁/解锁动作

        更新任务加锁/解锁动作

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_lock_v3_request: 
        :type update_task_lock_v3_request: UpdateTaskLockV3Request
        :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_task_lock_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_lock_v3_request=update_task_lock_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CheckUserVisibleInAppResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_lock_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_lock_v3_request: Optional[UpdateTaskLockV3Request] = 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:
        """更新任务加锁/解锁动作

        更新任务加锁/解锁动作

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_lock_v3_request: 
        :type update_task_lock_v3_request: UpdateTaskLockV3Request
        :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_task_lock_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_lock_v3_request=update_task_lock_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "CheckUserVisibleInAppResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_lock_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_lock_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_lock_v3_request is not None:
            _body_params = update_task_lock_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/access-policy/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/access-policy/update',
            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_task_members_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_members_v3_request: Optional[UpdateTaskMembersV3Request] = 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,
    ) -> UpdateTaskMembersV3Response:
        """更新任务参与者

        更新任务参与者

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_members_v3_request: 
        :type update_task_members_v3_request: UpdateTaskMembersV3Request
        :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_task_members_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_members_v3_request=update_task_members_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskMembersV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_members_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_members_v3_request: Optional[UpdateTaskMembersV3Request] = 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[UpdateTaskMembersV3Response]:
        """更新任务参与者

        更新任务参与者

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_members_v3_request: 
        :type update_task_members_v3_request: UpdateTaskMembersV3Request
        :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_task_members_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_members_v3_request=update_task_members_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskMembersV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_members_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_members_v3_request: Optional[UpdateTaskMembersV3Request] = 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:
        """更新任务参与者

        更新任务参与者

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_members_v3_request: 
        :type update_task_members_v3_request: UpdateTaskMembersV3Request
        :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_task_members_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_members_v3_request=update_task_members_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskMembersV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_members_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_members_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_members_v3_request is not None:
            _body_params = update_task_members_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/involveMembers"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/involveMembers',
            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_task_note_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_note_v3_request: Optional[UpdateTaskNoteV3Request] = 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,
    ) -> UpdateTaskNoteV3Response:
        """更新任务备注

        更新任务备注

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_note_v3_request: 
        :type update_task_note_v3_request: UpdateTaskNoteV3Request
        :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_task_note_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_note_v3_request=update_task_note_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskNoteV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_note_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_note_v3_request: Optional[UpdateTaskNoteV3Request] = 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[UpdateTaskNoteV3Response]:
        """更新任务备注

        更新任务备注

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_note_v3_request: 
        :type update_task_note_v3_request: UpdateTaskNoteV3Request
        :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_task_note_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_note_v3_request=update_task_note_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskNoteV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_note_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_note_v3_request: Optional[UpdateTaskNoteV3Request] = 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:
        """更新任务备注

        更新任务备注

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_note_v3_request: 
        :type update_task_note_v3_request: UpdateTaskNoteV3Request
        :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_task_note_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_note_v3_request=update_task_note_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskNoteV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_note_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_note_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_note_v3_request is not None:
            _body_params = update_task_note_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/note"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/note',
            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_task_parent_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        update_task_parent_v3_request: Optional[UpdateTaskParentV3Request] = 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,
    ) -> UpdateTaskParentV3Response:
        """改变任务的父任务

        改变任务的父任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param update_task_parent_v3_request: 
        :type update_task_parent_v3_request: UpdateTaskParentV3Request
        :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_task_parent_v3_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            update_task_parent_v3_request=update_task_parent_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskParentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_parent_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        update_task_parent_v3_request: Optional[UpdateTaskParentV3Request] = 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[UpdateTaskParentV3Response]:
        """改变任务的父任务

        改变任务的父任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param update_task_parent_v3_request: 
        :type update_task_parent_v3_request: UpdateTaskParentV3Request
        :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_task_parent_v3_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            update_task_parent_v3_request=update_task_parent_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskParentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_parent_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        update_task_parent_v3_request: Optional[UpdateTaskParentV3Request] = 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:
        """改变任务的父任务

        改变任务的父任务

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param update_task_parent_v3_request: 
        :type update_task_parent_v3_request: UpdateTaskParentV3Request
        :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_task_parent_v3_serialize(
            task_id=task_id,
            x_tenant_id=x_tenant_id,
            x_operator_id=x_operator_id,
            update_task_parent_v3_request=update_task_parent_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskParentV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_parent_v3_serialize(
        self,
        task_id,
        x_tenant_id,
        x_operator_id,
        update_task_parent_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        if x_operator_id is not None:
            _header_params['X-Operator-Id'] = x_operator_id
        # process the form parameters
        # process the body parameter
        if update_task_parent_v3_request is not None:
            _body_params = update_task_parent_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/parent"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/parent',
            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_task_priority_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_priority_v3_request: Optional[UpdateTaskPriorityV3Request] = 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,
    ) -> UpdateTaskPriorityV3Response:
        """更新任务优先级

        更新任务优先级

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_priority_v3_request: 
        :type update_task_priority_v3_request: UpdateTaskPriorityV3Request
        :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_task_priority_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_priority_v3_request=update_task_priority_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskPriorityV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_priority_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_priority_v3_request: Optional[UpdateTaskPriorityV3Request] = 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[UpdateTaskPriorityV3Response]:
        """更新任务优先级

        更新任务优先级

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_priority_v3_request: 
        :type update_task_priority_v3_request: UpdateTaskPriorityV3Request
        :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_task_priority_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_priority_v3_request=update_task_priority_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskPriorityV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_priority_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_priority_v3_request: Optional[UpdateTaskPriorityV3Request] = 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:
        """更新任务优先级

        更新任务优先级

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_priority_v3_request: 
        :type update_task_priority_v3_request: UpdateTaskPriorityV3Request
        :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_task_priority_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_priority_v3_request=update_task_priority_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskPriorityV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_priority_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_priority_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_priority_v3_request is not None:
            _body_params = update_task_priority_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/priority"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/priority',
            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_task_progress_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_progress_v3_request: Optional[UpdateTaskProgressV3Request] = 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,
    ) -> UpdateTaskProgressV3Response:
        """更新任务进度

        更新任务进度

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_progress_v3_request: 
        :type update_task_progress_v3_request: UpdateTaskProgressV3Request
        :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_task_progress_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_progress_v3_request=update_task_progress_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskProgressV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_progress_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_progress_v3_request: Optional[UpdateTaskProgressV3Request] = 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[UpdateTaskProgressV3Response]:
        """更新任务进度

        更新任务进度

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_progress_v3_request: 
        :type update_task_progress_v3_request: UpdateTaskProgressV3Request
        :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_task_progress_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_progress_v3_request=update_task_progress_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskProgressV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_progress_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_progress_v3_request: Optional[UpdateTaskProgressV3Request] = 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:
        """更新任务进度

        更新任务进度

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_progress_v3_request: 
        :type update_task_progress_v3_request: UpdateTaskProgressV3Request
        :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_task_progress_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_progress_v3_request=update_task_progress_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskProgressV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_progress_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_progress_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_progress_v3_request is not None:
            _body_params = update_task_progress_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/progress"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/progress',
            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_task_sfc_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_sfc_v3_request: Optional[UpdateTaskSfcV3Request] = 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,
    ) -> UpdateTaskSfcV3Response:
        """更新任务的任务类型

        更新任务的任务类型

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_sfc_v3_request: 
        :type update_task_sfc_v3_request: UpdateTaskSfcV3Request
        :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_task_sfc_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_sfc_v3_request=update_task_sfc_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskSfcV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_sfc_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_sfc_v3_request: Optional[UpdateTaskSfcV3Request] = 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[UpdateTaskSfcV3Response]:
        """更新任务的任务类型

        更新任务的任务类型

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_sfc_v3_request: 
        :type update_task_sfc_v3_request: UpdateTaskSfcV3Request
        :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_task_sfc_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_sfc_v3_request=update_task_sfc_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskSfcV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_sfc_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_sfc_v3_request: Optional[UpdateTaskSfcV3Request] = 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:
        """更新任务的任务类型

        更新任务的任务类型

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_sfc_v3_request: 
        :type update_task_sfc_v3_request: UpdateTaskSfcV3Request
        :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_task_sfc_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_sfc_v3_request=update_task_sfc_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskSfcV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_sfc_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_sfc_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_sfc_v3_request is not None:
            _body_params = update_task_sfc_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/sfc/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/sfc/update',
            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_task_sprint_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_sprint_v3_request: Optional[UpdateTaskSprintV3Request] = 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,
    ) -> UpdateTaskSprintV3Response:
        """更新任务迭代

        更新任务迭代

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_sprint_v3_request: 
        :type update_task_sprint_v3_request: UpdateTaskSprintV3Request
        :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_task_sprint_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_sprint_v3_request=update_task_sprint_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskSprintV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_sprint_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_sprint_v3_request: Optional[UpdateTaskSprintV3Request] = 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[UpdateTaskSprintV3Response]:
        """更新任务迭代

        更新任务迭代

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_sprint_v3_request: 
        :type update_task_sprint_v3_request: UpdateTaskSprintV3Request
        :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_task_sprint_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_sprint_v3_request=update_task_sprint_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskSprintV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_sprint_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_sprint_v3_request: Optional[UpdateTaskSprintV3Request] = 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:
        """更新任务迭代

        更新任务迭代

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_sprint_v3_request: 
        :type update_task_sprint_v3_request: UpdateTaskSprintV3Request
        :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_task_sprint_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_sprint_v3_request=update_task_sprint_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskSprintV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_sprint_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_sprint_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_sprint_v3_request is not None:
            _body_params = update_task_sprint_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/sprint"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/sprint',
            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_task_stage_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_stage_v3_request: Optional[UpdateTaskStageV3Request] = 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,
    ) -> UpdateTaskStageV3Response:
        """更新任务列表

        更新任务列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_stage_v3_request: 
        :type update_task_stage_v3_request: UpdateTaskStageV3Request
        :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_task_stage_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_stage_v3_request=update_task_stage_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStageV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_stage_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_stage_v3_request: Optional[UpdateTaskStageV3Request] = 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[UpdateTaskStageV3Response]:
        """更新任务列表

        更新任务列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_stage_v3_request: 
        :type update_task_stage_v3_request: UpdateTaskStageV3Request
        :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_task_stage_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_stage_v3_request=update_task_stage_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStageV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_stage_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_stage_v3_request: Optional[UpdateTaskStageV3Request] = 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:
        """更新任务列表

        更新任务列表

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_stage_v3_request: 
        :type update_task_stage_v3_request: UpdateTaskStageV3Request
        :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_task_stage_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_stage_v3_request=update_task_stage_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStageV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_stage_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_stage_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_stage_v3_request is not None:
            _body_params = update_task_stage_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/stage/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/stage/update',
            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_task_start_date_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_start_date_v3_request: Optional[UpdateTaskStartDateV3Request] = 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,
    ) -> UpdateTaskStartDateV3Response:
        """更新任务开始时间

        更新任务开始时间

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_start_date_v3_request: 
        :type update_task_start_date_v3_request: UpdateTaskStartDateV3Request
        :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_task_start_date_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_start_date_v3_request=update_task_start_date_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStartDateV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_start_date_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_start_date_v3_request: Optional[UpdateTaskStartDateV3Request] = 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[UpdateTaskStartDateV3Response]:
        """更新任务开始时间

        更新任务开始时间

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_start_date_v3_request: 
        :type update_task_start_date_v3_request: UpdateTaskStartDateV3Request
        :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_task_start_date_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_start_date_v3_request=update_task_start_date_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStartDateV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_start_date_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_start_date_v3_request: Optional[UpdateTaskStartDateV3Request] = 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:
        """更新任务开始时间

        更新任务开始时间

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_start_date_v3_request: 
        :type update_task_start_date_v3_request: UpdateTaskStartDateV3Request
        :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_task_start_date_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_start_date_v3_request=update_task_start_date_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStartDateV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_start_date_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_start_date_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_start_date_v3_request is not None:
            _body_params = update_task_start_date_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/startDate"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/startDate',
            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_task_status_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_status_v3_request: Optional[UpdateTaskStatusV3Request] = 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,
    ) -> UpdateTaskStatusV3Response:
        """更新任务状态

        更新任务状态

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_status_v3_request: 
        :type update_task_status_v3_request: UpdateTaskStatusV3Request
        :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_task_status_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_status_v3_request=update_task_status_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStatusV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_status_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_status_v3_request: Optional[UpdateTaskStatusV3Request] = 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[UpdateTaskStatusV3Response]:
        """更新任务状态

        更新任务状态

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_status_v3_request: 
        :type update_task_status_v3_request: UpdateTaskStatusV3Request
        :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_task_status_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_status_v3_request=update_task_status_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStatusV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_status_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_status_v3_request: Optional[UpdateTaskStatusV3Request] = 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:
        """更新任务状态

        更新任务状态

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_status_v3_request: 
        :type update_task_status_v3_request: UpdateTaskStatusV3Request
        :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_task_status_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_status_v3_request=update_task_status_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStatusV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_status_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_status_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_status_v3_request is not None:
            _body_params = update_task_status_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/taskflowstatus"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/taskflowstatus',
            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_task_story_point_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_story_point_v3_request: Optional[UpdateTaskStoryPointV3Request] = 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,
    ) -> UpdateTaskStoryPointV3Response:
        """更新任务StoryPoint

        更新任务StoryPoint

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_story_point_v3_request: 
        :type update_task_story_point_v3_request: UpdateTaskStoryPointV3Request
        :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_task_story_point_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_story_point_v3_request=update_task_story_point_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStoryPointV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_story_point_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_story_point_v3_request: Optional[UpdateTaskStoryPointV3Request] = 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[UpdateTaskStoryPointV3Response]:
        """更新任务StoryPoint

        更新任务StoryPoint

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_story_point_v3_request: 
        :type update_task_story_point_v3_request: UpdateTaskStoryPointV3Request
        :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_task_story_point_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_story_point_v3_request=update_task_story_point_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStoryPointV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_story_point_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_story_point_v3_request: Optional[UpdateTaskStoryPointV3Request] = 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:
        """更新任务StoryPoint

        更新任务StoryPoint

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_story_point_v3_request: 
        :type update_task_story_point_v3_request: UpdateTaskStoryPointV3Request
        :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_task_story_point_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_story_point_v3_request=update_task_story_point_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskStoryPointV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_story_point_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_story_point_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_story_point_v3_request is not None:
            _body_params = update_task_story_point_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/storyPoint"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/storyPoint',
            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_task_table_custom_field_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Optional[StrictStr] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_table_custom_field_v3_request: Optional[UpdateTaskTableCustomFieldV3Request] = 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,
    ) -> UpdateProjectTableCustomFieldResponse:
        """更新任务的表格自定义字段

        更新任务的表格自定义字段

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_table_custom_field_v3_request: 
        :type update_task_table_custom_field_v3_request: UpdateTaskTableCustomFieldV3Request
        :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_task_table_custom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_table_custom_field_v3_request=update_task_table_custom_field_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateProjectTableCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_table_custom_field_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Optional[StrictStr] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_table_custom_field_v3_request: Optional[UpdateTaskTableCustomFieldV3Request] = 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[UpdateProjectTableCustomFieldResponse]:
        """更新任务的表格自定义字段

        更新任务的表格自定义字段

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_table_custom_field_v3_request: 
        :type update_task_table_custom_field_v3_request: UpdateTaskTableCustomFieldV3Request
        :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_task_table_custom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_table_custom_field_v3_request=update_task_table_custom_field_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateProjectTableCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_table_custom_field_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Optional[StrictStr] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_table_custom_field_v3_request: Optional[UpdateTaskTableCustomFieldV3Request] = 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:
        """更新任务的表格自定义字段

        更新任务的表格自定义字段

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_table_custom_field_v3_request: 
        :type update_task_table_custom_field_v3_request: UpdateTaskTableCustomFieldV3Request
        :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_task_table_custom_field_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_table_custom_field_v3_request=update_task_table_custom_field_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateProjectTableCustomFieldResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_table_custom_field_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_table_custom_field_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_table_custom_field_v3_request is not None:
            _body_params = update_task_table_custom_field_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/customfield/table"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/customfield/table',
            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_task_tags_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_tags_v3_request: Optional[UpdateTaskTagsV3Request] = 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,
    ) -> UpdateTaskTagsV3Response:
        """更新任务标签

        更新任务标签

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_tags_v3_request: 
        :type update_task_tags_v3_request: UpdateTaskTagsV3Request
        :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_task_tags_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_tags_v3_request=update_task_tags_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskTagsV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_tags_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_tags_v3_request: Optional[UpdateTaskTagsV3Request] = 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[UpdateTaskTagsV3Response]:
        """更新任务标签

        更新任务标签

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_tags_v3_request: 
        :type update_task_tags_v3_request: UpdateTaskTagsV3Request
        :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_task_tags_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_tags_v3_request=update_task_tags_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskTagsV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_tags_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_tags_v3_request: Optional[UpdateTaskTagsV3Request] = 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:
        """更新任务标签

        更新任务标签

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_tags_v3_request: 
        :type update_task_tags_v3_request: UpdateTaskTagsV3Request
        :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_task_tags_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_tags_v3_request=update_task_tags_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskTagsV3Response",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_tags_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_tags_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_tags_v3_request is not None:
            _body_params = update_task_tags_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/tag"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='PUT',
            resource_path='/v3/task/{taskId}/tag',
            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_task_visibility_v3(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_visibility_v3_request: Optional[UpdateTaskVisibilityV3Request] = 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,
    ) -> UpdateTaskVisibilityV3Response:
        """更新任务可见性

        更新任务可见性

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_visibility_v3_request: 
        :type update_task_visibility_v3_request: UpdateTaskVisibilityV3Request
        :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_task_visibility_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_visibility_v3_request=update_task_visibility_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskVisibilityV3Response",
            '204': "UpdateOrgMemberResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_visibility_v3_with_http_info(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_visibility_v3_request: Optional[UpdateTaskVisibilityV3Request] = 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[UpdateTaskVisibilityV3Response]:
        """更新任务可见性

        更新任务可见性

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_visibility_v3_request: 
        :type update_task_visibility_v3_request: UpdateTaskVisibilityV3Request
        :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_task_visibility_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_visibility_v3_request=update_task_visibility_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskVisibilityV3Response",
            '204': "UpdateOrgMemberResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _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_task_visibility_v3_without_preload_content(
        self,
        task_id: Annotated[StrictStr, Field(description="任务ID")],
        x_operator_id: Annotated[Optional[StrictStr], Field(description="操作者ID")] = None,
        x_tenant_id: Annotated[Optional[StrictStr], Field(description="企业 ID")] = None,
        update_task_visibility_v3_request: Optional[UpdateTaskVisibilityV3Request] = 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:
        """更新任务可见性

        更新任务可见性

        :param task_id: 任务ID (required)
        :type task_id: str
        :param x_operator_id: 操作者ID
        :type x_operator_id: str
        :param x_tenant_id: 企业 ID
        :type x_tenant_id: str
        :param update_task_visibility_v3_request: 
        :type update_task_visibility_v3_request: UpdateTaskVisibilityV3Request
        :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_task_visibility_v3_serialize(
            task_id=task_id,
            x_operator_id=x_operator_id,
            x_tenant_id=x_tenant_id,
            update_task_visibility_v3_request=update_task_visibility_v3_request,
            _request_auth=_request_auth,
            _content_type=_content_type,
            _headers=_headers,
            _host_index=_host_index
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "UpdateTaskVisibilityV3Response",
            '204': "UpdateOrgMemberResponse",
        }

        method, url, header_params, body, post_params = _param
        response_data = self.api_client.call_api(
            method=method,
            url=url,
            header_params=header_params,
            body=body,
            post_params=post_params,
            _request_timeout=_request_timeout
        )
        return response_data.response

    def _update_task_visibility_v3_serialize(
        self,
        task_id,
        x_operator_id,
        x_tenant_id,
        update_task_visibility_v3_request,
        _request_auth,
        _content_type,
        _headers,
        _host_index,
    ) -> RequestSerialized:

        _host = 'https://open.teambition.com/api'  

        _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 task_id is not None:
            _path_params['taskId'] = task_id
        # process the query parameters
        # process the header parameters
        if x_operator_id is not None:
            _header_params['x-operator-id'] = x_operator_id
        if x_tenant_id is not None:
            _header_params['X-Tenant-Id'] = x_tenant_id
        # process the form parameters
        # process the body parameter
        if update_task_visibility_v3_request is not None:
            _body_params = update_task_visibility_v3_request


        # 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] = [
            'appToken'
        ]

        # Build the full URL
        url = _host + "/v3/task/{taskId}/visible/update"
        url = url.replace('{' + 'taskId' + '}', str(task_id))

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/v3/task/{taskId}/visible/update',
            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
        )

