AutoSDK Documentation
Generate production-ready, AOT-compatible .NET SDKs from OpenAPI specifications.
AutoSDK automates the generation of .NET SDKs from OpenAPI and AsyncAPI specifications. It produces fully typed, trimming-compatible, NativeAOT-ready C# clients — ready to publish as NuGet packages.
Key Features
- OpenAPI 3.0 & 3.1 support with full schema coverage
- Roslyn incremental source generators — compile-time code generation, no runtime reflection
- NativeAOT & trimming compatible via source-generated
JsonSerializerContext - Async methods with
CancellationTokensupport throughout - Nullable reference types fully enabled
- Strong naming for all generated assemblies
- CLI tool for on-demand generation and CI/CD pipelines
- 50+ production SDKs powering the tryAGI ecosystem
Quick Install
# Install the CLI tool globally
dotnet tool install --global autosdk.cli --prerelease
# Generate an SDK from an OpenAPI spec
autosdk generate https://api.example.com/openapi.json \
--namespace MyCompany.MyApi \
--clientClassName MyApiClient \
--output GeneratedOr use the NuGet source generator in your .csproj:
<PackageReference Include="AutoSDK" Version="*-*" PrivateAssets="all" />Next Steps
- Quickstart — Install the CLI and generate your first SDK in under 5 minutes
- Installation — Detailed setup for CLI and source generator workflows
- CLI Commands — Full reference for all
autosdkcommands - Real-World SDKs — See AutoSDK in production across 50+ projects
Edit on GitHub
Last updated on