Skip to content

Changelog

All notable changes to NSmithy are documented in this file.

The format is based on Keep a Changelog, and NSmithy aims to follow Semantic Versioning.

Preview. NSmithy is in preview — expect some API changes before 1.0. See Protocol Status for supported surfaces, maturity, and official conformance coverage.

Changes since the last release

GitHub release · Changes since 0.13.0

This release generates endpoint resolvers from Smithy endpoint rules and waiters from @waitable, moves server routing into the runtime, and lets integrations in separate packages add protocols, service generators, and shapes. NSmithy’s own AWS support is now such an integration, smithy-csharp-aws-codegen. When upgrading, implement StreamsRequestBody on custom server protocols, replace IServiceOperation and ServiceOperation.Create with IServerOperation and ServerOperation.Create, read SmithyEndpoint.Headers as lists and AuthSchemes as records in custom endpoint resolvers, expect an unmodeled SmithyClientException for error codes an operation does not model, and add smithy-csharp-aws-codegen to builds that run the Smithy CLI directly for AWS services.

  • Generated waiters for @waitable operations: a WaitUntil{Waiter}Async method per waiter on the client, its interface, and the fake client. Acceptor paths compile to C# at build time.
  • SmithyClientException.ErrorCode, the error code the protocol read from an error response that matched no modeled error, through the new IClientOperationProtocol.ReadErrorCode.
  • IServiceProtocol.GetServerRouting, through which a protocol reports how requests reach a service’s operations: a route per operation, or one route on which the protocol names the operation from the request.
  • MapSmithyService maps any service from its operation catalog and the protocols to serve it over.
  • CSharpIntegration.serviceGenerator, which lets an integration in a separate package generate the service surface for a protocol it supplies.
  • CSharpIntegration.protocols(), which lets an integration add a request/response protocol: a service carrying the protocol’s trait gets a client and server that use its runtime type, as for a built-in protocol.
  • The defaultProtocol code generation setting selects the generated client’s default protocol for a service with several.
  • Generated endpoint resolvers for services with @endpointRuleSet or @endpointBdd. Clients use them by default, and each rule parameter a client supplies becomes a {Service}ClientConfig property, such as Region.
  • NSmithy.Aws implements the aws.partition, aws.parseArn, and aws.isVirtualHostableS3Bucket rule functions and the AWS::* built-ins.
  • AwsSigV4AuthScheme(credentialsProvider), which takes the signing name and region from the resolved endpoint.
  • CSharpIntegration hooks for endpoint rule functions, built-ins, and auth scheme properties.
  • Generated S3 clients omit the modeled /{Bucket} path segment, since S3’s endpoint rules place the bucket in the host or endpoint path.
  • SmithyEndpointParameters.Operation gives custom endpoint resolvers the operation’s schema.
  • Every generated client can be constructed from its configuration alone, for example with only an EndpointResolver.
  • ClientConfigDefaultsSection, a code section integrations can append to through Smithy’s interceptors hook to set a generated client configuration’s defaults.
  • The closure code generation setting generates the types of a shapeClosures metadata entry, with or without a service, and CSharpIntegration.additionalShapes lets an integration add shapes that a service’s operations do not reach, such as published events.
  • An Add{Service}Client overload whose configuration callback receives the IServiceProvider, to resolve dependencies such as endpoint resolvers.
  • BREAKING: An error response whose error code names none of the operation’s modeled errors is now an unmodeled SmithyClientException, instead of the modeled error its HTTP status matched.
  • BREAKING: AWS support moved out of smithy-csharp-codegen into the smithy-csharp-aws-codegen integration: the AWS JSON, AWS Query, EC2 Query, and restXml protocols, the AWS endpoint rule functions and built-ins, and the Glacier client customization. NSmithy.MSBuild adds it to every build. Builds that run the Smithy CLI directly add io.github.thomaslaich.nsmithy:smithy-csharp-aws-codegen to maven.dependencies for AWS services.
  • AwsQueryProtocol takes an error’s status code from its @awsQueryError trait at runtime. The status code in generated error schemas no longer comes from that trait.
  • Generated servers route at runtime. Map{Service} keeps its signature and maps the protocols’ routes, and the generated code holds an operation table instead of an endpoint per operation and protocol. Endpoints are plain request delegates, with no minimal-API parameter binding.
  • Mapped services use a default SmithyServerRuntime when the application registers none, so registering operation handlers individually no longer requires AddSmithyServer().
  • Generated servers have one operation table, the ServiceOperationCatalog of their {Service}Definition, which HTTP routing and MCP both use. MCP tool calls now resolve their handler from the call’s services, so scoped handlers work with MCP, and run through SmithyServerRuntime like HTTP requests.
  • BREAKING: IServerOperation replaces IServiceOperation, and ServerOperation.Create replaces ServiceOperation.Create: it takes a function that resolves the handler from a request’s services. IServiceDefinition.Operations replaces CreateOperationCatalog, and MapSmithyService takes the catalog.
  • An event-stream input or output with sibling members on a gRPC service is now a model validation error (GrpcEventStream) instead of a code generation failure.
  • BREAKING: IServerOperationProtocol has a required StreamsRequestBody member. Custom server protocols must say whether the request body streams.
  • BREAKING: SmithyEndpoint.Headers values are lists, and SmithyEndpoint.AuthSchemes holds SmithyEndpointAuthScheme records with scheme properties instead of scheme ids. SmithyEndpoint also carries the endpoint’s other Properties.
  • SigV4 double-encodes and normalizes the canonical path for services other than S3, as the specification requires. It previously signed every path the S3 way, which differs for paths with reserved characters, such as a Lambda function ARN.

GitHub release · Changes since 0.12.0

This release adds the rpcv2Json protocol and reshapes parts of the generated API. Lists and maps are now plain IReadOnlyList<T> and IReadOnlyDictionary<string, T>, schema classes move to a Schemas namespace, and colliding generated names get a suffix. Every service in the AWS model catalog now generates code that compiles. When upgrading, replace .Values on list and map wrappers with the collection itself, update references to schema classes, and add the protocol package your server uses (NSmithy.Protocols.RestJson or NSmithy.Protocols.Grpc) next to NSmithy.Server.AspNetCore.

  • BREAKING: the ASP.NET Core host is protocol-agnostic. NSmithy.Server.AspNetCore no longer depends on NSmithy.Codecs.Json, NSmithy.Protocols.RestJson, or NSmithy.Protocols.Grpc. Existing REST/JSON servers must add NSmithy.Protocols.RestJson; gRPC servers must add NSmithy.Protocols.Grpc, using the same NSmithy version as the host. Servers generating multiple protocols need each corresponding protocol package. NSmithy.Protocols.RpcV2Cbor remains required for CBOR servers. The server template and examples now reference their protocol packages explicitly, so servers no longer acquire unrelated protocols and codecs through the host.
  • BREAKING: lists and maps are generated as read-only collections. Named list and map shapes no longer generate wrapper records with a Values property; members are typed IReadOnlyList<T> and IReadOnlyDictionary<string, T> directly. restJson1 and rpcv2Cbor move back to Preview.
  • BREAKING: schema classes live in <Namespace>.Schemas. All generated schema classes take the Schema suffix and move to their own namespace, so they never clash with a model type. A model type named Schemas fails generation.
  • BREAKING: generated name collisions are resolved. Members, enum values, and types named like their type or an inherited member (Equals, ToString, …) take a Value suffix (EqualsValue). Union variant classes named Value, Tag, Unknown, Match, an inherited member, or their union take a Case suffix (ValueCase); the factory stays FromValue.
  • BREAKING: error discriminators are a codec option. The JSON and CBOR codecs write CodecFactoryOptions.Discriminator ahead of a top-level structure’s members. The public SerializeError helpers on RestProtocol and RpcV2CborProtocol are removed.
  • smithy.protocols#rpcv2Json client and server support in the new NSmithy.Protocols.RpcV2Json package, including event streams. It shares a new NSmithy.Protocols.RpcV2 base with NSmithy.Protocols.RpcV2Cbor.
  • JsonCodecFactory options honorTimestampFormatTrait and bigNumbersAsStrings.
  • Operation @examples render as <example> blocks in generated client XML docs.
  • RPC v2 servers reject requests that carry an X-Amz-Target or X-Amzn-Target header, as the specification requires.
  • Generated code compiles for bigInteger trait values outside the long range.
  • String literals escape U+2028, U+2029, U+0085, and other control characters.
  • The deprecated smithy.api#Primitive* prelude shapes are supported.
  • Error structure members with a @default fall back to the modeled default when omitted, instead of failing to compile or throwing ArgumentNullException.
  • Union examples with no variant no longer crash doc generation.

GitHub release · Changes since 0.11.0

This release moves the Smithy CLI out of NSmithy.MSBuild and makes one effective smithy-build.json the way NSmithy configures every build. NSmithy.MSBuild drops from about 157 MB to about 3 MB; the CLI now comes from the new NSmithy.SmithyCli package or from your own installation, and code generation checks its version. When upgrading, reference NSmithy.SmithyCli or install Smithy CLI 1.73.0 or later, move SmithyBaseNamespace, SmithyGenerateDependencyInjection, and SmithyGenerateFakes into smithy-build.json as csharp-codegen settings, and remove service and NSmithy’s plugin artifacts from the smithy-build.json of projects that set SmithyService. Templates now use the Smithy CLI on PATH unless you pass --smithy-cli-package.

  • BREAKING: the Smithy CLI ships as its own package. NSmithy.MSBuild no longer bundles the Smithy CLI and its Java runtime, which drops it from about 157 MB to about 3 MB. Add <PackageReference Include="NSmithy.SmithyCli" Version="1.73.0" /> to each project that generates code, or once in Directory.Build.props. The package is versioned by the Smithy CLI it contains, so NSmithy upgrades reuse the copy in the NuGet cache. Without it, NSmithy runs SmithyCliPath or smithy on PATH, so a CLI from pixi, Nix, or Homebrew works without downloading the package. See Smithy CLI.
  • BREAKING: one effective smithy-build.json. NSmithy now always merges the project’s own smithy-build.json (if any), the referenced contracts, and the plugin settings from properties into one build file under obj/. Properties say what a project builds (SmithyService, SmithyGenerateClient, SmithyGenerateServer, SmithyGenerateDocs, SmithyOpenApiProtocol, SmithyGrpc); every other plugin setting goes in smithy-build.json, and a setting given both ways fails the build (NSMITHYPLUGIN). SmithyBaseNamespace, SmithyGenerateDependencyInjection, and SmithyGenerateFakes are removed: set baseNamespace, generateDependencyInjection, and generateFakes on the csharp-codegen plugin instead. A project that sets SmithyService must no longer set service in its smithy-build.json, and NSmithy adds its plugin artifacts itself. Maven Central is listed when no repository is.
  • BREAKING: template contracts options renamed. The server template’s --contracts <project> is now --contracts-project <project>, matching the client’s new option, and the client template’s --contracts maven|nuget is now --contracts-package maven|nuget.
  • Smithy CLI version check. Code generation fails with NSMITHYCLIVERSION when NSmithy.SmithyCli differs from SmithyVersion or a Smithy CLI you provide is older than it, and with NSMITHYCLIMISSING when no CLI can be run. SmithyCliVersionCheck (exact, minimum, or none) overrides the default.
  • dotnet nsmithy smithy. Runs the Smithy CLI a project’s build uses, with the same Maven setup, e.g. dotnet nsmithy smithy -- validate.
  • --contracts-project client template option. References a contracts project in the same solution, so the client generates its types from it without a smithy-build.json, as the server template already could.
  • --smithy-cli-package template option. By default the templates use the Smithy CLI on PATH; with --smithy-cli-package they reference NSmithy.SmithyCli instead.
  • SmithyUseBundledMavenRepo. Set it to false to resolve NSmithy’s plugins and every other Maven dependency from Maven repositories, as the plain Smithy CLI does, instead of from the repository bundled in NSmithy.MSBuild. See Maven dependencies.
  • SmithyCliPath on a read-only path. NSmithy no longer runs chmod on a user-supplied Smithy CLI, which failed for read-only installs such as the Nix store.

GitHub release · Changes since 0.10.1

This release generates a schema class and a shape serializer for every shape, which makes serialization faster and removes the schema visitor and builder APIs. It also reports Smithy validation errors as MSBuild errors, describes integer shapes as OpenAPI integers, and fixes stream ownership and empty awsJson errors. Regenerate models with the matching codegen version when upgrading, and review the breaking changes below if you use low-level runtime APIs.

  • BREAKING: generated schema classes and shape serializers. Each structure, union, list, and map schema is now a generated class deriving from StructSchema, UnionSchema, ListSchema, or MapSchema, in its own Person.Schema.g.cs file beside Person.g.cs. Operation schemas live in GetPerson.Schema.g.cs. Generated code reads and writes each member with one direct call on an IShapeSerializer or IShapeDeserializer. Codecs, the validator, HTTP bindings, and AWS Query forms consume values through those interfaces. Regenerate models with the matching codegen version when upgrading runtime packages. (#227)
  • BREAKING: removed schema visitors and fluent builders. Removed ISchemaVisitor, PartialSchemaVisitor, IMemberVisitor, IUnionCaseVisitor, the typed member interfaces (IMemberSchema, ITypedTargetMemberSchema<TValue>, IBuilderMemberSchema), IStructValueSerializer, DocumentDeserializer, Schemas.Structure, and Schemas.Union. A hand-written schema derives from the schema base classes; see the hand-written schemas in NSmithy.Core for examples. Members and union cases are MemberSchema. A custom value consumer implements IShapeSerializer. ICodecFactory.FromMember takes the target schema and the member’s traits. (#227)
  • Typed defaults. Modeled @default values are generated into each builder and each serializer, so no codec reads defaults from traits at runtime. XML and protobuf reads now fill defaults for absent members, as JSON and CBOR reads already did. (#227)
  • Faster serialization and request handling. The generated code calls the serializer directly. Server round trips with request bodies are up to 29% faster with up to 36% less allocation, XML serialization is up to 25% faster, protobuf serialization up to 11% faster with up to 35% less allocation, CBOR serialization allocates up to 31% less, and JSON serialization is about 5% faster. JSON and protobuf deserialization and gRPC round trips perform as before. See the benchmark results in benchmarks/results/. (#227)
  • Less allocation reading client responses. With a declared Content-Length, HttpClientTransport reads a buffered response into one array of that size instead of copying it out of a growing stream. Large list responses allocate about 18% less. (#228)
  • Updated build dependencies. The MSBuild tasks are compiled against MSBuild 18.0.2, the version in the oldest supported .NET 10 SDK, which removes the unsupported target framework warning. Scalar is updated. (#231)
  • Smithy errors in the build output. When the Smithy CLI fails, each validation error is reported as an MSBuild error with its event id and file location, so it appears with the terminal logger and in IDE error lists. Other CLI failures report the end of the CLI output. (#230)

  • Request stream ownership. HttpClientTransport no longer disposes a request stream the caller passed in, so callers can rewind and resend it. The REST server disposes a stream returned by a handler once the response body is written. (#229)

  • Empty awsJson errors. An awsJson error response with an empty body is built from the error’s schema. It previously threw MissingMethodException for generated errors with members. (#229)

  • Integer types in generated OpenAPI. With SmithyOpenApiProtocol set, Byte, Short, Integer, and Long members are described as OpenAPI integer, with int32 and int64 formats for Integer and Long, instead of an untyped number. (#235)

  • Stale generated files. A shape the model no longer produces, such as a renamed shape, no longer leaves its old generated file behind to collide with the new one. A Smithy CLI run that succeeds without producing any of the previously generated files now fails the build with NSMITHYGEN. (#227)

All packages are prepared for publication at 0.11.0. Codegen JARs and NuGet packages must use the same release version.

GitHub release · Changes since 0.10.0

Maintenance release with updated runtime and tooling dependencies, refreshed templates, and clearer documentation and examples.

  • Updated runtime and build dependencies. Refresh CBOR, hashing, Scalar, and MSBuild dependencies. The dotnet-nsmithy tool now uses the stable System.CommandLine API.
  • Updated Alloy traits. The bundled Maven repository and project templates now use alloy-core 0.3.40.
  • Clearer guides and examples. Rework the getting-started and Concepts pages, and organize examples by protocol and unary or streaming interaction style.

All packages are prepared for publication at 0.10.1. Codegen JARs and NuGet packages must use the same release version.

GitHub release · Changes since 0.9.0

This release adds MCP tools and prompts backed by generated service handlers, completes the applicable official HTTP protocol conformance suites, and simplifies the generated C#. It also makes codec construction consistent and removes the untyped schema API. Applications using low-level runtime APIs should review the migration notes below.

  • MCP tools and prompts. The new NSmithy.Server.Mcp package exposes generated unary service operations as MCP tools, with typed handlers, strict JSON codecs, validation, modeled errors, and Smithy-derived annotations. Service and operation smithy.ai#prompts traits produce MCP prompts with modeled arguments. The restJson1 example includes an MCP stdio mode. (#165, #168, #169)
  • Service catalogs for custom integrations. Generated service definitions expose registered operation handlers and JSON Schema metadata for non-streaming inputs and outputs, allowing custom hosts to reuse the same handlers. (#166, #168)
  • Official HTTP protocol conformance gaps. restJson1, simpleRestJson, and rpcv2Cbor now pass every applicable official request and response case on their client and server surfaces; restJson1 also passes all applicable malformed-request cases. AWS JSON 1.1, AWS Query, EC2 Query, and restXml pass every applicable official client request and response case. See Protocol Status for coverage by protocol and surface. (#157, #158, #161, #162)
  • BREAKING: consistent codec factories. Replace the removed static codec entry points with JsonCodecFactory, XmlCodecFactory, CborCodecFactory, or ProtoCodecFactory. For example, construct a JSON codec with JsonCodecFactory.Default.FromSchema(schema). Custom factories implement ICodecFactory, or IProjectionCodecFactory when projection support is needed; construction options now use CodecFactoryOptions. (#159)
  • BREAKING: typed schema APIs. Removed the untyped/object schema tier, including GetObject/SetObject, object-based collection and enum/union accessors, and Schemas.GetMembers. Custom schema integrations should use typed schema visitors and member APIs, including PartialSchemaVisitor, IBuilderMemberSchema, and ITypedTargetMemberSchema<TValue>.TypedTarget. Structure projections now snapshot their selected members. Regenerate models with the matching codegen version when upgrading runtime packages. (#167)
  • BREAKING: explicit server runtime registration for manual hosting. Generated aggregate handler registration calls AddSmithyServer() automatically. Applications registering individual operation handlers must call it themselves. Direct callers of SmithyAspNetCoreHost.DispatchAsync must supply the SmithyServerRuntime as the first argument. Existing application runtime registrations are preserved. (#170)
  • Earlier errors for unsupported HTTP bindings. Unsupported binding kinds and non-integer @httpResponseCode members now fail during operation protocol construction, before the first request. (#167)
  • More readable generated C#. Model and framework references use short names and collected imports where unambiguous, with global:: qualification for name collisions. (#171)

All packages are prepared for publication at 0.10.0, including the new NSmithy.Server.Mcp package. Codegen JARs and NuGet packages must use the same release version.

GitHub release · Changes since 0.8.1

Adds generated fakes, AWS Query and EC2 Query clients, and broader AWS endpoint, credential, and authentication support.

  • Fake handlers and clients. Enable SmithyGenerateFakes (or generateFakes in codegen settings) to generate Fake{Service}Handler and Fake{Service}Client. They match inputs against modeled @examples, return canned responses or modeled errors, and fall back to deterministic placeholder values. Operation methods are virtual; fake client paginators yield a single page. Register fake handlers with Add{Service}Handler<T>(). (#147, #148, #150)
  • AWS Query and EC2 Query clients. The new NSmithy.Protocols.AwsQuery package supports both protocols and passes their applicable official client conformance cases. (#155)
  • AWS endpoints and credentials. NSmithy.Aws adds regional endpoint resolution across AWS partitions; environment, shared-profile, IAM Identity Center/SSO, and IMDSv2 credential providers; a default provider chain; credential caching; and SigV4 presigning. (#152, #155)
  • Modeled client behavior. Generated clients support operation host prefixes, per-operation auth overrides, endpoint-provided auth narrowing, modeled HTTP version preferences, and a default NSmithy user agent. Host-prefix injection and the user agent are configurable through SmithyClientConfig. (#152)
  • BREAKING: auth scheme interfaces. Replace ISmithyAuthScheme.CreateInterceptor with IdentityResolver and Signer, implementing ISmithyIdentityResolver and ISmithySigner for custom schemes. SmithyAuthSchemeContext, ISmithyAuthHandler, HeaderAuthInterceptor, and QueryParameterAuthInterceptor are removed. SmithyClientRuntime’s auth map now contains ISmithyAuthScheme values. (#152)
  • BREAKING: protocol HTTP preferences. Replace IProtocol.RequiresHttp2 with HttpVersionPreference, which supports HTTP/1.1, HTTP/2, and HTTP/3 plus downgrade policy. Custom protocols using the default continue to use HTTP/1.1. (#152)
  • Lower codec and client overhead. Reduced processing time and allocations for JSON, CBOR, Proto, modeled errors, and client calls without changing the wire format. (#143, #146, #149, #151, #154)

GitHub release · Changes since 0.8.0

  • Generated template projects build correctly. Fixed the obsolete server mapper call, missing NSmithy.MSBuild reference in servers created without --contracts, and obsolete gRPC client constructor arguments. (#142)

GitHub release · Changes since 0.7.0

Adds server-side model validation and structured errors for malformed requests.

  • Modeled constraint validation. Generated servers enforce @length, @range, @pattern, @required, and enum values before invoking handlers. Clients receive typed NSmithy.Core.Validation.ValidationException errors containing the member path and failed constraint. (#131)
  • Structured request errors. Malformed values produce 400 SerializationException responses, unsupported request media types produce 415 UnsupportedMediaTypeException, and unacceptable response media types produce 406 NotAcceptableException. Generated restJson1 servers pass all 655 applicable official malformed-request cases. (#135)
  • Legacy @enum validation. Servers validate values on string shapes carrying the deprecated trait. @internal values are accepted but omitted from rejection messages. (#131, #135)
  • Model documentation in IntelliSense. Smithy documentation traits become XML comments on generated models, clients, servers, and errors. (#129)
  • BREAKING: schema codec APIs. Runtime schema member access now uses typed visitors. Top-level default materialization is aligned across JSON, CBOR, XML, and Proto codecs. (#134)
  • BREAKING: server mapper methods. Use the single service mapper with protocol flags instead of protocol-specific methods: app.MapWeatherServiceRpcV2Cbor() becomes app.MapWeatherService(). Mapping conflicting routes is rejected. (#128)
  • BREAKING: REST codec factory argument. RestServiceProtocol now takes Func<WireReadMode, IRestBodyCodecFactory> as its first constructor argument, allowing strict server reads and permissive client reads. (#135)
  • BREAKING: map key schemas. Schemas.Map accepts a key schema, defaulting to Schemas.String. Replace IMapSchema.TypedKeyMember with IMapSchema.KeyMember. Enum-keyed maps generate string keys, while server validation enforces the modeled enum values. (#134, #135)
  • BREAKING: legacy enum generation. String shapes with deprecated @enum traits no longer generate enum types; they map to string and retain server-side value validation. (#131)
  • Faster JSON codecs. Reduced serialization and deserialization time and allocations without changing wire output. (#136)
  • Smithy 1.73.0. Updated the bundled CLI and Smithy dependencies. NSmithy.MSBuild grows by roughly 20 MB with the bundled JRE 25; custom Java codegen integrations must account for the plugin’s bytecode target moving from Java 17 to 21. (#139)
  • Clearer model errors. Unsupported schemas, gRPC stream wrappers, and other unsupported constructs produce diagnostics naming the shape and reason. (#124–#127)
  • Defaults on explicit null. Codecs now apply a member’s modeled @default when its input value is explicitly null. (#136)

GitHub release · Changes since 0.6.0

Adds event streaming across rpcv2Cbor and restJson1.

  • NSmithy.EventStream. A standalone library for vnd.amazon.eventstream message framing. (#94)
  • rpcv2Cbor event streaming. Supports event-stream operations and their initial request and response messages. (#106, #108)
  • restJson1 streaming. Adds streaming support to the protocol. (#110)
  • BREAKING: protocol interfaces. Client and server interfaces are separate; custom protocol implementations own their streaming framing. (#93)
  • BREAKING: streaming operation signatures. Streaming operations now use Task<TOutput>(TInput), with the event stream carried inside the input/output structure alongside any initial fields. This applies to gRPC as well. (#93, #108)
  • Bundled codegen dependencies. NSmithy.MSBuild includes the codegen dependencies, so clean-machine builds need no locally built codegen JAR. (#105)
  • rpcv2Cbor example. Corrected the runnable example. (#111)
  • Prerelease templates. Scaffolded projects reference the actual published prerelease version. (#109)

GitHub release · Changes since 0.5.0

  • DebugInterceptor. Logs typed input/output, each transport attempt’s request and response, and body bytes as hex. Enable it in the rpcv2Cbor example client with --debug. (#100)
  • rpcv2Cbor templates. dotnet new accepts --protocol rpcv2Cbor. (#97)
  • Expanded rpcv2Cbor example. Demonstrates resources, pagination, modeled errors, and retries with the Weather service. (#98, #99)
  • Client template setup. Corrected project setup and stale template references in the quick-start flow. (#97)

GitHub release · Changes since 0.4.0

Adds client observability, pagination, operation timeouts, and more capable retries.

  • OpenTelemetry instrumentation. Client operations emit spans and metrics; the restJson1 example demonstrates an observability setup. (#86, #90)
  • Generated paginators. @paginated operations expose IAsyncEnumerable paginator methods on generated clients. (#89)
  • Per-operation endpoint and auth selection. Resolution runs for each operation rather than once per client. (#87)
  • Operation timeout. OperationTimeout covers the entire execution, including retries. (#85)
  • BREAKING: HTTP body APIs. SmithyHttpBody.Empty, Bytes, and Streaming replace separate buffered/streaming request and response fields. Streaming bodies preserve their content length. (#79)
  • BREAKING: retry and interceptor APIs. Custom retry strategies now return an ISmithyRetrySession from Begin(). IClientInterceptor.OnAfterExecution receives an additional Exception? argument. Direct runtime callers use InvokeAsync(binding, input, ct). (#82)
  • Standard retries. SmithyStandardRetryStrategy supports jittered exponential backoff, a shared retry quota, and Retry-After. Transport failures and modeled @retryable errors participate in retry classification; interceptors observe failures as well as successes. (#82)
  • Release packages build on clean machines. NSmithy.MSBuild now references the published codegen version instead of an unpublished -SNAPSHOT JAR. (#95)
  • Streaming response cleanup. The client runtime disposes abandoned streaming response bodies. (#84)
  • Client configuration isolation. Client construction takes a copy of caller-supplied configuration. (#83)

GitHub release · Changes since 0.3.0

Adds AWS JSON, SigV4 authentication, and bidirectional gRPC streaming.

  • AWS JSON clients. The new NSmithy.Protocols.AwsJson package supports AWS JSON services. (#60)
  • AWS authentication. The new NSmithy.Aws package supports SigV4 signing and generated auth configuration. An AWS LocalStack example demonstrates usage. (#61)
  • Bidirectional gRPC streams. Generated clients and ASP.NET Core servers support bidirectional event streams, with a Grpc.Net interoperability example. (#62)
  • Client interception and retries. Generated clients use SmithyClientRuntime with interceptor hooks, auth resolution, and configurable retries. (#65–#67)
  • Client middleware removed. Migrate custom middleware to client interceptors. (#69)

GitHub release · Changes since 0.2.0

Adds native gRPC and clients that can use any protocol declared by a service.

  • Native gRPC. New packages NSmithy.Codecs.Proto and NSmithy.Protocols.Grpc support HTTP/2 gRPC calls, modeled errors, and ASP.NET Core server mapping without protoc, Grpc.Tools, or Grpc.Net.Client. Map{Service}Grpc can coexist with REST mappings for services declaring both protocols. (#58)
  • Protocol selection on clients. A single {Service}Client accepts an endpoint, HttpClient, or invoker, with an optional protocol defaulting to the service’s primary declared protocol. (#58)
  • Opt-in dependency injection. Set SmithyGenerateDependencyInjection=true (or generateDependencyInjection in codegen settings) to generate Add{Service}Client(...). It configures HTTP/2 when required and only adds the Microsoft.Extensions.Http dependency when enabled. (#58)
  • Protocol construction. Instantiate protocols, such as new GrpcProtocol(), instead of using .Instance. IProtocol now exposes RequiresHttp2. (#58)
  • SmithyClientOptions removed. Pass middleware and idempotencyTokenProvider directly to the generated client constructor. (#58)
  • Low-level HTTP APIs. Request compression and content-MD5 handling move to NSmithy.Http/SmithyRequestModifiers. Custom operation protocols use RequiresErrorDiscriminator and SupportsHttpStatusErrorFallback for error dispatch. (#58)

GitHub release · Changes since 0.1.0

  • rpcv2Cbor servers. Generated ASP.NET Core servers handle CBOR requests, responses, and modeled errors at POST /service/{Service}/operation/{Operation}. (#54)
  • REST server responses. Generated servers honor @http(code), output header, payload, and document bindings, plus modeled-error headers and status codes. (#55)
  • Server-only generation by default. NSmithy.Server.AspNetCore sets SmithyGenerateServer=true and SmithyGenerateClient=false. Server projects no longer require NSmithy.Client or a manual setting to disable client generation. (#53)

GitHub release

First tagged release, superseding 0.1.0-preview.*. Generate typed C# clients, ASP.NET Core server stubs, and shared models from Smithy during dotnet build, without a separate codegen step or a Java installation.

  • Project templates. NSmithy.Templates provides nsmithy-server, nsmithy-client, and nsmithy-contracts templates.
  • REST clients and servers. Supports alloy#simpleRestJson and aws.protocols#restJson1.
  • Additional client protocols. Supports aws.protocols#restXml and smithy.protocols#rpcv2Cbor clients.
  • Experimental gRPC. Supports .proto emission, clients, and ASP.NET Core servers for alloy.proto#grpc.
  • Runtime and build integration: NSmithy.Core, NSmithy.Http, NSmithy.MSBuild.
  • Client and server: NSmithy.Client, NSmithy.Server.AspNetCore, NSmithy.Server.AspNetCore.Docs.
  • Codecs: NSmithy.Codecs.Json, NSmithy.Codecs.Cbor, NSmithy.Codecs.Xml.
  • Protocols: NSmithy.Protocols.Rest, NSmithy.Protocols.RestJson, NSmithy.Protocols.RestXml, NSmithy.Protocols.RpcV2Cbor.
  • Tooling: NSmithy.Templates, dotnet-nsmithy.