Mugi.Gen 0.1.3

dotnet tool install --global Mugi.Gen --version 0.1.3
                    
This package contains a .NET tool you can call from the shell/command line.
dotnet new tool-manifest
                    
if you are setting up this repo
dotnet tool install --local Mugi.Gen --version 0.1.3
                    
This package contains a .NET tool you can call from the shell/command line.
#tool dotnet:?package=Mugi.Gen&version=0.1.3
                    
nuke :add-package Mugi.Gen --version 0.1.3
                    

Mugi.Gen

mugi-gen is the command-line companion tool for the Mugi web framework. It generates the same source code as the Mugi.Generators compiler package as ordinary .cs files, and converts between Mugi routes and OpenAPI documents.

Install

dotnet tool install --global Mugi.Gen --version 0.1.3

Generate source without the compiler generator

Some build setups cannot run compiler-integrated source generators. mugi-gen produces the same JSON and routing code as .cs files that you generate as a build step:

dotnet build MyApp.csproj
mugi-gen --project MyApp.csproj --output Generated
dotnet build MyApp.csproj

It does not emit the interceptor optimization, so only the direct-call speedup is absent; behavior is the same.

Export an OpenAPI document

mugi-gen openapi reads the routes in a compiled project and writes an OpenAPI 3.1 document. Routes that use Mugi.Schema include their parameter sources, types, defaults, and validation constraints:

mugi-gen openapi --project MyApp.csproj --output openapi.json

Generate a typed HTTP client

mugi-gen client generates a typed HttpClient wrapper from an OpenAPI document. Each supported operation becomes an async method with typed parameters and a JSON request or response body; non-success responses throw the generated ApiException:

mugi-gen client --input api/openapi.json --output Generated \
  --namespace MyApp.Api --class-name CatalogClient

Import an OpenAPI document as a build step

mugi-gen import runs the same OpenAPI-to-C# import as the compiler generator, writing DTO records, route constants, and input schemas to disk:

mugi-gen import --input api/openapi.json --output Generated --namespace MyApp.Api

Full documentation is at github.com/hckaye/Mugi.

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

Version Downloads Last Updated
0.1.3 114 8/28/2026
0.1.2 97 8/28/2026