method

RiduClient.globalLiveValidation

Check unsaved global fields on the server without saving them.

Arguments

ArgumentTypeDescription
slugSlugThe global slug from your Go configuration.
inputOmit<LiveValidationRequest, "id"> & { id?: never; }The unsaved data and field paths to check. Do not supply a document ID; globals always use update rules.
optionsLiveValidationOptions<LocaleFor<Config>> | undefinedOptional. Exact locale, cancellation signal, and normal request options.

Returns

Resolves with evaluations for the requested fields. Each is checked with zero or more issues, or skipped with no issues. Invalid content is returned as feedback, while failed requests reject with the SDK’s normal errors. A checked response does not guarantee a later save.

Promise<LiveValidationEnvelope>

How it works

Runs only callbacks registered with LiveValidate. It does not save data, run defaults or save hooks, or invoke Validate callbacks.

The caller must pass admin access, read access, and the relevant create or update access rules. The server only checks fields the caller can read and edit.

Send the current form values, cancel superseded requests, and discard results from an older form state. Built-in admin forms handle this automatically.

Full signature

RiduClient.globalLiveValidation<Slug extends GlobalSlug<Config>>( slug: Slug, input: Omit<LiveValidationRequest, "id"> & { id?: never; }, options?: LiveValidationOptions<LocaleFor<Config>>, ): Promise<LiveValidationEnvelope>

Source packages/sdk/src/types.ts:930

Related types

Related guides