Skip to main content

Introduction

Pexip VPaaS is a cloud-based video conferencing solution that allows organizations to integrate high-quality video conferencing capabilities into their own applications, websites, or workflows using APIs. This enables businesses to create custom video communication experiences tailored to their specific needs without having to build the infrastructure from scratch.

Pexip VPaaS is an brand-new offering that has many significant differences from the self hosted Pexip Infinity solution.

Some of the main features and differences include:

  • Cloud environment: Instead of being a self-hosted solution, this is a multi-tenant cloud service. This simplifies the deployment and maintenance since you don’t have to worry about firewalls, protocols and different ports - and you don't have to take responsibility for running the video platform itself. You are only responsble for your own application.

  • Selective Forwarding: While Pexip Infinity transcodes, which mixes all the remote video streams in a single video stream, in VPaaS we do selective forwarding. You, as a developer, receive all the streams and it's up to you how to display them to the user.

  • No personal data stored: The video platform doesn’t store any personal data which is a key feature for data protection. A new “participant” is created for each meeting. It isn’t possible to track usage from Pexip VPaaS side. If you want to track the usage, you can do it in your own application backend.

    Only you handle your application's private data and your users' PII.

  • Simulcast: With simulcast a user can send several streams with different qualities. For example, they could send three videos with different resolutions. This way other participants can select which of these streams they want to receive. This allows us to save bandwidth and have a great quality at the same time.

  • Dynamic layouts: You, as a developer, don’t have any constraints about how the layout of the participant looks like. You can create your own layout, decide the size of each participant’s video and its location on-screen.

  • Multi-camera: A participant with several cameras connected to their device can share streams from all of them at the same time.

  • Multi-presentation: Several participants can share their screen at the same time.

  • High quality video: While Infinity can support two person 4K video calls via direct media, larger conferences are limited to 1080p. With VPaaS we can support 4K streams for multiple participants. To support this, each user's device should be powerful enough to encode and decode multiple high resolution video streams - and their network connection should be sufficient to handle the traffic.

Architecture

Before getting deep into the tutorials, let's take a look at the system architecture that we are going to build and the different parts that compose it.

There are three main components to video integrations:

  • Your Client App: This is the web application that the user interacts with. During these tutorials, we are going to build it from scratch with React and TypeScript, although you can use any other language or framework you want to integrate it with your own app.

  • Your Backend: You need to develop a small backend service or extend an existing one with new capabilities. The reason for this is that VPaaS was developed with privacy in mind. It stores the least amount of PII possible, so it doesn't know who the users are. This means that you need to handle the authentication, the mapping between users and VPaaS participants and the communication between the client app and VPaaS.

    In our case, we develop this server with NodeJS and Express, although you can use any other technology you like.

  • Pexip VPaaS: This is the service that provides cloud video capabilities. It handles the video streams and the communication between the participants. We use Pexip VPaaS REST API to interact with it.

The following diagram shows the architecture of the app:

Architecture

info

This is a simplified version of the architecture. In a real-world scenario there would be more API calls between your client app and backend, and your backend and Pexip VPaaS. However, this diagram helps you to understand the main parts of the app and how they interact.

Steps to join a meeting:

  1. User loads the URL for your server in the browser and the server returns the client app.
  2. Client app interacts with your backend to authenticate the user and create the meeting if it doesn't exist.
  3. Your backend interacts with Pexip VPaaS to create the meeting and create credentials for a user to join it.
  4. Your backend returns the information about the meeting and the token to join it to the client app.
  5. Client app uses this information to join the meeting.
  6. Client app and Pexip VPaaS negotiate the connection and start the audio and video streams between the participants.

After joining a meeting, the participants can interact with each other and Pexip VPaaS handles the video streams and the communication between them.

Network and Security

An integration with Pexip VPaaS has several components that communicate with each other.

In the previous diagram you saw that the client app communicates with your backend and your backend communicates with the VPaaS service:

  • Your Backend and VPaaS: The communication between your backend and the VPaaS service is done through the Pexip VPaaS REST API using HTTPS (443 TCP port). Don't forget configure your firewalls to allow this communication.

  • User: The user connects to your backend and Pexip VPaaS through the client app. During this tutorial, the connection to your backend is done through HTTPS (443 TCP port), but it could use any combination of protocol and port you like. Keep in mind that, in this case, you need to have a valid certificate to secure this connection. After that, the user connects to the VPaaS service to send and receive the video streams. This connection is done through WebRTC (32768-60999 UDP and 443 TCP ports).

The connection with the user is difficult to control, because it depends on the user's network. If the user is behind a firewall that blocks the WebRTC ports, the connection fails. To prevent this, you can recommend the user to open these ports in their firewall.