Skip to main content

An asyncio wrapper of matrix_client.api

Project description

An asyncio wrapper of matrix_client.api.

This is based on the work in https://github.com/matrix-org/matrix-python-sdk/pull/168

Usage

import aiohttp
from matrix_api_async import AsyncHTTPAPI

  async def main():
      async with aiohttp.ClientSession() as session:
          mapi = AsyncHTTPAPI("http://matrix.org", session)
          resp = await mapi.get_room_id("#matrix:matrix.org")
          print(resp)


  loop = asyncio.get_event_loop()
  loop.run_until_complete(main())

Installation

pip install matrix_api_async

Requirements

  • matrix_client
  • aiohttp (Could potentially be used with other libraries)

Compatibility

Python 3.5+

Licence

MIT

Authors

matrix_api_async was written by Stuart Mumford.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for matrix-api-async, version 0.1.0
Filename, size File type Python version Upload date Hashes
Filename, size matrix_api_async-0.1.0.tar.gz (3.8 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page