Skip to main content

Function

storeEncryptedKey(params)
Persists externally encrypted ciphertext and associated metadata to the wrapped-keys service.

Parameters

params.pkpSessionSigs
SessionSigsMap
required
params.litClient
LitClient
required
params.ciphertext
string
required
params.dataToEncryptHash
string
required
params.publicKey
string
required
params.keyType
'K256' | 'ed25519'
required
params.memo
string
required
params.userMaxPrice
bigint
Optional executeJs price cap.

Returns

result
StoreEncryptedKeyResult

Example

const { id } = await wrappedKeysApi.storeEncryptedKey({
  pkpSessionSigs,
  litClient,
  ciphertext,
  dataToEncryptHash,
  publicKey,
  keyType: 'K256',
  memo: 'pre-encrypted key',
});