Skip to main content

allof-with-ref

Category: Structural — overall schema structure triggers this rule

Error Codes​

ProfileCodeSeverity
anthropic.so.2026-04-30ANT-S-allof-with-refForbid

Description​

allOf combined with $ref is not supported by Anthropic

Provider Evidence​

ProfileStatusSourceBasis
anthropic.so.2026-04-30documentedAnthropic JSON Schema limitations—

Rationale​

Anthropic rejects schemas that combine allOf with $ref references.

Bad Example​

{ "type": "object", "allOf": [{ "$ref": "#/$defs/Base" }] }

Good Example​

{ "type": "object", "properties": { "id": { "type": "string" } } }