UNPKG

@owlprotocol/contracts-account-abstraction

Version:

ERC4337 Account Abstraction support for deploying relevant smart contracts and interacting with UserOps.

17 lines (13 loc) 387 B
import { z } from "zod"; import { Hex } from "viem"; // hexnum regex const hexPattern = /^0x[0-9a-f]*$/; export const targetCallResultSchema = z.object({ gasUsed: z.bigint(), success: z.boolean(), returnData: z .string() .regex(hexPattern) .transform((val) => val as Hex), }); export type TargetCallResult = z.infer<typeof targetCallResultSchema>;