from typing import Any


class AccountBaseException(Exception):
    def __init__(
        self, code: str, message_out: Any, status_code: int, header: dict = None
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class AuthenticationError(AccountBaseException):
    def __init__(
        self,
        code: str = "AUE",
        message_out: Any = "Authentication-Error",
        status_code: int = 403,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class DatabaseError(AccountBaseException):
    def __init__(
        self,
        code: str = "DBE",
        message_out: Any = "Database Error",
        status_code: int = 500,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class ValidationError(AccountBaseException):
    def __init__(
        self,
        code: str = "VAE",
        message_out: Any = "Validation Error",
        status_code: int = 403,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class ServiceIntegrationsError(AccountBaseException):
    def __init__(
        self,
        code: str = "SIE",
        message_out: Any = "Service Integrations Error",
        status_code: int = 500,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class ResourceNotFoundError(AccountBaseException):
    def __init__(
        self,
        code: str = "RNFE",
        message_out: Any = "Resource Not Found Error",
        status_code: int = 500,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class ConcurrencyLockError(AccountBaseException):
    def __init__(
        self,
        code: str = "CLE",
        message_out: Any = "Concurrency Lock Error",
        status_code: int = 404,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class RateLimitError(AccountBaseException):
    def __init__(
        self,
        code: str = "RLE",
        message_out: Any = "Rate Limit Error",
        status_code: int = 403,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class ConfigurationsError(AccountBaseException):
    def __init__(
        self,
        code: str = "COE",
        message_out: Any = "Configurations Error",
        status_code: int = 403,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class SecurityViolationsError(AccountBaseException):
    def __init__(
        self,
        code: str = "SVE",
        message_out: Any = "Security Violations Error",
        status_code: int = 403,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code


class PolicyViolationError(AccountBaseException):
    def __init__(
        self,
        code: str = "PVE",
        message_out: Any = "Policy Violation Error",
        status_code: int = 403,
        header: dict = None,
    ):
        self.code = code
        self.header = header
        self.message_out = message_out
        self.status_code = status_code
