.NET server SDK and OpenFeature server provider for ConfigDirector, remote config and feature flags with typed values, JSON Schema validation, and safe renames of live flags. Start free, no card required.
Each package carries its own README and changelog:
ConfigDirector.ServerSdk-- changelogConfigDirector.ServerSdk.AspNetCore-- changelogConfigDirector.ServerSdk.Testing-- changelogConfigDirector.ServerSdk.AspNetCore.Testing-- changelogConfigDirector.OpenFeature.ServerProvider-- changelog
dotnet add package ConfigDirector.ServerSdkIn an ASP.NET Core application, add ConfigDirector.ServerSdk.AspNetCore instead; it registers the client, binds its settings from configuration, connects before the server starts listening, and disposes it on shutdown.
To read configs through the OpenFeature API instead, add ConfigDirector.OpenFeature.ServerProvider, which brings the server SDK and the OpenFeature .NET SDK with it.
using ConfigDirector;
// The server SDK key is a secret. Do not commit it to your source code.
await using var client = new ConfigDirectorClient("YOUR-SERVER-SDK-KEY");
await client.InitializeAsync();
var newCheckout = client.GetValue("new-checkout", false);Full details are in the official documentation.
ConfigDirector.ServerSdk.Testing creates a test client: the real client connected to an in-memory
server that your test seeds and changes, with no network and no telemetry. In an ASP.NET Core
application, ConfigDirector.ServerSdk.AspNetCore.Testing registers it with the application under
test.
using ConfigDirector.Testing;
await using var testClient = ConfigDirectorTesting.CreateTestClient(
new Dictionary<string, object> { ["new-checkout"] = true });
await testClient.Client.InitializeAsync();
var newCheckout = testClient.Client.GetValue("new-checkout", false);using ConfigDirector.OpenFeature;
using OpenFeature;
await Api.Instance.SetProviderAsync(new ConfigDirectorProvider("YOUR-SERVER-SDK-KEY"));
var client = Api.Instance.GetClient();
var newCheckout = await client.GetBooleanValueAsync("new-checkout", false);Full details are in the official documentation for the OpenFeature .NET provider.
Refer to the official documentation for the .NET SDK and the OpenFeature .NET provider.
There is also a quickstart guide for ConfigDirector and any of our SDKs.
samples/ holds small, runnable applications built on this SDK. They are the same app
written each way -- a single /configs endpoint -- so they can be read side by side. The web
samples each come with a test project showing how to test an application against the testing
packages, or against OpenFeature's in-memory provider.
ConfigDirector.Samples.MinimalApi:
dotnet run --project samples/ConfigDirector.Samples.MinimalApiConfigDirector.Samples.Mvc, the same app wired up with
the ConfigDirector.ServerSdk.AspNetCore package rather than by hand:
dotnet run --project samples/ConfigDirector.Samples.MvcConfigDirector.Samples.NativeAot, a console
application published to native code:
dotnet run --project samples/ConfigDirector.Samples.NativeAotConfigDirector.Samples.OpenFeature, the same app
reading every value through an OpenFeature client, with the
ConfigDirector.OpenFeature.ServerProvider package registered through OpenFeature.Hosting:
dotnet run --project samples/ConfigDirector.Samples.OpenFeatureConfigDirector.Samples.OpenFeature.NativeAot,
the OpenFeature provider in a console application published to native code:
dotnet run --project samples/ConfigDirector.Samples.OpenFeature.NativeAot