Skip to content

Commit a4f1cbc

Browse files
committed
Little bit more documentation
1 parent b827bb5 commit a4f1cbc

File tree

1 file changed

+16
-8
lines changed

1 file changed

+16
-8
lines changed

src/apify/_charging.py

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,22 @@ class ChargeResult:
249249
"""How many events of each known type can still be charged within the limit"""
250250

251251

252+
@docs_group('Data structures')
253+
@dataclass
254+
class ActorPricingInfo:
255+
pricing_model: PricingModel | None
256+
"""The currently effective pricing model"""
257+
258+
max_total_charge_usd: Decimal
259+
"""A configured limit for the total charged amount - if you exceed it, you won't receive more money than this."""
260+
261+
is_pay_per_event: bool
262+
"""A shortcut - true if the Actor runs with the pay-per-event pricing model"""
263+
264+
per_event_prices: dict[str, Decimal]
265+
"""Price of every known event type"""
266+
267+
252268
@dataclass
253269
class ChargingStateItem:
254270
charge_count: int
@@ -259,11 +275,3 @@ class ChargingStateItem:
259275
class PricingInfoItem:
260276
price: Decimal
261277
title: str
262-
263-
264-
@dataclass
265-
class ActorPricingInfo:
266-
pricing_model: PricingModel | None
267-
max_total_charge_usd: Decimal
268-
is_pay_per_event: bool
269-
per_event_prices: dict[str, Decimal]

0 commit comments

Comments
 (0)