ReadonlyalgorithmsGet the list of algorithms this device supports.
Returns Array<EncryptionAlgorithm>.
Readonlycurve25519Get the Curve25519 key of the given device.
ReadonlydeviceThe unique ID of the device.
ReadonlydisplayGet the human readable name of the device.
Readonlyed25519Get the Ed25519 key of the given device.
ReadonlyisWhether or not the device is a dehydrated device.
ReadonlykeysGet a map containing all the device keys.
ReadonlylocalGet the trust state of the device.
ReadonlysignaturesGet a map containing all the device signatures.
ReadonlyuserThe 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.
Optionalshare_strategy: null | CollectStrategyTimestamp representing the first time this device has been seen (in milliseconds).
Get the key of the given key algorithm belonging to this device.
Is the device locally marked as blacklisted?
Blacklisted devices won’t receive any group sessions.
Is this device cross-signed by its owner?
Is this device considered to be verified using cross signing.
Is the device deleted?
Is the device locally marked as trusted?
Is this device considered to be verified.
This method returns true if either the is_locally_trusted
method returns true or if the is_cross_signing_trusted
method returns true.
Request an interactive verification with this device.
Returns a 2-element array [VerificationRequest, ToDeviceRequest].
Optionalmethods: null | any[]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.
Mark this device as verified. Works only if the device is owned by the current user.
Returns a signature upload request that needs to be sent out.
A device represents a E2EE capable client of an user.