Action utilities related to using modules and resource locking (e.g., installModule, addOwner, recoverEcdsaOwnership) were moved to separate subpackages:
Copy
Ask AI
// Beforeimport { addPasskeyOwner } from '@rhinestone/sdk'// Afterimport { addOwner as addPasskeyOwner } from '@rhinestone/sdk/actions/passkeys'
Additionally, you don’t need to pass rhinestoneAccount, address, chain, and provider params anymore when using actions:
Copy
Ask AI
// Beforeawait rhinestoneAccount.sendTransaction({ calls: [ ...installModule({ rhinestoneAccount, module, }) ], // …})// Afterawait rhinestoneAccount.sendTransaction({ calls: [ // Note that you don't need to spread the actions anymore installModule(module) ], // …})
All actions
/actions:
installModule to install a module
uninstallModule to uninstall a module
/actions/compact (resource locking with TheCompact):
depositEther to deposit ETH into TheCompact
enableEtherWithdrawal to enable permissionless ETH withdrawal (starts reset period)
disableEtherWithdrawal to cancel permissionless ETH withdrawal
withdrawEther to withdraw ETH after the reset period
approveErc20 to approve an ERC-20 token for deposit
depositErc20 to deposit ERC-20 into TheCompact
enableErc20Withdrawal to enable permissionless ERC-20 withdrawal (starts reset period)
disableErc20Withdrawal to cancel permissionless ERC-20 withdrawal
withdrawErc20 to withdraw ERC-20 after the reset period
/actions/ecdsa (ECDSA validator):
enable to enable the validator
disable to disable the validator
addOwner to add an owner
removeOwner to remove an owner
changeThreshold to change the signature threshold
/actions/mfa (multi-factor authorization):
enable to enable the validator
disable to disable the validator
setSubValidator to add a sub-validator to the MFA set
removeSubValidator to remove a sub-validator from the MFA set
changeThreshold to change the MFA signature threshold
/actions/passkeys (passkey validator):
enable to enable the validator
disable to disable the validator
addOwner to add an owner
removeOwner to remove an owner
changeThreshold to change the signature threshold
/actions/recovery (social recovery):
enable to enable the validator
recoverEcdsaOwnership to recover ownership to a new ECDSA owner
recoverPasskeyOwnership to recover ownership to a new passkey owner
All transactions executed with sendTransaction and prepareTransaction now use Rhinestone intents.Using the ERC-4337 user operations (for example, when using a social recovery) now requires a separate flow.This change lets us improve type-safety and DX around using intents.To keep using user operations for specific flows, change your code from:
Copy
Ask AI
const result = await rhinestoneAccount.sendTransaction( // …)
and
Copy
Ask AI
const data = await rhinestoneAccount.prepareTransaction({ // …})const signedData = await rhinestoneAccount.signTransaction(data)const result = await rhinestoneAccount.submitTransaction(signedData)
to:
Copy
Ask AI
const result = await rhinestoneAccount.sendUserOperation( // …)
and:
Copy
Ask AI
const data = await rhinestoneAccount.prepareUserOperation({ // …})const signedData = await rhinestoneAccount.signUserOperation(data)const result = await rhinestoneAccount.submitUserOperation(signedData)
To use the latest version of the SDK, install it with the alpha tag:
Copy
Ask AI
npm i @rhinestone/sdk@alpha
Note that the deployerAccount parameter has been removed, as all deployments are now handled via the Orchestrator.Also, sourceChains now accepts a list of chains instead of a single chain.
Due to the module address changes, you’d need to redeploy and refund the accounts.
This guide provides a detailed breakdown of the changes between the Orchestrator SDK and the new SDK. If you’re looking for a fresh start, see our Quickstart.
For now, using the SDK with existing accounts is not possible. Users would need to create a new smart account.We’re working on making it possible to use the SDK with existing (deployed) smart accounts.Reach out if you need this.