Skip to main content

An implementation of WebRTC and ORTC

Project description

rtd pypi-v pypi-pyversions pypi-l tests codecov gitter

What is aiortc?

aiortc 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 aiortc please read the documentation.

Why should I use aiortc?

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 aiortc 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 aiortc code to ensure best-in-class code quality.

Implementation status

aiortc 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

Since release 0.9.28 binary wheels are available on PyPI for Linux, Mac and Windows. The easiest way to install aiortc is to run:

pip install aiortc

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:

  • OpenSSL 1.0.2 or greater

  • FFmpeg 4.0 or greater

  • LibVPX for video encoding / decoding

  • Opus for audio encoding / decoding

Linux

On Debian/Ubuntu run:

apt install libavdevice-dev libavfilter-dev libopus-dev libvpx-dev pkg-config

pylibsrtp comes with binary wheels for most platforms, but if it needs to be built from you will also need to run:

apt install libsrtp2-dev

OS X

On OS X run:

brew install ffmpeg opus libvpx pkg-config

License

aiortc 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

aiortc-1.6.0.tar.gz (1.2 MB view details)

Uploaded Source

Built Distributions

aiortc-1.6.0-pp310-pypy310_pp73-win_amd64.whl (1.0 MB view details)

Uploaded PyPy Windows x86-64

aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.8 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.7 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ ARM64

aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.9 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

aiortc-1.6.0-pp310-pypy310_pp73-macosx_10_9_x86_64.whl (1.2 MB view details)

Uploaded PyPy macOS 10.9+ x86-64

aiortc-1.6.0-pp39-pypy39_pp73-win_amd64.whl (1.0 MB view details)

Uploaded PyPy Windows x86-64

aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.8 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.7 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ ARM64

aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.9 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

aiortc-1.6.0-pp39-pypy39_pp73-macosx_10_9_x86_64.whl (1.2 MB view details)

Uploaded PyPy macOS 10.9+ x86-64

aiortc-1.6.0-pp38-pypy38_pp73-win_amd64.whl (1.0 MB view details)

Uploaded PyPy Windows x86-64

aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.8 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ x86-64

aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.7 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ ARM64

aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.9 MB view details)

Uploaded PyPy manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

aiortc-1.6.0-pp38-pypy38_pp73-macosx_10_9_x86_64.whl (1.2 MB view details)

Uploaded PyPy macOS 10.9+ x86-64

aiortc-1.6.0-cp38-abi3-win_amd64.whl (1.0 MB view details)

Uploaded CPython 3.8+ Windows x86-64

aiortc-1.6.0-cp38-abi3-win32.whl (922.3 kB view details)

Uploaded CPython 3.8+ Windows x86

aiortc-1.6.0-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.9 MB view details)

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

aiortc-1.6.0-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.8 MB view details)

Uploaded CPython 3.8+ manylinux: glibc 2.17+ ARM64

aiortc-1.6.0-cp38-abi3-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl (1.9 MB view details)

Uploaded CPython 3.8+ manylinux: glibc 2.17+ i686 manylinux: glibc 2.5+ i686

aiortc-1.6.0-cp38-abi3-macosx_11_0_arm64.whl (895.1 kB view details)

Uploaded CPython 3.8+ macOS 11.0+ ARM64

aiortc-1.6.0-cp38-abi3-macosx_10_9_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.8+ macOS 10.9+ x86-64

File details

Details for the file aiortc-1.6.0.tar.gz.

File metadata

  • Download URL: aiortc-1.6.0.tar.gz
  • Upload date:
  • Size: 1.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for aiortc-1.6.0.tar.gz
Algorithm Hash digest
SHA256 08cffbcde3401b33731b1d4169b9ff860b0aaaca200b62e10ce5978238671ad7
MD5 97ad6f0bbd7fc7b25a17f1931fa443f1
BLAKE2b-256 c9c687d86996ad51d09ccd2b152ffe11fc7a36df9f6b495debcb5092f2ce4b95

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp310-pypy310_pp73-win_amd64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp310-pypy310_pp73-win_amd64.whl
Algorithm Hash digest
SHA256 0a41f4c0b31e45548e7c7397ef1aecc4be49ab68afd8fa134c07581fe0b3a9c2
MD5 4490b79a286998ed7066b4f62c782f03
BLAKE2b-256 b3387340dbd0344e49f6a7d2746b665b82b755c04c2390caeea37c3bb1973f7c

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 4e60d5bc269d4d12f1f5f47e2c17aa3799f3b5c8b73fd6d8d246ddc11bb29776
MD5 d65bddcb03e7e5838a867136ea573ca1
BLAKE2b-256 409cfb20fc24c43d738bc59aa26d7b4afe4a3512b36fc6864a7bad534ab27654

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 090936c719225e50cd4d66f476e6c17293a8062cf7687a1baa5080f3c90ec8b1
MD5 ede9a79b6461808d12fff56cc391ab04
BLAKE2b-256 9e34f25f13279fa96308d5420efe0758693ebbe7a6f31680c00a33c6c4718940

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp310-pypy310_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 607b9496b4a3c8cd9d32afb6d5bce07f9170831ec44a20ab8af54d53879aafc8
MD5 5a2a1b651581fbbc51e2f46bf2ac50ff
BLAKE2b-256 1f290984269d451e6b07ccfa5f28ee24a223f1e1ba6dff39ff1ce7912a8ce7a4

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp310-pypy310_pp73-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp310-pypy310_pp73-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 6677018833a5d648754c99c70e6c6f6d4f3942682cda07ed5afa73422f8a009a
MD5 6b903ce3a171a84c56d740d22aaa7cd8
BLAKE2b-256 b5538933977f7c8cd646f9b5570f65bf5dfc8f8509bcccc559467a8e1901fd27

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp39-pypy39_pp73-win_amd64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp39-pypy39_pp73-win_amd64.whl
Algorithm Hash digest
SHA256 9f20479d0dd06116ac81d332850fab874d83b561a73fd7252d218f55c6bd5b79
MD5 69db83ff79aa12e997c7b6eddfd93ae8
BLAKE2b-256 e9b982d4101be186a3935f4e39e3b079c7e4710463f956e5572ec44e2fc33531

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 f9759a3c00e46ba1c3499dbf5a8513ae37ba65b940a56b0e7fa5070478e9379f
MD5 6463689d01e97ebaeb962b524aeb2092
BLAKE2b-256 6d0ef46cc5d4495247e0500467b05b6bcace4a64122e0109d5c031bd457097d4

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 b5ba865be9708713397ec584ed1baeb2f15d2fa9c32594ce19a41ffa6e2517cb
MD5 51eae527cc45eec1b933ad5afd02f770
BLAKE2b-256 bf8e707896383020c95a331d238d56129826aa6223bd8d4263a6308f3159890f

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp39-pypy39_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 9cff7868663d9d1c74e237b86e45126022466240439a5f63c3440e3acdf0305b
MD5 915e78ad2e6436765623f13aee2ad47c
BLAKE2b-256 d9b6d1f1c073c2bfd43ad19fdc4b7806e5c75fbc4b5a16e13b6ad1be68223f45

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp39-pypy39_pp73-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp39-pypy39_pp73-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 febca6773de18a6bb9e5569ae87c8be55ed184695f1f9fc99aa4744a7b0375f8
MD5 be7f427e7fd78f658ee0a80b84642e24
BLAKE2b-256 026340911c40c1370c85dd23f9a0ab83cab67d2627e3ee582958ea589e22ca03

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp38-pypy38_pp73-win_amd64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp38-pypy38_pp73-win_amd64.whl
Algorithm Hash digest
SHA256 cecfa5f462e73218cadc9acd8013cb3a0d9007a4515bceba6e7755d77bb80061
MD5 ebd09b500bee0e57b3d2eb94213e60e9
BLAKE2b-256 f6f40a9f67c80895db72416a6325c907cbd43980d24f1236d2afba8e6d845777

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 672d0b4ad35c4d8f014f44a142aa55529ec82cfe2809226e1275e35a71fd4422
MD5 6fdfcf5f99e8bae10248b841e9e6eb4d
BLAKE2b-256 08ddf266867df1065a70ef1cad5379e1235784ab81094ba1cb73b471bf0ad9c8

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 813e7985665c94a0e3387b66e39dba6c751e5e588aedbca06d7e52068c6e37fb
MD5 27be6de081677f6144da5361804ccc0b
BLAKE2b-256 05683c9060cd68a793b5e4ca58a43b3576191b01940283daa7732046b8700542

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp38-pypy38_pp73-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 1526a1904174bb11958b8f7e93f01f37f80df2190e5089f0501984bdef79595e
MD5 4708e10a56e93db1e3f3df4690b3f42b
BLAKE2b-256 fe06ece11d5307a60780b847d00f6d665e5b9afdfd05e7d6a720c1c927cabc6b

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-pp38-pypy38_pp73-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-pp38-pypy38_pp73-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 64a9939016edbc8f300de6189983c983753827813ac9acd9b5be8ce61cc32684
MD5 d1ebc8781bfe83c16fc02ac47b9d83ad
BLAKE2b-256 13a90bdca1d9dea1a745f163a605a4373acdbf7dc93dfae5fb309b5090f839d4

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-cp38-abi3-win_amd64.whl.

File metadata

  • Download URL: aiortc-1.6.0-cp38-abi3-win_amd64.whl
  • Upload date:
  • Size: 1.0 MB
  • Tags: CPython 3.8+, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for aiortc-1.6.0-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 98b118d53ae874126b2e9ec6bb1397ea169b85550c4bd5453e279507ff7f0cf9
MD5 b9b7d7ffc910e664083dd908a60066a4
BLAKE2b-256 13455099b40632d44572da573992c446c34822013bacf2fba61f076a812e2d2f

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-cp38-abi3-win32.whl.

File metadata

  • Download URL: aiortc-1.6.0-cp38-abi3-win32.whl
  • Upload date:
  • Size: 922.3 kB
  • Tags: CPython 3.8+, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for aiortc-1.6.0-cp38-abi3-win32.whl
Algorithm Hash digest
SHA256 325f847397af2892aa051dc2880a75e9bd79f535cc05ec8f4538b5ed098b3c5d
MD5 3945e7db61f937d4c3562866370b7ea0
BLAKE2b-256 bb0afd9ce78d109e68cb5b9dabac7cc70d7716be239ed112ce7ea79cf314f76e

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 eb4bd45397945a5323bd077d43c702a3a991d75023f23649c1d18df5d80c221d
MD5 58a6093e1f7b68a0cf5c847f1ff9c45e
BLAKE2b-256 2a001a7979599855f91359ca76af41fd52637c61484c47946007e8a82195979a

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 33f846abd753935881158751994a51f14e345762130688b19c26cab42c01266f
MD5 24fd33598b4cac7bdb0aa97b106f2bfd
BLAKE2b-256 faf677d9eeae78a99df2cde8a00f4ddbad542b4cd874c2c184c964fb69e36e2d

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-cp38-abi3-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-cp38-abi3-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 f93561b515ff478b068bb9b047d8b1e896c747dcf3ee465463047c51a7bea24d
MD5 7540661e587cea80f213c33d1d14ead8
BLAKE2b-256 267b30453df51bfef594266cf4617464920345152c00b1b17897584c444a4e49

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 836c0686fca67f142c52e5af8043206c2bb702ad0ddcdc94ef19caf1c22f8d54
MD5 982dae00417869819a2db5f7e947c651
BLAKE2b-256 9b03fa1a6be5a2838bd0396658a86e48acf7f213693e7394e3a88aad53135763

See more details on using hashes here.

File details

Details for the file aiortc-1.6.0-cp38-abi3-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for aiortc-1.6.0-cp38-abi3-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 4675e04d8441797fef6c8a669b3a67d750670d1b897f08886072a084d743e07d
MD5 5e8717ef960cb900464948cdab9260a5
BLAKE2b-256 e8f6ed7aa7cb727c010ca63939c88099af2d35c2ddaad45859739f49fed01033

See more details on using hashes here.

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