Skip to main content

An implementation of WebRTC and ORTC

Project description

aiortc License Version Python versions Tests Coverage Documentation

What is vsaiortc?

vsaiortc is a library for Web Real-Time Communication (WebRTC) and Object Real-Time Communication (ORTC) in Python. It is built on top of asyncio, Python’s standard asynchronous I/O framework.

The API closely follows its Javascript counterpart while using pythonic constructs:

  • promises are replaced by coroutines

  • events are emitted using pyee.EventEmitter

To learn more about vsaiortc please read the documentation.

Why should I use vsaiortc?

The main WebRTC and ORTC implementations are either built into web browsers, or come in the form of native code. While they are extensively battle tested, their internals are complex and they do not provide Python bindings. Furthermore they are tightly coupled to a media stack, making it hard to plug in audio or video processing algorithms.

In contrast, the vsaiortc implementation is fairly simple and readable. As such it is a good starting point for programmers wishing to understand how WebRTC works or tinker with its internals. It is also easy to create innovative products by leveraging the extensive modules available in the Python ecosystem. For instance you can build a full server handling both signaling and data channels or apply computer vision algorithms to video frames using OpenCV.

Furthermore, a lot of effort has gone into writing an extensive test suite for the vsaiortc code to ensure best-in-class code quality.

Implementation status

vsaiortc allows you to exchange audio, video and data channels and interoperability is regularly tested against both Chrome and Firefox. Here are some of its features:

  • SDP generation / parsing

  • Interactive Connectivity Establishment, with half-trickle and mDNS support

  • DTLS key and certificate generation

  • DTLS handshake, encryption / decryption (for SCTP)

  • SRTP keying, encryption and decryption for RTP and RTCP

  • Pure Python SCTP implementation

  • Data Channels

  • Sending and receiving audio (Opus / PCMU / PCMA)

  • Sending and receiving video (VP8 / H.264)

  • Bundling audio / video / data channels

  • RTCP reports, including NACK / PLI to recover from packet loss

Installing

The easiest way to install vsaiortc is to run:

pip install vsaiortc

Building from source

If there are no wheels for your system or if you wish to build aiortc from source you will need a couple of libraries installed on your system:

  • Opus for audio encoding / decoding

  • LibVPX for video encoding / decoding

Linux

On Debian/Ubuntu run:

apt install libopus-dev libvpx-dev

OS X

On OS X run:

brew install opus libvpx

License

vsaiortc is released under the BSD license.

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

vsaiortc-0.0.7.tar.gz (1.2 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

vsaiortc-0.0.7-py3-none-any.whl (91.7 kB view details)

Uploaded Python 3

vsaiortc-0.0.7-cp39-abi3-win_amd64.whl (1.0 MB view details)

Uploaded CPython 3.9+Windows x86-64

vsaiortc-0.0.7-cp39-abi3-win32.whl (923.8 kB view details)

Uploaded CPython 3.9+Windows x86

vsaiortc-0.0.7-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.9 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ x86-64

vsaiortc-0.0.7-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.8 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

vsaiortc-0.0.7-cp39-abi3-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.9 MB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ i686manylinux: glibc 2.5+ i686

vsaiortc-0.0.7-cp39-abi3-macosx_11_0_arm64.whl (899.4 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

vsaiortc-0.0.7-cp39-abi3-macosx_10_9_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.9+macOS 10.9+ x86-64

File details

Details for the file vsaiortc-0.0.7.tar.gz.

File metadata

  • Download URL: vsaiortc-0.0.7.tar.gz
  • Upload date:
  • Size: 1.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for vsaiortc-0.0.7.tar.gz
Algorithm Hash digest
SHA256 7bb99ae6ff4860669e96a50e442993bcd01d365468e78ac697db779f7d04b2e6
MD5 d0a38d8dcd3023f5be2e7c15834dded2
BLAKE2b-256 9eedcb245b17e5455b9b8f6a81fed8e84722551b7e19e4ed1ea60495ee44f965

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-py3-none-any.whl.

File metadata

  • Download URL: vsaiortc-0.0.7-py3-none-any.whl
  • Upload date:
  • Size: 91.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for vsaiortc-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 b065cc0adad076920524cc40202b9d3caa3b536d20fb710b3636c9acb58b0a74
MD5 9fcbae4586f8d82e54862ee88ecbe382
BLAKE2b-256 b7fb03aa33d0f3e1968e9045e20a94c7992e7879ff0d1584384206c5a1b80954

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-cp39-abi3-win_amd64.whl.

File metadata

  • Download URL: vsaiortc-0.0.7-cp39-abi3-win_amd64.whl
  • Upload date:
  • Size: 1.0 MB
  • Tags: CPython 3.9+, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for vsaiortc-0.0.7-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 2caedf715df03802b3fa0f773a2d61f34e1f1c1cdf3e56a7143804dd86748103
MD5 9599d55a5e9a882b71fee70417ed9f31
BLAKE2b-256 fd91f1b91df19ee2a50912e0f49d0518748f3da90fb605a28ad23ee4e07fc7a6

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-cp39-abi3-win32.whl.

File metadata

  • Download URL: vsaiortc-0.0.7-cp39-abi3-win32.whl
  • Upload date:
  • Size: 923.8 kB
  • Tags: CPython 3.9+, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for vsaiortc-0.0.7-cp39-abi3-win32.whl
Algorithm Hash digest
SHA256 3bd91aae3283fa9df63367c94cbff20ae3e460d48e1b76f189b4cabdaae1393a
MD5 8a0c015625bd1b3180f218d67ca36d3b
BLAKE2b-256 9e9271ec601c4e024bb5b16700b92c261c36667a8462e496b52d25cf294cc1a6

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for vsaiortc-0.0.7-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1b8c3418472020ac39fb2a0be86cba0cb815b1ddb4ff313aaf6aaa5470ce99be
MD5 49aa28ca2fac214d08d86a1c2cd7e239
BLAKE2b-256 27bcce361d74c2eaf4527b015474728c83a36ed975e37422e3baac52cf86f20b

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for vsaiortc-0.0.7-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 de8f6d062c7bd0b1d5364c717daab97661b0fb41214d3f190121c4ca218cdd9c
MD5 20c7361eaf9e15381a59dc5ce3a31dee
BLAKE2b-256 1556b06f0e29542be4f2b2de830dc888f6150dfda8b7fa7bd6a81a772453cecd

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-cp39-abi3-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for vsaiortc-0.0.7-cp39-abi3-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 07a743a404cec97abb4d75dea625bf273d3e4886f8b79541fd8717a18c17ef7e
MD5 6e7d0d08e32298fac1ae7625564de899
BLAKE2b-256 2c914b3bed843ee6e6e604fdf64ccaf19b7fe38305e4bff8c78486e6f08f52da

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for vsaiortc-0.0.7-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 10a5cc4fb8da912abd9025948758fd25eb290dca79c7868741b08fa971f065c4
MD5 52c5c75c85bd67e16361809971f2aee6
BLAKE2b-256 f9f0399ca435a19084f8e98bf65f34216c49f6809eb679625a25b2d8002b31fe

See more details on using hashes here.

File details

Details for the file vsaiortc-0.0.7-cp39-abi3-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for vsaiortc-0.0.7-cp39-abi3-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 b834d045577a3b6cf7b5a0d959bae25b11b3c3305e22a84119ca39bf0c9f206e
MD5 beb4f5ddc9b1e19c32e410e7dd3967e7
BLAKE2b-256 469d796ecc15d2b11f0b127859a5d616fef2e50a1d455ea3aafbea85342c9bd5

See more details on using hashes here.

Supported by

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