Class ServiceCollectionExtensions
Dependency-injection registration.
Inherited Members
Namespace: Activout.Blue5
Assembly: Activout.Blue5.dll
Syntax
public static class ServiceCollectionExtensions
Remarks
These are C# 14 extension members on IServiceCollection. The API reference generator does not list extension blocks, so they are described here:
IHttpClientBuilder AddBlue5(this IServiceCollection services, Blue5Options options): registers Blue5Client with the given options.IHttpClientBuilder AddBlue5(this IServiceCollection services, Func<IServiceProvider, Blue5Options> optionsFactory): registers Blue5Client with options resolved from the container, for example bound from configuration.
Both register Blue5Client as a typed HttpClient client and return the
IHttpClientBuilder, so you can chain your own handlers, or AddBlue5Resilience() from the
Activout.Blue5.Resilience package.
builder.Services
.AddBlue5(builder.Configuration.GetSection("Blue5").Get<Blue5Options>()!)
.AddBlue5Resilience(); // optional
// then inject Blue5Client