Interface: ResourcefulPayloadValidatorGetter()
Function type for generating payload validation schemas based on request context.
These functions are called during create and update operations to generate context-specific validation schemas using Joi. They provide the core model-level validation that applies regardless of request-specific hooks.
ts
ResourcefulPayloadValidatorGetter(ctx: HttpContext, app: ApplicationService): PromiseAble<AnySchema<any>>;Parameters
| Parameter | Type | Description |
|---|---|---|
ctx | HttpContext | HTTP context containing request information and authentication |
app | ApplicationService | Application service instance for accessing app-level services |
Returns
PromiseAble<AnySchema<any>>
Promise resolving to a Joi schema for validating the request payload