ValidationMiddlewareOptions
Defined in: zod/src/index.ts:238
Options for validation middleware
Properties
Section titled “Properties”allowUnknownEvents?
Section titled “allowUnknownEvents?”
optionalallowUnknownEvents:boolean
Defined in: zod/src/index.ts:243
Whether to skip validation for events without registered schemas
Default
Section titled “Default”trueonError()?
Section titled “onError()?”
optionalonError: (error) =>void|Promise<void>
Defined in: zod/src/index.ts:248
Custom error handler for validation or unknown event errors
Parameters
Section titled “Parameters”WebhookValidationError | UnknownEventTypeError
Returns
Section titled “Returns”void | Promise<void>