#[non_exhaustive]pub enum LicenseAuthCode {
LicenseSuspended,
LicenseExpired,
LicenseNotAllowed,
}Expand description
A 401 from the licence-key auth gate, before any endpoint logic runs.
All three are configuration or lifecycle states, not transient
failures: retrying, backing off, or re-sending the same key changes
nothing. In particular LICENSE_NOT_ALLOWED means the licence’s policy
has authentication_strategy set to TOKEN (the column default) or
NONE, neither of which accepts a licence key as a credential at all —
the fix is provisioning the policy as LICENSE or MIXED, not client-side
retry logic. See crate::models::policy::AuthenticationStrategy.
Non-exhaustive for the same reason as LimitExceededCode.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
LicenseSuspended
LICENSE_SUSPENDED — the licence itself is suspended.
LicenseExpired
LICENSE_EXPIRED — the licence has expired and its policy’s
expiration strategy is REVOKE_ACCESS. Under MAINTAIN_ACCESS,
ALLOW_ACCESS or RESTRICT_ACCESS an expired licence still
authenticates and the expiry surfaces at validate instead.
LicenseNotAllowed
LICENSE_NOT_ALLOWED — the policy does not accept licence-key auth.