# coding: utf-8

"""
    Slack Web API

    One way to interact with the Slack platform is its HTTP RPC-based Web API, a collection of methods requiring OAuth 2.0-based user, bot, or workspace tokens blessed with related OAuth scopes.

    The version of the OpenAPI document: 1.7.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 Optional
from typing_extensions import Annotated
from slack_beta_ti.models.stars_add_schema import StarsAddSchema
from slack_beta_ti.models.stars_list_schema import StarsListSchema
from slack_beta_ti.models.stars_remove_schema import StarsRemoveSchema

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


class StarsApi:
    """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 stars_add(
        self,
        token: Annotated[StrictStr, Field(description="Authentication token. Requires scope: `stars:write`")],
        channel: Annotated[Optional[StrictStr], Field(description="Channel to add star to, or channel where the message to add star to was posted (used with `timestamp`).")] = None,
        file: Annotated[Optional[StrictStr], Field(description="File to add star to.")] = None,
        file_comment: Annotated[Optional[StrictStr], Field(description="File comment to add star to.")] = None,
        timestamp: Annotated[Optional[StrictStr], Field(description="Timestamp of the message to add star to.")] = 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__: Optional[StrictStr] = None,
    ) -> StarsAddSchema:
        """stars_add

        Adds a star to an item.

        :param token: Authentication token. Requires scope: `stars:write` (required)
        :type token: str
        :param channel: Channel to add star to, or channel where the message to add star to was posted (used with `timestamp`).
        :type channel: str
        :param file: File to add star to.
        :type file: str
        :param file_comment: File comment to add star to.
        :type file_comment: str
        :param timestamp: Timestamp of the message to add star to.
        :type timestamp: str
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_add_serialize(
            token=token,
            channel=channel,
            file=file,
            file_comment=file_comment,
            timestamp=timestamp,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "StarsAddSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            request_timeout__=request_timeout__
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def stars_add_with_http_info(
        self,
        token: Annotated[StrictStr, Field(description="Authentication token. Requires scope: `stars:write`")],
        channel: Annotated[Optional[StrictStr], Field(description="Channel to add star to, or channel where the message to add star to was posted (used with `timestamp`).")] = None,
        file: Annotated[Optional[StrictStr], Field(description="File to add star to.")] = None,
        file_comment: Annotated[Optional[StrictStr], Field(description="File comment to add star to.")] = None,
        timestamp: Annotated[Optional[StrictStr], Field(description="Timestamp of the message to add star to.")] = 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__: Optional[StrictStr] = None,
    ) -> ApiResponse[StarsAddSchema]:
        """stars_add

        Adds a star to an item.

        :param token: Authentication token. Requires scope: `stars:write` (required)
        :type token: str
        :param channel: Channel to add star to, or channel where the message to add star to was posted (used with `timestamp`).
        :type channel: str
        :param file: File to add star to.
        :type file: str
        :param file_comment: File comment to add star to.
        :type file_comment: str
        :param timestamp: Timestamp of the message to add star to.
        :type timestamp: str
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_add_serialize(
            token=token,
            channel=channel,
            file=file,
            file_comment=file_comment,
            timestamp=timestamp,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "StarsAddSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            request_timeout__=request_timeout__
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def stars_add_without_preload_content(
        self,
        token: Annotated[StrictStr, Field(description="Authentication token. Requires scope: `stars:write`")],
        channel: Annotated[Optional[StrictStr], Field(description="Channel to add star to, or channel where the message to add star to was posted (used with `timestamp`).")] = None,
        file: Annotated[Optional[StrictStr], Field(description="File to add star to.")] = None,
        file_comment: Annotated[Optional[StrictStr], Field(description="File comment to add star to.")] = None,
        timestamp: Annotated[Optional[StrictStr], Field(description="Timestamp of the message to add star to.")] = 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__: Optional[StrictStr] = None,
    ) -> RESTResponseType:
        """stars_add

        Adds a star to an item.

        :param token: Authentication token. Requires scope: `stars:write` (required)
        :type token: str
        :param channel: Channel to add star to, or channel where the message to add star to was posted (used with `timestamp`).
        :type channel: str
        :param file: File to add star to.
        :type file: str
        :param file_comment: File comment to add star to.
        :type file_comment: str
        :param timestamp: Timestamp of the message to add star to.
        :type timestamp: str
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_add_serialize(
            token=token,
            channel=channel,
            file=file,
            file_comment=file_comment,
            timestamp=timestamp,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

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


    def _stars_add_serialize(
        self,
        token,
        channel,
        file,
        file_comment,
        timestamp,
        request_auth__,
        content_type__,
        headers__,
        host__,
    ) -> RequestSerialized:


        _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 token is not None:
            _header_params['token'] = token
        # process the form parameters
        if channel is not None:
            _form_params.append(('channel', channel))
        if file is not None:
            _form_params.append(('file', file))
        if file_comment is not None:
            _form_params.append(('file_comment', file_comment))
        if timestamp is not None:
            _form_params.append(('timestamp', timestamp))
        # 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'
                ]
            )

        # 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/x-www-form-urlencoded', 
                        'application/json'
                    ]
                )
            )
            if _default_content_type is not None:
                _header_params['Content-Type'] = _default_content_type

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

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/stars.add',
            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 stars_list(
        self,
        token: Annotated[Optional[StrictStr], Field(description="Authentication token. Requires scope: `stars:read`")] = None,
        count: Optional[StrictStr] = None,
        page: Optional[StrictStr] = None,
        cursor: Annotated[Optional[StrictStr], Field(description="Parameter for pagination. Set `cursor` equal to the `next_cursor` attribute returned by the previous request's `response_metadata`. This parameter is optional, but pagination is mandatory: the default value simply fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more details.")] = None,
        limit: Annotated[Optional[StrictInt], Field(description="The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the list hasn't been reached.")] = 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__: Optional[StrictStr] = None,
    ) -> StarsListSchema:
        """stars_list

        Lists stars for a user.

        :param token: Authentication token. Requires scope: `stars:read`
        :type token: str
        :param count:
        :type count: str
        :param page:
        :type page: str
        :param cursor: Parameter for pagination. Set `cursor` equal to the `next_cursor` attribute returned by the previous request's `response_metadata`. This parameter is optional, but pagination is mandatory: the default value simply fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more details.
        :type cursor: str
        :param limit: The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the list hasn't been reached.
        :type limit: int
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_list_serialize(
            token=token,
            count=count,
            page=page,
            cursor=cursor,
            limit=limit,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "StarsListSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            request_timeout__=request_timeout__
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def stars_list_with_http_info(
        self,
        token: Annotated[Optional[StrictStr], Field(description="Authentication token. Requires scope: `stars:read`")] = None,
        count: Optional[StrictStr] = None,
        page: Optional[StrictStr] = None,
        cursor: Annotated[Optional[StrictStr], Field(description="Parameter for pagination. Set `cursor` equal to the `next_cursor` attribute returned by the previous request's `response_metadata`. This parameter is optional, but pagination is mandatory: the default value simply fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more details.")] = None,
        limit: Annotated[Optional[StrictInt], Field(description="The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the list hasn't been reached.")] = 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__: Optional[StrictStr] = None,
    ) -> ApiResponse[StarsListSchema]:
        """stars_list

        Lists stars for a user.

        :param token: Authentication token. Requires scope: `stars:read`
        :type token: str
        :param count:
        :type count: str
        :param page:
        :type page: str
        :param cursor: Parameter for pagination. Set `cursor` equal to the `next_cursor` attribute returned by the previous request's `response_metadata`. This parameter is optional, but pagination is mandatory: the default value simply fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more details.
        :type cursor: str
        :param limit: The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the list hasn't been reached.
        :type limit: int
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_list_serialize(
            token=token,
            count=count,
            page=page,
            cursor=cursor,
            limit=limit,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "StarsListSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            request_timeout__=request_timeout__
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def stars_list_without_preload_content(
        self,
        token: Annotated[Optional[StrictStr], Field(description="Authentication token. Requires scope: `stars:read`")] = None,
        count: Optional[StrictStr] = None,
        page: Optional[StrictStr] = None,
        cursor: Annotated[Optional[StrictStr], Field(description="Parameter for pagination. Set `cursor` equal to the `next_cursor` attribute returned by the previous request's `response_metadata`. This parameter is optional, but pagination is mandatory: the default value simply fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more details.")] = None,
        limit: Annotated[Optional[StrictInt], Field(description="The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the list hasn't been reached.")] = 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__: Optional[StrictStr] = None,
    ) -> RESTResponseType:
        """stars_list

        Lists stars for a user.

        :param token: Authentication token. Requires scope: `stars:read`
        :type token: str
        :param count:
        :type count: str
        :param page:
        :type page: str
        :param cursor: Parameter for pagination. Set `cursor` equal to the `next_cursor` attribute returned by the previous request's `response_metadata`. This parameter is optional, but pagination is mandatory: the default value simply fetches the first \"page\" of the collection. See [pagination](/docs/pagination) for more details.
        :type cursor: str
        :param limit: The maximum number of items to return. Fewer than the requested number of items may be returned, even if the end of the list hasn't been reached.
        :type limit: int
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_list_serialize(
            token=token,
            count=count,
            page=page,
            cursor=cursor,
            limit=limit,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

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


    def _stars_list_serialize(
        self,
        token,
        count,
        page,
        cursor,
        limit,
        request_auth__,
        content_type__,
        headers__,
        host__,
    ) -> RequestSerialized:


        _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 token is not None:
            
            _query_params.append(('token', token))
            
        if count is not None:
            
            _query_params.append(('count', count))
            
        if page is not None:
            
            _query_params.append(('page', page))
            
        if cursor is not None:
            
            _query_params.append(('cursor', cursor))
            
        if limit is not None:
            
            _query_params.append(('limit', limit))
            
        # process the header parameters
        # process the form parameters
        # process the body parameter


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


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

        return self.api_client.param_serialize(
            method='GET',
            resource_path='/stars.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 stars_remove(
        self,
        token: Annotated[StrictStr, Field(description="Authentication token. Requires scope: `stars:write`")],
        channel: Annotated[Optional[StrictStr], Field(description="Channel to remove star from, or channel where the message to remove star from was posted (used with `timestamp`).")] = None,
        file: Annotated[Optional[StrictStr], Field(description="File to remove star from.")] = None,
        file_comment: Annotated[Optional[StrictStr], Field(description="File comment to remove star from.")] = None,
        timestamp: Annotated[Optional[StrictStr], Field(description="Timestamp of the message to remove star from.")] = 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__: Optional[StrictStr] = None,
    ) -> StarsRemoveSchema:
        """stars_remove

        Removes a star from an item.

        :param token: Authentication token. Requires scope: `stars:write` (required)
        :type token: str
        :param channel: Channel to remove star from, or channel where the message to remove star from was posted (used with `timestamp`).
        :type channel: str
        :param file: File to remove star from.
        :type file: str
        :param file_comment: File comment to remove star from.
        :type file_comment: str
        :param timestamp: Timestamp of the message to remove star from.
        :type timestamp: str
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_remove_serialize(
            token=token,
            channel=channel,
            file=file,
            file_comment=file_comment,
            timestamp=timestamp,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "StarsRemoveSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            request_timeout__=request_timeout__
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        ).data


    @validate_call
    def stars_remove_with_http_info(
        self,
        token: Annotated[StrictStr, Field(description="Authentication token. Requires scope: `stars:write`")],
        channel: Annotated[Optional[StrictStr], Field(description="Channel to remove star from, or channel where the message to remove star from was posted (used with `timestamp`).")] = None,
        file: Annotated[Optional[StrictStr], Field(description="File to remove star from.")] = None,
        file_comment: Annotated[Optional[StrictStr], Field(description="File comment to remove star from.")] = None,
        timestamp: Annotated[Optional[StrictStr], Field(description="Timestamp of the message to remove star from.")] = 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__: Optional[StrictStr] = None,
    ) -> ApiResponse[StarsRemoveSchema]:
        """stars_remove

        Removes a star from an item.

        :param token: Authentication token. Requires scope: `stars:write` (required)
        :type token: str
        :param channel: Channel to remove star from, or channel where the message to remove star from was posted (used with `timestamp`).
        :type channel: str
        :param file: File to remove star from.
        :type file: str
        :param file_comment: File comment to remove star from.
        :type file_comment: str
        :param timestamp: Timestamp of the message to remove star from.
        :type timestamp: str
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_remove_serialize(
            token=token,
            channel=channel,
            file=file,
            file_comment=file_comment,
            timestamp=timestamp,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

        _response_types_map: Dict[str, Optional[str]] = {
            '200': "StarsRemoveSchema",
        }
        response_data = self.api_client.call_api(
            *_param,
            request_timeout__=request_timeout__
        )
        response_data.read()
        return self.api_client.response_deserialize(
            response_data=response_data,
            response_types_map=_response_types_map,
        )


    @validate_call
    def stars_remove_without_preload_content(
        self,
        token: Annotated[StrictStr, Field(description="Authentication token. Requires scope: `stars:write`")],
        channel: Annotated[Optional[StrictStr], Field(description="Channel to remove star from, or channel where the message to remove star from was posted (used with `timestamp`).")] = None,
        file: Annotated[Optional[StrictStr], Field(description="File to remove star from.")] = None,
        file_comment: Annotated[Optional[StrictStr], Field(description="File comment to remove star from.")] = None,
        timestamp: Annotated[Optional[StrictStr], Field(description="Timestamp of the message to remove star from.")] = 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__: Optional[StrictStr] = None,
    ) -> RESTResponseType:
        """stars_remove

        Removes a star from an item.

        :param token: Authentication token. Requires scope: `stars:write` (required)
        :type token: str
        :param channel: Channel to remove star from, or channel where the message to remove star from was posted (used with `timestamp`).
        :type channel: str
        :param file: File to remove star from.
        :type file: str
        :param file_comment: File comment to remove star from.
        :type file_comment: str
        :param timestamp: Timestamp of the message to remove star from.
        :type timestamp: str
        :return: Returns the result object.
        """ # noqa: E501

        _param = self._stars_remove_serialize(
            token=token,
            channel=channel,
            file=file,
            file_comment=file_comment,
            timestamp=timestamp,
            request_auth__=request_auth__,
            content_type__=content_type__,
            headers__=headers__,
            host__=host__
        )

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


    def _stars_remove_serialize(
        self,
        token,
        channel,
        file,
        file_comment,
        timestamp,
        request_auth__,
        content_type__,
        headers__,
        host__,
    ) -> RequestSerialized:


        _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 token is not None:
            _header_params['token'] = token
        # process the form parameters
        if channel is not None:
            _form_params.append(('channel', channel))
        if file is not None:
            _form_params.append(('file', file))
        if file_comment is not None:
            _form_params.append(('file_comment', file_comment))
        if timestamp is not None:
            _form_params.append(('timestamp', timestamp))
        # 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'
                ]
            )

        # 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/x-www-form-urlencoded', 
                        'application/json'
                    ]
                )
            )
            if _default_content_type is not None:
                _header_params['Content-Type'] = _default_content_type

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

        return self.api_client.param_serialize(
            method='POST',
            resource_path='/stars.remove',
            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__
        )


