Skip to content

Interface: Crypto ​

Defined in: types/desktop-engine.d.ts:5007

Cryptographically strong random values from the system: the Web Crypto API without subtle

Methods ​

getRandomValues() ​

ts
getRandomValues<T>(array): T;

Defined in: types/desktop-engine.d.ts:5012

Fills an integer typed array with random values and returns it. Throws a "TypeMismatchError" DOMException for other arrays (Float32Array, Float64Array, DataView), a "QuotaExceededError" one for more than 65536 bytes

Type Parameters ​

Type Parameter
T extends RandomValuesArray

Parameters ​

ParameterType
arrayT

Returns ​

T


randomUUID() ​

ts
randomUUID(): `${string}-${string}-${string}-${string}-${string}`;

Defined in: types/desktop-engine.d.ts:5014

A random version 4 UUID in lowercase, e.g. "3b241101-e2bb-4255-8caf-4136c566a962"

Returns ​

`${string}-${string}-${string}-${string}-${string}`

The SDK is released under the Apache License 2.0