z_string: Create String Schema

View source: R/schema.R

z_stringR Documentation

Create String Schema

Description

Create a JSON Schema for string type.

Usage

z_string(
  description = NULL,
  nullable = FALSE,
  default = NULL,
  min_length = NULL,
  max_length = NULL
)

Arguments

description

Optional description of the field.

nullable

If TRUE, allows null values.

default

Optional default value.

min_length

Optional minimum string length.

max_length

Optional maximum string length.

Value

A list representing JSON Schema for string.

Examples

z_string(description = "The city name")

aisdk documentation built on May 29, 2026, 9:07 a.m.