Skip to content

Latest commit

 

History

History
20 lines (14 loc) · 821 Bytes

File metadata and controls

20 lines (14 loc) · 821 Bytes

RustPlusApi.Fcm.Extensions.DependencyInjection

Microsoft.Extensions.DependencyInjection registration extensions for RustPlusApi.Fcm.

// one configured listener (singleton, container-disposed)
services.AddRustPlusFcm(credentials);

// runtime credentials (e.g. from FcmRegistration): caller-owned listeners via the factory
services.AddRustPlusFcmFactory();
await using var fcm = provider.GetRequiredService<IRustPlusFcmFactory>().Create(credentials);

Logging auto-wires from the host's ILoggerFactory; tuning via IOptions<RustPlusFcmSocketOptions>. FCM listeners are single-connection — create a new one to reconnect.

Documentation