createMediaKeys

The MediaKeySystemAccess.createMediaKeys() method returns a Promise that resolves to a new MediaKeys object.

MDN Reference