> ## Documentation Index
> Fetch the complete documentation index at: https://redop.useagents.site/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Schema Adapters

> Reference for Redop schema auto-detection and the supported schema styles for tool input and output schemas.

Redop uses schema detection to do two jobs with one `inputSchema` value:

* parse runtime tool arguments
* generate JSON Schema for MCP discovery

## Built-in paths

### Zod v4

* strong TypeScript inference
* defaults and coercions flow into handler input
* best default developer experience

### Standard Schema

* works with libraries that implement the Standard Schema contract
* Redop can infer input/output types through that shape

### Valibot and ArkType

* both fit the Standard Schema model
* Redop can usually auto-detect them

### TypeBox

* uses the schema directly as JSON Schema
* can validate with `@sinclair/typebox/value` when available

### Plain JSON Schema

* useful when you already have JSON Schema
* Redop uses the schema directly for tool metadata
* no extra adapter package is required
  Redop auto-detects these schema styles per declared schema.

## Output schemas

`outputSchema` supports the same schema styles as `inputSchema`.

Redop converts the declared schema to JSON Schema for MCP metadata, but it does not validate returned handler values against `outputSchema` at runtime.

## Rule of thumb

* use Zod if you are starting fresh
* use Valibot or ArkType if your project already standardizes on Standard Schema libraries
* use TypeBox if you want JSON-Schema-first definitions with optional runtime validation
* use JSON Schema if you already have schemas
* use a supported schema format that Redop can detect automatically
