Skip to main content
Configuration objects for the HyperAuth SDK client.

ClientConfig

Passed to createClient(config) or HyperAuthClient.create(plugin, config). All fields are optional.

Fields

Notes

  • wasmUrl and wasmBytes are mutually exclusive. wasmBytes takes precedence in the bridge implementation if both are supplied.
  • wasmUrl and vaultWasmUrl both default to the public CDN at https://cdn.hyperauth.dev/latest/. For production deployments, pin to a specific version (e.g. https://cdn.hyperauth.dev/v0.5.2/enclave.wasm) so a CDN rollout cannot break a live build.
  • autoLockTimeout triggers HyperAuthClient.lock() after the inactivity period. If an onAutoLock callback has been registered via setAutoLockCallback(), it receives the encrypted database bytes from the lock result.
  • createClient() uses wasmUrl and contracts to initialize the core worker bridge. HyperAuthClient.create() with a pre-constructed WasmPlugin does not use these fields.

ContractsConfig

Smart contract addresses for a specific EVM chain. Used by the enclave to construct and verify on-chain operations.

Fields

Default values (defaultContracts)

Exported as defaultContracts from @hyperauth/sdk. Matches the DEFAULT_CONTRACTS constant in the vault worker.

WorkerConfig

Configuration passed to createCoreBridge(). Used internally by createClient().

Fields


VaultStoreConfig

Configuration for VaultStore initialization. VaultStore manages the wa-sqlite persistence layer for fast page-reload restore.

Fields


VaultSnapshotConfig

Configuration for VaultSnapshot, which wraps vault bytes in DAG-CBOR and stores them in a Helia blockstore.

Fields


WebAuthn defaults

Constants defined in sdk/client/src/constants.ts.