This app is a sample video conferencing app that uses the Twilio Programmable Video SDK. The open source app can be easily configured by developers to try out real-time video and audio features.

NOTE: The Twilio Function that provides access tokens via a passcode should NOT be used in a production environment. This token server supports seamlessly getting started with the collaboration app, and while convenient, the passcode is not secure enough for production environments. You should use an authentication provider to securely provide access tokens to your client applications. You can find more information about Programmable Video access tokens in this tutorial.
The app requires a back-end to generate Twilio access tokens. Follow the instructions below to deploy a serverless back-end using Twilio Functions.
twilio login and follow prompts to login to your Twilio account.twilio plugins:install @twilio-labs/plugin-rtc.twilio rtc:apps:video:deploy --authentication passcode.The passcode will expire after one week. To generate a new passcode, run twilio rtc:apps:video:deploy --authentication passcode --override.
If any errors occur after running a Twilio CLI RTC Plugin command, or the application fails to validate a passcode, then try the following steps.
twilio plugins:update to update the RTC plugin to the latest version.twilio rtc:apps:video:delete to delete any existing authentication servers.twilio rtc:apps:video:deploy --authentication passcode to deploy a new authentication server.VideoApp/VideoApp.xcodeproj with Xcode.Video-Community target.Team to your team.Bundle identifier to something unique.Automatically manage signing.Video-Community scheme.⌘R the app.The Video-Internal scheme uses authentication that is only available to Twilio employees in order to make internal testing easier.
For each device:
Your name field.Passcode field.Sign in.Continue.Join Now.The passcode will expire after one week. Follow the steps below to sign in with a new passcode.
Settings > Sign Out.NOTE: Usage charges will apply for video calls. See pricing for more information.
This app uses SwiftUI. SwiftUI and Combine work particularly well for the video collaboration features in this app, which involve a lot of real-time state changes. SwiftUI has allowed us to build a better app with a lot less code.
If your app uses UIKit or an older version of SwiftUI, you should still be able to use a lot of code from this repo in your app. Here are some tips:
SwiftUI code from this repo even if your app is currently all UIKit.UIKit to SwiftUI. It has a lot of the same video collaboration features but the UI isn't as nice.SwiftUI but have to support iOS 13, most of the app should work well. The main issue will be LazyVGrid requires iOS 14. However our usage of LazyVGrid is very basic with no scrolling so it shouldn't be a lot of work to replace it with a custom grid built with HStack and VStack.SwiftUI but can use Combine (requires iOS 13), you should be able to use all of the view models and TwilioVideo integration code. For the UI, replace the SwiftUI code with your own UIKit implementation. The Combine interface provided by the view models and TwilioVideo integration layer should be nice for UIKit to use.SwiftUI code with your own UIKit implementation, and replace the Combine code used in the view models and TwilioVideo integration layer with something else. It shouldn't be a lot of work to replace Combine with NotificationCenter or a multicast delegate.For unit tests use:
Video-Internal scheme.Video-InternalTests target.Unit test plan.UI tests require credentials that are only available to Twilio employees.
⌘U will crash if the app was run ⌘R on the device previously. See issue #12 for a workaround and more details.Twilio employees should follow these instructions for internal testing.
Apache 2.0 license. See the LICENSE file for details.
Swift
88.8%
Objective-C
10.3%
This app is a sample video conferencing app that uses the Twilio Programmable Video SDK. The open source app can be easily configured by developers to try out real-time video and audio features.

NOTE: The Twilio Function that provides access tokens via a passcode should NOT be used in a production environment. This token server supports seamlessly getting started with the collaboration app, and while convenient, the passcode is not secure enough for production environments. You should use an authentication provider to securely provide access tokens to your client applications. You can find more information about Programmable Video access tokens in this tutorial.
The app requires a back-end to generate Twilio access tokens. Follow the instructions below to deploy a serverless back-end using Twilio Functions.
twilio login and follow prompts to login to your Twilio account.twilio plugins:install @twilio-labs/plugin-rtc.twilio rtc:apps:video:deploy --authentication passcode.The passcode will expire after one week. To generate a new passcode, run twilio rtc:apps:video:deploy --authentication passcode --override.
If any errors occur after running a Twilio CLI RTC Plugin command, or the application fails to validate a passcode, then try the following steps.
twilio plugins:update to update the RTC plugin to the latest version.twilio rtc:apps:video:delete to delete any existing authentication servers.twilio rtc:apps:video:deploy --authentication passcode to deploy a new authentication server.VideoApp/VideoApp.xcodeproj with Xcode.Video-Community target.Team to your team.Bundle identifier to something unique.Automatically manage signing.Video-Community scheme.⌘R the app.The Video-Internal scheme uses authentication that is only available to Twilio employees in order to make internal testing easier.
For each device:
Your name field.Passcode field.Sign in.Continue.Join Now.The passcode will expire after one week. Follow the steps below to sign in with a new passcode.
Settings > Sign Out.NOTE: Usage charges will apply for video calls. See pricing for more information.
This app uses SwiftUI. SwiftUI and Combine work particularly well for the video collaboration features in this app, which involve a lot of real-time state changes. SwiftUI has allowed us to build a better app with a lot less code.
If your app uses UIKit or an older version of SwiftUI, you should still be able to use a lot of code from this repo in your app. Here are some tips:
SwiftUI code from this repo even if your app is currently all UIKit.UIKit to SwiftUI. It has a lot of the same video collaboration features but the UI isn't as nice.SwiftUI but have to support iOS 13, most of the app should work well. The main issue will be LazyVGrid requires iOS 14. However our usage of LazyVGrid is very basic with no scrolling so it shouldn't be a lot of work to replace it with a custom grid built with HStack and VStack.SwiftUI but can use Combine (requires iOS 13), you should be able to use all of the view models and TwilioVideo integration code. For the UI, replace the SwiftUI code with your own UIKit implementation. The Combine interface provided by the view models and TwilioVideo integration layer should be nice for UIKit to use.SwiftUI code with your own UIKit implementation, and replace the Combine code used in the view models and TwilioVideo integration layer with something else. It shouldn't be a lot of work to replace Combine with NotificationCenter or a multicast delegate.For unit tests use:
Video-Internal scheme.Video-InternalTests target.Unit test plan.UI tests require credentials that are only available to Twilio employees.
⌘U will crash if the app was run ⌘R on the device previously. See issue #12 for a workaround and more details.Twilio employees should follow these instructions for internal testing.
Apache 2.0 license. See the LICENSE file for details.
Swift
88.8%
Objective-C
10.3%