Skip to main content

Interface: ZodDate

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:467

Extends​

Properties​

_def​

_def: $ZodDateDef

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:11

Deprecated​

Use .def instead.

Inherited from​

_ZodDate._def


_input​

_input: Date

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:15

Deprecated​

Use z.input<typeof schema> instead.

Inherited from​

_ZodDate._input


_output​

_output: Date

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:13

Deprecated​

Use z.output<typeof schema> instead.

Inherited from​

_ZodDate._output


_zod​

_zod: $ZodDateInternals

Defined in: packages/agentos/node_modules/zod/v4/core/schemas.d.cts:111

Inherited from​

_ZodDate._zod


~standard​

~standard: ZodStandardSchemaWithJSON<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:16

Inherited from​

_ZodDate.~standard


def​

def: $ZodDateDef

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:8

Inherited from​

_ZodDate.def


description?​

optional description: string

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:63

Inherited from​

_ZodDate.description


maxDate​

maxDate: Date | null

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:465

Deprecated​

Not recommended.

Inherited from​

_ZodDate.maxDate


minDate​

minDate: Date | null

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:463

Deprecated​

Not recommended.

Inherited from​

_ZodDate.minDate


spa()​

spa: (data, params?) => Promise<ZodSafeParseResult<Date>>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:30

Parameters​

data​

unknown

params?​

ParseContext<$ZodIssue>

Returns​

Promise<ZodSafeParseResult<Date>>

Inherited from​

_ZodDate.spa


type​

type: "date"

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:9

Inherited from​

_ZodDate.type

Methods​

and()​

and<T>(incoming): ZodIntersection<ZodDate, T>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:55

Type Parameters​

T​

T extends SomeType

Parameters​

incoming​

T

Returns​

ZodIntersection<ZodDate, T>

Inherited from​

_ZodDate.and


apply()​

apply<T, TArgs>(fn, ...args): T

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:85

Type Parameters​

T​

T

TArgs​

TArgs extends unknown[] = []

Parameters​

fn​

(schema, ...args) => T

args​

...TArgs

Returns​

T

Inherited from​

_ZodDate.apply


array()​

array(): ZodArray<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:53

Returns​

ZodArray<ZodDate>

Inherited from​

_ZodDate.array


brand()​

brand<T, Dir>(value?): PropertyKey extends T ? ZodDate : $ZodBranded<ZodDate, T, Dir>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:25

Type Parameters​

T​

T extends PropertyKey = PropertyKey

Dir​

Dir extends "inout" | "in" | "out" = "out"

Parameters​

value?​

T

Returns​

PropertyKey extends T ? ZodDate : $ZodBranded<ZodDate, T, Dir>

Inherited from​

_ZodDate.brand


catch()​

Call Signature​

catch(def): ZodCatch<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:57

Parameters​
def​

Date

Returns​

ZodCatch<ZodDate>

Inherited from​

_ZodDate.catch

Call Signature​

catch(def): ZodCatch<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:58

Parameters​
def​

(ctx) => Date

Returns​

ZodCatch<ZodDate>

Inherited from​

_ZodDate.catch


check()​

check(...checks): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:19

Parameters​

checks​

...(CheckFn<Date> | $ZodCheck<Date>)[]

Returns​

this

Inherited from​

_ZodDate.check


clone()​

clone(def?, params?): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:21

Parameters​

def?​

$ZodDateDef

params?​
parent​

boolean

Returns​

this

Inherited from​

_ZodDate.clone


decode()​

decode(data, params?): Date

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:34

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

Date

Inherited from​

_ZodDate.decode


decodeAsync()​

decodeAsync(data, params?): Promise<Date>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:36

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

Promise<Date>

Inherited from​

_ZodDate.decodeAsync


default()​

Call Signature​

default(def): ZodDefault<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:49

Parameters​
def​

Date

Returns​

ZodDefault<ZodDate>

Inherited from​

_ZodDate.default

Call Signature​

default(def): ZodDefault<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:50

Parameters​
def​

() => Date

Returns​

ZodDefault<ZodDate>

Inherited from​

_ZodDate.default


describe()​

describe(description): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:62

Returns a new instance that has been registered in z.globalRegistry with the specified description

Parameters​

description​

string

Returns​

this

Inherited from​

_ZodDate.describe


encode()​

encode(data, params?): Date

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:33

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

Date

Inherited from​

_ZodDate.encode


encodeAsync()​

encodeAsync(data, params?): Promise<Date>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:35

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

Promise<Date>

Inherited from​

_ZodDate.encodeAsync


exactOptional()​

exactOptional(): ZodExactOptional<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:45

Returns​

ZodExactOptional<ZodDate>

Inherited from​

_ZodDate.exactOptional


isNullable()​

isNullable(): boolean

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:84

Returns​

boolean

Deprecated​

Try safe-parsing null (this is what isNullable does internally):

const schema = z.string().nullable();
const isNullable = schema.safeParse(null).success; // true

Inherited from​

_ZodDate.isNullable


isOptional()​

isOptional(): boolean

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:75

Returns​

boolean

Deprecated​

Try safe-parsing undefined (this is what isOptional does internally):

const schema = z.string().optional();
const isOptional = schema.safeParse(undefined).success; // true

Inherited from​

_ZodDate.isOptional


max()​

max(value, params?): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:461

Parameters​

value​

number | Date

params?​

string |

{ abort?: boolean; error?: string | $ZodErrorMap<$ZodIssueTooBig<Numeric>>; message?: string; }

abort?​

boolean

If true, no later checks will be executed if this check fails. Default false.

error?​

string | $ZodErrorMap<$ZodIssueTooBig<Numeric>>

message?​

string

Deprecated

This parameter is deprecated. Use error instead.

Returns​

this

Inherited from​

_ZodDate.max


meta()​

Call Signature​

meta(): {[key: string]: unknown; deprecated?: boolean; description?: string; id?: string; title?: string; } | undefined

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:65

Returns the metadata associated with this instance in z.globalRegistry

Returns​

{[key: string]: unknown; deprecated?: boolean; description?: string; id?: string; title?: string; } | undefined

Inherited from​

_ZodDate.meta

Call Signature​

meta(data): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:67

Returns a new instance that has been registered in z.globalRegistry with the specified metadata

Parameters​
data​
deprecated?​

boolean

description?​

string

id?​

string

title?​

string

Returns​

this

Inherited from​

_ZodDate.meta


min()​

min(value, params?): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:460

Parameters​

value​

number | Date

params?​

string |

{ abort?: boolean; error?: string | $ZodErrorMap<$ZodIssueTooSmall<Numeric>>; message?: string; }

abort?​

boolean

If true, no later checks will be executed if this check fails. Default false.

error?​

string | $ZodErrorMap<$ZodIssueTooSmall<Numeric>>

message?​

string

Deprecated

This parameter is deprecated. Use error instead.

Returns​

this

Inherited from​

_ZodDate.min


nonoptional()​

nonoptional(params?): ZodNonOptional<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:46

Parameters​

params?​

string |

{ error?: string | $ZodErrorMap<$ZodIssueInvalidType<unknown>>; message?: string; }

error?​

string | $ZodErrorMap<$ZodIssueInvalidType<unknown>>

message?​

string

Deprecated

This parameter is deprecated. Use error instead.

Returns​

ZodNonOptional<ZodDate>

Inherited from​

_ZodDate.nonoptional


nullable()​

nullable(): ZodNullable<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:47

Returns​

ZodNullable<ZodDate>

Inherited from​

_ZodDate.nullable


nullish()​

nullish(): ZodOptional<ZodNullable<ZodDate>>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:48

Returns​

ZodOptional<ZodNullable<ZodDate>>

Inherited from​

_ZodDate.nullish


optional()​

optional(): ZodOptional<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:44

Returns​

ZodOptional<ZodDate>

Inherited from​

_ZodDate.optional


or()​

or<T>(option): ZodUnion<[ZodDate, T]>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:54

Type Parameters​

T​

T extends SomeType

Parameters​

option​

T

Returns​

ZodUnion<[ZodDate, T]>

Inherited from​

_ZodDate.or


overwrite()​

overwrite(fn): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:43

Parameters​

fn​

(x) => Date

Returns​

this

Inherited from​

_ZodDate.overwrite


parse()​

parse(data, params?): Date

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:26

Parameters​

data​

unknown

params?​

ParseContext<$ZodIssue>

Returns​

Date

Inherited from​

_ZodDate.parse


parseAsync()​

parseAsync(data, params?): Promise<Date>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:28

Parameters​

data​

unknown

params?​

ParseContext<$ZodIssue>

Returns​

Promise<Date>

Inherited from​

_ZodDate.parseAsync


pipe()​

pipe<T>(target): ZodPipe<ZodDate, T>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:59

Type Parameters​

T​

T extends $ZodType<any, Date, $ZodTypeInternals<any, Date>>

Parameters​

target​

T | $ZodType<any, Date, $ZodTypeInternals<any, Date>>

Returns​

ZodPipe<ZodDate, T>

Inherited from​

_ZodDate.pipe


prefault()​

Call Signature​

prefault(def): ZodPrefault<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:51

Parameters​
def​

() => Date

Returns​

ZodPrefault<ZodDate>

Inherited from​

_ZodDate.prefault

Call Signature​

prefault(def): ZodPrefault<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:52

Parameters​
def​

Date

Returns​

ZodPrefault<ZodDate>

Inherited from​

_ZodDate.prefault


readonly()​

readonly(): ZodReadonly<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:60

Returns​

ZodReadonly<ZodDate>

Inherited from​

_ZodDate.readonly


refine()​

refine<Ch>(check, params?): Ch extends (arg) => arg is R ? ZodDate & ZodType<R, Date, $ZodTypeInternals<R, Date>> : ZodDate

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:41

Type Parameters​

Ch​

Ch extends (arg) => unknown

Parameters​

check​

Ch

params?​

string |

{ abort?: boolean; error?: string | $ZodErrorMap<NonNullable<$ZodIssue>>; message?: string; params?: Record<string, any>; path?: PropertyKey[]; when?: (payload) => boolean; }

abort?​

boolean

If true, no later checks will be executed if this check fails. Default false.

error?​

string | $ZodErrorMap<NonNullable<$ZodIssue>>

message?​

string

Deprecated

This parameter is deprecated. Use error instead.

params?​

Record<string, any>

path?​

PropertyKey[]

when?​

(payload) => boolean

If provided, the check runs only when this returns true. By default, it is skipped if prior parsing produced aborting issues.

Returns​

Ch extends (arg) => arg is R ? ZodDate & ZodType<R, Date, $ZodTypeInternals<R, Date>> : ZodDate

Inherited from​

_ZodDate.refine


register()​

register<R>(registry, ...meta): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:24

Type Parameters​

R​

R extends $ZodRegistry<MetadataType, $ZodType<unknown, unknown, $ZodTypeInternals<unknown, unknown>>>

Parameters​

registry​

R

meta​

...ZodDate extends R["_schema"] ? undefined extends R["_meta"] ? [$replace<R["_meta"], R["_schema"] & ZodDate>?] : [$replace<R["_meta"], R["_schema"] & ZodDate>] : ["Incompatible schema"]

Returns​

this

Inherited from​

_ZodDate.register


safeDecode()​

safeDecode(data, params?): ZodSafeParseResult<Date>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:38

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

ZodSafeParseResult<Date>

Inherited from​

_ZodDate.safeDecode


safeDecodeAsync()​

safeDecodeAsync(data, params?): Promise<ZodSafeParseResult<Date>>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:40

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

Promise<ZodSafeParseResult<Date>>

Inherited from​

_ZodDate.safeDecodeAsync


safeEncode()​

safeEncode(data, params?): ZodSafeParseResult<Date>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:37

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

ZodSafeParseResult<Date>

Inherited from​

_ZodDate.safeEncode


safeEncodeAsync()​

safeEncodeAsync(data, params?): Promise<ZodSafeParseResult<Date>>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:39

Parameters​

data​

Date

params?​

ParseContext<$ZodIssue>

Returns​

Promise<ZodSafeParseResult<Date>>

Inherited from​

_ZodDate.safeEncodeAsync


safeParse()​

safeParse(data, params?): ZodSafeParseResult<Date>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:27

Parameters​

data​

unknown

params?​

ParseContext<$ZodIssue>

Returns​

ZodSafeParseResult<Date>

Inherited from​

_ZodDate.safeParse


safeParseAsync()​

safeParseAsync(data, params?): Promise<ZodSafeParseResult<Date>>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:29

Parameters​

data​

unknown

params?​

ParseContext<$ZodIssue>

Returns​

Promise<ZodSafeParseResult<Date>>

Inherited from​

_ZodDate.safeParseAsync


superRefine()​

superRefine(refinement, params?): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:42

Parameters​

refinement​

(arg, ctx) => void | Promise<void>

params?​

$ZodSuperRefineParams

Returns​

this

Inherited from​

_ZodDate.superRefine


toJSONSchema()​

toJSONSchema(params?): ZodStandardJSONSchemaPayload<ZodDate>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:18

Converts this schema to a JSON Schema representation.

Parameters​

params?​

ToJSONSchemaParams

Returns​

ZodStandardJSONSchemaPayload<ZodDate>

Inherited from​

_ZodDate.toJSONSchema


transform()​

transform<NewOut>(transform): ZodPipe<ZodDate, ZodTransform<Awaited<NewOut>, Date>>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:56

Type Parameters​

NewOut​

NewOut

Parameters​

transform​

(arg, ctx) => NewOut | Promise<NewOut>

Returns​

ZodPipe<ZodDate, ZodTransform<Awaited<NewOut>, Date>>

Inherited from​

_ZodDate.transform


validate()​

validate(data, params?): data is Date

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:31

Parameters​

data​

unknown

params?​

ParseContext<$ZodIssue>

Returns​

data is Date

Inherited from​

_ZodDate.validate


validateAsync()​

validateAsync(data, params?): Promise<boolean>

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:32

Parameters​

data​

unknown

params?​

ParseContext<$ZodIssue>

Returns​

Promise<boolean>

Inherited from​

_ZodDate.validateAsync


with()​

with(...checks): this

Defined in: packages/agentos/node_modules/zod/v4/classic/schemas.d.cts:20

Parameters​

checks​

...(CheckFn<Date> | $ZodCheck<Date>)[]

Returns​

this

Inherited from​

_ZodDate.with