Skip to content
Get startedWebsite
Guides
Quick start

C#

Reference the generated Rails C# project in your solution and configure the client from the environment.

The SDK README documents consuming the generated source from the repository:

Terminal window
git clone git@github.com:railsinfra/rails-csharp.git
dotnet add reference rails-csharp/src/Rails

Adjust paths if you vendor the repo inside your monorepo layout.

.NET Standard 2.0 or later (per README).

RailsClient with no arguments is configured from RAILS_API_KEY and RAILS_BASE_URL, as described in the README’s configuration table.

See the examples directory in rails-sdks/rails-csharp/ for runnable programs.

Use the API Reference tab for HTTP details and examples that track the generated surface.

Follow Path A on the Quick start overview and use rails-sdk-samples/csharp/ when you want a sample server with OpenAPI first.