diff --git a/lago_python_client/models/__init__.py b/lago_python_client/models/__init__.py index 5aae834..215779c 100644 --- a/lago_python_client/models/__init__.py +++ b/lago_python_client/models/__init__.py @@ -19,7 +19,8 @@ from .subscription import Subscription from .customer_usage import Metric, ChargeObject, ChargeUsage, CustomerUsageResponse from .tax import Tax, Taxes, TaxResponse, TaxesResponse -from .usage_threshold import UsageThreshold, UsageThresholds, UsageThresholdResponse, UsageThresholdsResponse +from .usage_threshold import UsageThreshold, UsageThresholds, UsageThresholdResponse, \ + UsageThresholdsResponse, AppliedUsageThresholdResponse, AppliedUsageThresholdsResponse from .wallet import Wallet, RecurringTransactionRule, RecurringTransactionRuleList, \ RecurringTransactionRuleResponse, RecurringTransactionRuleResponseList from .wallet_transaction import WalletTransaction diff --git a/lago_python_client/models/invoice.py b/lago_python_client/models/invoice.py index f575052..013b801 100644 --- a/lago_python_client/models/invoice.py +++ b/lago_python_client/models/invoice.py @@ -6,6 +6,7 @@ from .customer import CustomerResponse from .fee import FeesResponse from .subscription import SubscriptionsResponse +from .usage_threshold import AppliedUsageThresholdsResponse from ..base_model import BaseResponseModel @@ -96,3 +97,4 @@ class InvoiceResponse(BaseResponseModel): credits: Optional[CreditsResponse] metadata: Optional[InvoiceMetadataList] applied_taxes: Optional[InvoiceAppliedTaxes] + applied_usage_thresholds: Optional[AppliedUsageThresholdsResponse] diff --git a/lago_python_client/models/usage_threshold.py b/lago_python_client/models/usage_threshold.py index 793ba93..1037469 100644 --- a/lago_python_client/models/usage_threshold.py +++ b/lago_python_client/models/usage_threshold.py @@ -27,3 +27,13 @@ class UsageThresholdResponse(BaseResponseModel): class UsageThresholdsResponse(BaseResponseModel): __root__: List[UsageThresholdResponse] + + +class AppliedUsageThresholdResponse(BaseResponseModel): + lifetime_usage_amount_cents: int + created_at: str + usage_threshold: UsageThresholdResponse + + +class AppliedUsageThresholdsResponse(BaseResponseModel): + __root__: List[AppliedUsageThresholdResponse]