Specification compatibility
Tungsten loads OpenAPI 3.0.x and 3.1.x as JSON or YAML. Compatibility is a feature-level contract: accepting a document does not establish that every JSON Schema validation keyword or service behavior is implemented. Diagnostics identify rejected input and approximations. The checks named below run offline against focused interoperability fragments. Public source distributions do not include the private test corpus.
| Feature | Status | Diagnostic / exact check | Constraint |
|---|---|---|---|
OpenAPI 3.0 nullable and exclusive numeric bounds | Supported | normalization checks, normalized_30_equals_its_31_form | 3.0 schemas normalize to the internal 3.1 representation; requiredness remains separate from nullability. |
| External complete OpenAPI documents with a different 3.x dialect | Supported | compatibility checks, external_openapi_30_document_keeps_its_dialect_from_a_31_entry, external_openapi_31_document_is_not_normalized_by_a_30_entry, nested_external_documents_propagate_their_own_dialects_to_fragments | A referenced complete document keeps its declared dialect. A dialectless fragment inherits the referring document's dialect; fragments shared with 3.0 are normalized as documented by the normalization checks. Referenced documents do not become new input namespaces. |
| 3.1 nullable type arrays and non-null scalar type unions | Supported | compatibility checks, nullable_type_arrays_and_allof_record_composition_keep_presence; nullable checks | null becomes presence/nullability metadata; named types keep their non-null shape. Scalar unions retain their variants. |
oneOf / anyOf with string discriminators | Supported | union checks; sanitized error-envelope fixture | Explicit mappings or distinct required constant string tags select variants. Invalid mappings produce TG0306. |
| Ambiguous untagged schema unions | Limited | TG0301; union checks | Ordered variants approximate ambiguous unions. Acceptance by a generated validator does not guarantee JSON Schema oneOf exclusivity. |
allOf record composition | Limited | TG0302 when flattening is unsafe; composition checks, nullable_type_arrays_and_allof_record_composition_keep_presence | Compatible record fields and constraints flatten. Other intersections remain explicit; no claim of arbitrary JSON Schema intersection solving. |
Local and relative-file JSON Pointer $ref | Supported | reference checks, mixed-dialect Petstore fixture | References stay under an input directory. Dangling refs produce TG0201; traversal produces TG0204. |
Schemas inside Path Item $ref siblings | Limited | compatibility checks, path_item_ref_siblings_have_their_schemas_normalized_and_checked, path_item_siblings_follow_external_files_without_following_example_payload_refs | The frontend resolves and normalizes sibling schemas. Operation generation follows the referenced Path Item; sibling operations/parameters are not merged into the generated surface. OpenAPI leaves overlapping Path Item fields undefined. |
Request media: JSON / +json, form, multipart, text, bytes | Supported in the IR; target behavior is limited by runtime capabilities | media-type corpus assertions, multipart fixture | Wire encoding is selected per media type. This does not establish arbitrary per-property OpenAPI Encoding Object support or service interoperability for every emitted language. |
patternProperties, conditional/dependent schemas, unevaluated*, tuple prefixItems, $dynamicRef | Limited | TG0303; pattern-properties fixture | These keywords are reported and ignored. Remaining schema shape still builds; generated validation can be broader than the source. |
Anchor $ref fragments, remote $ref fetching | Rejected | TG0201 (anchor), TG0202 (remote); reference checks | Vendor remote descriptions locally and use JSON Pointer file references. $id URI scope resolution and dynamic anchors are not implemented. |
| Swagger 2.0 / OpenAPI 3.2 | Rejected | TG0103; version checks, unsupported_external_document_versions_are_diagnosed_at_the_document_and_reference | Convert unsupported inputs to supported OpenAPI versions first. |
The Petstore interoperability fragment adapts the versioned OAI Petstore example from the Apache-2.0 licensed specification repository. The fixture deliberately splits a 3.1 operation document and a 3.0 model document and adds nullable tag metadata; it does not claim the upstream example uses mixed dialects. This catches the loader defect where a 3.1 entry previously lost 3.0 model nullability.
The Claude error-envelope fragment is an authored reduction of two discriminator variants from the pilot's pinned specification, associated with official SDK release 0.123.0 of the official TypeScript SDK. It uses a synthetic endpoint. The check covers that error shape, not the entire Claude API; no full vendor specification or credentials are redistributed.
Validation includes exact diagnostic and IR shape assertions, deterministic
serialization, IR JSON Schema validation and generated TypeScript packages
checked with tsc --noEmit --strict. These checks establish the tested
fragment's compiler and generated type behavior. Live API authentication, server
behavior, pagination and endpoint coverage need separate integration checks.