Skip to main content

Function: nanoid()

nanoid(params?): ZodNanoID

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

Parameters​

params?​

string |

{ abort?: boolean; error?: string | $ZodErrorMap<NonNullable<$ZodIssueInvalidType<unknown> | $ZodIssueInvalidStringFormat>>; length?: number; message?: string; }

abort?​

boolean

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

error?​

string | $ZodErrorMap<NonNullable<$ZodIssueInvalidType<unknown> | $ZodIssueInvalidStringFormat>>

length?​

number

message?​

string

Deprecated

This parameter is deprecated. Use error instead.

Returns​

ZodNanoID