Type Alias RequestSchema<RequestBody, QueryParameters, PathParameters>

RequestSchema: {
    body: never extends RequestBody ? undefined : RequestBody;
    params: never extends PathParameters ? undefined : PathParameters;
    query: never extends QueryParameters ? undefined : QueryParameters;
}

An object with Zod schemas for validating a request body, query parameters, and/or path parameters with validateRequest.

Type Parameters

  • RequestBody extends z.Schema | undefined = never
  • QueryParameters extends z.Schema | undefined = never
  • PathParameters extends z.Schema | undefined = never

Type declaration