@retaila/shared-types 1.1.85 → 1.1.89

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -694,6 +694,13 @@ declare enum PaymentMethodType {
694
694
  CASH = "CASH",
695
695
  OTHER = "OTHER"
696
696
  }
697
+ interface PaymentConversion {
698
+ fromCurrency: Currency;
699
+ toCurrency: Currency;
700
+ rate: number;
701
+ originalAmount: number;
702
+ finalAmount: number;
703
+ }
697
704
  interface Payment {
698
705
  id: string;
699
706
  accountId: string;
@@ -715,6 +722,7 @@ interface Payment {
715
722
  cardBrandInfo?: PaymentCardBrand;
716
723
  cardLast4?: string;
717
724
  data?: Record<string, any>;
725
+ conversion?: PaymentConversion;
718
726
  metadata?: Record<string, any>;
719
727
  internalComment?: string;
720
728
  demo: boolean;
@@ -723,6 +731,12 @@ interface Payment {
723
731
  deletedAt?: string | Date;
724
732
  accountPaymentMethod?: Partial<AccountPaymentMethod> | null;
725
733
  order?: Order;
734
+ allowedActions?: {
735
+ canCopyLink: boolean;
736
+ canMarkAsPaid: boolean;
737
+ canRecapture: boolean;
738
+ canRefund: boolean;
739
+ };
726
740
  }
727
741
  type PaymentProviderKey = 'MERCADOPAGO' | 'PLEXO' | 'MANUAL_PAYMENT';
728
742
  interface PaymentProviderContext {
@@ -1975,4 +1989,173 @@ declare enum IntegrationDeliveryZoneStatus {
1975
1989
  INACTIVE = "INACTIVE"
1976
1990
  }
1977
1991
 
1978
- export { type Account, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, AccountStatus, type Address, type AdminOrderStatusChangeDto, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, type ButtonStyle, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, 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 CreateAccountDeliveryOptionDTO, type CreateDeliveryOptionDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, Currency, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, 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 GeoZone, type GeoZoneInput, GeoZoneStatus, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type MapPosition, type Media, MediaType, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type Payment, type PaymentCardBrand, PaymentCardBrandKey, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Phone, type PickupLocation, type Product, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, 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 StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationLayoutComponent, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type ThemeConfig, type UpdateAccountDeliveryOptionDTO, type UpdateFulfillmentDto, type UpdatePromotionDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCurrencySymbol, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, parsePriceFormatPattern };
1992
+ interface ExchangeRate extends BaseEntity {
1993
+ id: string;
1994
+ baseCurrency: Currency;
1995
+ targetCurrency: Currency;
1996
+ rate: number;
1997
+ effectiveDate: Date;
1998
+ source: string;
1999
+ isLatest: boolean;
2000
+ metadata?: ExchangeRateMetadata;
2001
+ createdAt: Date;
2002
+ updatedAt: Date;
2003
+ deletedAt?: Date;
2004
+ }
2005
+ interface ExchangeRateMetadata {
2006
+ provider?: string;
2007
+ sourceTimestamp?: Date;
2008
+ confidence?: number;
2009
+ [key: string]: any;
2010
+ }
2011
+ interface CreateExchangeRateDto {
2012
+ baseCurrency: Currency;
2013
+ targetCurrency: Currency;
2014
+ rate: number;
2015
+ effectiveDate?: Date;
2016
+ source: string;
2017
+ metadata?: ExchangeRateMetadata;
2018
+ }
2019
+ interface UpdateExchangeRateDto {
2020
+ rate?: number;
2021
+ effectiveDate?: Date;
2022
+ source?: string;
2023
+ isLatest?: boolean;
2024
+ metadata?: ExchangeRateMetadata;
2025
+ }
2026
+ interface ExchangeRateQueryDto {
2027
+ baseCurrency?: Currency;
2028
+ targetCurrency?: Currency;
2029
+ source?: string;
2030
+ isLatest?: boolean;
2031
+ effectiveDateFrom?: Date;
2032
+ effectiveDateTo?: Date;
2033
+ limit?: number;
2034
+ offset?: number;
2035
+ }
2036
+ interface ExchangeRateResponse {
2037
+ item: ExchangeRate;
2038
+ }
2039
+ interface ExchangeRateListResponse {
2040
+ items: ExchangeRate[];
2041
+ total: number;
2042
+ }
2043
+ interface CurrencyConversion {
2044
+ fromCurrency: Currency;
2045
+ toCurrency: Currency;
2046
+ amount: number;
2047
+ convertedAmount: number;
2048
+ rate: number;
2049
+ effectiveDate: Date;
2050
+ source: string;
2051
+ }
2052
+
2053
+ interface AccountExchangeRate extends BaseEntityWithAccount {
2054
+ id: string;
2055
+ accountId: string;
2056
+ baseCurrency: Currency;
2057
+ targetCurrency: Currency;
2058
+ configurationType: AccountExchangeRateType;
2059
+ manualRate?: number;
2060
+ adjustmentPercentage?: number;
2061
+ roundingConfig?: RoundingConfig;
2062
+ isActive: boolean;
2063
+ lastManualUpdate?: Date;
2064
+ metadata?: AccountExchangeRateMetadata;
2065
+ createdAt: Date;
2066
+ updatedAt: Date;
2067
+ deletedAt?: Date;
2068
+ }
2069
+ declare enum AccountExchangeRateType {
2070
+ AUTOMATIC = "AUTOMATIC",
2071
+ AUTOMATIC_WITH_ADJUSTMENT = "AUTOMATIC_WITH_ADJUSTMENT",
2072
+ MANUAL = "MANUAL"
2073
+ }
2074
+ interface RoundingConfig {
2075
+ method: RoundingMethod;
2076
+ decimalPlaces: number;
2077
+ roundingRule?: RoundingRule;
2078
+ }
2079
+ declare enum RoundingMethod {
2080
+ ROUND = "ROUND",
2081
+ CEIL = "CEIL",
2082
+ FLOOR = "FLOOR",
2083
+ BANKERS = "BANKERS"
2084
+ }
2085
+ declare enum RoundingRule {
2086
+ ROUND_TO_5_CENTS = "ROUND_TO_5_CENTS",
2087
+ ROUND_TO_10_CENTS = "ROUND_TO_10_CENTS",
2088
+ NONE = "NONE"
2089
+ }
2090
+ interface AccountExchangeRateMetadata {
2091
+ description?: string;
2092
+ notes?: string;
2093
+ [key: string]: any;
2094
+ }
2095
+ interface CreateAccountExchangeRateDto {
2096
+ baseCurrency: Currency;
2097
+ targetCurrency: Currency;
2098
+ configurationType: AccountExchangeRateType;
2099
+ manualRate?: number;
2100
+ adjustmentPercentage?: number;
2101
+ roundingConfig?: RoundingConfig;
2102
+ metadata?: AccountExchangeRateMetadata;
2103
+ }
2104
+ interface UpdateAccountExchangeRateDto {
2105
+ configurationType?: AccountExchangeRateType;
2106
+ manualRate?: number;
2107
+ adjustmentPercentage?: number;
2108
+ roundingConfig?: RoundingConfig;
2109
+ isActive?: boolean;
2110
+ metadata?: AccountExchangeRateMetadata;
2111
+ }
2112
+ interface AccountExchangeRateQueryDto {
2113
+ baseCurrency?: Currency;
2114
+ targetCurrency?: Currency;
2115
+ configurationType?: AccountExchangeRateType;
2116
+ isActive?: boolean;
2117
+ limit?: number;
2118
+ offset?: number;
2119
+ }
2120
+ interface AccountExchangeRateResponse {
2121
+ item: AccountExchangeRate;
2122
+ }
2123
+ interface UpdateAccountExchangeRateAllDto {
2124
+ globalConfig?: any;
2125
+ rates: Array<{
2126
+ id?: string;
2127
+ targetCurrency: Currency;
2128
+ configurationType: AccountExchangeRateType;
2129
+ manualRate?: number;
2130
+ adjustmentPercentage?: number;
2131
+ roundingConfig?: RoundingConfig;
2132
+ }>;
2133
+ }
2134
+ interface AccountExchangeRateListResponse {
2135
+ storeCurrency: Currency;
2136
+ paymentCurrencies: Currency[];
2137
+ rates: AccountExchangeRateWithEffectiveRate[];
2138
+ }
2139
+ interface AccountExchangeRateWithEffectiveRate extends AccountExchangeRate {
2140
+ effectiveRate: number;
2141
+ baseGlobalRate: number;
2142
+ source: string;
2143
+ effectiveDate: Date;
2144
+ }
2145
+ interface AccountCurrencyConfig {
2146
+ accountId: string;
2147
+ primaryCurrency: Currency;
2148
+ exchangeRates: AccountExchangeRate[];
2149
+ effectiveRates: EffectiveExchangeRate[];
2150
+ }
2151
+ interface EffectiveExchangeRate {
2152
+ baseCurrency: Currency;
2153
+ targetCurrency: Currency;
2154
+ effectiveRate: number;
2155
+ baseGlobalRate: number;
2156
+ configurationType: AccountExchangeRateType;
2157
+ effectiveDate: Date;
2158
+ source: string;
2159
+ }
2160
+
2161
+ export { type Account, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountCurrencyConfig, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountExchangeRate, type AccountExchangeRateListResponse, type AccountExchangeRateMetadata, type AccountExchangeRateQueryDto, type AccountExchangeRateResponse, AccountExchangeRateType, type AccountExchangeRateWithEffectiveRate, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, AccountStatus, type Address, type AdminOrderStatusChangeDto, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, type ButtonStyle, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, 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 CreateAccountDeliveryOptionDTO, type CreateAccountExchangeRateDto, type CreateDeliveryOptionDto, type CreateExchangeRateDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, Currency, type CurrencyConversion, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, type EffectiveExchangeRate, type ExchangeRate, type ExchangeRateListResponse, type ExchangeRateMetadata, type ExchangeRateQueryDto, type ExchangeRateResponse, 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 GeoZone, type GeoZoneInput, GeoZoneStatus, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type MapPosition, type Media, MediaType, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type Payment, type PaymentCardBrand, PaymentCardBrandKey, type PaymentConversion, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Phone, type PickupLocation, type Product, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, 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 RoundingConfig, RoundingMethod, RoundingRule, type StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationLayoutComponent, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type ThemeConfig, type UpdateAccountDeliveryOptionDTO, type UpdateAccountExchangeRateAllDto, type UpdateAccountExchangeRateDto, type UpdateExchangeRateDto, type UpdateFulfillmentDto, type UpdatePromotionDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCurrencySymbol, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, parsePriceFormatPattern };
package/dist/index.d.ts CHANGED
@@ -694,6 +694,13 @@ declare enum PaymentMethodType {
694
694
  CASH = "CASH",
695
695
  OTHER = "OTHER"
696
696
  }
697
+ interface PaymentConversion {
698
+ fromCurrency: Currency;
699
+ toCurrency: Currency;
700
+ rate: number;
701
+ originalAmount: number;
702
+ finalAmount: number;
703
+ }
697
704
  interface Payment {
698
705
  id: string;
699
706
  accountId: string;
@@ -715,6 +722,7 @@ interface Payment {
715
722
  cardBrandInfo?: PaymentCardBrand;
716
723
  cardLast4?: string;
717
724
  data?: Record<string, any>;
725
+ conversion?: PaymentConversion;
718
726
  metadata?: Record<string, any>;
719
727
  internalComment?: string;
720
728
  demo: boolean;
@@ -723,6 +731,12 @@ interface Payment {
723
731
  deletedAt?: string | Date;
724
732
  accountPaymentMethod?: Partial<AccountPaymentMethod> | null;
725
733
  order?: Order;
734
+ allowedActions?: {
735
+ canCopyLink: boolean;
736
+ canMarkAsPaid: boolean;
737
+ canRecapture: boolean;
738
+ canRefund: boolean;
739
+ };
726
740
  }
727
741
  type PaymentProviderKey = 'MERCADOPAGO' | 'PLEXO' | 'MANUAL_PAYMENT';
728
742
  interface PaymentProviderContext {
@@ -1975,4 +1989,173 @@ declare enum IntegrationDeliveryZoneStatus {
1975
1989
  INACTIVE = "INACTIVE"
1976
1990
  }
1977
1991
 
1978
- export { type Account, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, AccountStatus, type Address, type AdminOrderStatusChangeDto, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, type ButtonStyle, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, 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 CreateAccountDeliveryOptionDTO, type CreateDeliveryOptionDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, Currency, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, 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 GeoZone, type GeoZoneInput, GeoZoneStatus, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type MapPosition, type Media, MediaType, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type Payment, type PaymentCardBrand, PaymentCardBrandKey, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Phone, type PickupLocation, type Product, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, 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 StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationLayoutComponent, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type ThemeConfig, type UpdateAccountDeliveryOptionDTO, type UpdateFulfillmentDto, type UpdatePromotionDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCurrencySymbol, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, parsePriceFormatPattern };
1992
+ interface ExchangeRate extends BaseEntity {
1993
+ id: string;
1994
+ baseCurrency: Currency;
1995
+ targetCurrency: Currency;
1996
+ rate: number;
1997
+ effectiveDate: Date;
1998
+ source: string;
1999
+ isLatest: boolean;
2000
+ metadata?: ExchangeRateMetadata;
2001
+ createdAt: Date;
2002
+ updatedAt: Date;
2003
+ deletedAt?: Date;
2004
+ }
2005
+ interface ExchangeRateMetadata {
2006
+ provider?: string;
2007
+ sourceTimestamp?: Date;
2008
+ confidence?: number;
2009
+ [key: string]: any;
2010
+ }
2011
+ interface CreateExchangeRateDto {
2012
+ baseCurrency: Currency;
2013
+ targetCurrency: Currency;
2014
+ rate: number;
2015
+ effectiveDate?: Date;
2016
+ source: string;
2017
+ metadata?: ExchangeRateMetadata;
2018
+ }
2019
+ interface UpdateExchangeRateDto {
2020
+ rate?: number;
2021
+ effectiveDate?: Date;
2022
+ source?: string;
2023
+ isLatest?: boolean;
2024
+ metadata?: ExchangeRateMetadata;
2025
+ }
2026
+ interface ExchangeRateQueryDto {
2027
+ baseCurrency?: Currency;
2028
+ targetCurrency?: Currency;
2029
+ source?: string;
2030
+ isLatest?: boolean;
2031
+ effectiveDateFrom?: Date;
2032
+ effectiveDateTo?: Date;
2033
+ limit?: number;
2034
+ offset?: number;
2035
+ }
2036
+ interface ExchangeRateResponse {
2037
+ item: ExchangeRate;
2038
+ }
2039
+ interface ExchangeRateListResponse {
2040
+ items: ExchangeRate[];
2041
+ total: number;
2042
+ }
2043
+ interface CurrencyConversion {
2044
+ fromCurrency: Currency;
2045
+ toCurrency: Currency;
2046
+ amount: number;
2047
+ convertedAmount: number;
2048
+ rate: number;
2049
+ effectiveDate: Date;
2050
+ source: string;
2051
+ }
2052
+
2053
+ interface AccountExchangeRate extends BaseEntityWithAccount {
2054
+ id: string;
2055
+ accountId: string;
2056
+ baseCurrency: Currency;
2057
+ targetCurrency: Currency;
2058
+ configurationType: AccountExchangeRateType;
2059
+ manualRate?: number;
2060
+ adjustmentPercentage?: number;
2061
+ roundingConfig?: RoundingConfig;
2062
+ isActive: boolean;
2063
+ lastManualUpdate?: Date;
2064
+ metadata?: AccountExchangeRateMetadata;
2065
+ createdAt: Date;
2066
+ updatedAt: Date;
2067
+ deletedAt?: Date;
2068
+ }
2069
+ declare enum AccountExchangeRateType {
2070
+ AUTOMATIC = "AUTOMATIC",
2071
+ AUTOMATIC_WITH_ADJUSTMENT = "AUTOMATIC_WITH_ADJUSTMENT",
2072
+ MANUAL = "MANUAL"
2073
+ }
2074
+ interface RoundingConfig {
2075
+ method: RoundingMethod;
2076
+ decimalPlaces: number;
2077
+ roundingRule?: RoundingRule;
2078
+ }
2079
+ declare enum RoundingMethod {
2080
+ ROUND = "ROUND",
2081
+ CEIL = "CEIL",
2082
+ FLOOR = "FLOOR",
2083
+ BANKERS = "BANKERS"
2084
+ }
2085
+ declare enum RoundingRule {
2086
+ ROUND_TO_5_CENTS = "ROUND_TO_5_CENTS",
2087
+ ROUND_TO_10_CENTS = "ROUND_TO_10_CENTS",
2088
+ NONE = "NONE"
2089
+ }
2090
+ interface AccountExchangeRateMetadata {
2091
+ description?: string;
2092
+ notes?: string;
2093
+ [key: string]: any;
2094
+ }
2095
+ interface CreateAccountExchangeRateDto {
2096
+ baseCurrency: Currency;
2097
+ targetCurrency: Currency;
2098
+ configurationType: AccountExchangeRateType;
2099
+ manualRate?: number;
2100
+ adjustmentPercentage?: number;
2101
+ roundingConfig?: RoundingConfig;
2102
+ metadata?: AccountExchangeRateMetadata;
2103
+ }
2104
+ interface UpdateAccountExchangeRateDto {
2105
+ configurationType?: AccountExchangeRateType;
2106
+ manualRate?: number;
2107
+ adjustmentPercentage?: number;
2108
+ roundingConfig?: RoundingConfig;
2109
+ isActive?: boolean;
2110
+ metadata?: AccountExchangeRateMetadata;
2111
+ }
2112
+ interface AccountExchangeRateQueryDto {
2113
+ baseCurrency?: Currency;
2114
+ targetCurrency?: Currency;
2115
+ configurationType?: AccountExchangeRateType;
2116
+ isActive?: boolean;
2117
+ limit?: number;
2118
+ offset?: number;
2119
+ }
2120
+ interface AccountExchangeRateResponse {
2121
+ item: AccountExchangeRate;
2122
+ }
2123
+ interface UpdateAccountExchangeRateAllDto {
2124
+ globalConfig?: any;
2125
+ rates: Array<{
2126
+ id?: string;
2127
+ targetCurrency: Currency;
2128
+ configurationType: AccountExchangeRateType;
2129
+ manualRate?: number;
2130
+ adjustmentPercentage?: number;
2131
+ roundingConfig?: RoundingConfig;
2132
+ }>;
2133
+ }
2134
+ interface AccountExchangeRateListResponse {
2135
+ storeCurrency: Currency;
2136
+ paymentCurrencies: Currency[];
2137
+ rates: AccountExchangeRateWithEffectiveRate[];
2138
+ }
2139
+ interface AccountExchangeRateWithEffectiveRate extends AccountExchangeRate {
2140
+ effectiveRate: number;
2141
+ baseGlobalRate: number;
2142
+ source: string;
2143
+ effectiveDate: Date;
2144
+ }
2145
+ interface AccountCurrencyConfig {
2146
+ accountId: string;
2147
+ primaryCurrency: Currency;
2148
+ exchangeRates: AccountExchangeRate[];
2149
+ effectiveRates: EffectiveExchangeRate[];
2150
+ }
2151
+ interface EffectiveExchangeRate {
2152
+ baseCurrency: Currency;
2153
+ targetCurrency: Currency;
2154
+ effectiveRate: number;
2155
+ baseGlobalRate: number;
2156
+ configurationType: AccountExchangeRateType;
2157
+ effectiveDate: Date;
2158
+ source: string;
2159
+ }
2160
+
2161
+ export { type Account, type AccountBranch, type AccountBranchSchedule, AccountBranchScheduleDay, AccountBranchScheduleStatus, AccountBranchStatus, type AccountCurrencyConfig, type AccountDeliveryOption, type AccountDeliveryOptionCalculatedCost, AccountDeliveryOptionPriceLogic, AccountDeliveryOptionStatus, type AccountDeliveryOptionZone, AccountDeliveryOptionZoneStatus, type AccountDomain, AccountDomainStatus, type AccountExchangeRate, type AccountExchangeRateListResponse, type AccountExchangeRateMetadata, type AccountExchangeRateQueryDto, type AccountExchangeRateResponse, AccountExchangeRateType, type AccountExchangeRateWithEffectiveRate, type AccountIntegration, type AccountIntegrationConfigDTO, AccountIntegrationConnectionStatus, AccountIntegrationEnvironment, AccountIntegrationStatus, type AccountPaymentMethod, AccountPaymentMethodStatus, AccountStatus, type Address, type AdminOrderStatusChangeDto, type BaseEntity, type BaseEntityWithAccount, type BaseEntityWithAccountAndUser, type BaseEntityWithUser, type ButtonStyle, type Campaign, type CampaignBudget, CampaignBudgetType, type CampaignBudgetUsage, 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 CreateAccountDeliveryOptionDTO, type CreateAccountExchangeRateDto, type CreateDeliveryOptionDto, type CreateExchangeRateDto, type CreateFulfillmentDto, type CreateFulfillmentItemDto, type CreatePromotionDTO, Currency, type CurrencyConversion, type Customer, CustomerStatus, type CustomerUpsertDto, DayOfWeek, DeliveryType, type DeliveryZoneInput, type EffectiveExchangeRate, type ExchangeRate, type ExchangeRateListResponse, type ExchangeRateMetadata, type ExchangeRateQueryDto, type ExchangeRateResponse, 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 GeoZone, type GeoZoneInput, GeoZoneStatus, type Integration, IntegrationCategory, type IntegrationDeliveryZone, IntegrationDeliveryZoneStatus, IntegrationStatus, type MapPosition, type Media, MediaType, type NextStatusAction, type Order, type OrderCreateFromCartDto, type OrderDeliveryMethod, type OrderDeliveryMethodAdjustment, type OrderDeliveryMethodCreateData, type OrderDeliveryMethodUpdateData, OrderDeliveryType, type OrderItem, type OrderItemSnapshot, type OrderLineItemAdjustment, OrderPaymentStatus, type OrderPromotion, OrderSource, OrderStatus, type Payment, type PaymentCardBrand, PaymentCardBrandKey, type PaymentConversion, PaymentMethodType, type PaymentProviderAdapter, type PaymentProviderCaptureInput, type PaymentProviderCaptureOutput, type PaymentProviderContext, type PaymentProviderInitInput, type PaymentProviderInitOutput, type PaymentProviderKey, type PaymentProviderRefundInput, type PaymentProviderRefundOutput, type PaymentProviderWebhookResult, PaymentStatus, type Phone, type PickupLocation, type Product, type ProductAttribute, type ProductAttributeOption, ProductAttributeStatus, ProductAttributeType, type ProductCategory, ProductCategoryStatus, ProductStatus, ProductType, type ProductVariant, 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 RoundingConfig, RoundingMethod, RoundingRule, type StandardCategory, StandardCategoryStatus, type StatusChangeHistory, type StatusFlow, type StoreBanner, StoreBannerStatus, type StoreCustomization, type StoreCustomizationComponentSettings, type StoreCustomizationLayoutComponent, type StoreCustomizationPage, type StoreCustomizationPageComponent, type StoreCustomizationSeo, type StoreCustomizationThemeButtons, type StoreCustomizationThemeColors, type StoreCustomizationThemeTypography, type StorePage, StorePageStatus, StorePageType, type SupportConversation, SupportConversationChannel, type SupportConversationMessage, SupportConversationMessageAiAnalysisStatus, SupportConversationMessageDeliveryStatus, SupportConversationMessageDirection, SupportConversationMessageSenderType, SupportConversationPriority, SupportConversationStatus, SupportConversationVisibility, type ThemeConfig, type UpdateAccountDeliveryOptionDTO, type UpdateAccountExchangeRateAllDto, type UpdateAccountExchangeRateDto, type UpdateExchangeRateDto, type UpdateFulfillmentDto, type UpdatePromotionDTO, type Webhook, type WebhookPayload, getAccountPaymentMethodStatusInfo, getCurrencySymbol, getFulfillmentStatusInfo, getIntegrationCategoryName, getOrderPaymentStatusInfo, getOrderStatusInfo, getPaymentCardBrand, getPaymentStatusInfo, getProductStatusInfo, parsePriceFormatPattern };
package/dist/index.js CHANGED
@@ -28,6 +28,7 @@ __export(index_exports, {
28
28
  AccountDeliveryOptionStatus: () => AccountDeliveryOptionStatus,
29
29
  AccountDeliveryOptionZoneStatus: () => AccountDeliveryOptionZoneStatus,
30
30
  AccountDomainStatus: () => AccountDomainStatus,
31
+ AccountExchangeRateType: () => AccountExchangeRateType,
31
32
  AccountIntegrationConnectionStatus: () => AccountIntegrationConnectionStatus,
32
33
  AccountIntegrationEnvironment: () => AccountIntegrationEnvironment,
33
34
  AccountIntegrationStatus: () => AccountIntegrationStatus,
@@ -67,6 +68,8 @@ __export(index_exports, {
67
68
  PromotionTargetType: () => PromotionTargetType,
68
69
  PromotionType: () => PromotionType,
69
70
  PubSubTopics: () => PubSubTopics,
71
+ RoundingMethod: () => RoundingMethod,
72
+ RoundingRule: () => RoundingRule,
70
73
  StandardCategoryStatus: () => StandardCategoryStatus,
71
74
  StoreBannerStatus: () => StoreBannerStatus,
72
75
  StorePageStatus: () => StorePageStatus,
@@ -812,6 +815,27 @@ var IntegrationDeliveryZoneStatus = /* @__PURE__ */ ((IntegrationDeliveryZoneSta
812
815
  IntegrationDeliveryZoneStatus2["INACTIVE"] = "INACTIVE";
813
816
  return IntegrationDeliveryZoneStatus2;
814
817
  })(IntegrationDeliveryZoneStatus || {});
818
+
819
+ // src/accountExchangeRate/types.ts
820
+ var AccountExchangeRateType = /* @__PURE__ */ ((AccountExchangeRateType2) => {
821
+ AccountExchangeRateType2["AUTOMATIC"] = "AUTOMATIC";
822
+ AccountExchangeRateType2["AUTOMATIC_WITH_ADJUSTMENT"] = "AUTOMATIC_WITH_ADJUSTMENT";
823
+ AccountExchangeRateType2["MANUAL"] = "MANUAL";
824
+ return AccountExchangeRateType2;
825
+ })(AccountExchangeRateType || {});
826
+ var RoundingMethod = /* @__PURE__ */ ((RoundingMethod2) => {
827
+ RoundingMethod2["ROUND"] = "ROUND";
828
+ RoundingMethod2["CEIL"] = "CEIL";
829
+ RoundingMethod2["FLOOR"] = "FLOOR";
830
+ RoundingMethod2["BANKERS"] = "BANKERS";
831
+ return RoundingMethod2;
832
+ })(RoundingMethod || {});
833
+ var RoundingRule = /* @__PURE__ */ ((RoundingRule2) => {
834
+ RoundingRule2["ROUND_TO_5_CENTS"] = "ROUND_TO_5_CENTS";
835
+ RoundingRule2["ROUND_TO_10_CENTS"] = "ROUND_TO_10_CENTS";
836
+ RoundingRule2["NONE"] = "NONE";
837
+ return RoundingRule2;
838
+ })(RoundingRule || {});
815
839
  // Annotate the CommonJS export names for ESM import in node:
816
840
  0 && (module.exports = {
817
841
  AccountBranchScheduleDay,
@@ -821,6 +845,7 @@ var IntegrationDeliveryZoneStatus = /* @__PURE__ */ ((IntegrationDeliveryZoneSta
821
845
  AccountDeliveryOptionStatus,
822
846
  AccountDeliveryOptionZoneStatus,
823
847
  AccountDomainStatus,
848
+ AccountExchangeRateType,
824
849
  AccountIntegrationConnectionStatus,
825
850
  AccountIntegrationEnvironment,
826
851
  AccountIntegrationStatus,
@@ -860,6 +885,8 @@ var IntegrationDeliveryZoneStatus = /* @__PURE__ */ ((IntegrationDeliveryZoneSta
860
885
  PromotionTargetType,
861
886
  PromotionType,
862
887
  PubSubTopics,
888
+ RoundingMethod,
889
+ RoundingRule,
863
890
  StandardCategoryStatus,
864
891
  StoreBannerStatus,
865
892
  StorePageStatus,