mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-07-05 03:31:54 +00:00
ccb269caa2
Co-authored-by: Alan Buscaglia <gentlemanprogramming@gmail.com> Co-authored-by: Pepe Fagoaga <pepe@prowler.com>
37 lines
883 B
TypeScript
37 lines
883 B
TypeScript
/**
|
|
* Enum for standardized error types across the application
|
|
*/
|
|
export enum SentryErrorType {
|
|
// API Errors
|
|
API_ERROR = "api_error",
|
|
SERVER_ERROR = "server_error",
|
|
CLIENT_ERROR = "client_error",
|
|
|
|
// Request Processing
|
|
REQUEST_PROCESSING = "request_processing",
|
|
STREAM_PROCESSING = "stream_processing",
|
|
|
|
// Application Errors
|
|
APPLICATION_ERROR = "application_error",
|
|
UNEXPECTED_ERROR = "unexpected_error",
|
|
NON_ERROR_OBJECT = "non_error_object",
|
|
|
|
// Authentication
|
|
AUTH_ERROR = "auth_error",
|
|
PERMISSION_ERROR = "permission_error",
|
|
|
|
// Server Actions
|
|
SERVER_ACTION_ERROR = "server_action_error",
|
|
}
|
|
|
|
/**
|
|
* Enum for error sources
|
|
*/
|
|
export enum SentryErrorSource {
|
|
ERROR_BOUNDARY = "error_boundary",
|
|
API_ROUTE = "api_route",
|
|
SERVER_ACTION = "server_action",
|
|
HANDLE_API_ERROR = "handleApiError",
|
|
HANDLE_API_RESPONSE = "handleApiResponse",
|
|
}
|