A module to write amy plugins
Project description
AMY Plugin
Just import amy to write your plugin.
from amy import Plugin, Instance, Message
class Messenger(FacebookClient, Instance):
def onCreate(self, username):
self.username = username
def onAuth(self, token):
FacebookClient.__init__(self, self.username, token)
def onStart(self):
FacebookClient.listen()
def onStop(self):
FacebookClient.stopListening()
def myNewMessageFunc(message)
unifiedMessage = Message()
.setPlatform('messanger')
# .setUser(message['user'])
# ...
Plugin.publishMessange(unifiedMessage.toDict())
def main():
Messenger = Plugin('messenger', Messenger)
if __name__ == "__main__":
main()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
amy-3.4.0.tar.gz
(4.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
amy-3.4.0-py3-none-any.whl
(5.5 kB
view details)
File details
Details for the file amy-3.4.0.tar.gz.
File metadata
- Download URL: amy-3.4.0.tar.gz
- Upload date:
- Size: 4.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.7.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
33ed12d0fab4050792e54e24b43bcc9b021206bd6fadecd69f8eaae3ac944dc0
|
|
| MD5 |
d4b465925af81705c5ef023c236854b1
|
|
| BLAKE2b-256 |
907ec56e37db22c777431932f8b16cce68b88d4871a6ffb3a00500d1cf1151f9
|
File details
Details for the file amy-3.4.0-py3-none-any.whl.
File metadata
- Download URL: amy-3.4.0-py3-none-any.whl
- Upload date:
- Size: 5.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.19.1 setuptools/40.4.3 requests-toolbelt/0.8.0 tqdm/4.26.0 CPython/3.7.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
38e2903f005a656f93e5613a38ecebe1ab44542a49bb82f5ee24b3488a875026
|
|
| MD5 |
60ea37ff0a3cfe6261b38b7830bbee53
|
|
| BLAKE2b-256 |
2cefef4a4f4651f32e78106fcfacc9e33e34186c43b9147c9a00779e7dde36b3
|