Skip to main content

New C# SDK Now Available in Beta

· 2 min read

The new C# SDK is now available in beta. You can generate it today using the APIMatic CLI. Try it out and share your feedback with us.

What's New?

  • Redesigned Core Architecture: Single-orchestrator pipeline with dedicated, fully decoupled components for auth, resilience, serialization, and error handling
  • Predictable Endpoint Structure: Every endpoint maps directly to its HTTP call, making the full request lifecycle visible and predictable across all methods
  • Type-Safe Models: Response models enforce optionality and presence contracts at compile time, eliminating runtime surprises
  • Per-Endpoint Typed Errors: Each endpoint exposes its own error type, fully navigable in the IDE without consulting documentation
  • Broad Runtime Compatibility: Targets netstandard2.0 with full C# 14 language features and native IHttpClientFactory and DI support

Generating the SDK

The apimatic sdk generate command now supports two new flags for selecting the code generator version and stability level:

FlagOptionsDescription
--codegen-versionv3 (default), v4Version of the code generator to use.
--stabilitystable (default), betaStability level of the generated SDK.

Pass --codegen-version=v4 and --stability=beta to generate the new SDK:

apimatic sdk generate --language=csharp --codegen-version=v4 --stability=beta
note

v4 beta is currently available for C# only. While the --codegen-version and --stability flags are accepted for all languages, using --codegen-version=v4 with any other language will result in a generation error.