aa-schnorr-multisig-sdk
Version:
Account Abstraction Schnorr Multi-Signatures SDK
97 lines (96 loc) • 8.49 kB
TypeScript
import z from "zod";
import type { Transport } from "viem";
import type { SmartAccountSigner, SupportedTransports } from "@alchemy/aa-core";
export declare const createBaseSmartAccountParamsSchema: <TTransport extends SupportedTransports = Transport, TOwner extends SmartAccountSigner<any> = SmartAccountSigner<any>>() => z.ZodObject<{
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
factoryAddress: z.ZodEffects<z.ZodString, `0x${string}`, string>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
}, "strip", z.ZodTypeAny, { [k_1 in keyof z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
factoryAddress: z.ZodEffects<z.ZodString, `0x${string}`, string>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
}>, undefined extends TOwner ? never : "owner">]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
factoryAddress: z.ZodEffects<z.ZodString, `0x${string}`, string>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
}>, undefined extends TOwner ? never : "owner">[k_1]; }, { [k_2 in keyof z.baseObjectInputType<{
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
factoryAddress: z.ZodEffects<z.ZodString, `0x${string}`, string>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
}>]: z.baseObjectInputType<{
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
factoryAddress: z.ZodEffects<z.ZodString, `0x${string}`, string>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
}>[k_2]; }>;
export declare const MultiSigSmartAccountParamsSchema: <TTransport extends SupportedTransports = Transport, TOwner extends SmartAccountSigner<any> = SmartAccountSigner<any>>() => z.ZodObject<{
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
combinedAddress: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
salt: z.ZodOptional<z.ZodString>;
factoryAddress: z.ZodOptional<z.ZodString>;
}, "strip", z.ZodTypeAny, z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
combinedAddress: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
salt: z.ZodOptional<z.ZodString>;
factoryAddress: z.ZodOptional<z.ZodString>;
}>, undefined extends TOwner ? never : "owner"> extends infer T ? { [k in keyof T]: z.objectUtil.addQuestionMarks<z.baseObjectOutputType<{
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
combinedAddress: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
salt: z.ZodOptional<z.ZodString>;
factoryAddress: z.ZodOptional<z.ZodString>;
}>, undefined extends TOwner ? never : "owner">[k]; } : never, z.baseObjectInputType<{
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
combinedAddress: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
salt: z.ZodOptional<z.ZodString>;
factoryAddress: z.ZodOptional<z.ZodString>;
}> extends infer T_1 ? { [k_1 in keyof T_1]: z.baseObjectInputType<{
initCode: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
rpcClient: z.ZodUnion<[z.ZodString, z.ZodType<import("/aa-core").PublicErc4337Client<TTransport>, z.ZodTypeDef, import("/aa-core").PublicErc4337Client<TTransport>>]>;
chain: z.ZodType<import("viem").Chain, z.ZodTypeDef, import("viem").Chain>;
owner: z.ZodOptional<z.ZodType<TOwner, z.ZodTypeDef, TOwner>>;
entryPointAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
accountAddress: z.ZodOptional<z.ZodEffects<z.ZodString, `0x${string}`, string>>;
combinedAddress: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
salt: z.ZodOptional<z.ZodString>;
factoryAddress: z.ZodOptional<z.ZodString>;
}>[k_1]; } : never>;
export type MultiSigAccountAbstractionParams<TTransport extends SupportedTransports = Transport, TOwner extends SmartAccountSigner = SmartAccountSigner> = z.input<ReturnType<typeof MultiSigSmartAccountParamsSchema<TTransport, TOwner>>>;