Readonly
algorithmsGet the list of algorithms this device supports.
Returns Array<EncryptionAlgorithm>
.
Readonly
curve25519Get the Curve25519 key of the given device.
Readonly
deviceThe unique ID of the device.
Readonly
displayGet the human readable name of the device.
Readonly
ed25519Get the Ed25519 key of the given device.
Readonly
isWhether or not the device is a dehydrated device.
Readonly
keysGet a map containing all the device keys.
Readonly
localGet the trust state of the device.
Readonly
signaturesGet a map containing all the device signatures.
Readonly
userThe user ID of the device owner.
Encrypt a to-device message to be sent to this device, using Olm encryption.
Prior to calling this method you must ensure that an Olm session is available for the target device. This can be done by calling OlmMachine.getMissingSessions.
The caller is responsible for sending the encrypted event to the target device. If multiple messages are encrypted for the same device using this method they should be sent in the same order as they are encrypted.
Returns a promise for a JSON string containing the content
of an
encrypted event, which be used to create the payload for a
/sendToDevice
API.
Get the key of the given key algorithm belonging to this device.
Set the local trust state of the device to the given state.
This won’t affect any cross signing trust state, this only sets a flag marking to have the given trust state.
trust_state
represents the new trust state that should be
set for the device.
A device represents a E2EE capable client of an user.