interface BaseEntity {
    id: string;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}
interface BaseEntityWithAccount extends BaseEntity {
    accountId: string;
}
interface BaseEntityWithUser extends BaseEntity {
    userId: string;
}
interface BaseEntityWithAccountAndUser extends BaseEntityWithAccount {
    userId: string;
}

interface Address {
    country: string;
    department: string;
    locality: string;
    street: string;
    number: string;
    mapPosition: MapPosition;
}
interface MapPosition {
    lat: number;
    lng: number;
}

declare const SUPPORTED_COUNTRIES: readonly ["UY", "AR"];
type SupportedCountryCode = (typeof SUPPORTED_COUNTRIES)[number];
declare function isSupportedCountry(code: string): code is SupportedCountryCode;
interface CountryDefaultBranchAddress {
    country: string;
    department: string;
    locality: string;
    street: string;
    number: string;
    mapPosition: {
        lat: number;
        lng: number;
    };
}
interface CountryDefaultTax {
    name: string;
    rate: number;
    rateType: string;
}
interface CountryDefaultConfig {
    /** Display name for the country (e.g. for select options). */
    name: string;
    timezone: string;
    currency: string;
    phoneCountryCode: string;
    locale: string;
    defaultBranchAddress: CountryDefaultBranchAddress;
    defaultTaxes: CountryDefaultTax[];
}
/** Default configurations for enabled countries. Only countries with defaults are listed. */
declare const COUNTRY_DEFAULTS: Record<string, CountryDefaultConfig>;
declare function getCountryDefaults(code: string): CountryDefaultConfig | null;

/**
 * Entidad Media
 * Se utiliza para almacenar y gestionar archivos y recursos multimedia.
 */
interface Media {
    id: string;
    accountId: string;
    filename: string;
    url: string;
    thumbnailUrl: string;
    mimeType: string;
    extension: string;
    size: number;
    type: MediaType;
    altText: string;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum MediaType {
    IMAGE = "IMAGE",
    VIDEO = "VIDEO",
    FAVICON = "FAVICON",
    DOCUMENT = "DOCUMENT",
    AUDIO = "AUDIO",
    ARCHIVE = "ARCHIVE",
    OTHER = "OTHER"
}

interface Phone {
    countryCode: string;
    national: string;
    international: string;
    type: 'mobile' | 'landline';
    validated: boolean;
}

declare enum Currency {
    ARS = "ARS",// Peso argentino
    BRL = "BRL",// Real brasileño
    CLP = "CLP",// Peso chileno
    COP = "COP",// Peso colombiano
    EUR = "EUR",// Euro
    MXN = "MXN",// Peso mexicano
    PEN = "PEN",// Sol peruano
    PYG = "PYG",// Guaraní paraguayo
    USD = "USD",// Dólar estadounidense
    UYU = "UYU"
}
declare function getCurrencySymbol(currencyCode: Currency): string;
/**
 * Analiza un patrón de formato de precio y extrae la configuración necesaria
 * @param pattern - Patrón de ejemplo como '1,000.12', '1.000,12', '1000.12', '1000'
 * @returns Configuración de formato de precio para Intl.NumberFormat
 *
 * Patrones soportados:
 * - '1.000,12' → es-ES (punto para miles, coma para decimales)
 * - '1,000.12' → en-US (coma para miles, punto para decimales)
 * - '1000,12'  → sin separador de miles, coma para decimales
 * - '1000.12'  → sin separador de miles, punto para decimales
 * - '1.000'    → punto para miles, sin decimales
 * - '1,000'    → coma para miles, sin decimales
 * - '1000'     → sin separadores, sin decimales
 */
declare function parsePriceFormatPattern(pattern: string): {
    locale: string;
    useGrouping: boolean;
    minimumFractionDigits: number;
    maximumFractionDigits: number;
};

type Webhook = {
    body: Record<string, unknown>;
    headers: Record<string, string>;
};

declare enum DayOfWeek {
    MONDAY = "MONDAY",
    TUESDAY = "TUESDAY",
    WEDNESDAY = "WEDNESDAY",
    THURSDAY = "THURSDAY",
    FRIDAY = "FRIDAY",
    SATURDAY = "SATURDAY",
    SUNDAY = "SUNDAY"
}

/**
 * Entidad AccountDomain
 * Representa un dominio personalizado asociado a una cuenta.
 * Permite dominios completos y subdominios, con control de estado y verificación.
 */
interface AccountDomain {
    id: string;
    accountId: string;
    domain: string; /** Dominio completo (ej: example.com) */
    subdomain?: string; /** Subdominio opcional (ej: shop, blog) */
    isPrimary: boolean; /** Indica si este es el dominio principal de la cuenta */
    preferWww: boolean; /** Preferencia de dominio: true = www.example.com, false = example.com */
    status: AccountDomainStatus; /** Estado del dominio: PENDING, ACTIVE, INACTIVE */
    verifiedAt?: Date; /** Fecha de verificación del dominio */
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum AccountDomainStatus {
    PENDING = "PENDING",
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}

/** Balance for a calendar month (1-31). */
interface SellerPeriodBalance {
    year: number;
    month: number;
    balance: number;
}
interface Seller {
    id: string;
    name: string;
    commissionPercent: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
    /** Balance by calendar month (1-31). Present when requested from API. */
    balanceByPeriod?: SellerPeriodBalance[];
}
interface ChargeSellerAllocation {
    id: string;
    accountServiceBillingChargeId: string;
    sellerId: string;
    amount: number;
    commissionPercentUsed: number;
    createdAt: Date;
}

/** Billing data for Retaila service invoices (tenant / legal entity). Stored as JSON on `account.billingProfile`. */
interface AccountBillingProfile {
    legalName?: string | null;
    /** Tax id (e.g. RUT in UY/PY). */
    taxId?: string | null;
    address?: string | null;
    billingContactEmail?: string | null;
    /**
     * Whether VAT (IVA) is charged/invoiced on top of service amounts.
     * Service plan amounts in the system are always stored net (sin IVA); this flag is for documents and UI.
     */
    invoiceVat?: boolean | null;
    /** VAT rate when `invoiceVat` is true (e.g. 22 for Uruguay). Percent 0–100. */
    vatPercent?: number | null;
}
interface Account {
    id: string;
    name: string;
    slug: string;
    logoId?: string;
    currency: string;
    email: string;
    timezone: string;
    status: AccountStatus;
    country: string;
    themeConfig?: ThemeConfig;
    privateKey?: string;
    demo: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
    sellerId?: string;
    seller?: Seller;
    accountDomains?: AccountDomain[];
    billingProfile?: AccountBillingProfile | null;
    /** Set when the backoffice onboarding wizard was finished successfully. */
    onboardingWizardCompletedAt?: Date | null;
    /** Set when the merchant chose to skip the onboarding wizard. */
    onboardingWizardSkippedAt?: Date | null;
    /** True until the wizard is completed or skipped (backoffice gate). */
    needsOnboardingWizard?: boolean;
}
declare enum AccountStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE",
    PENDING = "PENDING",
    SUSPENDED = "SUSPENDED"
}
interface ThemeConfig {
    backgroundColor: string;
    textColor: string;
    primaryColor: string;
    secondaryColor: string;
}

/** Job lifecycle persisted in `account_onboarding_job`. */
type AccountOnboardingJobStatus = 'queued' | 'running' | 'completed' | 'failed';
/** Row shape for `account_onboarding_job` (phases/result/requestBody are JSON in MySQL). */
interface AccountOnboardingJob {
    id: string;
    accountId: string;
    status: AccountOnboardingJobStatus;
    phases: unknown[];
    percent: number;
    result: unknown | null;
    error?: string | null;
    requestBody: Record<string, unknown>;
    createdAt: Date;
    updatedAt: Date;
}

declare enum AiCreditType {
    IMAGE = "IMAGE",
    TEXT = "TEXT"
}
declare enum AiCreditSource {
    FREE = "FREE",
    PAID = "PAID"
}
declare enum AiCreditTransactionReason {
    GENERATION = "generation",
    MONTHLY_REFILL = "monthly_refill",
    PURCHASE = "purchase",
    MANUAL_ADJUSTMENT = "manual_adjustment"
}
interface AccountAiCredits {
    accountId: string;
    monthlyFreeImageCredits: number;
    paidImageCredits: number;
    monthlyFreeTextCredits: number;
    paidTextCredits: number;
    lastMonthlyRefill: Date | null;
    updatedAt: Date;
}
interface AccountAiCreditTransaction {
    id: string;
    accountId: string;
    type: AiCreditType;
    amount: number;
    source: AiCreditSource;
    reason: AiCreditTransactionReason;
    createdAt: Date;
}
interface AiCreditsBalance {
    imageCredits: number;
    textCredits: number;
}

interface AccountIntegrationConfigDTO {
    accountId: string;
    integrationId: string;
    settingsProduction?: Record<string, any>;
    settingsDevelopment?: Record<string, any>;
    environment: AccountIntegrationEnvironment;
    status?: AccountIntegrationStatus;
}

/**
 * Entidad Integration
 * Define las integraciones de terceros disponibles en la plataforma (ej. pasarelas de pago, transportistas).
 * Almacena información sobre el proveedor, categoría y esquema de parámetros requeridos.
 */
declare enum IntegrationCategory {
    PAYMENT_GATEWAY = "PAYMENT_GATEWAY",
    SHIPPING_CARRIER = "SHIPPING_CARRIER",
    MARKETPLACE = "MARKETPLACE",
    EMAIL_MARKETING = "EMAIL_MARKETING",
    ANALYTICS = "ANALYTICS",
    ACCOUNTING = "ACCOUNTING",
    SOCIAL_MEDIA = "SOCIAL_MEDIA",
    OTHER = "OTHER"
}
declare enum IntegrationStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE",
    BETA = "BETA",
    DEPRECATED = "DEPRECATED"
}
interface Integration {
    id: string;
    category: IntegrationCategory;
    providerKey: string;
    name: string;
    slug: string;
    description?: string;
    setupInstructions?: string;
    logoUrl?: string;
    requiredParamsSchema?: any;
    supportedPaymentMethods?: string[];
    paymentCanRecapture?: boolean;
    paymentCanRefund?: boolean;
    status: IntegrationStatus;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    order: number;
    /** ISO country codes where this integration is available. Null or empty = all countries. */
    countries?: string[] | null;
    accountIntegration: AccountIntegration | null;
}

declare function getIntegrationCategoryName(category: IntegrationCategory): string;

/**
 * Entidad AccountIntegration
 * Contiene información de la integración y sus credenciales.
 */
declare enum AccountIntegrationStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE",
    BETA = "BETA",
    DEPRECATED = "DEPRECATED"
}
declare enum AccountIntegrationConnectionStatus {
    CONNECTED = "CONNECTED",
    DISCONNECTED = "DISCONNECTED",
    ERROR = "ERROR",
    WARNING = "WARNING"
}
declare enum AccountIntegrationEnvironment {
    PRODUCTION = "PRODUCTION",
    DEVELOPMENT = "DEVELOPMENT"
}
interface AccountIntegration {
    id: string;
    accountId: string;
    integrationId: string;
    settingsProduction: Object | null;
    settingsDevelopment: Object | null;
    environment: AccountIntegrationEnvironment;
    productionStatus: AccountIntegrationConnectionStatus;
    developmentStatus: AccountIntegrationConnectionStatus;
    status: AccountIntegrationStatus;
    demo: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    integration: Integration;
    settings: Record<string, any>;
}

/**
 * GeoZone types
 * Define zonas geográficas reutilizables que pueden ser referenciadas por otras entidades.
 */

interface GeoZone {
    id: string;
    name: string;
    description?: string;
    accountId?: string | null;
    area: MapPosition[];
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum GeoZoneStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}

/**
 * Delivery types to distinguish between shipping and pickup options
 */
declare enum DeliveryType {
    SHIPPING = "SHIPPING",
    PICKUP = "PICKUP"
}
/**
 * Entidad AccountDeliveryOption
 * Representa una opción de envío de una cuenta.
 */
interface AccountDeliveryOption {
    id: string;
    accountId: string;
    accountBranchId: string;
    name: string;
    accountIntegrationId?: string;
    isScheduled: boolean;
    priceLogic: AccountDeliveryOptionPriceLogic;
    status: AccountDeliveryOptionStatus;
    deliveryType: DeliveryType;
    demo: boolean;
    hideAccountBranchAddress: boolean;
    /** When true, estimated delivery times are calculated by AI and shown to customers at checkout */
    showEstimatedDeliveryTime: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    data?: Record<string, unknown>;
    deliveryZones: AccountDeliveryOptionZone[];
    integration?: AccountIntegration | null;
    price?: number | null;
    accountBranch?: AccountBranch | null;
    /** Computed by api-public when listing delivery options; ISO date strings */
    estimatedDelivery?: {
        start: string;
        end: string;
    };
}
declare enum AccountDeliveryOptionPriceLogic {
    FIXED = "FIXED",
    BY_ZONE = "BY_ZONE",
    PROVIDER = "PROVIDER",
    /** @deprecated Use BY_ZONE instead */
    CALCULATED = "CALCULATED"
}
declare enum AccountDeliveryOptionStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}
interface AccountDeliveryOptionCalculatedCost {
    basePrice: number;
    distanceKm: number;
    finalPrice: number;
    priceLogic: AccountDeliveryOptionPriceLogic;
    currency: string;
}
interface AccountDeliveryOptionZone {
    id: string;
    accountId: string;
    accountDeliveryOptionId: string;
    geoZoneId: string;
    price?: number | null;
    status: AccountDeliveryOptionZoneStatus;
    demo: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    geoZone?: GeoZone;
}
declare enum AccountDeliveryOptionZoneStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}
interface DeliveryZoneInput {
    geoZoneId?: string;
    geoZone?: GeoZoneInput;
    price?: number | null;
}
interface GeoZoneInput {
    name: string;
    area: MapPosition[];
    description?: string;
}
interface CreateAccountDeliveryOptionDTO {
    accountId: string;
    accountBranchId: string;
    name: string;
    accountIntegrationId?: string | null;
    isScheduled?: boolean;
    priceLogic?: AccountDeliveryOptionPriceLogic;
    price?: number;
    status?: AccountDeliveryOptionStatus;
    deliveryType: DeliveryType;
    deliveryZones?: DeliveryZoneInput[];
    data?: Record<string, unknown>;
    showEstimatedDeliveryTime?: boolean;
}
interface UpdateAccountDeliveryOptionDTO {
    accountBranchId: string;
    name?: string;
    accountIntegrationId?: string | null;
    isScheduled?: boolean;
    priceLogic?: AccountDeliveryOptionPriceLogic;
    status?: AccountDeliveryOptionStatus;
    deliveryType?: DeliveryType;
    deliveryZones?: DeliveryZoneInput[];
    data?: Record<string, unknown>;
    showEstimatedDeliveryTime?: boolean;
}
/** Rule types for estimated delivery calculation */
declare enum DeliveryOptionRuleType {
    PROCESSING_DAYS = "PROCESSING_DAYS",
    SAME_DAY_CUTOFF = "SAME_DAY_CUTOFF",
    DELIVERY_DAYS = "DELIVERY_DAYS",
    PICKUP_READY_HOURS = "PICKUP_READY_HOURS",
    FIXED_OFFSET_DAYS = "FIXED_OFFSET_DAYS",
    /** ISO weekday numbers (1=Mon..7=Sun) that count as operating days */
    BUSINESS_DAYS = "BUSINESS_DAYS",
    /** Delivery time-of-day window inferred by AI from historical orders */
    DELIVERY_HOURS = "DELIVERY_HOURS",
    /** Extra days added to the pessimistic end when volume is high */
    BUFFER_SAFETY_MARGIN = "BUFFER_SAFETY_MARGIN"
}
interface AccountDeliveryOptionRule {
    id: string;
    accountId: string;
    accountDeliveryOptionId: string;
    ruleType: DeliveryOptionRuleType;
    params?: Record<string, unknown>;
    priority: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
interface CreateDeliveryOptionRuleDTO {
    ruleType: DeliveryOptionRuleType;
    params?: Record<string, unknown>;
    priority?: number;
}
interface UpdateDeliveryOptionRuleDTO {
    ruleType?: DeliveryOptionRuleType;
    params?: Record<string, unknown>;
    priority?: number;
}
/** Params per rule type for estimation */
interface ProcessingDaysParams {
    minDays: number;
    maxDays?: number;
}
interface SameDayCutoffParams {
    cutoffTime: string;
}
interface DeliveryDaysParams {
    minDays: number;
    maxDays: number;
}
interface PickupReadyHoursParams {
    hours?: number;
    minHours?: number;
    maxHours?: number;
}
interface FixedOffsetDaysParams {
    minDays: number;
    maxDays?: number;
}
interface BusinessDaysParams {
    /** ISO weekday numbers: 1=Monday … 7=Sunday */
    days: number[];
}
interface DeliveryHoursParams {
    /** Start of delivery window "HH:mm" */
    start: string;
    /** End of delivery window "HH:mm" */
    end: string;
}
interface BufferSafetyMarginParams {
    /** Extra days added to the pessimistic (end) delivery date */
    extraDays: number;
}
/** Unified delivery config shape used by the backoffice form */
interface UnifiedDeliveryConfig {
    businessDays: number[];
    cutoffEnabled: boolean;
    cutoffTime: string;
    processingMinDays: number;
    processingMaxDays: number;
    deliveryMinDays: number;
    deliveryMaxDays: number;
    pickupHours: number;
}

/**
 * Entidad AccountBranch
 * Representa una sucursal de una cuenta.
 */
interface AccountBranch {
    id: string;
    accountId: string;
    name: string;
    address?: Address;
    addressInstructions?: string;
    isAddressPublic?: boolean;
    phone?: Phone | null;
    email?: string | null;
    demo: boolean;
    status: AccountBranchStatus;
    isOpen?: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    schedule: AccountBranchSchedule[];
    deliveryOptions: AccountDeliveryOption[];
}
declare enum AccountBranchStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}
interface AccountBranchSchedule {
    id: string;
    accountBranchId: string;
    day: AccountBranchScheduleDay;
    start: number;
    end: number;
    status: AccountBranchScheduleStatus;
    demo: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum AccountBranchScheduleStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}
declare enum AccountBranchScheduleDay {
    MONDAY = "MONDAY",
    TUESDAY = "TUESDAY",
    WEDNESDAY = "WEDNESDAY",
    THURSDAY = "THURSDAY",
    FRIDAY = "FRIDAY",
    SATURDAY = "SATURDAY",
    SUNDAY = "SUNDAY"
}

declare enum AccountEmailDomainStatus {
    PENDING = "PENDING",
    DNS_PENDING = "DNS_PENDING",
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}
interface AccountEmailDomain {
    id: string;
    accountId: string;
    accountDomainId: string;
    domain: string;
    status: AccountEmailDomainStatus;
    activatedAt: Date | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt: Date | null;
}

interface AccountMailbox {
    id: string;
    accountId: string;
    accountEmailDomainId: string;
    localPart: string;
    email: string;
    displayName: string;
    mayReceive: boolean;
    maySend: boolean;
    /** Storage limit in megabytes. Default 500. */
    storageLimitMb: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt: Date | null;
}

interface StatusInfo {
    text: string;
    class: string;
    actionText?: string;
}

interface AccountExchangeRate extends BaseEntityWithAccount {
    id: string;
    accountId: string;
    baseCurrency: Currency;
    targetCurrency: Currency;
    configurationType: AccountExchangeRateType;
    manualRate?: number;
    adjustmentPercentage?: number;
    roundingConfig?: RoundingConfig;
    isActive: boolean;
    lastManualUpdate?: Date;
    metadata?: AccountExchangeRateMetadata;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}
declare enum AccountExchangeRateType {
    AUTOMATIC = "AUTOMATIC",
    AUTOMATIC_WITH_ADJUSTMENT = "AUTOMATIC_WITH_ADJUSTMENT",
    MANUAL = "MANUAL"
}
interface RoundingConfig {
    method: RoundingMethod;
    decimalPlaces: number;
    roundingRule?: RoundingRule;
}
declare enum RoundingMethod {
    ROUND = "ROUND",
    CEIL = "CEIL",
    FLOOR = "FLOOR",
    BANKERS = "BANKERS"
}
declare enum RoundingRule {
    ROUND_TO_5_CENTS = "ROUND_TO_5_CENTS",
    ROUND_TO_10_CENTS = "ROUND_TO_10_CENTS",
    NONE = "NONE"
}
interface AccountExchangeRateMetadata {
    description?: string;
    notes?: string;
    [key: string]: any;
}
interface CreateAccountExchangeRateDto {
    baseCurrency: Currency;
    targetCurrency: Currency;
    configurationType: AccountExchangeRateType;
    manualRate?: number;
    adjustmentPercentage?: number;
    roundingConfig?: RoundingConfig;
    metadata?: AccountExchangeRateMetadata;
}
interface UpdateAccountExchangeRateDto {
    configurationType?: AccountExchangeRateType;
    manualRate?: number;
    adjustmentPercentage?: number;
    roundingConfig?: RoundingConfig;
    isActive?: boolean;
    metadata?: AccountExchangeRateMetadata;
}
interface AccountExchangeRateQueryDto {
    baseCurrency?: Currency;
    targetCurrency?: Currency;
    configurationType?: AccountExchangeRateType;
    isActive?: boolean;
    limit?: number;
    offset?: number;
}
interface AccountExchangeRateResponse {
    item: AccountExchangeRate;
}
interface UpdateAccountExchangeRateAllDto {
    globalConfig?: any;
    rates: Array<{
        id?: string;
        targetCurrency: Currency;
        configurationType: AccountExchangeRateType;
        manualRate?: number;
        adjustmentPercentage?: number;
        roundingConfig?: RoundingConfig;
    }>;
}
interface AccountExchangeRateListResponse {
    storeCurrency: Currency;
    paymentCurrencies: Currency[];
    rates: AccountExchangeRateWithEffectiveRate[];
}
interface AccountExchangeRateWithEffectiveRate extends AccountExchangeRate {
    effectiveRate: number;
    baseGlobalRate: number;
    source: string;
    effectiveDate: Date;
}
interface AccountCurrencyConfig {
    accountId: string;
    primaryCurrency: Currency;
    exchangeRates: AccountExchangeRate[];
    effectiveRates: EffectiveExchangeRate[];
}
interface EffectiveExchangeRate {
    baseCurrency: Currency;
    targetCurrency: Currency;
    effectiveRate: number;
    baseGlobalRate: number;
    configurationType: AccountExchangeRateType;
    effectiveDate: Date;
    source: string;
}

declare enum AccountPaymentMethodStatus {
    ACTIVE = "ACTIVE",// Active
    INACTIVE = "INACTIVE"
}
interface AccountPaymentMethod {
    id: string;
    accountId: string;
    accountIntegrationId?: string;
    name: string;
    description?: string;
    customerInstructions?: string;
    order: number;
    availableForWeb?: boolean;
    status: AccountPaymentMethodStatus;
    demo: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
    accountIntegration?: AccountIntegration;
    account?: Account;
    statusInfo?: StatusInfo;
    typeName?: string;
    /** Currency the gateway will charge in (API-resolved; do not infer from provider in UI). */
    chargeCurrency?: Currency;
    /** Present when account store currency differs from chargeCurrency and a rate exists. */
    exchangeRate?: EffectiveExchangeRate;
}

declare function getAccountPaymentMethodStatusInfo(status: AccountPaymentMethodStatus): StatusInfo;

/**
 * Currency in which the payment gateway will settle the charge for checkout.
 * Centralizes provider-specific rules; consumers (e.g. storefront) should use
 * {@link AccountPaymentMethod.chargeCurrency} from the API instead of branching on providerKey.
 */
declare function resolveChargeCurrency(params: {
    providerKey?: string | null;
    settingsCurrency?: string | null;
    /** Store / account currency; used when settings omit currency or for MANUAL_PAYMENT. */
    accountCurrency?: string | null;
}): Currency | undefined;

/**
 * Entidad Customer
 * Cliente de la tienda
*/

interface Customer {
    id: string;
    accountId: string;
    firstName?: string;
    lastName?: string;
    email: string;
    phone?: Phone;
    newsletter: boolean;
    status: CustomerStatus;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum CustomerStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE",
    BLACKLISTED = "BLACKLISTED",// e.g., for fraudulent activity
    PENDING = "PENDING"
}

/**
 * Register or update a customer
 */
interface CustomerUpsertDto {
    id?: string;
    accountId: string;
    firstName?: string;
    lastName?: string;
    email: string;
    newsletter?: boolean;
    phone?: Phone;
}

/**
 * Size guides: reusable measurement tables and optional "how to measure" content.
 * Used by admin API, storefront payload (ProductSizeGuidePayload), and DB alignment.
 */
declare enum SizeGuideStatus {
    DRAFT = "DRAFT",
    PUBLIC = "PUBLIC"
}
declare enum SizeGuideUnitBase {
    CM = "cm",
    IN = "in"
}
declare enum SizeGuideUnitDisplayPolicy {
    AUTO = "AUTO",
    FIXED = "FIXED"
}
interface SizeGuideTableColumn {
    id: string;
    label: string;
    order: number;
}
interface SizeGuideTableRow {
    id: string;
    /** Maps column id -> cell display value (may include ranges or *literal* markers). */
    cells: Record<string, string>;
    order: number;
}
interface SizeGuideTableJson {
    columns: SizeGuideTableColumn[];
    rows: SizeGuideTableRow[];
}
interface SizeGuide {
    id: string;
    accountId: string;
    name: string;
    status: SizeGuideStatus;
    tableJson: SizeGuideTableJson;
    infoTitle?: string | null;
    infoBody?: string | null;
    infoMediaId?: string | null;
    unitBase: SizeGuideUnitBase;
    unitDisplayPolicy?: SizeGuideUnitDisplayPolicy | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
/** Row in size_guide_category (category-scoped rule with priority). */
interface SizeGuideCategoryRule {
    sizeGuideId: string;
    categoryId: string;
    priority: number;
}
/** Assignment returned by admin API (without repeating sizeGuideId on each row). */
interface SizeGuideCategoryAssignment {
    categoryId: string;
    priority: number;
}
type SizeGuideDetail = SizeGuide & {
    categoryRules?: SizeGuideCategoryAssignment[];
};
interface CreateSizeGuideDTO {
    accountId: string;
    name: string;
    status?: SizeGuideStatus;
    tableJson: SizeGuideTableJson;
    infoTitle?: string | null;
    infoBody?: string | null;
    infoMediaId?: string | null;
    unitBase?: SizeGuideUnitBase;
    unitDisplayPolicy?: SizeGuideUnitDisplayPolicy | null;
}
interface UpdateSizeGuideDTO {
    name?: string;
    status?: SizeGuideStatus;
    tableJson?: SizeGuideTableJson;
    infoTitle?: string | null;
    infoBody?: string | null;
    infoMediaId?: string | null;
    unitBase?: SizeGuideUnitBase;
    unitDisplayPolicy?: SizeGuideUnitDisplayPolicy | null;
}
interface SizeGuideCategoryRuleInput {
    categoryId: string;
    priority: number;
}
/** Resolved size guide on product detail (api-public / storefront). */
interface ProductSizeGuidePayload {
    id: string;
    name: string;
    table: SizeGuideTableJson;
    unitBase: SizeGuideUnitBase;
    unitDisplayPolicy?: SizeGuideUnitDisplayPolicy | null;
    infoTitle?: string | null;
    infoBody?: string | null;
    infoImageUrl?: string | null;
}

/**
 * Entidad StandardCategory
 * Define las categorías estándar de productos.
 * Estas categorías estan pensadas para unificar o agrupar productos de diferentes cuentas.
 */
interface StandardCategory {
    id: string;
    parentId?: string;
    name: string;
    slug: string;
    description?: string;
    imageId?: string | null;
    order: number;
    status: StandardCategoryStatus;
    metadata?: {
        icon?: string;
        displayInMenu?: boolean;
        seoTitle?: string;
        seoDescription?: string;
        attributes?: string[];
    };
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    children: StandardCategory[];
    parent: StandardCategory | null;
}
declare enum StandardCategoryStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}

/**
 * Entidad ProductCategory
 * Define las categorías de productos.
 * Soporta una estructura jerárquica (categorías y subcategorías) mediante el campo parentId.
 * Cada categoría debe estar asociada a una categoría estándar del sistema.
 */
interface ProductCategory {
    id: string;
    accountId: string;
    parentId?: string;
    standardCategoryId: string | null;
    name: string;
    slug: string;
    description?: string;
    imageId?: string | null;
    order: number;
    isFeatured: boolean;
    status: ProductCategoryStatus;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    children: ProductCategory[];
    parent: ProductCategory | null;
    standardCategory: StandardCategory;
}
declare enum ProductCategoryStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}

/**
 * Entidad Product
 * Representa un producto vendible en la tienda. Es la entidad base que puede tener múltiples variantes.
 */
interface Product {
    id: string;
    accountId: string;
    code: string;
    brandId?: string | null;
    supplierId?: string | null;
    /** When set, storefront uses this size guide instead of category rules. */
    sizeGuideId?: string | null;
    productType: ProductType;
    sku?: string | null;
    barcode?: string | null;
    name: string;
    slug: string;
    description?: string | null;
    isFeatured: boolean;
    allowBackorder: boolean;
    weight?: number | null;
    weightUnit?: string | null;
    height?: number | null;
    width?: number | null;
    depth?: number | null;
    dimensionUnit?: string | null;
    shippingLeadTime?: string | null;
    status: ProductStatus;
    statusInfo?: StatusInfo;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    media?: Media[];
    variants?: ProductVariant[];
    categories?: ProductCategory[];
    /** Present on storefront product detail after server-side resolution. */
    sizeGuide?: ProductSizeGuidePayload | null;
}
declare enum ProductStatus {
    ACTIVE = "ACTIVE",// Available for sale
    INACTIVE = "INACTIVE",// Not visible/purchasable
    ARCHIVED = "ARCHIVED",// Not visible, kept for records
    DRAFT = "DRAFT"
}
declare enum ProductType {
    SIMPLE = "SIMPLE",// Product without variants (may have a default hidden variant)
    VARIABLE = "VARIABLE",// Product with distinct variants (color, size, etc.)
    BUNDLE = "BUNDLE",// A package of other products/variants
    GIFT_CARD = "GIFT_CARD"
}
interface ProductVariant {
    id: string;
    accountId: string;
    productId: string;
    sku?: string | null;
    barcode?: string | null;
    currency: string;
    price: number;
    compareAtPrice?: number;
    allowBackorder?: boolean;
    stock: number;
    status: ProductVariantStatus;
    weight?: number | null;
    weightUnit?: string | null;
    height?: number | null;
    width?: number | null;
    depth?: number | null;
    dimensionUnit?: string | null;
    shippingLeadTime?: string | null;
    order: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}
declare enum ProductVariantStatus {
    ACTIVE = "ACTIVE",
    OUT_OF_STOCK = "OUT_OF_STOCK",
    COMING_SOON = "COMING_SOON"
}

declare function getProductStatusInfo(status: ProductStatus): StatusInfo;

type FulfillmentItem = {
    id: string;
    fulfillmentId: string;
    quantity: number;
};

type CreateFulfillmentItemDto = {
    quantity: number;
    orderItemId: string;
};

/**
 * FulfillmentLabel Entity
 * Represents shipping labels and tracking information returned by fulfillment providers
 */
interface FulfillmentLabel {
    id: string;
    fulfillmentId: string;
    trackingNumber: string;
    trackingUrl?: string;
    labelUrl?: string;
    accountId: string;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}
interface FulfillmentLabelCreateData {
    fulfillmentId: string;
    trackingNumber: string;
    trackingUrl?: string;
    labelUrl?: string;
}
interface FulfillmentLabelUpdateData {
    trackingNumber?: string;
    trackingUrl?: string;
    labelUrl?: string;
}

declare enum PaymentStatus {
    PENDING = "PENDING",// Pendiente
    PREAUTHORIZED = "PREAUTHORIZED",
    APPROVED = "APPROVED",// Pago aprobado online
    PAID = "PAID",// Pago realizado por redes fisicas
    REJECTED = "REJECTED",// Pago rechazado
    REFUND_IN_PROCESS = "REFUND_IN_PROCESS",// En proceso de reembolso con la plataforma de pagos
    PARTIAL_REFUND = "PARTIAL_REFUND",// Pago parcialmente reembolsado
    REFUNDED = "REFUNDED",// Pago reembolsado
    ERROR = "ERROR"
}
declare enum PaymentMethodType {
    BANK_TRANSFER = "BANK_TRANSFER",
    CREDIT_CARD = "CREDIT_CARD",
    DEBIT_CARD = "DEBIT_CARD",
    MERCADOPAGO = "MERCADOPAGO",
    MERCADOPAGO_MARKETPLACE = "MERCADOPAGO_MARKETPLACE",
    PHYSICAL = "PHYSICAL",
    INTERNATIONAL = "INTERNATIONAL",
    PAYPAL = "PAYPAL",
    AKUA = "AKUA",
    CASH = "CASH",
    OTHER = "OTHER"
}
interface PaymentConversion {
    fromCurrency: Currency;
    toCurrency: Currency;
    rate: number;
    originalAmount: number;
    finalAmount: number;
}
interface Payment {
    id: string;
    accountId: string;
    orderId: string;
    invoiceId?: string;
    accountPaymentMethodId?: string;
    accountIntegrationId?: string;
    referenceCode?: string;
    paymentMethodType?: PaymentMethodType;
    currency: Currency;
    amount: number;
    amountReceived: number;
    amountRefunded: number;
    paidAt?: string | Date;
    refundedAt?: string | Date;
    status: PaymentStatus;
    statusInfo?: StatusInfo;
    cardBrand?: string;
    cardBrandInfo?: PaymentCardBrand;
    cardLast4?: string;
    data?: Record<string, any>;
    conversion?: PaymentConversion;
    metadata?: Record<string, any>;
    internalComment?: string;
    demo: boolean;
    createdAt: string | Date;
    updatedAt: string | Date;
    deletedAt?: string | Date;
    accountPaymentMethod?: Partial<AccountPaymentMethod> | null;
    order?: Order;
    allowedActions?: {
        canCopyLink: boolean;
        canMarkAsPaid: boolean;
        canRecapture: boolean;
        canRefund: boolean;
    };
}
type PaymentProviderKey = 'MERCADOPAGO' | 'MERCADOPAGO_MARKETPLACE' | 'PLEXO' | 'MANUAL_PAYMENT' | 'PAYPAL' | 'AKUA';
interface PaymentProviderContext {
    data: Record<string, unknown>;
}
interface PaymentProviderInitInput {
    data: Record<string, any>;
}
interface PaymentProviderInitOutput {
    data: Record<string, any>;
    status: PaymentStatus;
}
interface PaymentProviderCaptureInput {
    data: Record<string, any>;
}
interface PaymentProviderCaptureOutput {
    data: Record<string, any>;
}
interface PaymentProviderRefundInput {
    amount: number;
    data: Record<string, any>;
}
interface PaymentProviderRefundOutput {
    data: Record<string, any>;
}
interface PaymentProviderWebhookResult {
    paymentId: string | null;
    status: PaymentStatus;
    data: Record<string, unknown>;
    paymentDetails: {
        referenceCode?: string;
        method?: string;
        last4?: string;
    };
}
interface WebhookPayload {
    provider: string;
    accountId: string;
    payload: {
        query: Record<string, unknown>;
        body: Record<string, unknown>;
        headers: Record<string, unknown>;
    };
}
declare enum PaymentCardBrandKey {
    mp_account_money = "mp_account_money",
    master = "master",
    debmaster = "debmaster",
    visa = "visa",
    debvisa = "debvisa",
    diners = "diners",
    oca = "oca",
    lider = "lider",
    amex = "amex",
    redpagos = "redpagos",
    abitab = "abitab"
}
interface PaymentCardBrand {
    key: string;
    name: string;
    image: string;
    icon: string;
}
declare function getPaymentCardBrand(key: PaymentCardBrandKey): PaymentCardBrand;
interface PaymentProviderAdapter {
    readonly key: PaymentProviderKey;
    initPayment(input: PaymentProviderInitInput): Promise<PaymentProviderInitOutput>;
    capture(input: PaymentProviderCaptureInput): Promise<PaymentProviderCaptureOutput>;
    refund(input: PaymentProviderRefundInput): Promise<PaymentProviderRefundOutput>;
    processWebhook(input: WebhookPayload['payload']): Promise<PaymentProviderWebhookResult>;
}

declare function getPaymentStatusInfo(status: PaymentStatus): StatusInfo;

/** Item en el JSON integration.supportedPaymentMethods (íconos de medios). */
interface SupportedPaymentMethodIconRow {
    id: string;
    name?: string;
    thumbnail?: string;
    icon?: string;
    [key: string]: unknown;
}
/** Parsea supportedPaymentMethods desde fila integration (simple-json / array / string JSON). */
declare function parseIntegrationSupportedPaymentMethodsArray(raw: unknown): SupportedPaymentMethodIconRow[];
/**
 * Lista única de medios de pago en el orden canónico:
 * 1) Integraciones PAYMENT_GATEWAY ordenadas por integration.order ASC, providerKey ASC
 * 2) Dentro de cada una, el orden del array integration.supportedPaymentMethods
 * 3) Deduplicación por id conservando la primera aparición
 */
declare function flattenSupportedPaymentMethodsFromAccountIntegrations(accountIntegrations: Array<{
    integration?: {
        category?: string;
        order?: number;
        providerKey?: string;
        supportedPaymentMethods?: unknown;
    } | null;
}>): SupportedPaymentMethodIconRow[];

declare enum FulfillmentStatus {
    PENDING = "pending",
    SHIPPED = "shipped",
    DELIVERED = "delivered",
    CANCELLED = "cancelled"
}
type FulfillmentTrackingEvent = {
    providerStatus: string;
    providerStatusLabel?: string;
    retailaStatus: FulfillmentStatus;
    at: string;
    raw?: Record<string, unknown>;
};
type Fulfillment = {
    id: string;
    code: string;
    accountId: string;
    orderId: string;
    accountBranchId: string;
    deliveryOptionId: string;
    items: FulfillmentItem[];
    labels: FulfillmentLabel[];
    status: FulfillmentStatus;
    data: Record<string, unknown> | null;
    trackingEvents?: FulfillmentTrackingEvent[];
    shippedAt: Date | null;
    deliveredAt: Date | null;
    cancelledAt: Date | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
};
type FulfillmentDeliveryOption = {
    id: string;
    name: string;
    deliveryType?: 'SHIPPING' | 'PICKUP';
    pickupLocations?: PickupLocation[];
    [key: string]: unknown;
};
interface PickupLocation {
    id: string;
    name: string;
    address: Address;
    hours?: string;
    phone?: string;
    additionalInfo?: Record<string, unknown>;
}
type FulfillmentRecollectionMode = 'RECOLLECTION' | 'DROP_OFF';
type FulfillmentRecollectionSchedule = {
    dayOfWeek: number;
    startHour: number;
    endHour: number;
    intervalMinutes?: number;
};
type FulfillmentRecollectionCapabilities = {
    supportsRecollection: boolean;
    supportsDropOff: boolean;
    allowsScheduling: boolean;
    recollectionSchedule?: FulfillmentRecollectionSchedule[];
    leadTimeHours: number;
    maxAdvanceDays: number;
    dropOffLocationsUrl?: string;
};
type FulfillmentRecollectionConfig = {
    mode: FulfillmentRecollectionMode;
    scheduledDateTime?: Date;
    recollectionAddress?: Address;
    contactInfo?: {
        name: string;
        phone: string;
        email?: string;
    };
    specialInstructions?: string;
};
type FulfillmentProviderCreateInput = {
    data: Record<string, unknown>;
    items: FulfillmentItem[];
    order: Order;
    fulfillment: Fulfillment;
    recollectionConfig?: FulfillmentRecollectionConfig;
    /** ISO 3166-1 alpha-2 country code (e.g. 'UY', 'AR') for provider defaults (e.g. phone fallback). */
    accountCountryCode?: string;
};
type FulfillmentProviderCreateOutput = {
    data?: Record<string, unknown>;
    labels: {
        trackingNumber: string;
        trackingUrl?: string;
        label?: {
            url?: string;
            base64?: string;
            format?: 'pdf' | 'png' | 'zpl';
        };
    }[];
};
type FulfillmentProviderProcessWebhookInput = WebhookPayload & {
    fulfillmentService: any;
};
type FulfillmentProviderProcessWebhookOutput = {
    fulfillmentId: string;
    fulfillmentStatus: FulfillmentStatus;
    data: Record<string, any>;
    trackingEvent?: FulfillmentTrackingEvent;
};
type FulfillmentProviderKey = 'MANUAL_FULFILLMENT' | 'DAC' | 'PEDIDOSYA';
type FulfillmentProviderContext = {
    data: Record<string, any>;
};
interface FulfillmentProviderAdapter {
    readonly key: FulfillmentProviderKey;
    listDeliveryOptions(): Promise<FulfillmentDeliveryOption[]>;
    canCalculate(data: Record<string, unknown>): Promise<boolean>;
    calculatePrice(data: Record<string, unknown>): Promise<number>;
    getRecollectionCapabilities(): Promise<FulfillmentRecollectionCapabilities>;
    createFulfillment(input: FulfillmentProviderCreateInput): Promise<FulfillmentProviderCreateOutput>;
    processWebhook(input: FulfillmentProviderProcessWebhookInput): Promise<FulfillmentProviderProcessWebhookOutput | null>;
    /** Optional: cancel the fulfillment with the provider (e.g. cancel shipping label). */
    cancelFulfillment?(fulfillment: Fulfillment): Promise<void>;
}

/**
 * OrderDeliveryMethod Entity
 * Represents a snapshot of the selected delivery option for an order
 */

interface OrderDeliveryMethod {
    id: string;
    orderId: string;
    deliveryOptionId: string;
    name: string;
    description?: string;
    amount: number;
    data?: Record<string, any>;
    accountId: string;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
    deliveryOption?: AccountDeliveryOption;
}
interface OrderDeliveryMethodCreateData {
    orderId: string;
    deliveryOptionId: string;
    name: string;
    description?: string;
    amount: number;
    data?: Record<string, any>;
}
interface OrderDeliveryMethodUpdateData {
    name?: string;
    description?: string;
    amount?: number;
    data?: Record<string, any>;
}

/**
 * Entidad Order
 * Define la orden de compra de un cliente en el sitio web.
 */
interface Order {
    id: string;
    accountId: string;
    customerId: string;
    cartId?: string;
    code: string;
    deliveryType: OrderDeliveryType;
    deliveryFirstName?: string;
    deliveryLastName?: string;
    deliveryAddress?: any;
    deliveryPhone?: any;
    pickupBranchId?: string;
    accountPaymentMethodId?: string;
    paymentMethodIntegrationId?: string;
    billingInformation?: any;
    currency: Currency;
    currencySymbol?: string;
    subtotalPrice: number;
    totalDiscounts: number;
    totalShippingPrice: number;
    totalTax: number;
    taxDetails?: any;
    totalPrice: number;
    totalRefunded: number;
    status: OrderStatus;
    statusInfo?: StatusInfo;
    paymentStatus: OrderPaymentStatus;
    paymentStatusInfo?: StatusInfo;
    fulfillmentStatus: FulfillmentStatus;
    statusHistory?: StatusChangeHistory[];
    customerNote?: string;
    internalNote?: string;
    source: OrderSource;
    sourceAccountDomainId?: string;
    demo: boolean;
    createdAt: Date;
    updatedAt: Date;
    cancelledAt?: Date;
    cancelReason?: string;
    deletedAt?: Date;
    /** Estimated delivery window start (from delivery option rules) */
    estimatedDeliveryStart?: Date;
    /** Estimated delivery window end (from delivery option rules) */
    estimatedDeliveryEnd?: Date;
    items?: OrderItem[];
    /** Applied promotions snapshot at order creation (checkout promos with name/code/amount). */
    promotions?: OrderAppliedPromotion[];
    customer?: Customer | null;
    paymentMethodIntegration?: AccountIntegration | null;
    accountDomain?: AccountDomain;
    deliveryMethod?: OrderDeliveryMethod | null;
    account?: Account;
    accountPaymentMethod?: Partial<AccountPaymentMethod> | null;
    payments?: Payment[];
    statusFlow?: StatusFlow[];
    statusChangeAllowed?: OrderStatus[];
    hasShipment?: boolean;
}
interface OrderItem {
    id: string;
    accountId: string;
    orderId: string;
    productId: string;
    productVariantId: string;
    sku?: string;
    productName: string;
    variantName?: string;
    currency: Currency;
    currencySymbol?: string;
    unitPrice: number;
    totalDiscount: number;
    totalPrice: number;
    quantity: number;
    quantityFulfilled: number;
    quantityRefunded: number;
    quantityReturned: number;
    totalTax: number;
    taxName?: string;
    createdAt: Date;
    updatedAt: Date;
    productSnapshot?: OrderItemSnapshot;
    product?: Product;
}
declare enum OrderStatus {
    PENDING = "PENDING",// Order placed, awaiting payment confirmation
    CONFIRMED = "CONFIRMED",// Payment received, order confirmed
    PROCESSING = "PROCESSING",// Order being prepared
    PROCESSED = "PROCESSED",// Order ready to be shipped
    ON_HOLD = "ON_HOLD",// Order temporarily paused
    COMPLETED = "COMPLETED",// Order finished (e.g., after return period)
    CANCELLED = "CANCELLED",// Order cancelled before fulfillment
    FAILED = "FAILED"
}
declare enum OrderPaymentStatus {
    PENDING = "PENDING",
    PARTIAL = "PARTIAL",
    PAID = "PAID",
    OVERPAID = "OVERPAID",
    REFUNDED = "REFUNDED",
    PARTIALLY_REFUNDED = "PARTIALLY_REFUNDED"
}
declare enum OrderSource {
    WEB = "WEB",
    POS = "POS",
    API = "API"
}
declare enum OrderDeliveryType {
    SHIPPING = "SHIPPING",
    PICKUP = "PICKUP"
}
/**
 * Pseudo-estado amigable para la vista/filtro de órdenes en backoffice.
 * Cada valor se deriva de combinaciones de status, paymentStatus, fulfillmentStatus y deliveryType.
 */
declare enum DisplayOrderStatus {
    PENDIENTES_DE_PAGO = "PENDIENTES_DE_PAGO",
    EN_PROCESO = "EN_PROCESO",
    LISTAS_PARA_ENVIAR = "LISTAS_PARA_ENVIAR",
    LISTAS_PARA_RETIRAR = "LISTAS_PARA_RETIRAR",
    ENVIADAS = "ENVIADAS",
    ENTREGADAS = "ENTREGADAS",
    EN_ESPERA = "EN_ESPERA",
    CON_PROBLEMAS = "CON_PROBLEMAS",
    CANCELADAS = "CANCELADAS",
    REEMBOLSADAS = "REEMBOLSADAS"
}
interface StatusChangeHistory {
    type: 'order' | 'fulfillment' | 'payment';
    status: OrderStatus | FulfillmentStatus | PaymentStatus;
    timestamp: Date;
    reason?: string;
    userId?: string;
    metadata?: Record<string, any>;
}
interface OrderItemSnapshot {
    sku?: string;
    productName: string;
    variantName?: string;
    media?: Media[];
}
/** Promotion applied to an order (snapshot at checkout time). */
interface OrderAppliedPromotion {
    code: string;
    amount: number;
    name?: string;
    description?: string;
    isAutomatic?: boolean;
}
type StatusByType = {
    order: OrderStatus;
    fulfillment: FulfillmentStatus;
    payment: PaymentStatus;
};
type StatusFlow<T extends keyof StatusByType = keyof StatusByType> = {
    type: T;
    status: StatusByType[T];
    text?: string;
    doneAt: Date | null;
};
type NextStatusAction<T extends keyof StatusByType = keyof StatusByType> = {
    type: T;
    status: StatusByType[T];
    text: string;
    fulfillmentId?: string;
};

interface OrderCreateFromCartDto {
    cartId: string;
    paymentMethodIntegrationId?: string;
    customerNote?: string;
}
interface AdminOrderStatusChangeDto {
    status: OrderStatus;
}

declare function getOrderStatusInfo(status: OrderStatus): StatusInfo;
declare function getOrderPaymentStatusInfo(status: OrderPaymentStatus): StatusInfo;
declare function getDisplayOrderStatusInfo(displayStatus: DisplayOrderStatus): StatusInfo;
/** Order-like minimal shape for computing display status */
type OrderForDisplayStatus = Pick<Order, 'status' | 'paymentStatus' | 'deliveryType'> & {
    fulfillmentStatus?: FulfillmentStatus | null;
};
/**
 * Derives the display (pseudo) status for an order from real status, paymentStatus, fulfillmentStatus and deliveryType.
 * Evaluation order matters: Canceladas and Reembolsadas are mutually exclusive (Canceladas wins).
 */
declare function getDisplayOrderStatus(order: OrderForDisplayStatus): DisplayOrderStatus;

/**
 * Add an item to the cart
*/
interface CartItemAddDto {
    cartId: string;
    productId: string;
    variantId?: string;
    quantity: number;
    attributes?: {
        [key: string]: string | number;
    };
    userEmail?: string;
    userId?: string;
}
/**
 * Update an item in the cart
 */
interface CartItemUpdateDto {
    cartId: string;
    itemId: string;
    quantity: number;
}
/**
 * Remove an item from the cart
 */
interface CartItemRemoveDto {
    cartId: string;
    itemId: string;
}
interface CartUpdateDto {
    cartId: string;
    source: OrderSource;
    accountDomainId?: string;
    customer: {
        email: string;
    };
    delivery: {
        type: 'SHIPPING' | 'PICKUP';
        pickupBranchId?: string;
        firstname: string;
        lastname: string;
        phone: {
            countryCode: string;
            national: string;
            international: string;
            type: string;
            validated: boolean;
        };
        address: {
            country: string;
            department: string;
            locality: string;
            street: string;
            complement?: string;
            notes?: string;
            postalCode: string;
            mapPosition: {
                lat: number;
                lng: number;
            };
        };
    };
    billing: {
        name: string;
        address: string;
        city: string;
        department: string;
    };
    accountPaymentMethodId?: string;
    customerNote?: string | null;
}
/**
 * Confirm a cart
 */
interface CartConfirmDto {
    cartId: string;
}
/**
 * Validation information for a cart item
 */
interface CartItemValidation {
    hasIssues: boolean;
    issues: string[];
    errorCode?: CartItemErrorCode;
    currentPrice?: number;
    availableStock?: number;
    isProductActive?: boolean;
}
/**
 * Error codes for cart items
 */
declare enum CartItemErrorCode {
    PRICE_INCREASED = "PRICE_INCREASED",// Precio aumentó
    PRICE_DECREASED = "PRICE_DECREASED",// Precio disminuyó  
    PRODUCT_INACTIVE = "PRODUCT_INACTIVE",// Producto ya no está disponible
    STOCK_INSUFFICIENT = "STOCK_INSUFFICIENT",// Stock insuficiente (hay algo disponible)
    STOCK_UNAVAILABLE = "STOCK_UNAVAILABLE",// Sin stock (0 disponible)
    VALIDATION_ERROR = "VALIDATION_ERROR"
}

/**
 * Promotion Module Types
 * Types for the promotion system including promotions, rules, application methods, and adjustments
 */
/**
 * Main promotion entity that defines discount rules and metadata
 */
interface Promotion {
    id: string;
    accountId: string;
    code: string;
    type: PromotionType;
    isAutomatic: boolean;
    isStackable: boolean;
    campaignId?: string | null;
    name: string;
    description?: string | null;
    /** Public URL for badge/icon on storefront (e.g. GCS media) */
    badgeImageUrl?: string | null;
    /** When true, storefront may show badge image on product cards */
    badgeShowOnProductCard?: boolean;
    /** When true, storefront may show badge image on product detail */
    badgeShowOnProductDetail?: boolean;
    status: PromotionStatus;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum PromotionType {
    STANDARD = "standard"
}
declare enum PromotionStatus {
    ACTIVE = "active",
    INACTIVE = "inactive"
}
/**
 * Reusable rule entity that can be attached to either Promotions (cart/order level)
 * or ApplicationMethods (target level)
 */
interface PromotionRule {
    id: string;
    accountId: string;
    ruleAttribute: string;
    ruleOperator: PromotionRuleOperator;
    createdAt: Date;
    updatedAt: Date;
}
declare enum PromotionRuleOperator {
    GT = "gt",// greater than
    GTE = "gte",// greater than or equal
    LT = "lt",// less than
    LTE = "lte",// less than or equal
    EQ = "eq",// equals
    IN = "in",// in array
    NIN = "nin"
}
/**
 * Stores the values that a PromotionRule is evaluated against
 */
interface PromotionRuleValue {
    id: string;
    promotionRuleId: string;
    value: string;
    createdAt: Date;
    updatedAt: Date;
}
/**
 * Many-to-many relationship between Promotion and PromotionRule for cart/order-level rules
 */
interface PromotionPromotionRule {
    promotionId: string;
    promotionRuleId: string;
}
/**
 * Many-to-many relationship between PromotionApplicationMethod and PromotionRule for target-level rules
 */
interface PromotionApplicationMethodPromotionRule {
    applicationMethodId: string;
    promotionRuleId: string;
}
/**
 * Defines how the promotion discount is applied
 */
interface PromotionApplicationMethod {
    id: string;
    accountId: string;
    promotionId: string;
    targetType: PromotionTargetType;
    applicationType: PromotionApplicationType;
    value: number;
    /** For N_FOR_M: number of units to buy (e.g. 2 for 2x1, 3 for 3x2) */
    buyQuantity?: number | null;
    /** For N_FOR_M: number of units to pay (e.g. 1 for 2x1, 2 for 3x2) */
    payQuantity?: number | null;
    /** Optional: label for badge (e.g. "2x1", "20% OFF") */
    badgeLabel?: string | null;
    /** Optional: badge type for preview (e.g. "n_for_m", "percentage") */
    badgeType?: string | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum PromotionTargetType {
    ITEMS = "items",// apply to cart/order line items
    SHIPPING = "shipping",// apply to cart/order delivery methods
    ORDER = "order"
}
declare enum PromotionApplicationType {
    PERCENTAGE = "percentage",// e.g., 10% off
    FIXED = "fixed",// e.g., $5 off
    N_FOR_M = "n_for_m"
}
/**
 * Tracks promotion adjustments applied to individual cart items
 */
interface CartLineItemAdjustment {
    id: string;
    accountId: string;
    cartItemId: string;
    promotionId?: string | null;
    description: string;
    code?: string | null;
    amount: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
/**
 * Tracks promotion adjustments applied to cart delivery methods
 */
interface CartDeliveryMethodAdjustment {
    id: string;
    accountId: string;
    cartDeliveryMethodId: string;
    promotionId?: string | null;
    description: string;
    code?: string | null;
    amount: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
/**
 * Links carts to applied promotions for easy querying (pivot table)
 */
interface CartPromotion {
    cartId: string;
    promotionId: string;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
/**
 * Tracks promotion adjustments on order items (snapshot from cart)
 */
interface OrderLineItemAdjustment {
    id: string;
    accountId: string;
    orderItemId: string;
    promotionId?: string | null;
    description: string;
    code?: string | null;
    amount: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
/**
 * Tracks promotion adjustments on order delivery methods
 */
interface OrderDeliveryMethodAdjustment {
    id: string;
    accountId: string;
    orderDeliveryMethodId: string;
    promotionId?: string | null;
    description: string;
    code?: string | null;
    amount: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
/**
 * Links orders to applied promotions for easy querying (pivot table, snapshot from cart)
 */
interface OrderPromotion {
    id: string;
    orderId: string;
    accountId: string;
    promotionId: string;
    code?: string | null;
    name?: string | null;
    amount: number;
    isAutomatic: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
interface PromotionRuleInput {
    ruleAttribute: string;
    ruleOperator: PromotionRuleOperator;
    values: string[];
}
interface PromotionApplicationMethodInput {
    targetType: PromotionTargetType;
    applicationType: PromotionApplicationType;
    value: number;
    /** Required when applicationType is N_FOR_M: units to buy (e.g. 2 for 2x1) */
    buyQuantity?: number | null;
    /** Required when applicationType is N_FOR_M: units to pay (e.g. 1 for 2x1) */
    payQuantity?: number | null;
}
interface CreatePromotionDTO {
    name: string;
    description?: string | null;
    code?: string | null;
    isAutomatic: boolean;
    isStackable?: boolean;
    status: PromotionStatus;
    type?: PromotionType;
    campaignId?: string | null;
    promotionRules?: PromotionRuleInput[];
    targetRules?: PromotionRuleInput[];
    applicationMethod: PromotionApplicationMethodInput;
}
interface UpdatePromotionDTO extends Partial<CreatePromotionDTO> {
    id: string;
}
interface PromotionListFilters {
    page?: number;
    limit?: number;
    search?: string | null;
    status?: PromotionStatus | null;
    isAutomatic?: boolean | null;
}

/**
 * CartDeliveryMethod Entity
 * Represents a snapshot of the selected delivery option for a cart
 */

interface CartDeliveryMethod {
    id: string;
    cartId: string;
    deliveryOptionId: string;
    name: string;
    description?: string;
    amount: number;
    data?: Record<string, any>;
    accountId: string;
    adjustments?: CartDeliveryMethodAdjustment[];
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}
interface CartDeliveryMethodCreateData {
    cartId: string;
    deliveryOptionId: string;
    name: string;
    description?: string;
    amount: number;
    data?: Record<string, any>;
}
interface CartDeliveryMethodUpdateData {
    name?: string;
    description?: string;
    amount?: number;
    data?: Record<string, any>;
}

/**
 * DTOs for CartDeliveryMethod operations
 */
interface CartDeliveryMethodCreateDto {
    cartId: string;
    deliveryOptionId: string;
    data?: Record<string, any>;
}
interface CartDeliveryMethodUpdateDto {
    deliveryOptionId?: string;
    name?: string;
    description?: string;
    amount?: number;
    data?: Record<string, any>;
}
interface CartDeliveryMethodFindParams {
    cartId: string;
    accountId: string;
}
interface CartDeliveryMethodResponse {
    success: boolean;
    item?: CartDeliveryMethod | null;
    error?: string;
}

/**
 * Entidad Cart
 * Define el carrito de compras de un cliente en el sitio web.
 */
interface Cart {
    id: string;
    code: string;
    customerId?: string;
    sessionId?: string;
    items: CartItem[];
    currency: string;
    subtotal: number;
    total: number;
    deliveryType: CartDeliveryType;
    deliveryFirstName?: string;
    deliveryLastName?: string;
    deliveryAddress?: string;
    deliveryPhone?: string;
    pickupBranchId?: string;
    accountPaymentMethodId?: string;
    itemCount: number;
    createdAt: Date;
    updatedAt: Date;
    status: CartStatus;
    source: CartSource;
    sourceAccountDomainId?: string;
    recoveryToken?: string;
    customerNote?: string;
    hasIssues: boolean;
    issuesCount: number;
    subtotalPrice?: number;
    totalDiscounts?: number;
    totalShippingPrice?: number;
    totalTax?: number;
    totalPrice?: number;
    taxDetails?: any;
    /** BIN de la tarjeta (primeros 6–8 dígitos) cuando se escribe en el checkout; usado para promociones por BIN. */
    cardBin?: string | null;
    customer?: Partial<Customer> | null;
    accountDomain?: Partial<AccountDomain> | null;
    deliveryMethod?: CartDeliveryMethod | null;
    promotions: {
        code: string;
        amount: number;
        name?: string;
        description?: string;
        isAutomatic?: boolean;
    }[];
    freeShippingProgress?: {
        threshold: number;
        currentSubtotal: number;
        remaining: number;
        qualified: boolean;
    } | null;
}
interface CartItem {
    id: string;
    productId: string;
    productVariantId: string;
    name: string;
    unitPrice: number;
    quantity: number;
    image?: string;
    thumbnailUrl?: string;
    sku?: string;
    attributeDetails: CartItemAttributeDetail[];
    validation?: CartItemValidation;
    adjustments?: CartLineItemAdjustment[];
}
interface CartItemAttributeDetail {
    name: string;
    alias: string;
    value: string;
    type?: string;
}
declare enum CartStatus {
    ACTIVE = "ACTIVE",
    LOCKED = "LOCKED",
    EXPIRED = "EXPIRED",
    CONVERTED = "CONVERTED",
    ABANDONED = "ABANDONED",
    MERGED = "MERGED"
}
declare enum CartSource {
    WEB = "WEB",
    POS = "POS",
    API = "API"
}
declare enum CartDeliveryType {
    SHIPPING = "SHIPPING",
    PICKUP = "PICKUP"
}

/**
 * Entidad ProductAttribute
 * Define los atributos disponibles que se pueden asignar a las variantes de producto (ej. Color, Talla).
 * Especifica el nombre y tipo del atributo para ayudar en la representación y filtrado.
 */

interface ProductAttribute {
    id: string;
    accountId: string;
    name: string;
    alias: string;
    slug: string;
    type: ProductAttributeType;
    isRequired: boolean;
    suffix: string;
    status: ProductAttributeStatus;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    productCategories: ProductCategory[];
    productCategoryLinks: Array<{
        categoryId: string;
        isRequired: boolean;
        displayOrder: number;
    }>;
    options: ProductAttributeOption[];
    displayOrder: number;
}
declare enum ProductAttributeStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}
declare enum ProductAttributeType {
    TEXT = "TEXT",// text input
    NUMBER = "NUMBER",// number input
    COLOR = "COLOR",// Special type for color swatches
    SELECT = "SELECT",// Dropdown list
    BOOLEAN = "BOOLEAN"
}
/**
 * Una opción específica para un atributo (ej. "Talle 42" para el atributo "Talle").
 */
interface ProductAttributeOption {
    id: string;
    accountId: string;
    productAttributeId: string;
    value: string;
    imageId?: string | null;
    order: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    count: number;
}

/**
 * Entidad Collection
 * Define colecciones de productos para merchandising y agrupaciones flexibles.
 * Similar al modelo de Shopify Collections.
 */
declare enum CollectionType {
    MANUAL = "MANUAL",
    AUTOMATIC = "AUTOMATIC"
}
declare enum CollectionStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE",
    SCHEDULED = "SCHEDULED"
}
declare enum CollectionRulesLogic {
    ALL = "ALL",
    ANY = "ANY"
}
declare enum CollectionRuleField {
    TAG = "TAG",
    PRICE = "PRICE",
    CATEGORY = "CATEGORY",
    BRAND = "BRAND",
    TITLE = "TITLE",
    STATUS = "STATUS",
    INVENTORY = "INVENTORY",
    CREATED_AT = "CREATED_AT"
}
declare enum CollectionRuleOperator {
    EQUALS = "EQUALS",
    NOT_EQUALS = "NOT_EQUALS",
    CONTAINS = "CONTAINS",
    GREATER_THAN = "GREATER_THAN",
    LESS_THAN = "LESS_THAN",
    IS_SET = "IS_SET",
    IS_NOT_SET = "IS_NOT_SET"
}
interface CollectionRule {
    field: CollectionRuleField;
    operator: CollectionRuleOperator;
    value: string | number | boolean | null;
}
interface CollectionMedia {
    id: string;
    url: string;
    name?: string;
}
interface Collection {
    id: string;
    accountId: string;
    name: string;
    slug: string;
    description?: string;
    imageId?: string;
    image?: CollectionMedia | null;
    collectionType: CollectionType;
    status: CollectionStatus;
    isFeatured: boolean;
    rules?: CollectionRule[];
    rulesLogic: CollectionRulesLogic;
    publishAt?: Date;
    unpublishAt?: Date;
    order: number;
    productCount?: number;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}
interface CollectionProductLink {
    collectionId: string;
    productId: string;
    accountId: string;
    displayOrder: number;
    addedAt: Date;
}
interface CreateCollectionDTO {
    accountId: string;
    name: string;
    description?: string;
    imageId?: string;
    collectionType: CollectionType;
    status?: CollectionStatus;
    isFeatured?: boolean;
    rules?: CollectionRule[];
    rulesLogic?: CollectionRulesLogic;
    publishAt?: Date;
    unpublishAt?: Date;
    order?: number;
    products?: string[];
}
interface UpdateCollectionDTO {
    name?: string;
    description?: string;
    imageId?: string | null;
    collectionType?: CollectionType;
    status?: CollectionStatus;
    isFeatured?: boolean;
    rules?: CollectionRule[];
    rulesLogic?: CollectionRulesLogic;
    publishAt?: Date | null;
    unpublishAt?: Date | null;
    order?: number;
}
declare const CollectionRuleFieldLabels: Record<CollectionRuleField, string>;
declare const CollectionRuleOperatorLabels: Record<CollectionRuleOperator, string>;
declare const CollectionTypeLabels: Record<CollectionType, string>;
declare const CollectionStatusLabels: Record<CollectionStatus, string>;

declare enum CampaignStatus {
    ACTIVE = "active",
    INACTIVE = "inactive"
}
interface Campaign {
    id: string;
    accountId: string;
    name: string;
    description?: string | null;
    startDate?: Date | null;
    endDate?: Date | null;
    status: CampaignStatus;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum CampaignBudgetType {
    USAGE = "usage",
    SPEND = "spend",
    USAGE_BY_ATTRIBUTE = "usage_by_attribute",
    SPEND_BY_ATTRIBUTE = "spend_by_attribute"
}
interface CampaignBudget {
    id: string;
    accountId: string;
    campaignId: string;
    type: CampaignBudgetType;
    limit?: number | null;
    used: number;
    attribute?: string | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
interface CampaignBudgetUsage {
    id: string;
    campaignBudgetId: string;
    attributeValue: string;
    used: number;
    createdAt: Date;
    updatedAt: Date;
}

/**
 * Entidad StoreBanner
 * Banners para la portada de la web de la tienda
 */

interface StoreBanner {
    id: string;
    accountId: string;
    title: string;
    desktopMediaId: string;
    mobileMediaId?: string | null;
    linkUrl?: string | null;
    altText?: string | null;
    displayOrder: number;
    startDate?: Date | null;
    endDate?: Date | null;
    status: StoreBannerStatus;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    desktopMedia?: Partial<Media> | null;
    mobileMedia?: Partial<Media> | null;
}
declare enum StoreBannerStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}

/**
 * Entidad StorePage
 * Páginas de la web de la tienda
 */
interface StorePage {
    id: string;
    accountId: string;
    type: StorePageType;
    title: string;
    slug: string;
    content?: string | null;
    seoTitle?: string | null;
    seoDescription?: string | null;
    status: StorePageStatus;
    canDelete: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
declare enum StorePageStatus {
    PUBLISHED = "PUBLISHED",
    DRAFT = "DRAFT",
    ARCHIVED = "ARCHIVED"
}
declare enum StorePageType {
    ABOUT_US = "ABOUT_US",
    CONTACT = "CONTACT",
    FAQ = "FAQ",
    TERMS_AND_CONDITIONS = "TERMS_AND_CONDITIONS",
    PRIVACY_POLICY = "PRIVACY_POLICY",
    RETURN_POLICY = "RETURN_POLICY",
    SHIPPING_POLICY = "SHIPPING_POLICY",
    BRANCHES = "BRANCHES",
    JOBS = "JOBS",
    OTHER = "OTHER"
}

declare enum PubSubTopics {
    ORDER_PLACED = "order-placed",
    ORDER_CONFIRMED = "order-confirmed",
    ORDER_PROCESSING = "order-processing",
    ORDER_PROCESSED = "order-processed",
    ORDER_SHIPPED = "order-shipped",
    ORDER_DELIVERED = "order-delivered",
    ORDER_COMPLETED = "order-completed",
    ORDER_CANCELLED = "order-cancelled",
    PAYMENT_PAID = "payment-paid",
    NOTIFICATION_CREATED = "notification-created",
    CONTACT_FORM_SUBMITTED = "contact-form-submitted"
}

declare enum SupportConversationChannel {
    WEB = "WEB",
    CHATBOT = "CHATBOT",
    EMAIL = "EMAIL",
    WHATSAPP = "WHATSAPP"
}
declare enum SupportConversationVisibility {
    INTERNAL = "INTERNAL",
    MERCHANT = "MERCHANT"
}
declare enum SupportConversationPriority {
    LOW = "LOW",
    MEDIUM = "MEDIUM",
    HIGH = "HIGH",
    URGENT = "URGENT"
}
declare enum SupportConversationStatus {
    OPEN = "OPEN",
    CLOSED = "CLOSED",
    PENDING = "PENDING"
}
declare enum SupportConversationMessageDeliveryStatus {
    QUEUED = "QUEUED",
    SENT = "SENT",
    DELIVERED = "DELIVERED",
    READ = "READ",
    FAILED = "FAILED"
}
declare enum SupportConversationMessageAiAnalysisStatus {
    PENDING = "PENDING",
    PROCESSING = "PROCESSING",
    COMPLETED = "COMPLETED",
    FAILED = "FAILED"
}
declare enum SupportConversationMessageDirection {
    INBOUND = "INBOUND",
    OUTBOUND = "OUTBOUND"
}
declare enum SupportConversationMessageSenderType {
    CUSTOMER = "CUSTOMER",
    ACCOUNT_USER = "ACCOUNT_USER",
    ANONYMOUS = "ANONYMOUS",
    SYSTEM = "SYSTEM",
    AI = "AI"
}
interface SupportConversation {
    id: string;
    accountId: string;
    subject?: string | null;
    channel: SupportConversationChannel;
    assigneeId?: string | null;
    visibility: SupportConversationVisibility;
    priority: SupportConversationPriority;
    requiresMerchantAction: boolean;
    requiresInternalAction: boolean;
    customerId?: string | null;
    customerName?: string | null;
    customerLastname?: string | null;
    customerEmail?: string | null;
    customerPhone?: string | null;
    status: SupportConversationStatus;
    lastMessageAt?: Date | null;
    unreadForAgent: number;
    unreadForCustomer: number;
    metadata?: Object | null;
    aiSuggestion?: Object | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    account: Account;
    customer: Customer | null;
    messages: SupportConversationMessage[];
}
interface SupportConversationMessage {
    id: string;
    accountId: string;
    conversationId: string;
    direction: SupportConversationMessageDirection;
    senderType: SupportConversationMessageSenderType;
    senderId?: string | null;
    body: string;
    isAiGenerated: boolean;
    isSystem: boolean;
    deliveryStatus: SupportConversationMessageDeliveryStatus;
    requiresAiAnalysis: boolean;
    aiAnalysisStatus: SupportConversationMessageAiAnalysisStatus;
    aiAnalyzedAt?: Date | null;
    externalMessageId?: string | null;
    externalThreadId?: string | null;
    attachments?: Array<{
        url: string;
        type?: string;
        name?: string;
        sizeBytes?: number;
    }>;
    metadata?: Object | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}

type CreateFulfillmentDto = {
    accountId: string;
    orderId: string;
    accountBranchId: string;
    deliveryOptionId: string;
    items: CreateFulfillmentItemDto[];
    data?: Record<string, unknown>;
    recollectionConfig?: FulfillmentRecollectionConfig;
};
type UpdateFulfillmentDto = {
    status?: FulfillmentStatus;
    data?: Record<string, unknown>;
    trackingEvents?: FulfillmentTrackingEvent[];
    shippedAt?: Date;
    deliveredAt?: Date;
};
type CreateDeliveryOptionDto = {
    accountId: string;
    accountBranchId: string;
    name: string;
    integrationId?: string | null;
    isScheduled?: boolean;
    priceLogic?: 'FIXED' | 'PER_KM';
    price?: number;
    status?: 'ACTIVE' | 'INACTIVE';
};

declare function getFulfillmentStatusInfo(status: FulfillmentStatus): StatusInfo;

/**
 * Entidad StoreCustomization
 * Configuración de la tienda
 */

/**
 * Tipos para la navegación personalizable del menú
 */
declare enum NavigationItemType {
    HOME = "HOME",
    CATALOG = "CATALOG",
    CATEGORY = "CATEGORY",
    COLLECTION = "COLLECTION",
    PAGE = "PAGE",
    CUSTOM = "CUSTOM"
}
interface NavigationMenuItem {
    id: string;
    label: string;
    itemType: NavigationItemType;
    referenceId?: string;
    customUrl?: string;
    order: number;
    includeChildren?: boolean;
    highlight?: boolean;
    highlightColor?: string;
    openInNewTab?: boolean;
}
interface NavigationMenuConfig {
    items: NavigationMenuItem[];
    autoFallback?: boolean;
}
/**
 * Zona del Header: componentes antes y después del header principal
 */
interface StoreCustomizationHeaderZone {
    header: StoreCustomizationLayoutComponent;
    preComponents: StoreCustomizationLayoutComponent[];
    postComponents: StoreCustomizationLayoutComponent[];
}
/**
 * Zona del Footer: componentes antes y después del footer principal
 */
interface StoreCustomizationFooterZone {
    footer: StoreCustomizationLayoutComponent;
    preComponents: StoreCustomizationLayoutComponent[];
    postComponents: StoreCustomizationLayoutComponent[];
}
/**
 * Nueva estructura de layout con zonas
 */
interface StoreCustomizationLayout {
    headerZone: StoreCustomizationHeaderZone;
    footerZone: StoreCustomizationFooterZone;
}
declare function isZonedLayout(layout: unknown): layout is StoreCustomizationLayout;
interface StoreCustomization {
    id: string;
    accountId: string;
    layout: StoreCustomizationLayout;
    pages: StoreCustomizationPage[];
    theme: {
        colors: StoreCustomizationThemeColors;
        typography: StoreCustomizationThemeTypography;
        buttons: StoreCustomizationThemeButtons;
        designTokens?: DesignTokens;
    };
    seo: StoreCustomizationSeo;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
interface StoreCustomizationLayoutComponent {
    id: string;
    type: string;
    name: string;
    version: string;
    settings: StoreCustomizationComponentSettings;
}
interface StoreCustomizationPageComponent {
    id: string;
    type: string;
    name: string;
    version: string;
    settings: StoreCustomizationComponentSettings;
}
/** Builder page entry. For CMS pages (store_page type OTHER), id matches store_page.id. */
interface StoreCustomizationPage {
    id: string;
    name: string;
    path: string;
    components: StoreCustomizationPageComponent[];
}
interface StoreCustomizationComponentSettings {
    [key: string]: any;
}
interface StoreCustomizationThemeColors {
    background: {
        backgroundColor: string;
    };
    text: {
        titleTextColor: string;
        bodyTextColor: string;
    };
    theme: {
        primaryColor: string;
        secondaryColor: string;
    };
}
interface StoreCustomizationThemeTypography {
    headings: {
        fontFamily: string;
        fontSizeBase: number;
        fontUppercase: boolean;
    };
    body: {
        fontFamily: string;
        fontSizeBase: number;
        fontUppercase: boolean;
    };
}
interface ButtonStyle {
    backgroundColor: string;
    textColor: string;
    borderColor: string;
    /** CSS string e.g. "6px 6px 6px 6px" */
    borderRadius: string;
    shadow: string;
    hoverBackgroundColor: string;
    hoverTextColor: string;
    hoverBorderColor: string;
    hoverEffect: string;
}
interface LinkButtonStyle extends ButtonStyle {
    textDecoration?: string;
    hoverTextDecoration?: string;
}
interface StoreCustomizationThemeButtons {
    primary: ButtonStyle;
    secondary: ButtonStyle;
    outline: ButtonStyle;
    link: LinkButtonStyle;
    success: ButtonStyle;
    warning: ButtonStyle;
    danger: ButtonStyle;
}
/**
 * Variante de color con sus estados
 */
interface ColorVariant {
    default: string;
    light: string;
    dark: string;
    contrast: string;
}
/**
 * Escala de colores neutrales (50-900)
 */
interface NeutralColorScale {
    50: string;
    100: string;
    200: string;
    300: string;
    400: string;
    500: string;
    600: string;
    700: string;
    800: string;
    900: string;
}
/**
 * Colores de superficie (fondos)
 */
interface SurfaceColors {
    background: string;
    card: string;
    overlay: string;
}
/**
 * Paleta de colores completa del theme
 */
interface ThemeColorPalette {
    primary: ColorVariant;
    secondary: ColorVariant;
    accent: ColorVariant;
    neutral: NeutralColorScale;
    success: ColorVariant;
    warning: ColorVariant;
    error: ColorVariant;
    info: ColorVariant;
    surface: SurfaceColors;
}
/**
 * Estilo de tipografía predefinido
 */
interface TypographyStyle {
    size: string;
    weight: string;
    lineHeight: number;
    letterSpacing?: string;
}
/**
 * Estilos de tipografía disponibles
 */
interface ThemeTypographyStyles {
    display: TypographyStyle;
    'heading-1': TypographyStyle;
    'heading-2': TypographyStyle;
    'heading-3': TypographyStyle;
    'heading-4': TypographyStyle;
    'body-large': TypographyStyle;
    body: TypographyStyle;
    'body-small': TypographyStyle;
    caption: TypographyStyle;
    label: TypographyStyle;
}
/**
 * Escala de tamaños de tipografía
 */
interface ThemeTypographySizes {
    xs: string;
    sm: string;
    base: string;
    lg: string;
    xl: string;
    '2xl': string;
    '3xl': string;
    '4xl': string;
    '5xl': string;
}
/**
 * Fuentes del theme
 */
interface ThemeFonts {
    heading: string;
    body: string;
}
/**
 * Configuración completa de tipografía
 */
interface ThemeTypography {
    styles: ThemeTypographyStyles;
    sizes: ThemeTypographySizes;
    fonts: ThemeFonts;
}
/**
 * Estilo de variante de botón
 */
interface ThemeButtonVariant {
    background: string;
    text: string;
    border: string;
    hoverBackground: string;
    hoverText?: string;
    hoverBorder?: string;
}
/**
 * Tamaño de botón
 */
interface ThemeButtonSize {
    padding: string;
    fontSize: string;
    borderRadius: string;
}
/**
 * Variantes de botones disponibles
 */
interface ThemeButtonVariants {
    primary: ThemeButtonVariant;
    secondary: ThemeButtonVariant;
    outline: ThemeButtonVariant;
    ghost: ThemeButtonVariant;
    danger: ThemeButtonVariant;
    success: ThemeButtonVariant;
}
/**
 * Tamaños de botones disponibles
 */
interface ThemeButtonSizes {
    sm: ThemeButtonSize;
    md: ThemeButtonSize;
    lg: ThemeButtonSize;
}
/**
 * Configuración completa de botones
 */
interface ThemeButtons {
    variants: ThemeButtonVariants;
    sizes: ThemeButtonSizes;
}
/**
 * Escala de espaciado
 */
interface ThemeSpacing {
    none: string;
    xs: string;
    sm: string;
    md: string;
    lg: string;
    xl: string;
    '2xl': string;
    '3xl': string;
    '4xl': string;
}
/**
 * Escala de border radius
 */
interface ThemeBorderRadius {
    none: string;
    sm: string;
    md: string;
    lg: string;
    xl: string;
    '2xl': string;
    full: string;
}
/**
 * Escala de border width
 */
interface ThemeBorderWidth {
    none: string;
    thin: string;
    medium: string;
    thick: string;
}
/**
 * Configuración completa de bordes
 */
interface ThemeBorders {
    radius: ThemeBorderRadius;
    width: ThemeBorderWidth;
}
/**
 * Escala de sombras
 */
interface ThemeShadows {
    none: string;
    sm: string;
    md: string;
    lg: string;
    xl: string;
}
/**
 * Configuración de Product Cards
 */
interface ThemeProductCard {
    borderRadius: string;
    shadow: string;
    padding: string;
    imageAspectRatio: string;
    showBorder: boolean;
    borderColor: string;
    hoverEffect: string;
    titleSize: string;
    titleWeight: string;
    priceSize: string;
    priceWeight: string;
}
/**
 * Design Tokens completo
 */
interface DesignTokens {
    colors: ThemeColorPalette;
    typography: ThemeTypography;
    buttons: ThemeButtons;
    spacing: ThemeSpacing;
    borders: ThemeBorders;
    shadows: ThemeShadows;
    productCard: ThemeProductCard;
}
interface StoreCustomizationSeo {
    pageTitle: string;
    pageSlogan: string;
    pageDescription: string;
    pageKeywords: string;
    pageImageId?: string | null;
    pageImage?: Media | null;
    faviconId?: string | null;
    favicon?: Media | null;
}

/**
 * Store customization revision types
 * Historical snapshots and draft workspace for store_customization changes.
 */
declare enum StoreCustomizationRevisionSource {
    BUILDER = "builder",
    RESTORE = "restore",
    INITIAL = "initial",
    TEMPLATE = "template",
    SEO = "seo",
    CMS = "cms",
    PUBLISH = "publish"
}
declare enum StoreCustomizationRevisionStatus {
    DRAFT = "draft",
    ARCHIVED = "archived"
}
interface StoreCustomizationRevisionSummary {
    id: string;
    accountId: string;
    customizationId: string;
    version: number | null;
    source: StoreCustomizationRevisionSource;
    status: StoreCustomizationRevisionStatus;
    createdAt: Date;
}
interface StoreCustomizationRevisionSnapshot extends StoreCustomizationRevisionSummary {
    layout: unknown;
    pages: unknown;
    theme: unknown;
    seo: unknown | null;
}
interface StoreCustomizationDraftResponse {
    id: string;
    accountId: string;
    layout: unknown;
    pages: unknown;
    theme: unknown;
    seo: unknown | null;
    previewToken: string;
    previewUrl: string;
    hasUnpublishedChanges: boolean;
    updatedAt: Date;
    createdAt: Date;
}
interface PublishCustomizationDraftResponse {
    id: string;
    accountId: string;
    revisionVersion: number;
    hasUnpublishedChanges: boolean;
    updatedAt: Date;
}
interface StoreCustomizationPublishedCurrentSummary {
    updatedAt: Date;
    /** True when the builder draft already matches the live storefront. */
    matchesDraft: boolean;
}
interface StoreCustomizationRevisionListResponse {
    items: StoreCustomizationRevisionSummary[];
    total: number;
    publishedCurrent: StoreCustomizationPublishedCurrentSummary | null;
}

declare function createEmptyStoreCustomizationLayout(): StoreCustomizationLayout;
/** True when layout is legacy-only (`components[]` without zones). */
declare function isLegacyStoreCustomizationLayout(layout: unknown): boolean;
/**
 * Accepts only zoned layouts. Strips stray legacy `components` from the payload.
 * Returns null for legacy-only or invalid input (must not be persisted as-is).
 */
declare function sanitizeStoreCustomizationLayout(layout: unknown): StoreCustomizationLayout | null;
/**
 * Upgrades legacy `{ components[] }` from old DB rows or templates to zoned layout.
 * Use on read paths only — never persist the legacy shape again.
 */
declare function upgradeLegacyStoreCustomizationLayout(layout: unknown): StoreCustomizationLayout;
/** @deprecated Use sanitizeStoreCustomizationLayout (write) or upgradeLegacyStoreCustomizationLayout (read). */
declare function normalizeStoreCustomizationLayout(layout: unknown): StoreCustomizationLayout;
declare function resolveStoreCustomizationLayoutForRead(layout: unknown): StoreCustomizationLayout;
declare function resolveStoreCustomizationLayoutForWrite(layout: unknown): StoreCustomizationLayout | null;

/**
 * IntegrationDeliveryZone types
 * Define las zonas de entrega permitidas para cada integración de fulfillment provider.
 */
interface IntegrationDeliveryZone {
    id: string;
    integrationId: string;
    geoZoneId: string;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
    integration?: Integration;
    geoZone?: GeoZone;
}
declare enum IntegrationDeliveryZoneStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE"
}

interface ExchangeRate extends BaseEntity {
    id: string;
    baseCurrency: Currency;
    targetCurrency: Currency;
    rate: number;
    effectiveDate: Date;
    source: string;
    isLatest: boolean;
    metadata?: ExchangeRateMetadata;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}
interface ExchangeRateMetadata {
    provider?: string;
    sourceTimestamp?: Date;
    confidence?: number;
    [key: string]: any;
}
interface CreateExchangeRateDto {
    baseCurrency: Currency;
    targetCurrency: Currency;
    rate: number;
    effectiveDate?: Date;
    source: string;
    metadata?: ExchangeRateMetadata;
}
interface UpdateExchangeRateDto {
    rate?: number;
    effectiveDate?: Date;
    source?: string;
    isLatest?: boolean;
    metadata?: ExchangeRateMetadata;
}
interface ExchangeRateQueryDto {
    baseCurrency?: Currency;
    targetCurrency?: Currency;
    source?: string;
    isLatest?: boolean;
    effectiveDateFrom?: Date;
    effectiveDateTo?: Date;
    limit?: number;
    offset?: number;
}
interface ExchangeRateResponse {
    item: ExchangeRate;
}
interface ExchangeRateListResponse {
    items: ExchangeRate[];
    total: number;
}
interface CurrencyConversion {
    fromCurrency: Currency;
    toCurrency: Currency;
    amount: number;
    convertedAmount: number;
    rate: number;
    effectiveDate: Date;
    source: string;
}

/** Default sort for product listings on the storefront (query param `sort`). */
type ProductListSortId = 'name_asc' | 'name_desc' | 'price_asc' | 'price_desc';
interface WebPaymentMethodInfo {
    paymentMethodId: string;
    installments: number | null;
    installmentsText?: string;
    enabled?: boolean;
    order: number;
}
interface StoreSettings {
    id: string;
    accountId: string;
    showOutOfStockItems: boolean;
    allowBackorder: boolean;
    hasDelivery: boolean;
    priceFormatPattern?: string;
    /** Applied when the URL has no `sort` query param. */
    defaultProductListSort?: ProductListSortId | null;
    publicEmail?: string;
    publicPhone?: Phone | string;
    whatsapp?: Phone | string;
    instagram?: string;
    facebook?: string;
    address?: string;
    shippingPolicies?: {
        shortText: string;
        mediumText: string;
        fullContent: string;
    } | string;
    returnsPolicies?: {
        shortText: string;
        mediumText: string;
        fullContent: string;
    } | string;
    webPaymentMethodsInfo?: WebPaymentMethodInfo[];
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
}

/**
 * Entidad StoreTemplate
 * Templates predefinidos para el constructor de tiendas
 */

interface StoreTemplate {
    id: string;
    name: string;
    description?: string | null;
    image?: string | null;
    config: Partial<StoreCustomization>;
    mocks: StoreTemplateMocks;
    isActive: boolean;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
interface StoreTemplateMocks {
    products?: any[];
    categories?: any[];
    brands?: any[];
    [key: string]: any[] | undefined;
}
interface CreateStoreTemplateDTO {
    name: string;
    description?: string | null;
    image?: string | null;
    config: Partial<StoreCustomization>;
    mocks: StoreTemplateMocks;
}
interface UpdateStoreTemplateDTO {
    name?: string;
    description?: string | null;
    image?: string | null;
    config?: Partial<StoreCustomization>;
    mocks?: StoreTemplateMocks;
    isActive?: boolean;
}

/** Builder/system page IDs that stay stable across accounts (not store_page UUIDs). */
declare const SYSTEM_BUILDER_PAGE_IDS: ReadonlySet<string>;
/** Portable CMS page IDs in persisted store_template rows (avoid cross-account UUID leaks). */
declare const TPL_PAGE_PREFIX: "tpl-page:";
/**
 * Matches template path or web URL segment to a single canonical key (slug only, lowercase).
 * Example: "/Mi-Pagina/" -> "mi-pagina".
 */
declare function slugKeyFromCustomizationPath(path: string | undefined | null): string;
declare function isTplPortablePageId(id: string): boolean;
/** True when id is a probable store_page UUID (not system, not portable prefix). */
declare function isLikelyLegacyCmsPageUuid(id: string): boolean;
declare function remapPageReferenceIdsDeep(obj: unknown, idMap: ReadonlyMap<string, string>): void;
/**
 * Replaces CMS page IDs with portable `tpl-page:{slugKey}` IDs and rewires PAGE referenceIds (header, grids…).
 */
declare function normalizeTemplateConfigForPersist(config: Partial<Pick<StoreCustomization, 'layout' | 'pages' | 'theme'>>): Partial<Pick<StoreCustomization, "layout" | "pages" | "theme">>;
/** Local preview: remap portable UUIDs/refs to ids from the current customization `pages`. */
declare function remapPortableTemplateForLocalPreview<T extends Partial<Pick<StoreCustomization, 'layout' | 'pages' | 'theme'>>>(config: T, localCustomizationPages: Array<{
    id?: string;
    path?: string;
}>): T;

interface StoreComponentTemplate {
    id: string;
    componentType: string;
    name: string;
    description?: string;
    image?: string;
    config: Record<string, any>;
    isActive: boolean;
    createdAt: Date;
    updatedAt: Date;
}
interface CreateStoreComponentTemplateDTO {
    componentType: string;
    name: string;
    description?: string;
    image?: string;
    config: Record<string, any>;
    isActive?: boolean;
}
interface UpdateStoreComponentTemplateDTO {
    componentType?: string;
    name?: string;
    description?: string;
    image?: string;
    config?: Record<string, any>;
    isActive?: boolean;
}

/**
 * Traffic source types
 */
declare enum TrafficSource {
    DIRECT = "direct",
    ORGANIC = "organic",
    PAID = "paid",
    REFERRAL = "referral",
    SOCIAL = "social",
    EMAIL = "email",
    OTHER = "other"
}
/**
 * Device types
 */
declare enum DeviceType {
    DESKTOP = "desktop",
    MOBILE = "mobile",
    TABLET = "tablet"
}
/**
 * Page types for categorization
 */
declare enum PageType {
    HOME = "home",
    CATALOG = "catalog",
    PRODUCT = "product",
    CART = "cart",
    CHECKOUT = "checkout",
    ORDER_CONFIRMATION = "order_confirmation",
    PAGE = "page",
    SEARCH = "search",
    OTHER = "other"
}
/**
 * Event types for analytics tracking
 */
declare enum AnalyticsEventType {
    SESSION_START = "session_start",
    SESSION_END = "session_end",
    PAGE_VIEW = "page_view",
    PRODUCT_VIEW = "product_view",
    PRODUCT_LIST_VIEW = "product_list_view",
    PRODUCT_SEARCH = "product_search",
    SEARCH_SUGGESTION_CLICK = "search_suggestion_click",
    PRODUCT_SELECT = "product_select",
    PRODUCT_SHARE = "product_share",
    ADD_TO_CART = "add_to_cart",
    REMOVE_FROM_CART = "remove_from_cart",
    UPDATE_CART_QUANTITY = "update_cart_quantity",
    CART_ITEM_ADDED = "cart_item_added",
    CART_ITEM_REMOVED = "cart_item_removed",
    CART_ITEM_QUANTITY_UPDATED = "cart_item_quantity_updated",
    CHECKOUT_START = "checkout_start",
    CHECKOUT_STEP = "checkout_step",
    CHECKOUT_COMPLETE = "checkout_complete",
    CHECKOUT_VIEW = "checkout_view",
    CHECKOUT_ADD_CUSTOMER_INFO = "checkout_add_customer_info",
    CHECKOUT_ADD_PAYMENT_INFO = "checkout_add_payment_info",
    CHECKOUT_ADD_SHIPPING_INFO = "checkout_add_shipping_info",
    CHECKOUT_ADD_BILLING_INFO = "checkout_add_billing_info",
    CHECKOUT_CONFIRMED = "checkout_confirmed",
    PURCHASE = "purchase",
    CLICK = "click",
    SCROLL = "scroll"
}
/**
 * Funnel steps for sales funnel analysis
 */
declare enum FunnelStep {
    VISIT = "visit",
    PRODUCT_VIEW = "product_view",
    ADD_TO_CART = "add_to_cart",
    CHECKOUT_START = "checkout_start",
    CHECKOUT_COMPLETE = "checkout_complete",
    PURCHASE = "purchase"
}
/**
 * Analytics Session - Tracks a user visit session
 */
interface AnalyticsSession extends BaseEntityWithAccount {
    visitorId: string;
    cartId?: string;
    customerId?: string;
    startedAt: Date;
    endedAt?: Date;
    duration?: number;
    lastActivityAt: Date;
    source: TrafficSource;
    medium?: string;
    campaign?: string;
    content?: string;
    term?: string;
    referrer?: string;
    referrerDomain?: string;
    landingPage: string;
    exitPage?: string;
    pageviews: number;
    events: number;
    device: DeviceType;
    browser?: string;
    browserVersion?: string;
    os?: string;
    osVersion?: string;
    screenWidth?: number;
    screenHeight?: number;
    country?: string;
    region?: string;
    city?: string;
    isConverted: boolean;
    conversionValue: number;
    orderId?: string;
}
/**
 * Analytics Event - Individual user action
 */
interface AnalyticsEvent extends BaseEntityWithAccount {
    sessionId: string;
    visitorId: string;
    eventType: AnalyticsEventType;
    eventData?: Record<string, any>;
    pageUrl: string;
    pageTitle?: string;
    pageType?: PageType;
    productId?: string;
    productVariantId?: string;
    productSku?: string;
    categoryId?: string;
    cartId?: string;
    orderId?: string;
    value?: number;
    currency?: string;
    timestamp: Date;
}
/**
 * Analytics Pageview - Page view tracking
 */
interface AnalyticsPageview extends BaseEntityWithAccount {
    sessionId: string;
    visitorId: string;
    pageUrl: string;
    pageTitle?: string;
    pageType: PageType;
    referrerUrl?: string;
    timeOnPage?: number;
    scrollDepth?: number;
    timestamp: Date;
}
/**
 * Analytics Funnel Step - Aggregated funnel data
 */
interface AnalyticsFunnelStep extends BaseEntityWithAccount {
    date: Date;
    step: FunnelStep;
    count: number;
    uniqueVisitors: number;
    conversionFromPrevious?: number;
}
/**
 * DTO for creating/updating a session
 */
interface CreateAnalyticsSessionDto {
    visitorId: string;
    cartId?: string;
    customerId?: string;
    landingPage: string;
    source: TrafficSource;
    medium?: string;
    campaign?: string;
    content?: string;
    term?: string;
    referrer?: string;
    referrerDomain?: string;
    device: DeviceType;
    browser?: string;
    browserVersion?: string;
    os?: string;
    osVersion?: string;
    screenWidth?: number;
    screenHeight?: number;
}
/**
 * DTO for tracking an event
 */
interface TrackEventDto {
    sessionId: string;
    visitorId: string;
    eventType: AnalyticsEventType;
    eventData?: Record<string, any>;
    pageUrl: string;
    pageTitle?: string;
    pageType?: PageType;
    productId?: string;
    productVariantId?: string;
    productSku?: string;
    categoryId?: string;
    cartId?: string;
    orderId?: string;
    value?: number;
    currency?: string;
}
/**
 * DTO for tracking a pageview
 */
interface TrackPageviewDto {
    sessionId: string;
    visitorId: string;
    pageUrl: string;
    pageTitle?: string;
    pageType: PageType;
    referrerUrl?: string;
}
/**
 * DTO for session heartbeat (keep alive)
 */
interface SessionHeartbeatDto {
    sessionId: string;
    visitorId: string;
    currentPage?: string;
    scrollDepth?: number;
    timeOnPage?: number;
    pageviewId?: string;
}
/**
 * Real-time analytics data
 */
interface RealtimeAnalytics {
    activeVisitors: number;
    activeSessions: ActiveSession[];
    recentEvents: RecentEvent[];
    pageviewsLastHour: number;
    conversionsLastHour: number;
    revenueLastHour: number;
}
interface ActiveSession {
    sessionId: string;
    visitorId: string;
    currentPage: string;
    pageType: PageType;
    device: DeviceType;
    source: TrafficSource;
    startedAt: Date;
    pageviews: number;
}
interface RecentEvent {
    eventType: AnalyticsEventType;
    pageUrl: string;
    productName?: string;
    value?: number;
    timestamp: Date;
}
/**
 * Overview analytics for a period
 */
interface AnalyticsOverview {
    totalVisits: number;
    uniqueVisitors: number;
    newVisitors: number;
    returningVisitors: number;
    totalPageviews: number;
    avgSessionDuration: number;
    avgPagesPerSession: number;
    bounceRate: number;
    totalConversions: number;
    conversionRate: number;
    totalRevenue: number;
    avgOrderValue: number;
    visitsPop?: number;
    conversionsPop?: number;
    revenuePop?: number;
}
/**
 * Traffic sources breakdown
 */
interface TrafficSourcesData {
    sources: TrafficSourceItem[];
    total: number;
}
interface TrafficSourceItem {
    source: TrafficSource;
    visits: number;
    uniqueVisitors: number;
    conversions: number;
    conversionRate: number;
    revenue: number;
    percentage: number;
}
/**
 * Sales funnel data
 */
interface FunnelData {
    steps: FunnelStepData[];
    overallConversionRate: number;
}
interface FunnelStepData {
    step: FunnelStep;
    label: string;
    count: number;
    uniqueVisitors: number;
    conversionRate: number;
    dropoffRate: number;
}
/**
 * Campaign performance
 */
interface CampaignPerformance {
    campaigns: CampaignData[];
    total: {
        visits: number;
        conversions: number;
        revenue: number;
    };
}
interface CampaignData {
    campaign: string;
    source: string;
    medium: string;
    visits: number;
    uniqueVisitors: number;
    conversions: number;
    conversionRate: number;
    revenue: number;
    avgOrderValue: number;
}
/**
 * Top pages data
 */
interface TopPagesData {
    pages: PageData[];
}
interface PageData {
    pageUrl: string;
    pageTitle: string;
    pageType: PageType;
    views: number;
    uniqueViews: number;
    avgTimeOnPage: number;
    bounceRate: number;
    exitRate: number;
}
/**
 * Product analytics
 */
interface ProductAnalyticsData {
    products: ProductAnalyticsItem[];
}
interface ProductAnalyticsItem {
    productId: string;
    productName: string;
    sku: string;
    views: number;
    addToCarts: number;
    purchases: number;
    viewToCartRate: number;
    cartToPurchaseRate: number;
    revenue: number;
}
/**
 * Historical data point for charts
 */
interface HistoricalDataPoint {
    date: string;
    visits: number;
    uniqueVisitors: number;
    pageviews: number;
    conversions: number;
    revenue: number;
}
/**
 * Query parameters for analytics endpoints
 */
interface AnalyticsQueryParams {
    startDate: string;
    endDate: string;
    compareWithPrevious?: boolean;
    source?: TrafficSource;
    device?: DeviceType;
    campaign?: string;
}
/**
 * Pagination for analytics lists
 */
interface AnalyticsPagination {
    page: number;
    limit: number;
    total: number;
}

/**
 * RBAC (Role-Based Access Control) Types
 */
interface Permission {
    id: string;
    key: string;
    description?: string;
    groupName?: string;
    createdAt: Date | string;
    updatedAt: Date | string;
}
interface Role {
    id: string;
    accountId: string | null;
    name: string;
    description?: string;
    permissions?: Permission[];
    createdAt: Date | string;
    updatedAt: Date | string;
    deletedAt?: Date | string | null;
}
interface RolePermissionLink {
    roleId: string;
    permissionId: string;
    accountId: string;
}
interface AccountUserRoleLink {
    accountUserId: string;
    roleId: string;
    accountId: string;
}
interface CreateRoleDTO {
    name: string;
    description?: string;
    permissionIds: string[];
}
interface UpdateRoleDTO {
    name?: string;
    description?: string;
    permissionIds?: string[];
}

declare enum InternalNotificationType {
    ORDER_PLACED_SELLER = "ORDER_PLACED_SELLER",
    CONTACT_FORM_SUBMITTED = "CONTACT_FORM_SUBMITTED",
    ABANDONED_CART = "ABANDONED_CART",
    ORDER_PENDING_PAYMENT = "ORDER_PENDING_PAYMENT"
}
interface CustomerNotificationConfig {
    delayHours?: number;
}
interface InternalNotificationConfig {
    id: string;
    accountId: string;
    notificationType: InternalNotificationType;
    enabled: boolean;
    recipientUserIds: string[] | null;
    recipientEmails: string[] | null;
    config: CustomerNotificationConfig | null;
    createdAt: Date;
    updatedAt: Date;
}
interface UpdateNotificationSettingsDTO {
    enabled?: boolean;
    recipientUserIds?: string[];
    recipientEmails?: string[];
    delayHours?: number;
}

/** Catalog price row and contract term: amount is the total for this period (e.g. full year for ANNUAL). */
declare enum BillingInterval {
    MONTHLY = "MONTHLY",
    SEMIANNUAL = "SEMIANNUAL",
    ANNUAL = "ANNUAL"
}
/** How often a subscription charge is generated (may split the contract total into installments). */
declare enum PaymentFrequency {
    MONTHLY = "MONTHLY",
    QUARTERLY = "QUARTERLY",
    SEMIANNUAL = "SEMIANNUAL",
    ANNUAL = "ANNUAL"
}
/** Single item in a spec category (display-like structure). */
interface ServiceBillingPlanSpecItem {
    key: string;
    label: string;
}
/** Category for the plan comparison table (display only). */
interface ServiceBillingPlanSpecCategory {
    id: string;
    label: string;
    /** Keys to show. Legacy when items is set. */
    itemKeys?: string[];
    /** Display-like: each item has key and label. When set, used instead of itemKeys + labels. */
    items?: ServiceBillingPlanSpecItem[];
}
/** Defines comparison table: structure and optional values. Stored in service_billing_plan.specs. */
interface ServiceBillingPlanSpec {
    categories: ServiceBillingPlanSpecCategory[];
    /** Map key -> label. Used when category uses itemKeys (legacy). */
    labels?: Record<string, string>;
    /** Values for this plan; when set, used for comparison instead of limits. */
    values?: Record<string, unknown>;
}
interface ServiceBillingPlanLimits {
    maxProducts?: number | null;
    maxBranches?: number | null;
    maxAccountUsers?: number | null;
    maxProductCategories?: number | null;
    maxDeliveryOptions?: number | null;
    maxIntegrations?: number | null;
    maxStorageMb?: number | null;
    customDomainAllowed?: boolean;
    bulkImportAllowed?: boolean;
    maxBulkImportRows?: number | null;
    advancedAnalytics?: boolean;
    maxOrdersPerMonth?: number | null;
    /** Soporte: "Estándar" | "Prioritario" | "Dedicado" */
    supportLevel?: string | null;
    marketingIncluded?: boolean;
    customApiIntegrations?: boolean;
    storeCustomization?: boolean;
    customEmail?: boolean;
    /** Maximum number of mailboxes (email accounts) the account can create. */
    maxMailboxes?: number | null;
    reportsAndExport?: boolean;
    multiCurrency?: boolean;
    webhooks?: boolean;
    eInvoicing?: boolean;
    trainingOnboarding?: boolean;
    whiteLabel?: boolean;
}
interface ServiceBillingPlan {
    id: string;
    name: string;
    slug: string;
    currency: string;
    description?: string | null;
    order: number;
    /** Enforced and display values (maxProducts, maxBranches, feature flags, etc.). */
    limits?: ServiceBillingPlanLimits | null;
    /** Optional: comparison table structure (categories, order, labels). If null, backoffice uses default. */
    specs?: ServiceBillingPlanSpec | null;
    createdAt: Date;
    updatedAt: Date;
}
interface ServiceBillingPlanPrice {
    id: string;
    serviceBillingPlanId: string;
    /** Contract / pricing period this row applies to (matches account assignment contract term). */
    billingInterval: BillingInterval;
    amount: number;
    aiImageCreditsIncluded: number;
    aiTextCreditsIncluded: number;
    createdAt: Date;
    updatedAt: Date;
}
declare enum AccountServicePlanStatus {
    ACTIVE = "ACTIVE",
    ENDED = "ENDED",
    CANCELLED = "CANCELLED"
}
interface AccountServicePlan {
    id: string;
    accountId: string;
    serviceBillingPlanId: string;
    status: AccountServicePlanStatus;
    customAmount?: number | null;
    /** Contract term; selects `service_billing_plan_price` row (catalog total for this term). */
    billingInterval?: BillingInterval | null;
    /** Charge cadence; installments divide the contract catalog/custom total. Null = same as billingInterval (legacy). */
    paymentFrequency?: PaymentFrequency | null;
    /** Optional one-time fee; generates an INSTALLATION charge when the job runs. */
    installationFee?: number | null;
    /** First day of the first billable subscription period; installation fee is also anchored to this date. */
    startedAt: Date;
    endedAt?: Date | null;
    notes?: string | null;
    createdAt: Date;
    updatedAt: Date;
    serviceBillingPlan?: ServiceBillingPlan;
    prices?: ServiceBillingPlanPrice[];
}
declare enum ChargeType {
    SUBSCRIPTION = "SUBSCRIPTION",
    INSTALLATION = "INSTALLATION",
    ADJUSTMENT = "ADJUSTMENT",
    OTHER = "OTHER"
}
declare enum ChargeStatus {
    PENDING = "PENDING",
    PAID = "PAID",
    CANCELLED = "CANCELLED"
}
/** Sociedad que recibió el pago del comercio (cobro en caja propia). No es el vendedor. */
declare enum BillingSociety {
    COBRATICKET = "COBRATICKET",
    RHINO = "RHINO"
}
interface AccountServiceBillingCharge {
    id: string;
    accountId: string;
    accountServicePlanId?: string | null;
    amount: number;
    currency: string;
    type: ChargeType;
    /** For SUBSCRIPTION: length of the billed period (payment frequency), e.g. MONTHLY or QUARTERLY. */
    billingInterval?: BillingInterval | PaymentFrequency | null;
    periodStart?: Date | null;
    periodEnd?: Date | null;
    dueDate?: Date | null;
    paidAt?: Date | null;
    status: ChargeStatus;
    externalReference?: string | null;
    description?: string | null;
    /** Public URL of invoice/receipt PDF or image (e.g. Gestión upload to GCS). */
    invoiceUrl?: string | null;
    /** Set when status is PAID: which society collected the payment. */
    collectedBySociety?: BillingSociety | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}

declare function contractTermMonths(contract: BillingInterval): number;
declare function paymentFrequencyMonths(freq: PaymentFrequency): number;
/**
 * Number of subscription charges in one full contract term, or null if incompatible
 * (e.g. quarterly billing on a 1-month contract).
 */
declare function subscriptionInstallmentCount(contract: BillingInterval, payment: PaymentFrequency): number | null;
declare function resolveEffectivePaymentFrequency(contract: BillingInterval, paymentFrequency: PaymentFrequency | null | undefined): PaymentFrequency;
/** Per-charge amount from the contract-period total (catalog or custom). */
declare function subscriptionAmountPerInstallment(contractTotalAmount: number, contract: BillingInterval, payment: PaymentFrequency): number | null;
/** IA credits to grant per subscription charge (proportional to installments). */
declare function aiCreditsPerSubscriptionInstallment(creditsIncludedPerContract: number, contract: BillingInterval, payment: PaymentFrequency): number;

declare enum HolidayType {
    /** Business is expected to be closed. Default: excluded from delivery calculation. */
    NON_WORKING = "NON_WORKING",
    /** Business may choose to work. Default: included in delivery calculation. */
    WORKING = "WORKING"
}
interface Holiday {
    id: string;
    /** ISO date string "YYYY-MM-DD" */
    date: string;
    /** ISO 3166-1 alpha-2 country code (e.g. "UY", "AR") */
    country: string;
    name: string;
    type: HolidayType;
    createdAt: Date;
    updatedAt: Date;
}
interface AccountHolidaySchedule {
    id: string;
    accountId: string;
    holidayId: string;
    /** Whether the account will operate on this holiday */
    isOpen: boolean;
    respondedAt: Date;
    /** Tracks whether a reminder has already been sent */
    reminderSentAt?: Date | null;
    createdAt: Date;
    updatedAt: Date;
}

/** Ordered pipeline stages for Kanban (fixed funnel v1). */
declare const LEAD_DEAL_STAGE_ORDER: readonly ["NEW", "CONTACTED", "QUALIFIED", "DEMO_SCHEDULED", "TRIAL", "PROPOSAL", "NEGOTIATION", "WON", "LOST"];
type LeadDealStage = (typeof LEAD_DEAL_STAGE_ORDER)[number];
declare const LEAD_DEAL_STAGES: readonly LeadDealStage[];
declare function isLeadDealStage(value: string): value is LeadDealStage;
type LeadActivityType = 'NOTE' | 'CALL' | 'EMAIL' | 'MEETING' | 'STAGE_CHANGE' | 'ASSIGNMENT_CHANGE';
type LeadLostReason = 'PRICE' | 'TIMING' | 'COMPETITOR' | 'NO_FIT' | 'NO_RESPONSE' | 'OTHER';
type LeadPriority = 'LOW' | 'MEDIUM' | 'HIGH';
type LeadSource = 'WEB' | 'REFERRAL' | 'OUTBOUND' | 'PARTNER' | 'OTHER';
interface Lead {
    id: string;
    name: string;
    company: string;
    email: string;
    phone: string;
    message: string;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date;
    /** CRM pipeline stage (DB default NEW). */
    dealStage?: LeadDealStage;
    /** Retail `seller` (comisionista), not gestión interna. */
    assignedSellerId?: string | null;
    leadSource?: LeadSource | string | null;
    estimatedValue?: number | null;
    estimatedValueCurrency?: string | null;
    expectedCloseAt?: Date | null;
    nextFollowUpAt?: Date | null;
    priority?: LeadPriority | string | null;
    convertedAccountId?: string | null;
    lostReason?: string | null;
}
/** Payload to create a lead (e.g. from landing form). */
interface CreateLeadDTO {
    name: string;
    company: string;
    email: string;
    phone: string;
    message: string;
}
interface UpdateLeadDTO {
    dealStage?: LeadDealStage;
    /** Retail `seller` (comisionista), not gestión interna. */
    assignedSellerId?: string | null;
    leadSource?: LeadSource | string | null;
    estimatedValue?: number | null;
    estimatedValueCurrency?: string | null;
    expectedCloseAt?: string | null;
    nextFollowUpAt?: string | null;
    priority?: LeadPriority | string | null;
    convertedAccountId?: string | null;
    lostReason?: string | null;
}
interface CreateLeadActivityDTO {
    type: LeadActivityType;
    body?: string | null;
    metadata?: Record<string, unknown> | null;
}
interface LeadActivity {
    id: string;
    leadId: string;
    type: LeadActivityType;
    body: string | null;
    metadata: Record<string, unknown> | null;
    createdByGestionUserId: string | null;
    createdByName?: string | null;
    createdAt: Date;
    updatedAt: Date;
}
type LeadCrmDashboardSummary = {
    total: number;
    byStage: Record<LeadDealStage, number>;
    followUpOverdue: number;
};

declare enum GestionUserRole {
    OWNER = "OWNER",
    ADMIN = "ADMIN",
    ANALYST = "ANALYST"
}
declare enum GestionUserStatus {
    ACTIVE = "ACTIVE",
    INACTIVE = "INACTIVE",
    LOCKED = "LOCKED"
}
interface GestionUser {
    id: string;
    email: string;
    passwordHash?: string;
    name: string;
    role: GestionUserRole;
    status: GestionUserStatus;
    lastLoginAt?: Date | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}

interface GestionSession {
    id: string;
    gestionUserId: string;
    tokenHash: string;
    expiresAt: Date;
    lastSeenAt?: Date | null;
    ip?: string | null;
    userAgent?: string | null;
    revokedAt?: Date | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}

interface GestionLoginAttempt {
    id: string;
    email: string;
    ip?: string | null;
    userAgent?: string | null;
    createdAt: Date;
}

type ChatbotSourceType = 'products' | 'categories' | 'policies' | 'customFaq' | 'orderStatus';
interface ChatbotSource {
    id: string;
    accountId: string;
    sourceType: ChatbotSourceType;
    enabled: boolean;
    /** Parsed JSON; e.g. custom FAQ entries */
    config: Record<string, unknown> | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
interface ChatbotSettings {
    id: string;
    accountId: string;
    enabled: boolean;
    displayName: string | null;
    welcomeMessage: string | null;
    /** Stored tone id (see `ChatbotToneId` in `./tone`). */
    tone: string | null;
    handoffEnabled: boolean;
    /** When true, the public widget may call the LLM after each shopper message (if conversation is not paused). */
    aiAutoReplyEnabled: boolean;
    /** Free-form notes from the merchant; injected into the model baseline when set. */
    additionalContext: string | null;
    createdAt: Date;
    updatedAt: Date;
    deletedAt?: Date | null;
}
interface ChatbotSettingsWithSources extends ChatbotSettings {
    sources: Pick<ChatbotSource, 'sourceType' | 'enabled' | 'config'>[];
}
/** Public bootstrap payload (no internal ids). */
interface ChatbotPublicBootstrap {
    enabled: boolean;
    displayName: string | null;
    welcomeMessage: string | null;
    handoffEnabled: boolean;
    aiAutoReplyEnabled: boolean;
}

declare const CHATBOT_TONE_IDS: readonly ["professional", "friendly", "concise", "enthusiastic", "formal", "casual"];
type ChatbotToneId = (typeof CHATBOT_TONE_IDS)[number];
declare const DEFAULT_CHATBOT_TONE: ChatbotToneId;
declare function isChatbotToneId(value: string): value is ChatbotToneId;

export { type Account, type AccountAiCreditTransaction, type AccountAiCredits, type AccountBillingProfile, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountCurrencyConfig, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, type AccountDeliveryOptionRule, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountEmailDomain, AccountEmailDomainStatus, type AccountExchangeRate, type AccountExchangeRateListResponse, type AccountExchangeRateMetadata, type AccountExchangeRateQueryDto, type AccountExchangeRateResponse, AccountExchangeRateType, type AccountExchangeRateWithEffectiveRate, type AccountHolidaySchedule, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountMailbox, type AccountOnboardingJob, type AccountOnboardingJobStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, type AccountServiceBillingCharge, type AccountServicePlan, AccountServicePlanStatus, AccountStatus, type AccountUserRoleLink, type ActiveSession, type Address, type AdminOrderStatusChangeDto, AiCreditSource, AiCreditTransactionReason, AiCreditType, type AiCreditsBalance, type AnalyticsEvent, AnalyticsEventType, type AnalyticsFunnelStep, type AnalyticsOverview, type AnalyticsPageview, type AnalyticsPagination, type AnalyticsQueryParams, type AnalyticsSession, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, BillingInterval, BillingSociety, type BufferSafetyMarginParams, type BusinessDaysParams, type ButtonStyle, CHATBOT_TONE_IDS, COUNTRY_DEFAULTS, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, type CampaignData, type CampaignPerformance, CampaignStatus, type Cart, type CartConfirmDto, type CartDeliveryMethod, type CartDeliveryMethodAdjustment, type CartDeliveryMethodCreateData, type CartDeliveryMethodCreateDto, type CartDeliveryMethodFindParams, type CartDeliveryMethodResponse, type CartDeliveryMethodUpdateData, type CartDeliveryMethodUpdateDto, CartDeliveryType, type CartItem, type CartItemAddDto, type CartItemAttributeDetail, CartItemErrorCode, type CartItemRemoveDto, type CartItemUpdateDto, type CartItemValidation, type CartLineItemAdjustment, type CartPromotion, CartSource, CartStatus, type CartUpdateDto, type ChargeSellerAllocation, ChargeStatus, ChargeType, type ChatbotPublicBootstrap, type ChatbotSettings, type ChatbotSettingsWithSources, type ChatbotSource, type ChatbotSourceType, type ChatbotToneId, type Collection, type CollectionMedia, type CollectionProductLink, type CollectionRule, CollectionRuleField, CollectionRuleFieldLabels, CollectionRuleOperator, CollectionRuleOperatorLabels, CollectionRulesLogic, CollectionStatus, CollectionStatusLabels, CollectionType, CollectionTypeLabels, type ColorVariant, type CountryDefaultBranchAddress, type CountryDefaultConfig, type CountryDefaultTax, type CreateAccountDeliveryOptionDTO, type CreateAccountExchangeRateDto, type CreateAnalyticsSessionDto, type CreateCollectionDTO, type CreateDeliveryOptionDto, type CreateDeliveryOptionRuleDTO, type CreateExchangeRateDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreateLeadActivityDTO, type CreateLeadDTO, type CreatePromotionDTO, type CreateRoleDTO, type CreateSizeGuideDTO, type CreateStoreComponentTemplateDTO, type CreateStoreTemplateDTO, Currency, type CurrencyConversion, type Customer, type CustomerNotificationConfig, CustomerStatus, type CustomerUpsertDto, DEFAULT_CHATBOT_TONE, DayOfWeek, type DeliveryDaysParams, type DeliveryHoursParams, DeliveryOptionRuleType, DeliveryType, type DeliveryZoneInput, type DesignTokens, DeviceType, DisplayOrderStatus, type EffectiveExchangeRate, type ExchangeRate, type ExchangeRateListResponse, type ExchangeRateMetadata, type ExchangeRateQueryDto, type ExchangeRateResponse, type FixedOffsetDaysParams, type Fulfillment, type FulfillmentDeliveryOption, type FulfillmentItem, type FulfillmentLabel, type FulfillmentLabelCreateData, type FulfillmentLabelUpdateData, type FulfillmentProviderAdapter, type FulfillmentProviderContext, type FulfillmentProviderCreateInput, type FulfillmentProviderCreateOutput, type FulfillmentProviderKey, type FulfillmentProviderProcessWebhookInput, type FulfillmentProviderProcessWebhookOutput, type FulfillmentRecollectionCapabilities, type FulfillmentRecollectionConfig, type FulfillmentRecollectionMode, type FulfillmentRecollectionSchedule, FulfillmentStatus, type FulfillmentTrackingEvent, type FunnelData, FunnelStep, type FunnelStepData, type GeoZone, type GeoZoneInput, GeoZoneStatus, type GestionLoginAttempt, type GestionSession, type GestionUser, GestionUserRole, GestionUserStatus, type HistoricalDataPoint, type Holiday, HolidayType, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type InternalNotificationConfig, InternalNotificationType, LEAD_DEAL_STAGES, LEAD_DEAL_STAGE_ORDER, type Lead, type LeadActivity, type LeadActivityType, type LeadCrmDashboardSummary, type LeadDealStage, type LeadLostReason, type LeadPriority, type LeadSource, type LinkButtonStyle, type MapPosition, type Media, MediaType, NavigationItemType, type NavigationMenuConfig, type NavigationMenuItem, type NeutralColorScale, type NextStatusAction, type Order, type OrderAppliedPromotion, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type PageData, PageType, type Payment, type PaymentCardBrand, PaymentCardBrandKey, type PaymentConversion, PaymentFrequency, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Permission, type Phone, type PickupLocation, type PickupReadyHoursParams, type ProcessingDaysParams, type Product, type ProductAnalyticsData, type ProductAnalyticsItem, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, type ProductListSortId, type ProductSizeGuidePayload, ProductStatus, ProductType, type ProductVariant, ProductVariantStatus, type Promotion, type PromotionApplicationMethod, type PromotionApplicationMethodInput, type PromotionApplicationMethodPromotionRule, PromotionApplicationType, type PromotionListFilters, type PromotionPromotionRule, type PromotionRule, type PromotionRuleInput, PromotionRuleOperator, type PromotionRuleValue, PromotionStatus, PromotionTargetType, PromotionType, PubSubTopics, type PublishCustomizationDraftResponse, type RealtimeAnalytics, type RecentEvent, type Role, type RolePermissionLink, type RoundingConfig, RoundingMethod, RoundingRule, SUPPORTED_COUNTRIES, SYSTEM_BUILDER_PAGE_IDS, type SameDayCutoffParams, type Seller, type SellerPeriodBalance, type ServiceBillingPlan, type ServiceBillingPlanLimits, type ServiceBillingPlanPrice, type ServiceBillingPlanSpec, type ServiceBillingPlanSpecCategory, type ServiceBillingPlanSpecItem, type SessionHeartbeatDto, type SizeGuide, type SizeGuideCategoryAssignment, type SizeGuideCategoryRule, type SizeGuideCategoryRuleInput, type SizeGuideDetail, SizeGuideStatus, type SizeGuideTableColumn, type SizeGuideTableJson, type SizeGuideTableRow, SizeGuideUnitBase, SizeGuideUnitDisplayPolicy, type StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreComponentTemplate, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationDraftResponse, type StoreCustomizationFooterZone, type StoreCustomizationHeaderZone, type StoreCustomizationLayout, type StoreCustomizationLayoutComponent, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationPublishedCurrentSummary, type StoreCustomizationRevisionListResponse, type StoreCustomizationRevisionSnapshot, StoreCustomizationRevisionSource, StoreCustomizationRevisionStatus, type StoreCustomizationRevisionSummary, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type StoreSettings, type StoreTemplate, type StoreTemplateMocks, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type SupportedCountryCode, type SupportedPaymentMethodIconRow, type SurfaceColors, TPL_PAGE_PREFIX, type ThemeBorderRadius, type ThemeBorderWidth, type ThemeBorders, type ThemeButtonSize, type ThemeButtonSizes, type ThemeButtonVariant, type ThemeButtonVariants, type ThemeButtons, type ThemeColorPalette, type ThemeConfig, type ThemeFonts, type ThemeProductCard, type ThemeShadows, type ThemeSpacing, type ThemeTypography, type ThemeTypographySizes, type ThemeTypographyStyles, type TopPagesData, type TrackEventDto, type TrackPageviewDto, TrafficSource, type TrafficSourceItem, type TrafficSourcesData, type TypographyStyle, type UnifiedDeliveryConfig, type UpdateAccountDeliveryOptionDTO, type UpdateAccountExchangeRateAllDto, type UpdateAccountExchangeRateDto, type UpdateCollectionDTO, type UpdateDeliveryOptionRuleDTO, type UpdateExchangeRateDto, type UpdateFulfillmentDto, type UpdateLeadDTO, type UpdateNotificationSettingsDTO, type UpdatePromotionDTO, type UpdateRoleDTO, type UpdateSizeGuideDTO, type UpdateStoreComponentTemplateDTO, type UpdateStoreTemplateDTO, type WebPaymentMethodInfo, type Webhook, type WebhookPayload, aiCreditsPerSubscriptionInstallment, contractTermMonths, createEmptyStoreCustomizationLayout, flattenSupportedPaymentMethodsFromAccountIntegrations, getAccountPaymentMethodStatusInfo, getCountryDefaults, getCurrencySymbol, getDisplayOrderStatus, getDisplayOrderStatusInfo, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, isChatbotToneId, isLeadDealStage, isLegacyStoreCustomizationLayout, isLikelyLegacyCmsPageUuid, isSupportedCountry, isTplPortablePageId, isZonedLayout, normalizeStoreCustomizationLayout, normalizeTemplateConfigForPersist, parseIntegrationSupportedPaymentMethodsArray, parsePriceFormatPattern, paymentFrequencyMonths, remapPageReferenceIdsDeep, remapPortableTemplateForLocalPreview, resolveChargeCurrency, resolveEffectivePaymentFrequency, resolveStoreCustomizationLayoutForRead, resolveStoreCustomizationLayoutForWrite, sanitizeStoreCustomizationLayout, slugKeyFromCustomizationPath, subscriptionAmountPerInstallment, subscriptionInstallmentCount, upgradeLegacyStoreCustomizationLayout };
