Skip to main content

A websocket library

Project description

asyncwebsockets is an anyio-compatible websocket client library. Thus it works with curio, trio, or asyncio.


To install the latest stable version:

$ pip install asyncwebsockets

To install the latest development version:

$ pip install git+

Basic Usage

import anyio
import asyncwebsockets

async def test():
    async with asyncwebsockets.open_websocket("wss://") as ws:
        await ws.send("test")
        evt = await ws.next_event()
        print(type(evt), getattr(evt, 'data', None))

Project details

Download files

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

Source Distribution

asyncwebsockets-0.9.4.tar.gz (13.0 kB view hashes)

Uploaded source

Built Distribution

asyncwebsockets-0.9.4-py3-none-any.whl (6.1 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page