Table of Contents
API reference

Method AddDiscordIncomingWebhookHandler

Namespace
DisCatSharp.Hosting.AspNetCore
Assembly
DisCatSharp.Hosting.AspNetCore.dll

AddDiscordIncomingWebhookHandler<THandler>(IServiceCollection)

Registers a generic incoming webhook ingress handler.

public static IServiceCollection AddDiscordIncomingWebhookHandler<THandler>(this IServiceCollection services) where THandler : class, IDiscordIncomingWebhookHandler

Parameters

services IServiceCollection

The service collection to update.

Returns

IServiceCollection

The service collection for chaining purposes.

Type Parameters

THandler

The handler implementation to add.

Remarks

Handlers run in registration order until one returns a non-null response.

Exceptions

ArgumentNullException

services is null.