final | |
|---|---|
extends |
ToolSchema<list<mixed>, array{type: 'array', description?: non-empty-string, title?: non-empty-string, minItems?: int<0, max>, maxItems?: int<0, max>, uniqueItems?: bool, prefixItems?: array<string, mixed>, items?: array<string, mixed>, default?: list<mixed>}> |
The array type is used for validating JSON indexed arrays. This schema follows JSON Schema Draft 2020-12.
| Methods | ||
|---|---|---|
public
|
minItems(int $minItems): self
|
# |
public
|
maxItems(int $maxItems): self
|
# |
public
|
uniqueItems(bool $uniqueItems): self
|
# |
public
|
prefixItems<T, U is array<string, mixed>>(ToolSchema<T, U> $prefixItems): self
|
# |
public
|
items<T, U is array<string, mixed>>(ToolSchema<T, U> $items): self
|
# |
public
|
toArray(): array
|
# |
| Methods inherited from Nexus\Mcp\Schema\Tool\ToolSchema\ToolSchema |
|---|
__construct(), root(), asArray(), asBoolean(), asInteger(), asNull(), asNumber(), asObject(), asString(), title(), description(), default(), required(), isRequired(), jsonSerialize() |
| Properties inherited from Nexus\Mcp\Schema\Tool\ToolSchema\ToolSchema |
|---|
$title, $description, $default, $name |