Skip to main content

crypto

Namespace

Namespace in the Lens Scripting API.

  • Available on all platforms
Platform details: Snapchat, SPECS, Camera Kit Web, Camera Kit Mobile fully supported.

Platform details

  • Snapchat — Fully supported.

  • SPECS — Fully supported.

  • Camera Kit Web — Fully supported.

  • Camera Kit Mobile — Fully supported.

Namespaces

NamespaceDescription
subtle-

Functions

FunctionDescription
getRandomValuesFills a provided Uint8Array with cryptographically secure random values. This method emulates crypto.getRandomValues() from the Web Crypto API.
randomUUIDGenerates a cryptographically secure UUID. This method mimics crypto.randomUUID() from the Web Crypto API.