Baseline Widely available
Secure context: This feature is available only in secure contexts (HTTPS), in some or all supporting browsers.
The generateRequest()
method of the MediaKeySession
interface returns a Promise
after generating a license request based on initialization data.
generateRequest(initDataType, initData)
Parameters
initDataType
A string that specifies the format of the initData
parameter. This must be one of the following values:
initData
Initialization data for the request, in the format specified by initDataType
. It is an instance of any of the following types:
A Promise
.
TypeError
Raised if initDataType
is an empty string, if initData
is an empty array, or if the provided initData
is not valid according to the specified initDataType
.
DOMException
NotSupportedError
Raised if the Key System implementation associated with the MediaKeySession
object does not support the provided initDataType
, if the sanitized initialization data is empty, or if the sanitized initialization data is not supported by the content decryption module (CDM).
DOMException
QuotaExceededError
Raised if the operation fails due to a lack of resources on the user agent or CDM.
DOMException
InvalidStateError
Raised if the MediaKeySession
object is in a closing
or closed
state, or if it has already been initialized.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4