|
64 | 64 | from linebot.v3.messaging.models.room_member_count_response import RoomMemberCountResponse
|
65 | 65 | from linebot.v3.messaging.models.room_user_profile_response import RoomUserProfileResponse
|
66 | 66 | from linebot.v3.messaging.models.set_webhook_endpoint_request import SetWebhookEndpointRequest
|
| 67 | +from linebot.v3.messaging.models.show_loading_animation_request import ShowLoadingAnimationRequest |
67 | 68 | from linebot.v3.messaging.models.test_webhook_endpoint_request import TestWebhookEndpointRequest
|
68 | 69 | from linebot.v3.messaging.models.test_webhook_endpoint_response import TestWebhookEndpointResponse
|
69 | 70 | from linebot.v3.messaging.models.update_rich_menu_alias_request import UpdateRichMenuAliasRequest
|
@@ -8004,6 +8005,165 @@ def set_webhook_endpoint_with_http_info(self, set_webhook_endpoint_request : Set
|
8004 | 8005 | collection_formats=_collection_formats,
|
8005 | 8006 | _request_auth=_params.get('_request_auth'))
|
8006 | 8007 |
|
| 8008 | + @overload |
| 8009 | + async def show_loading_animation(self, show_loading_animation_request : ShowLoadingAnimationRequest, **kwargs) -> object: # noqa: E501 |
| 8010 | + ... |
| 8011 | + |
| 8012 | + @overload |
| 8013 | + def show_loading_animation(self, show_loading_animation_request : ShowLoadingAnimationRequest, async_req: Optional[bool]=True, **kwargs) -> object: # noqa: E501 |
| 8014 | + ... |
| 8015 | + |
| 8016 | + @validate_arguments |
| 8017 | + def show_loading_animation(self, show_loading_animation_request : ShowLoadingAnimationRequest, async_req: Optional[bool]=None, **kwargs) -> Union[object, Awaitable[object]]: # noqa: E501 |
| 8018 | + """show_loading_animation # noqa: E501 |
| 8019 | +
|
| 8020 | + Display a loading animation in one-on-one chats between users and LINE Official Accounts. # noqa: E501 |
| 8021 | + This method makes a synchronous HTTP request by default. To make an |
| 8022 | + asynchronous HTTP request, please pass async_req=True |
| 8023 | +
|
| 8024 | + >>> thread = api.show_loading_animation(show_loading_animation_request, async_req=True) |
| 8025 | + >>> result = thread.get() |
| 8026 | +
|
| 8027 | + :param show_loading_animation_request: (required) |
| 8028 | + :type show_loading_animation_request: ShowLoadingAnimationRequest |
| 8029 | + :param async_req: Whether to execute the request asynchronously. |
| 8030 | + :type async_req: bool, optional |
| 8031 | + :param _request_timeout: timeout setting for this request. If one |
| 8032 | + number provided, it will be total request |
| 8033 | + timeout. It can also be a pair (tuple) of |
| 8034 | + (connection, read) timeouts. |
| 8035 | + :return: Returns the result object. |
| 8036 | + If the method is called asynchronously, |
| 8037 | + returns the request thread. |
| 8038 | + :rtype: object |
| 8039 | + """ |
| 8040 | + kwargs['_return_http_data_only'] = True |
| 8041 | + if '_preload_content' in kwargs: |
| 8042 | + raise ValueError("Error! Please call the show_loading_animation_with_http_info method with `_preload_content` instead and obtain raw data from ApiResponse.raw_data") |
| 8043 | + if async_req is not None: |
| 8044 | + kwargs['async_req'] = async_req |
| 8045 | + return self.show_loading_animation_with_http_info(show_loading_animation_request, **kwargs) # noqa: E501 |
| 8046 | + |
| 8047 | + @validate_arguments |
| 8048 | + def show_loading_animation_with_http_info(self, show_loading_animation_request : ShowLoadingAnimationRequest, **kwargs) -> ApiResponse: # noqa: E501 |
| 8049 | + """show_loading_animation # noqa: E501 |
| 8050 | +
|
| 8051 | + Display a loading animation in one-on-one chats between users and LINE Official Accounts. # noqa: E501 |
| 8052 | + This method makes a synchronous HTTP request by default. To make an |
| 8053 | + asynchronous HTTP request, please pass async_req=True |
| 8054 | +
|
| 8055 | + >>> thread = api.show_loading_animation_with_http_info(show_loading_animation_request, async_req=True) |
| 8056 | + >>> result = thread.get() |
| 8057 | +
|
| 8058 | + :param show_loading_animation_request: (required) |
| 8059 | + :type show_loading_animation_request: ShowLoadingAnimationRequest |
| 8060 | + :param async_req: Whether to execute the request asynchronously. |
| 8061 | + :type async_req: bool, optional |
| 8062 | + :param _preload_content: if False, the ApiResponse.data will |
| 8063 | + be set to none and raw_data will store the |
| 8064 | + HTTP response body without reading/decoding. |
| 8065 | + Default is True. |
| 8066 | + :type _preload_content: bool, optional |
| 8067 | + :param _return_http_data_only: response data instead of ApiResponse |
| 8068 | + object with status code, headers, etc |
| 8069 | + :type _return_http_data_only: bool, optional |
| 8070 | + :param _request_timeout: timeout setting for this request. If one |
| 8071 | + number provided, it will be total request |
| 8072 | + timeout. It can also be a pair (tuple) of |
| 8073 | + (connection, read) timeouts. |
| 8074 | + :param _request_auth: set to override the auth_settings for an a single |
| 8075 | + request; this effectively ignores the authentication |
| 8076 | + in the spec for a single request. |
| 8077 | + :type _request_auth: dict, optional |
| 8078 | + :type _content_type: string, optional: force content-type for the request |
| 8079 | + :return: Returns the result object. |
| 8080 | + If the method is called asynchronously, |
| 8081 | + returns the request thread. |
| 8082 | + :rtype: tuple(object, status_code(int), headers(HTTPHeaderDict)) |
| 8083 | + """ |
| 8084 | + |
| 8085 | + _host = self.line_base_path |
| 8086 | + _params = locals() |
| 8087 | + |
| 8088 | + _all_params = [ |
| 8089 | + 'show_loading_animation_request' |
| 8090 | + ] |
| 8091 | + _all_params.extend( |
| 8092 | + [ |
| 8093 | + 'async_req', |
| 8094 | + '_return_http_data_only', |
| 8095 | + '_preload_content', |
| 8096 | + '_request_timeout', |
| 8097 | + '_request_auth', |
| 8098 | + '_content_type', |
| 8099 | + '_headers' |
| 8100 | + ] |
| 8101 | + ) |
| 8102 | + |
| 8103 | + # validate the arguments |
| 8104 | + for _key, _val in _params['kwargs'].items(): |
| 8105 | + if _key not in _all_params: |
| 8106 | + raise ApiTypeError( |
| 8107 | + "Got an unexpected keyword argument '%s'" |
| 8108 | + " to method show_loading_animation" % _key |
| 8109 | + ) |
| 8110 | + _params[_key] = _val |
| 8111 | + del _params['kwargs'] |
| 8112 | + |
| 8113 | + _collection_formats = {} |
| 8114 | + |
| 8115 | + # process the path parameters |
| 8116 | + _path_params = {} |
| 8117 | + |
| 8118 | + # process the query parameters |
| 8119 | + _query_params = [] |
| 8120 | + # process the header parameters |
| 8121 | + _header_params = dict(_params.get('_headers', {})) |
| 8122 | + # process the form parameters |
| 8123 | + _form_params = [] |
| 8124 | + _files = {} |
| 8125 | + # process the body parameter |
| 8126 | + _body_params = None |
| 8127 | + if _params['show_loading_animation_request'] is not None: |
| 8128 | + _body_params = _params['show_loading_animation_request'] |
| 8129 | + |
| 8130 | + # set the HTTP header `Accept` |
| 8131 | + _header_params['Accept'] = self.api_client.select_header_accept( |
| 8132 | + ['application/json']) # noqa: E501 |
| 8133 | + |
| 8134 | + # set the HTTP header `Content-Type` |
| 8135 | + _content_types_list = _params.get('_content_type', |
| 8136 | + self.api_client.select_header_content_type( |
| 8137 | + ['application/json'])) |
| 8138 | + if _content_types_list: |
| 8139 | + _header_params['Content-Type'] = _content_types_list |
| 8140 | + |
| 8141 | + # authentication setting |
| 8142 | + _auth_settings = ['Bearer'] # noqa: E501 |
| 8143 | + |
| 8144 | + _response_types_map = { |
| 8145 | + '202': "object", |
| 8146 | + '400': "ErrorResponse", |
| 8147 | + } |
| 8148 | + |
| 8149 | + return self.api_client.call_api( |
| 8150 | + '/v2/bot/chat/loading/start', 'POST', |
| 8151 | + _path_params, |
| 8152 | + _query_params, |
| 8153 | + _header_params, |
| 8154 | + body=_body_params, |
| 8155 | + post_params=_form_params, |
| 8156 | + files=_files, |
| 8157 | + response_types_map=_response_types_map, |
| 8158 | + auth_settings=_auth_settings, |
| 8159 | + async_req=_params.get('async_req'), |
| 8160 | + _return_http_data_only=_params.get('_return_http_data_only'), # noqa: E501 |
| 8161 | + _preload_content=_params.get('_preload_content', True), |
| 8162 | + _request_timeout=_params.get('_request_timeout'), |
| 8163 | + _host=_host, |
| 8164 | + collection_formats=_collection_formats, |
| 8165 | + _request_auth=_params.get('_request_auth')) |
| 8166 | + |
8007 | 8167 | @overload
|
8008 | 8168 | async def test_webhook_endpoint(self, test_webhook_endpoint_request : Optional[TestWebhookEndpointRequest] = None, **kwargs) -> TestWebhookEndpointResponse: # noqa: E501
|
8009 | 8169 | ...
|
|
0 commit comments