Skip to main content

Function: string()

Call Signature

string(params?): ZodString

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

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

ZodString

Call Signature

string<T>(params?): $ZodType<T, T>

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

Type Parameters

T

T extends string

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

$ZodType<T, T>