api.video is the video infrastructure for product builders. Lightning fast video APIs for integrating, scaling, and managing on-demand & low latency live streaming features in your app.
NodeJS app to upload videos to api.video
- Clone github repo
- add environmental variables
- install node dependancies
- Run with 'node src/index.js'
When you add a video, there is a request to api.video to create a video. This creates the video 'container' with all the options selected in the form. A delegated token (public upload key) is also created, with a 90s expiration.
The video container id (videoId) and the token are sent back to the broswer, and the upload begins. The video is split into 1 MB segments. As long as the first segment uplads in 90s the token TTL), the video will successfully upload.