whatsapp-chatbot-python 0.9.7__tar.gz → 0.9.9__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/PKG-INFO +2 -2
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/setup.py +2 -2
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/manager/handler.py +14 -8
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python.egg-info/PKG-INFO +2 -2
- whatsapp_chatbot_python-0.9.9/whatsapp_chatbot_python.egg-info/requires.txt +1 -0
- whatsapp_chatbot_python-0.9.7/whatsapp_chatbot_python.egg-info/requires.txt +0 -1
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/LICENSE +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/README.md +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/setup.cfg +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/tests/test_manager.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/__init__.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/bot.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/filters.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/manager/__init__.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/manager/observer.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/manager/router.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/manager/state.py +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python.egg-info/SOURCES.txt +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python.egg-info/dependency_links.txt +0 -0
- {whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: whatsapp-chatbot-python
|
|
3
|
-
Version: 0.9.
|
|
3
|
+
Version: 0.9.9
|
|
4
4
|
Summary: This library helps you easily create a Python chatbot with WhatsApp API.
|
|
5
5
|
Home-page: https://github.com/green-api/whatsapp-chatbot-python
|
|
6
6
|
Author: GREEN API
|
|
@@ -30,7 +30,7 @@ Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
|
|
|
30
30
|
Requires-Python: >=3.7
|
|
31
31
|
Description-Content-Type: text/markdown
|
|
32
32
|
License-File: LICENSE
|
|
33
|
-
Requires-Dist: whatsapp-api-client-python>=0.0.
|
|
33
|
+
Requires-Dist: whatsapp-api-client-python>=0.0.53
|
|
34
34
|
Dynamic: author
|
|
35
35
|
Dynamic: author-email
|
|
36
36
|
Dynamic: classifier
|
|
@@ -5,7 +5,7 @@ with open("README.md", encoding="UTF-8") as file:
|
|
|
5
5
|
|
|
6
6
|
setup(
|
|
7
7
|
name="whatsapp-chatbot-python",
|
|
8
|
-
version="0.9.
|
|
8
|
+
version="0.9.9",
|
|
9
9
|
description=(
|
|
10
10
|
"This library helps you easily create"
|
|
11
11
|
" a Python chatbot with WhatsApp API."
|
|
@@ -43,6 +43,6 @@ setup(
|
|
|
43
43
|
"Creative Commons Attribution-NoDerivatives 4.0 International"
|
|
44
44
|
" (CC BY-ND 4.0)"
|
|
45
45
|
),
|
|
46
|
-
install_requires=["whatsapp-api-client-python>=0.0.
|
|
46
|
+
install_requires=["whatsapp-api-client-python>=0.0.53"],
|
|
47
47
|
python_requires=">=3.7"
|
|
48
48
|
)
|
|
@@ -60,6 +60,8 @@ class Notification:
|
|
|
60
60
|
type_message = message_data["typeMessage"]
|
|
61
61
|
if type_message == "textMessage":
|
|
62
62
|
return message_data["textMessageData"]["textMessage"]
|
|
63
|
+
if type_message == "interactiveButtonsResponse":
|
|
64
|
+
return message_data["interactiveButtonsResponse"]["selectedDisplayText"]
|
|
63
65
|
elif (
|
|
64
66
|
type_message == "extendedTextMessage"
|
|
65
67
|
or type_message == "quotedMessage"
|
|
@@ -86,12 +88,13 @@ class Notification:
|
|
|
86
88
|
message: str,
|
|
87
89
|
quoted_message_id: Optional[str] = None,
|
|
88
90
|
archive_chat: Optional[bool] = None,
|
|
89
|
-
link_preview: Optional[bool] = None
|
|
91
|
+
link_preview: Optional[bool] = None,
|
|
92
|
+
typing_time: Optional[int] = None
|
|
90
93
|
) -> Optional[Response]:
|
|
91
94
|
chat = self.get_chat()
|
|
92
95
|
if chat:
|
|
93
96
|
return self.api.sending.sendMessage(
|
|
94
|
-
chat, message, quoted_message_id, archive_chat, link_preview
|
|
97
|
+
chat, message, quoted_message_id, archive_chat, link_preview, typing_time
|
|
95
98
|
)
|
|
96
99
|
|
|
97
100
|
def answer_buttons(
|
|
@@ -113,7 +116,7 @@ class Notification:
|
|
|
113
116
|
body: str,
|
|
114
117
|
buttons: List[Dict[str, Union[str, Dict[str, str]]]],
|
|
115
118
|
header: Optional[str] = None,
|
|
116
|
-
footer: Optional[str] = None
|
|
119
|
+
footer: Optional[str] = None
|
|
117
120
|
) -> Optional[Response]:
|
|
118
121
|
chat = self.get_chat()
|
|
119
122
|
if chat:
|
|
@@ -126,7 +129,7 @@ class Notification:
|
|
|
126
129
|
body: str,
|
|
127
130
|
buttons: List[Dict[str, str]],
|
|
128
131
|
header: Optional[str] = None,
|
|
129
|
-
footer: Optional[str] = None
|
|
132
|
+
footer: Optional[str] = None
|
|
130
133
|
) -> Optional[Response]:
|
|
131
134
|
chat = self.get_chat()
|
|
132
135
|
if chat:
|
|
@@ -139,12 +142,14 @@ class Notification:
|
|
|
139
142
|
file: str,
|
|
140
143
|
file_name: Optional[str] = None,
|
|
141
144
|
caption: Optional[str] = None,
|
|
142
|
-
quoted_message_id: Optional[str] = None
|
|
145
|
+
quoted_message_id: Optional[str] = None,
|
|
146
|
+
typing_time: Optional[int] = None,
|
|
147
|
+
typing_type: Optional[str] = None
|
|
143
148
|
) -> Optional[Response]:
|
|
144
149
|
chat = self.get_chat()
|
|
145
150
|
if chat:
|
|
146
151
|
return self.api.sending.sendFileByUpload(
|
|
147
|
-
chat, file, file_name, caption, quoted_message_id
|
|
152
|
+
chat, file, file_name, caption, quoted_message_id, typing_time, typing_type
|
|
148
153
|
)
|
|
149
154
|
|
|
150
155
|
def answer_with_poll(
|
|
@@ -152,12 +157,13 @@ class Notification:
|
|
|
152
157
|
message: str,
|
|
153
158
|
options: List[Dict[str, str]],
|
|
154
159
|
multiple_answers: Optional[bool] = None,
|
|
155
|
-
quoted_message_id: Optional[str] = None
|
|
160
|
+
quoted_message_id: Optional[str] = None,
|
|
161
|
+
typing_time: Optional[int] = None
|
|
156
162
|
) -> Optional[Response]:
|
|
157
163
|
chat = self.get_chat()
|
|
158
164
|
if chat:
|
|
159
165
|
return self.api.sending.sendPoll(
|
|
160
|
-
chat, message, options, multiple_answers, quoted_message_id
|
|
166
|
+
chat, message, options, multiple_answers, quoted_message_id, typing_time
|
|
161
167
|
)
|
|
162
168
|
|
|
163
169
|
HandlerType = Callable[[Notification], Any]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: whatsapp-chatbot-python
|
|
3
|
-
Version: 0.9.
|
|
3
|
+
Version: 0.9.9
|
|
4
4
|
Summary: This library helps you easily create a Python chatbot with WhatsApp API.
|
|
5
5
|
Home-page: https://github.com/green-api/whatsapp-chatbot-python
|
|
6
6
|
Author: GREEN API
|
|
@@ -30,7 +30,7 @@ Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
|
|
|
30
30
|
Requires-Python: >=3.7
|
|
31
31
|
Description-Content-Type: text/markdown
|
|
32
32
|
License-File: LICENSE
|
|
33
|
-
Requires-Dist: whatsapp-api-client-python>=0.0.
|
|
33
|
+
Requires-Dist: whatsapp-api-client-python>=0.0.53
|
|
34
34
|
Dynamic: author
|
|
35
35
|
Dynamic: author-email
|
|
36
36
|
Dynamic: classifier
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
whatsapp-api-client-python>=0.0.53
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
whatsapp-api-client-python>=0.0.49
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/__init__.py
RENAMED
|
File without changes
|
{whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/bot.py
RENAMED
|
File without changes
|
{whatsapp_chatbot_python-0.9.7 → whatsapp_chatbot_python-0.9.9}/whatsapp_chatbot_python/filters.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|