function getSignerType<TTransport, TChain>(params): Promise<SignerType>;Defined in: account-kit/smart-contracts/src/msca/plugins/multisig/utils/getSignerType.ts:51
Determines the type of signer (Externally Owned Account (EOA) or CONTRACT) based on the provided client, signature, and signer.
import { getSignerType } from "@account-kit/smart-contracts";
import { LocalAccountSigner } from "@aa-sdk/core";
import { createPublicClient, generatePrivateKey } from "viem";
const signer = LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey());
const client = createPublicClient(...);
const signature = signer.signMessage("Hello World");
const signerType = await getSignerType({ client, signature, signer }); // EOA| Type Parameter | Default type |
|---|---|
| |
|
|
| Parameter | Type | Description |
|---|---|---|
|
| the parameters including the client, signature, and signer |
Promise<SignerType>
A promise that resolves to the signer type, which is either "EOA" or "CONTRACT"