Class Error.Forbidden
- Namespace
- Trellis
- Assembly
- Trellis.Core.dll
HTTP 403 — authorization policy refused the request.
public sealed record Error.Forbidden : Error, IEquatable<Error>, IEquatable<Error.Forbidden>
- Inheritance
-
Error.Forbidden
- Implements
- Inherited Members
- Extension Methods
Constructors
Forbidden(string, ResourceRef?)
HTTP 403 — authorization policy refused the request.
public Forbidden(string PolicyId, ResourceRef? Resource = null)
Parameters
PolicyIdstringIdentifier of the policy that denied access.
ResourceResourceRef?Optional resource the policy was evaluated against.
Properties
Code
Gets the per-instance machine-readable code. Defaults to Kind; cases
whose payload carries a per-instance ReasonCode override this.
public override string Code { get; }
Property Value
Kind
Gets the stable, IANA-aligned identifier for this case (e.g. "not-found",
"unprocessable-content"). Suitable for telemetry, problem-details
type URI synthesis, and wire serialization.
public override string Kind { get; }
Property Value
PolicyId
Identifier of the policy that denied access.
public string PolicyId { get; init; }
Property Value
Resource
Optional resource the policy was evaluated against.
public ResourceRef? Resource { get; init; }