Mobizon Client
Ссылка на официальную документацию
Примеры:
Асинхронный клиент
import asyncio
from mobizon_client import AsyncMobizonClient
async def main():
url = 'https://api.mobizon.kz'
api_key = 'xisNSPPFj05WTVyH5oALU86VVuH7SocEUiitN0Og'
client = AsyncMobizonClient(url=url, api_key=api_key)
result = await client.send_message(recipient='77071234567', text='Test message', sender_signature=None)
await asyncio.sleep(3)
result = await client.get_message_status([result.message_id])
assert result[0].status == 'DELIVRD'
await client.close()
if __name__ == '__main__':
asyncio.run(main())
Синхронный клиент
from time import sleep
from mobizon_client import MobizonClient
def main():
url = 'https://api.mobizon.kz'
api_key = 'xisNSPPFj05WTVyH5oALU86VVuH7SocEUiitN0Og'
client = MobizonClient(url=url, api_key=api_key)
result = client.send_message(recipient='77071234567', text='Test message', sender_signature=None)
sleep(3)
result = client.get_message_status([result.message_id])
assert result[0].status == 'DELIVRD'
client.close()
if __name__ == '__main__':
main()
Metadata
Release files for mobizon-client 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| mobizon_client-0.1.2.tar.gz | 3.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| mobizon_client-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.2 kB
Release files / mobizon_client-0.1.2.tar.gz
| Download URL | mobizon_client-0.1.2.tar.gz |
|---|---|
| Size | 3.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
13c91e8d4c0ac296256a7230725f395c58283f87e4152eff9689623b76a921fc
|
|
BLAKE2b-256 checksum How to use checksums |
546e76b1800fb63b21f2e3472cc4b0cb96175427eba7fa1edbdf46184ceddb7c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.2 CPython/3.10.6 Darwin/22.1.0
|
Release files / mobizon_client-0.1.2-py3-none-any.whl
| Download URL | mobizon_client-0.1.2-py3-none-any.whl |
|---|---|
| Size | 4.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c6e2d7fb0a26b72ad03391919db92f878bb244713e5c1818ca8eb92a9519587f
|
|
BLAKE2b-256 checksum How to use checksums |
9900e66597785ce97a43e47fbaa5ca2a27c1d86dd5257e1b8fc447ce788e14d2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.2 CPython/3.10.6 Darwin/22.1.0
|