Skip to content

0.3.2

Latest

Choose a tag to compare

@github-actions github-actions released this 28 Nov 19:36

Release Notes

Breaking Changes

  • Go now generates a typed struct instead of any for inferred internal unions
    with optional tags or multiple legal labels. When regenerating, construct the
    union by setting one member pointer, or use
    --generator-config go-http.tagged_union_strategy=dynamic to keep any.
  • Regenerating some inferred tagged unions changes their case constructors or
    payload types. Rust enum variants and Java/Kotlin cases can expose a separate
    discriminator and store a projected payload as JSON; Python uses named case
    dataclasses. Update consumers that construct or match these cases, and
    recompile or retest them against the regenerated SDK.
  • Custom generator extensions that construct IR with struct literals must
    initialize IrSpec::wire_schemas, IrUnion::authored_wire, and
    IrTaggedUnion::inferred_wire. Exhaustive matches on WriteError must handle
    invalid, duplicate, and conflicting generated output paths.

Added

  • Add tagged_union_strategy for inferred tag handling in the Rust, Go, Java,
    Kotlin, Python, and TypeScript generators. firstMatch selects the first
    concrete match in schema order before considering opaque fallbacks; strict
    rejects multiple concrete matches; raw bypasses member selection.
    TypeScript runtime conversion uses camelCase; preserve mode remains
    converter-free.

Changed

  • Emit Rust operation signatures and response dispatch, and Go, Java, Kotlin,
    and Rust multipart inputs, through structured code generation without
    changing their generated interfaces.
  • Share the golden case registry with native client checks and stage complete
    golden updates before replacing snapshots. Run independent CI checks in
    parallel and generate TypeScript test SDKs in one Rust process.

Fixed

  • Select inferred union members using the wire shapes declared in OpenAPI 3.0,
    3.1, and 3.2, then invoke only the selected payload codec. Preserve omitted
    tags, allowed explicit null, original tag labels, and required fields in
    nested or composed payloads.
  • Preserve original envelope shapes when inferring unions with optional content
    or mixed wrappers. Recognize fixed tags in anonymous single-field unions.
  • Honor optional discriminators and alternate labels in inferred adjacent Rust
    unions without changing the distinct fixed-label representation. Match
    ordinary Rust union branches by their declared string constants.
  • Preserve scalar and array payloads and exact string tags in generated Java
    and Kotlin union codecs.
  • Escape generated Rust request paths and path parameter names as string
    literals. Emit numeric Rust response ranges for accepted case-insensitive
    success keys such as 2xx.
  • Reject invalid or colliding generated output paths before writing that batch
    of files.

Install openapi-nexus 0.3.2

Install prebuilt binaries via shell script

curl --proto '=https' --tlsv1.2 -LsSf https://github.com/rust-codegen-group/openapi-nexus/releases/download/0.3.2/openapi-nexus-installer.sh | sh

Install prebuilt binaries via powershell script

powershell -ExecutionPolicy Bypass -c "irm https://github.com/rust-codegen-group/openapi-nexus/releases/download/0.3.2/openapi-nexus-installer.ps1 | iex"

Download openapi-nexus 0.3.2

File Platform Checksum
openapi-nexus-aarch64-apple-darwin.tar.xz Apple Silicon macOS checksum
openapi-nexus-x86_64-apple-darwin.tar.xz Intel macOS checksum
openapi-nexus-x86_64-pc-windows-msvc.zip x64 Windows checksum
openapi-nexus-aarch64-unknown-linux-gnu.tar.xz ARM64 Linux checksum
openapi-nexus-x86_64-unknown-linux-gnu.tar.xz x64 Linux checksum
openapi-nexus-aarch64-unknown-linux-musl.tar.xz ARM64 MUSL Linux checksum
openapi-nexus-x86_64-unknown-linux-musl.tar.xz x64 MUSL Linux checksum