import type { JsonSchema, PropsSpec } from '../types/data-contract.js'; /** Frozen wire values for the handshake's `propsSchemaProfile` field. */ export type PropsSchemaProfile = 'grammar-safe' | 'full'; /** * The grammar-safe core — the closed keyword set a `'grammar-safe'` * schema may use (P3 pin 4; purely syntactic). `aliases` is enumerated * now (it is the P4 in-contract alias keyword) so arming P4 needs no * grammar change; until P4 ships it simply never appears in emitted * bytes. */ export declare const GRAMMAR_SAFE_KEYWORDS: ReadonlySet; /** * The restricted `format` vocabulary admitted to the grammar-safe core * (P3 pin 5). A consumer grammar MAY enforce any subset its engine * supports; unenforced formats remain server-validated — AUTHORITY is * one-directional, so an under-enforcing grammar is safe. A schema * carrying a format outside this list classifies `'full'`. */ export declare const GRAMMAR_SAFE_FORMATS: ReadonlySet; /** * RFC 8785 (JCS) serialization of a props schema — the canonical * bytes `propsSchemaHash` is computed over, and the byte form the * emitted `propsSchema` value is constructed to match. Consumers * verify by re-canonicalizing the received value with any JCS * library and hashing — raw received bytes are equivalent whenever * the transport preserves key order (JS enumeration reorders * integer-like property names, so re-canonicalization is the * guaranteed path). */ export declare function canonicalPropsSchemaBytes(schema: JsonSchema): string; /** * Build the enforced props schema for a {@link PropsSpec} — the exact * schema `ggui_render` compiles and validates against for the paired * handshake, in emission form (closed shape materialized, `nullable` * rewritten, metadata keywords stripped, canonical key order). * * An empty / degenerate spec yields the empty closed wrapper * `{additionalProperties:false, properties:{}, required:[], type:'object'}` * — never omitted for a non-declined handshake: under it, any * non-empty props are invalid, which makes the props-without-propsSpec * rejection schema-derivable and the accept-path drop documented * leniency (one-directional AUTHORITY). * * `injectClosedShape` is idempotent, so compiling this pre-injected * tree (`compileForValidation`) enforces byte-identical semantics to * `validatePropsData` over the source spec — the AUTHORITY property * the conformance kit's drift fixture pins. */ export declare function buildEnforcedPropsSchema(spec: PropsSpec): JsonSchema; /** * Classify an (emission-form) props schema against the grammar-safe * core — P3 pins 4+5. Purely syntactic; the conformance kit's profile * fixture asserts the wire flag agrees with this reference checker. */ export declare function classifyPropsSchemaProfile(schema: JsonSchema): PropsSchemaProfile; //# sourceMappingURL=enforced-props-schema.d.ts.map