Struct RateLimitDecision

Assembly: redb.Identity.Core.dll

C1 — Outcome of a rate-limit check / increment.

public readonly record struct RateLimitDecision : IEquatable<RateLimitDecision>

Implements

Properties

Allowed

true if the call may proceed; false if it should be rejected with HTTP 429.

public bool Allowed { get; init; }

Count

The bucket count AFTER the increment (or the current count when denied without incrementing).

public int Count { get; init; }

RetryAfter

When is false, hint to the client for the Retry-After header.

public TimeSpan RetryAfter { get; init; }

Constructors

RateLimitDecision(bool, int, TimeSpan)

C1 — Outcome of a rate-limit check / increment.