Interface IWebhookRejectionStore
- Namespace
- FlowOrchestrator.Core.Storage
- Assembly
- FlowOrchestrator.Core.dll
Persistence contract for the webhook receive log + DLQ. Stores both rejected (IsAccepted false) and accepted entries so the dashboard can render a unified recent-deliveries table with precise reason chips.
public interface IWebhookRejectionStore
Methods
CountsByReasonAsync(TimeSpan, CancellationToken)
Returns counts by reason for the last window.
Keys are reason strings, values are occurrence counts.
ValueTask<IReadOnlyDictionary<string, long>> CountsByReasonAsync(TimeSpan window, CancellationToken ct = default)
Parameters
windowTimeSpanLook-back window (typically 24 h).
ctCancellationTokenCancellation token.
Returns
QueryAsync(WebhookRejectionQuery, CancellationToken)
Filtered + paged query that also returns the matching total count. Supersedes QueryRecentAsync(Guid?, string?, bool, int, int, CancellationToken) for new callers — that method is kept for backwards compatibility with the v1.25.0 dashboard endpoint that lacked search + pagination.
ValueTask<WebhookRejectionPage> QueryAsync(WebhookRejectionQuery query, CancellationToken ct = default)
Parameters
queryWebhookRejectionQueryFilter + paging parameters.
ctCancellationTokenCancellation token.
Returns
QueryRecentAsync(Guid?, string?, bool, int, int, CancellationToken)
Returns the most recent entries, optionally filtered by flow + reason.
ValueTask<IReadOnlyList<WebhookRejectionRecord>> QueryRecentAsync(Guid? flowId, string? reason, bool includeAccepted, int skip, int take, CancellationToken ct = default)
Parameters
flowIdGuid?Restrict to a single flow when supplied.
reasonstringRestrict to a single reason chip when supplied (case-insensitive).
includeAcceptedboolfalse to return rejections only.
skipintPagination skip.
takeintPage size; capped at 500.
ctCancellationTokenCancellation token.
Returns
WriteAsync(WebhookRejectionRecord, CancellationToken)
Appends one row to the store.
ValueTask WriteAsync(WebhookRejectionRecord record, CancellationToken ct = default)
Parameters
recordWebhookRejectionRecordRow to persist; Id ignored on input.
ctCancellationTokenCancellation token.