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

# Provider Comparison

> JSON Schema support across structured output providers.

export const Y = () => <span data-mark="yes">✓</span>;
export const N = () => <span data-mark="no">✗</span>;
export const P = () => <span data-mark="partial" aria-label="Partial support">◐</span>;

Every structured output provider supports a different subset of JSON Schema. This page shows where they diverge so you can pick the right one for your schema.

The table only includes features where at least one provider differs. Basic types, `items`, and `$defs` / `$ref` are supported by all four.

## String constraints

| Feature                   | dottxt | OpenAI | Anthropic | Gemini |
| ------------------------- | ------ | ------ | --------- | ------ |
| `minLength` / `maxLength` | <Y />  | <Y />  | <N />     | <N />  |
| `pattern` (regex)         | <Y />  | <Y />  | <Y />     | <N />  |
| `format`                  | <Y />  | <P />  | <P />     | <P />  |

## Number constraints

| Feature                                 | dottxt | OpenAI | Anthropic | Gemini |
| --------------------------------------- | ------ | ------ | --------- | ------ |
| `minimum` / `maximum`                   | <Y />  | <Y />  | <N />     | <Y />  |
| `exclusiveMinimum` / `exclusiveMaximum` | <Y />  | <Y />  | <N />     | <N />  |
| `multipleOf`                            | <Y />  | <P />  | <N />     | <N />  |

## Array constraints

| Feature                 | dottxt | OpenAI | Anthropic | Gemini |
| ----------------------- | ------ | ------ | --------- | ------ |
| `prefixItems` (tuples)  | <Y />  | <N />  | <N />     | <Y />  |
| `minItems` / `maxItems` | <Y />  | <Y />  | <N />     | <Y />  |
| `contains`              | <Y />  | <N />  | <N />     | <N />  |
| `uniqueItems`           | <N />  | <N />  | <N />     | <N />  |

## Multiple choices

| Feature | dottxt | OpenAI | Anthropic | Gemini |
| ------- | ------ | ------ | --------- | ------ |
| `enum`  | <Y />  | <Y />  | <P />     | <Y />  |

## Object constraints

| Feature                            | dottxt | OpenAI | Anthropic | Gemini |
| ---------------------------------- | ------ | ------ | --------- | ------ |
| Optional fields                    | <Y />  | <N />  | <Y />     | <Y />  |
| `additionalProperties` (as schema) | <Y />  | <N />  | <N />     | <N />  |
| `propertyNames`                    | <Y />  | <N />  | <N />     | <N />  |
| `patternProperties`                | <Y />  | <P />  | <N />     | <N />  |
| Arbitrary JSON                     | <Y />  | <N />  | <N />     | <N />  |
| `minProperties` / `maxProperties`  | <Y />  | <Y />  | <N />     | <Y />  |

## Composition

| Feature | dottxt | OpenAI | Anthropic | Gemini |
| ------- | ------ | ------ | --------- | ------ |
| `anyOf` | <Y />  | <P />  | <Y />     | <N />  |
| `allOf` | <Y />  | <N />  | <P />     | <N />  |
| `oneOf` | <Y />  | <N />  | <N />     | <N />  |
| `not`   | <Y />  | <N />  | <N />     | <N />  |

## Conditionals

| Feature                | dottxt | OpenAI | Anthropic | Gemini |
| ---------------------- | ------ | ------ | --------- | ------ |
| `if` / `then` / `else` | <Y />  | <N />  | <N />     | <N />  |
| `dependentRequired`    | <Y />  | <N />  | <N />     | <N />  |
| `dependentSchemas`     | <N />  | <N />  | <N />     | <N />  |

## Schema reuse and recursion

| Feature           | dottxt | OpenAI | Anthropic | Gemini |
| ----------------- | ------ | ------ | --------- | ------ |
| Recursive schemas | <Y />  | <Y />  | <N />     | <N />  |

## Schema limits

| Limit                 | dottxt | OpenAI    | Anthropic       | Gemini          |
| --------------------- | ------ | --------- | --------------- | --------------- |
| Nesting depth         | None   | 10 levels | None documented | None documented |
| Total properties      | None   | 5000      | None documented | None documented |
| Enum values           | None   | 1000      | None documented | None documented |
| Optional parameters   | None   | N/A       | 24 per request  | None documented |
| Union type parameters | None   | N/A       | 16 per request  | None documented |

## Handling of unsupported features

| Provider      | Behavior                                                                                                    |
| ------------- | ----------------------------------------------------------------------------------------------------------- |
| **dottxt**    | Rejects the schema with an error specifying the unsupported construct                                       |
| **OpenAI**    | With `strict: true`, unsupported schemas return an API error                                                |
| **Anthropic** | SDK strips unsupported constraints, adds them as text in field descriptions, validates response client-side |
| **Gemini**    | Silently ignores unsupported properties                                                                     |

## Sources

* [OpenAI documentation](https://developers.openai.com/api/docs/guides/structured-outputs/)
* [Anthropic documentation](https://platform.claude.com/docs/en/build-with-claude/structured-outputs)
* [Gemini documentation](https://ai.google.dev/gemini-api/docs/structured-output)
* Last verified: February 26, 2026

## Next steps

* [Supported JSON Schema features](/supported-features)
* [Migrate from other providers](/migrate-from-other-providers)
* [API overview](/api/overview)
* [Integrations overview](/integrations/overview)
