Home
Softono
resumeAVideo

resumeAVideo

Open source MIT JavaScript
12
Stars
0
Forks
13
Issues
0
Watchers
3 years
Last Commit

About resumeAVideo

Use analytics and metadata to determine where a viewer "left off" in a video. restart the video at that point. From api.video (https://api.video)

Platforms

Web Self-hosted

Languages

JavaScript

badge

badge

badge

api.video resume a video

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.

resume a video

This demo uses NodeJS and api.video to resume a video from where the viewer left off.

Requires NodeJS.

Simply clone this repo, and install the requiried node modules

npm install

You'll need a .env file where you can add your api.video API key.

Read about how it works in our blog, and check out the demo at resume.a.video

Summary how how it works

Each session has a metadata[userName] attribute that assigns the session to a specific user. Each video session has playback events.

By grabbing the last event in the most recent session - we are able to determine where the user stopped watching the video.

We can then serve the video to start at this timestamp.

If no sessions for user: start at 0

Try it out, and let us know what you think!