Creates a multi-owner light account client using the provided parameters. It first creates a multi-owner light account and then creates a smart account client with the provided configurations.
import { createMultiOwnerLightAccountClient } from "@account-kit/smart-contracts";
import { LocalAccountSigner } from "@aa-sdk/core";
import { sepolia } from "viem/chains";
import { http, generatePrivateKey } from "viem";
const account = await createMultiOwnerLightAccountClient({
chain: sepolia,
transport: http("RPC_URL"),
signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey()),
});import { createMultiOwnerLightAccountClient } from "@account-kit/smart-contracts";
import { sepolia, alchemy } from "@account-kit/infra";
import { LocalAccountSigner } from "@aa-sdk/core";
import { generatePrivateKey } from "viem"
const lightAccountClient = await createMultiOwnerLightAccountClient({
transport: alchemy({
apiKey: "your-api-key",
}),
chain: sepolia
signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey())
});the configuration for creating the multi-owner light / alchemy account client with the provided parameters transport
function createMultiOwnerLightAccountClient<TSigner>(
params,
): Promise<
AlchemySmartAccountClient<
undefined | Chain,
MultiOwnerLightAccount<TSigner>,
MultiOwnerLightAccountClientActions<TSigner>
>
>;Defined in: account-kit/smart-contracts/src/light-account/clients/multiOwnerLightAccount.ts:55
| Type Parameter | Default type |
|---|---|
|
|
| Parameter | Type |
|---|---|
|
|
Promise<AlchemySmartAccountClient<undefined | Chain, MultiOwnerLightAccount<TSigner>, MultiOwnerLightAccountClientActions<TSigner>>>
function createMultiOwnerLightAccountClient<TTransport, TChain, TSigner>(
args,
): Promise<
SmartAccountClient<
CustomTransport,
Chain,
MultiOwnerLightAccount<TSigner>,
SmartAccountClientActions<Chain, SmartContractAccount> &
MultiOwnerLightAccountClientActions<
TSigner,
MultiOwnerLightAccount<TSigner>
>
>
>;Defined in: account-kit/smart-contracts/src/light-account/clients/multiOwnerLightAccount.ts:69
| Type Parameter | Default type |
|---|---|
| |
|
|
|
|
| Parameter | Type |
|---|---|
|
|
Promise<SmartAccountClient<CustomTransport, Chain, MultiOwnerLightAccount<TSigner>, SmartAccountClientActions<Chain, SmartContractAccount> & MultiOwnerLightAccountClientActions<TSigner, MultiOwnerLightAccount<TSigner>>>>