Modules - tKey JS SDK
Modules extend the tKey SDK's capability to provide additional functionality for managing your tKey shares. These modules can be used for multiple purposes, from storing shares to generating password or converting them into a form that can remembered or sent out.
A standard tKey flow looks something like this:
Out of the multiple modules available, you can choose the module you want to include in your implementation. Here is the list of available modules:
- Storage Modules: Storage Modules are used to store Shares B in the user's device storage.
- Recovery Modules: Recovery Modules are used to recover the Shares C and so, in the case user doesn't have access to their device/storage or needs additional security.
- Additional Modules: These modules provide extra capability to the tKey SDK, like importing users' existing private keys or seed phrases.
Storage Modules (Share B)
Storage Modules are used to store the tKey shares in the user's device storage. You can choose any of the following modules:
Web Storage Module
Adds the capability to add or remove a share from the local and file storage.
@tkey/web-storage
- npm
- Yarn
- pnpm
npm install --save @tkey/web-storage
yarn add @tkey/web-storage
pnpm add @tkey/web-storage
React Native Storage Module
Adds the capability to add or remove a share from the React Native Encrypted Store/ Expo Secure Store.
@tkey/react-native-storage
- npm
- Yarn
- pnpm
npm install --save @tkey/react-native-storage
yarn add @tkey/react-native-storage
pnpm add @tkey/react-native-storage
Chrome Storage Module
Adds the capability to add or remove a share from the Chrome Extension storage.
@tkey/chrome-storage
- npm
- Yarn
- pnpm
npm install --save @tkey/chrome-storage
yarn add @tkey/chrome-storage
pnpm add @tkey/chrome-storage
Recovery Modules (Share C)
Recovery Modules are used to recover the tKey shares in the case user doesn't have access to their device/storage or needs additional security.
Security Questions Module
Adds the capability to add or remove a question and password as a share.
@tkey/security-questions
- npm
- Yarn
- pnpm
npm install --save @tkey/security-questions
yarn add @tkey/security-questions
pnpm add @tkey/security-questions
Share Transfer Module
Adds the capability to transfer a share to another device.
@tkey/share-transfer
- npm
- Yarn
- pnpm
npm install --save @tkey/share-transfer
yarn add @tkey/share-transfer
pnpm add @tkey/share-transfer
Share Serialization Module
Adds the capability to serialize/ deserialize a BN (private key) into a mnemonic.
@tkey/share-serialization
- npm
- Yarn
- pnpm
npm install --save @tkey/share-serialization
yarn add @tkey/share-serialization
pnpm add @tkey/share-serialization
Additional Modules
These modules provide extra capability to the tKey SDK, like importing users' existing private keys or seedphrases.
Seed Phrase Module
Adds the capability to store and use seed phrases on the metadata.
@tkey/seed-phrase
- npm
- Yarn
- pnpm
npm install --save @tkey/seed-phrase
yarn add @tkey/seed-phrase
pnpm add @tkey/seed-phrase
Private Keys Module
Adds the capability to store extra private keys on the metadata.
@tkey/private-keys
- npm
- Yarn
- pnpm
npm install --save @tkey/private-keys
yarn add @tkey/private-keys
pnpm add @tkey/private-keys