Table of Contents
API reference

Method TryDeserializeData

Namespace
DisCatSharp.Hosting.AspNetCore.Ingress.WebhookEvents
Assembly
DisCatSharp.Hosting.AspNetCore.dll

TryDeserializeData<T>(out T?)

Attempts to deserialize the nested event data into a typed model.

public bool TryDeserializeData<T>(out T? data) where T : ObservableApiObject

Parameters

data T

The deserialized payload model when successful.

Returns

bool

true when the payload was deserialized successfully.

Type Parameters

T

The payload model type.

Remarks

This method swallows JSON deserialization failures so callers can fall back to UnknownWebhookEventReceived or other raw-payload handling paths.