At startup, the player should make a call out to a path in order to authenticate and receive a token to allow playback of the video being embedded.
Initially this endpoint will just return a static value, as the aim is simply to make sure the embed code cached in the wild has support for it before even considering enabling tokens in production.
To receive the token, the player should place a request to https://videos.bentasker.co.uk/token_endpoint
and include the following params in the query string
Path of the video to be played
The referring page
The token server will respond with a JSON encapsulated object containing the following attributes
(boolean) - is auth granted?
(string) - the token string
(unsigned int) - Expiry epoch for the token, 0
if no expiry
The embed code then needs to append token
to the manifest path the player will use as query string arguments t