@hyperauth/sdk (package @hyperauth/client). Types sourced from @hyperauth/schemas (auto-generated from Go struct definitions) are noted as such. Types that intentionally diverge from the Go-generated schemas are noted separately.
Identity
GenerateInput
Input to the generate enclave operation. Passed as JSON to the WASM plugin.
GenerateOutput
Returned from the enclave generate operation. Sourced from @hyperauth/schemas.
GenerateOutputWithShares
Extends GenerateOutput with MPC share material. Used internally when the enclave returns shares alongside the database.
GenerateResult
Result type returned by HyperAuthClient.generate() and CoreAPI.generate().
AccountInfo
Minimal account descriptor returned from enclave generation. Sourced from @hyperauth/schemas.
Account
Full account descriptor as returned by query(). Includes additional fields beyond the schema-generated AccountInfo. These extra fields (coin_type, account_index, address_index) reflect the SDK’s local definition, which intentionally diverges from @hyperauth/schemas.
VerificationMethod
Public key associated with a DID document. Sourced from @hyperauth/schemas.
Credential
WebAuthn credential record as returned by query(). Sourced from @hyperauth/schemas.
CreateRegistrationInput
Input to HyperAuthClient.createRegistration().
RegistrationResult
Returned by HyperAuthClient.createRegistration(). The SDK’s local definition intentionally diverges from @hyperauth/schemas (which omits alias_hash).
Vault state
LoadInput
LoadOutput
Sourced from @hyperauth/schemas.
LockOutput
Sourced from @hyperauth/schemas.
UnlockInput
UnlockOutput
Sourced from @hyperauth/schemas.
StatusOutput
Sourced from @hyperauth/schemas.
QueryInput
QueryOutput
The SDK’s local definition of QueryOutput. The accounts field uses the SDK’s extended Account type (adds coin_type, account_index, address_index), which diverges from @hyperauth/schemas.
ExecInput
ExecOutput<T>
Generic result type for exec operations. The SDK uses a generic T for the result field; @hyperauth/schemas generates result?: number[] (raw bytes). Use the SDK’s generic form when calling HyperAuthClient.execute().
VaultExportOutput
Sourced from @hyperauth/schemas.
VaultImportOutput
Sourced from @hyperauth/schemas.
VaultExportOptions
Options for HyperAuthClient.exportVault().
VaultImportOptions
Options for HyperAuthClient.importVault().
ERC-4337
UserOp
ERC-4337 PackedUserOperation. Sourced from @hyperauth/schemas. All numeric fields are hex strings as required by the bundler JSON-RPC API.
SignUserOpResult
Returned by HyperAuthClient.signUserOp().
GetSmartAccountAddressInput
Input to getSmartAccountAddress() (wallet utility function).
GetAccountStateInput
Input to getAccountState() (wallet utility function).
AccountState
Decoded from the accountHelper contract’s getAccountState ABI-encoded response.
UCAN
Resource
String literal union of resource identifiers used in execute() filter expressions.
DelegationOptions
Options for HyperAuthClient.delegate().
InvocationOptions
Options for HyperAuthClient.createInvocation().
Sync
SyncInitResult
Returned by HyperAuthClient.syncInit(). Sourced from @hyperauth/schemas.
SyncRespondResult
Returned by HyperAuthClient.syncRespond(). Sourced from @hyperauth/schemas.
SyncCompleteResult
Returned by HyperAuthClient.syncComplete(). Sourced from @hyperauth/schemas.
Payment
PaymentParams
Input to HyperAuthClient.submitPayment().
PaymentResult
Returned by HyperAuthClient.submitPayment().
PaymentHandlerOptions
Options for HyperAuthClient.registerPaymentHandler().
PaymentHandlerRegistration
Returned by HyperAuthClient.registerPaymentHandler().
Crypto / Enclave
BinaryPayload
EncryptedShares
Encrypted MPC key material returned from generate and used as input to sign, mintUcan, and signUserOp.
SignResult
DeriveAddressResult
MintUcanResult
ParseWebAuthnResult
Boot / Worker
BootStatus
Returned by HyperAuthClient.getBootStatus().
BootEvent
Progress event emitted during worker initialization.
WebAuthn
CreatePasskeyResult
Returned by createPasskey().
CreatePasskeyOptions
Options for createPasskey().
DeviceCapabilities
Result of querying platform WebAuthn support.
Vault persistence
VaultManifest
Single-row metadata record stored in wa-sqlite, tracking the vault’s content-addressed state.
VaultStoreConfig
VaultSnapshotConfig
PinStatus
PinRequest
PinInfo
Indexer
IndexerAlias
IndexerDid
IndexerAccount
IndexerStats
IndexerHealth
Keccak256Fn
Function type for alias hash computation. Accepts implementations from viem, ethers, or @noble/hashes. When omitted, computeAliasHash falls back to hash-wasm.
Error classes
All error classes extendHyperAuthError, which extends Error. The name property is set on each subclass for reliable instanceof-free discrimination.
HyperAuthError
Base class for all SDK errors.
WasmLoadError
Thrown when the WASM plugin fails to load or initialize. Message is prefixed with "WASM load failed: ".
PluginCallError
Thrown when a plugin function call returns no output or throws internally. The functionName property identifies which operation failed.
"${functionName}: ${message}".
ClientStateError
Thrown when the client is used before initialization completes or after close() is called.
WebAuthnError
Thrown when a WebAuthn operation fails: unsupported browser, user cancellation, or an incompatible authenticator algorithm.
NetworkError
Thrown when a network request to the indexer or another remote endpoint fails. Message is prefixed with "Network: ".
StorageError
Thrown when secure storage operations fail. Message is prefixed with "Storage: ".