Summary
The managed-reporting schemas in #6953 leave two byte/value integrity rules in prose or x-adcp-validation, even though both are expressible in Draft-07 JSON Schema:
- reporting-control-total.value_type set to integer still accepts a decimal value such as "1.5".
- A physical_checksums entry accepts either 64 or 128 hex characters regardless of whether algorithm is sha256 or sha512.
The TypeScript implementation for adcontextprotocol/adcp-client#2744 had to add handwritten predicates for both. Without those overlays, generated Zod/AJV validators accept evidence that reconciliation must later reject.
Proposed schema changes
- Add a conditional to reporting-control-total.json:
- value_type integer => integer-only canonical string
- value_type decimal => retain the canonical base-10 pattern.
- Make each physical_checksums item a discriminated oneOf, or add if/then branches:
- sha256 => exactly 64 hex characters
- sha512 => exactly 128 hex characters.
- Add protocol contract tests proving invalid algorithm/length and integer/decimal combinations fail.
- Include generated-validator smoke tests so both SDK generators preserve the conditionals.
Acceptance signal
The protocol JSON Schema, generated TypeScript Zod schema, and generated Python validator all reject:
- value_type integer with value "1.5"
- algorithm sha256 with 128 hex characters
- algorithm sha512 with 64 hex characters
Valid canonical integer/decimal values and correctly sized digests remain accepted.
Related: #6953, adcontextprotocol/adcp-client#2744.
Summary
The managed-reporting schemas in #6953 leave two byte/value integrity rules in prose or x-adcp-validation, even though both are expressible in Draft-07 JSON Schema:
The TypeScript implementation for adcontextprotocol/adcp-client#2744 had to add handwritten predicates for both. Without those overlays, generated Zod/AJV validators accept evidence that reconciliation must later reject.
Proposed schema changes
Acceptance signal
The protocol JSON Schema, generated TypeScript Zod schema, and generated Python validator all reject:
Valid canonical integer/decimal values and correctly sized digests remain accepted.
Related: #6953, adcontextprotocol/adcp-client#2744.