createBundlerClientFromExisting

Creates a bundler client from an existing public client with the provided transport and chain.

Import

1import { createBundlerClientFromExisting } from "@aa-sdk/core";

Usage

1import { createPublicClient } from "viem";
2import { createBundlerClientFromExisting } from "@aa-sdk/core";
3
4const publicClient = createPublicClient(...);
5const bundlerClient = createBundlerClientFromExisting(publicClient);

Parameters

client

PublicClient<T, Chain> The existing public client to be extended with bundler actions

Returns

BundlerClient<T> A bundler client that extends the functionality of the provided public client