Class: SessionRevokedError
Defined in: src/auth/errors.ts:93
Session revoked error.
Remarks
Thrown when attempting to use a revoked session. HTTP mapping: 401 Unauthorized
Extends
Constructors
new SessionRevokedError()
new SessionRevokedError(
sessionId):SessionRevokedError
Defined in: src/auth/errors.ts:106
Creates a new SessionRevokedError.
Parameters
sessionId
string
Revoked session ID
Returns
Overrides
Properties
cause?
readonlyoptionalcause:Error
Defined in: src/types/errors.ts:71
Original error that caused this error (if any).
Remarks
Error chaining allows tracking the full error context through multiple layers of the application. Useful for debugging complex error scenarios.
Example
try {
await fetchData();
} catch (err) {
throw new ValidationError('Failed to validate data', 'field', 'required', err as Error);
}
Inherited from
code
readonlycode:"SESSION_REVOKED"='SESSION_REVOKED'
Defined in: src/auth/errors.ts:94
Machine-readable error code.
Remarks
Error codes are unique identifiers for error types, enabling programmatic error handling (switch statements, error maps), error tracking in monitoring systems, and client-side error translation (i18n).
Overrides
sessionId
readonlysessionId:string
Defined in: src/auth/errors.ts:99
Session ID that was revoked.