package com.saas.shared.exception;

import lombok.Getter;

@Getter
public enum ErrorCode {
    USER_NOT_FOUND("USER_001", "User not found"),
    USER_ALREADY_EXISTS("USER_002", "User already exists"),
    INVALID_CREDENTIALS("USER_003", "Invalid credentials"),
    
    TENANT_NOT_FOUND("TENANT_001", "Tenant not found"),
    TENANT_ALREADY_EXISTS("TENANT_002", "Tenant already exists"),
    INVALID_TENANT_NAME("TENANT_003", "Invalid tenant name"),
    
    INVALID_TOKEN("AUTH_001", "Invalid or expired token"),
    UNAUTHORIZED("AUTH_002", "Unauthorized access"),
    FORBIDDEN("AUTH_003", "Access forbidden"),
    
    VALIDATION_ERROR("VAL_001", "Validation failed"),
    INVALID_INPUT("VAL_002", "Invalid input"),
    
    INTERNAL_ERROR("SYS_001", "Internal server error"),
    DATABASE_ERROR("SYS_002", "Database operation failed");
    
    private final String code;
    private final String message;
    
    ErrorCode(String code, String message) {
        this.code = code;
        this.message = message;
    }
}
