Skip to main content
Session keys only work with CHIPI wallets - not READY wallets. Make sure your wallet was created with walletType: "CHIPI".

Usage

Parameters

Return Value

Returns an object containing:

SessionKeyData Structure

Example Implementation

Security Considerations

Never store session keys in your backend database. This defeats the purpose of self-custodial security. Store only in client-side secure storage.

Best Practices

  1. Set short durations - Use 1-6 hours, not days
  2. Clear on logout - Always remove session from storage when user logs out
  3. Register on-chain - After creating, use useAddSessionKeyToContract to register it
This hook only generates the session keypair locally. You must call useAddSessionKeyToContract to register it on-chain before it can be used for transactions.