diff --git a/build/lib/evolutionapi/services/chat.py b/build/lib/evolutionapi/services/chat.py index b2af456..d4d3291 100644 --- a/build/lib/evolutionapi/services/chat.py +++ b/build/lib/evolutionapi/services/chat.py @@ -66,4 +66,17 @@ class ChatService: f'chat/sendPresence/{instance_id}', data=data.__dict__, instance_token=instance_token - ) \ No newline at end of file + ) + + def get_messages(self, instance_id: str, remote_jid: str, instance_token: str, page: int = 1, offset: int = 50): + '''Get messages from a chat''' + payload = { + "where": {"key": {"remoteJid": remote_jid}}, + "page": page, + "offset": offset, + } + return self.client.post( + f'chat/findMessages/{instance_id}', + data=payload, + instance_token=instance_token, + ) diff --git a/dist/evolutionapi-0.0.6.tar.gz b/dist/evolutionapi-0.0.6.tar.gz deleted file mode 100644 index dc38dc7..0000000 Binary files a/dist/evolutionapi-0.0.6.tar.gz and /dev/null differ diff --git a/dist/evolutionapi-0.0.6-py3-none-any.whl b/dist/evolutionapi-0.0.7-py3-none-any.whl similarity index 83% rename from dist/evolutionapi-0.0.6-py3-none-any.whl rename to dist/evolutionapi-0.0.7-py3-none-any.whl index 4aebe1a..390170f 100644 Binary files a/dist/evolutionapi-0.0.6-py3-none-any.whl and b/dist/evolutionapi-0.0.7-py3-none-any.whl differ diff --git a/dist/evolutionapi-0.0.7.tar.gz b/dist/evolutionapi-0.0.7.tar.gz new file mode 100644 index 0000000..ef6ff39 Binary files /dev/null and b/dist/evolutionapi-0.0.7.tar.gz differ diff --git a/evolutionapi.egg-info/PKG-INFO b/evolutionapi.egg-info/PKG-INFO new file mode 100644 index 0000000..ab0b0c0 --- /dev/null +++ b/evolutionapi.egg-info/PKG-INFO @@ -0,0 +1,9 @@ +Metadata-Version: 2.1 +Name: evolutionapi +Version: 0.0.7 +Summary: Client Python para a API Evolution +Author: Davidson Gomes +Author-email: contato@agenciadgcode.com +Requires-Python: >=3.6 +Requires-Dist: requests>=2.25.1 +Requires-Dist: requests_toolbelt>=1.0.0 diff --git a/evolutionapi.egg-info/SOURCES.txt b/evolutionapi.egg-info/SOURCES.txt new file mode 100644 index 0000000..e8a8b5b --- /dev/null +++ b/evolutionapi.egg-info/SOURCES.txt @@ -0,0 +1,28 @@ +README.md +setup.py +evolutionapi/__init__.py +evolutionapi/client.py +evolutionapi/exceptions.py +evolutionapi.egg-info/PKG-INFO +evolutionapi.egg-info/SOURCES.txt +evolutionapi.egg-info/dependency_links.txt +evolutionapi.egg-info/requires.txt +evolutionapi.egg-info/top_level.txt +evolutionapi/models/__init__.py +evolutionapi/models/call.py +evolutionapi/models/chat.py +evolutionapi/models/group.py +evolutionapi/models/instance.py +evolutionapi/models/label.py +evolutionapi/models/message.py +evolutionapi/models/presence.py +evolutionapi/models/profile.py +evolutionapi/services/__init__.py +evolutionapi/services/call.py +evolutionapi/services/chat.py +evolutionapi/services/group.py +evolutionapi/services/instance.py +evolutionapi/services/instance_operations.py +evolutionapi/services/label.py +evolutionapi/services/message.py +evolutionapi/services/profile.py \ No newline at end of file diff --git a/evolutionapi.egg-info/dependency_links.txt b/evolutionapi.egg-info/dependency_links.txt new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/evolutionapi.egg-info/dependency_links.txt @@ -0,0 +1 @@ + diff --git a/evolutionapi.egg-info/requires.txt b/evolutionapi.egg-info/requires.txt new file mode 100644 index 0000000..031d8e7 --- /dev/null +++ b/evolutionapi.egg-info/requires.txt @@ -0,0 +1,2 @@ +requests>=2.25.1 +requests_toolbelt>=1.0.0 diff --git a/evolutionapi.egg-info/top_level.txt b/evolutionapi.egg-info/top_level.txt new file mode 100644 index 0000000..74af2d6 --- /dev/null +++ b/evolutionapi.egg-info/top_level.txt @@ -0,0 +1 @@ +evolutionapi diff --git a/setup.py b/setup.py index d56141a..29b00ca 100644 --- a/setup.py +++ b/setup.py @@ -2,7 +2,7 @@ from setuptools import setup, find_packages setup( name='evolutionapi', - version='0.0.6', + version='0.0.7', description='Client Python para a API Evolution', author='Davidson Gomes', author_email='contato@agenciadgcode.com',