buildSessionKeysToRemoveStruct

Finds predecessors for each provided key and returns them in the struct ISessionKeyPlugin.SessionKeyToRemove[].

Import

1import { buildSessionKeysToRemoveStruct } from "@account-kit/smart-contracts";

Usage

1import { buildSessionKeysToRemoveStruct } from "@account-kit/smart-contracts";
2
3const client = createSmartAccountClient(...);
4
5const keysToRemove = await buildSessionKeysToRemoveStruct(client, {
6keys: ["0x...", "0x..."],
7});

Parameters

client

Client<TTransport, TChain, TAccount> The client instance used to interact with the smart account

args

BuildSessionKeysToRemoveStructParams<TAccount> Arguments to configure the session key removal process

Returns

Promise<{ sessionKey: Address; predecessor: Address }[]> A promise that resolves to an array of objects each containing a session key and its predecessor