A friendly and easy to use XMPP client for Python
Project description
TinyXMPP
TinyXMPP is a small XMPP client for Python applications. It allows developers to easily connect to XMPP servers and exchange messages in a fast and secure way.
Getting Started
pip install tinyxmpp
To connect to an XMPP server:
from tinyxmpp import XMPPClient
async def main():
client = XMPPClient(jid='user@xmppserver.net/python',
password='mypassword')
client.on_message = on_message
client.on_iq = on_iq
client.on_presence = on_presence
await client.connect(host_addr='xmppserver.net')
await client.send_message(to='someuser@xmppserver.net/Resource',
message='Hello There')
async def on_message(message):
print(message)
async def on_presence(element):
print(element)
async def on_iq(element):
print(element)
loop = asyncio.get_event_loop()
loop.create_task(main())
loop.run_forever()
License
TinyXMPP is made available under the Apache 2.0 license.
Development
You can follow the development of TinyXMPP on GitHub.
Contributing
To contribute to TinyXMPP, please open an issue on our GitHub issue tracker and/or leave a Pull Request. Thanks!
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
tinyxmpp-0.1.1.tar.gz
(7.4 kB
view details)
Built Distribution
tinyxmpp-0.1.1-py3-none-any.whl
(10.8 kB
view details)
File details
Details for the file tinyxmpp-0.1.1.tar.gz
.
File metadata
- Download URL: tinyxmpp-0.1.1.tar.gz
- Upload date:
- Size: 7.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e177ddd89d3cf0306824b664f5754eff205f2d709713530e382139aa4f0224d8 |
|
MD5 | bc34581122a8d384ebce5af0410617c3 |
|
BLAKE2b-256 | be75ef58af2c112ba324defbf3dddf9bc28d58c8ebfc341fcb1a356740805880 |
File details
Details for the file tinyxmpp-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: tinyxmpp-0.1.1-py3-none-any.whl
- Upload date:
- Size: 10.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.9.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 20c54f37c4b6630bc907b2b12369887707e1341c74f37897354078d818815bad |
|
MD5 | ae35cbb5985b61e6724db04951a5af7f |
|
BLAKE2b-256 | 22a735215c27140323c88b6dee65d3db7ff2437221d098bcd749a60173b80af0 |