elemento-loyalty-processing 1.0.12__py3-none-any.whl → 1.0.14__py3-none-any.whl

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.
@@ -176,14 +176,14 @@ class ElementoLoyaltyProcessingClient(RPCClientService):
176
176
  customer_id: CustomerId,
177
177
  source: str,
178
178
  transaction_id: TransactionExtId,
179
- positions: list[int],
179
+ items: list[RefundItem],
180
180
  _max_timeout: int = None,
181
181
  _nowait: bool = False,
182
182
  ) -> Points:
183
183
  """Call Balance.refund."""
184
184
  data = await self.call(
185
185
  method="Balance.refund",
186
- params=dict(customer_id=customer_id, source=source, transaction_id=transaction_id, positions=positions),
186
+ params=dict(customer_id=customer_id, source=source, transaction_id=transaction_id, items=items),
187
187
  max_timeout=_max_timeout,
188
188
  nowait=_nowait,
189
189
  )
@@ -224,7 +224,7 @@ class ElementoLoyaltyProcessingClient(RPCClientService):
224
224
  async def balance_history_expiring(
225
225
  self, customer_id: int, active_to: date, _max_timeout: int = None, _nowait: bool = False
226
226
  ):
227
- """Call alance.history.expiring."""
227
+ """Call balance.history.expiring."""
228
228
  return await self.call(
229
229
  method="Balance.history.expiring",
230
230
  params={"customer_id": customer_id, "active_to": active_to},
@@ -22,6 +22,7 @@ __all__ = [
22
22
  "Transaction",
23
23
  "EventTypeId",
24
24
  "Item",
25
+ "RefundItem",
25
26
  "Cart",
26
27
  "BalanceAction",
27
28
  "Customer",
@@ -143,6 +144,11 @@ class Item(Struct):
143
144
  offers_sub: list[AppliedOffer] = []
144
145
 
145
146
 
147
+ class RefundItem(TypedDict):
148
+ pos: int
149
+ quantity: int
150
+
151
+
146
152
  class Cart(Struct):
147
153
  items: list[Item]
148
154
  total: Decimal = Decimal(0)
@@ -180,6 +186,7 @@ class Transaction(Struct):
180
186
  timestamp: datetime = None
181
187
  cart: Cart = None
182
188
  confirmed: bool = False
189
+ payment_type: str | None = None
183
190
 
184
191
 
185
192
  class PurchaseStats(Struct):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: elemento-loyalty-processing
3
- Version: 1.0.12
3
+ Version: 1.0.14
4
4
  Summary: Elemento Loyalty Processing
5
5
  Requires-Python: >=3.11
6
6
  Requires-Dist: kaiju-tools<3,>=2.4.12
@@ -0,0 +1,7 @@
1
+ elemento_loyalty_processing/__init__.py,sha256=32qjgePFNecQb5PvKkcoMCOEoSSl-OkQ2BEWgQ069bE,118
2
+ elemento_loyalty_processing/client.py,sha256=F33_41ND_AFc1Jo253oEa7Dm_LBx4t-FmGk70sJEwkQ,7963
3
+ elemento_loyalty_processing/types.py,sha256=Mm9XiB0BogpPSChM7AQ4v0SFzLjOT9O6WfvKm6DZhN8,4099
4
+ elemento_loyalty_processing-1.0.14.dist-info/METADATA,sha256=Wk_2sxPJ5yGD8otJS-Z3e-FWLk4GpBBTaqKerw8n0jQ,450
5
+ elemento_loyalty_processing-1.0.14.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
6
+ elemento_loyalty_processing-1.0.14.dist-info/top_level.txt,sha256=N_AtPyYKvkr1NkoPAUrVl_4VCTP-kJIehtsLhkdacAc,28
7
+ elemento_loyalty_processing-1.0.14.dist-info/RECORD,,
@@ -1,7 +0,0 @@
1
- elemento_loyalty_processing/__init__.py,sha256=32qjgePFNecQb5PvKkcoMCOEoSSl-OkQ2BEWgQ069bE,118
2
- elemento_loyalty_processing/client.py,sha256=_u2ObL9p1-bMqFHD4okzpNT-6IyaUKIVaHlLw8vK8dg,7967
3
- elemento_loyalty_processing/types.py,sha256=JPR1RlZ2XEmR0VOf3azhwvd7yrivpCMObF-QAU7qfmA,3983
4
- elemento_loyalty_processing-1.0.12.dist-info/METADATA,sha256=rONe7DgqnoFYKqsqK-eifeZz5io9pTTbYrLNJRmdRQI,450
5
- elemento_loyalty_processing-1.0.12.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
6
- elemento_loyalty_processing-1.0.12.dist-info/top_level.txt,sha256=N_AtPyYKvkr1NkoPAUrVl_4VCTP-kJIehtsLhkdacAc,28
7
- elemento_loyalty_processing-1.0.12.dist-info/RECORD,,