Skip to content

Commit

Permalink
Update generated code for v1446
Browse files Browse the repository at this point in the history
  • Loading branch information
stripe-openapi[bot] committed Jan 14, 2025
1 parent 9f9fe80 commit 7202fe1
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v1444
v1446
17 changes: 17 additions & 0 deletions stripe/checkout/_session.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,14 @@

if TYPE_CHECKING:
from stripe._account import Account
from stripe._coupon import Coupon
from stripe._customer import Customer
from stripe._discount import Discount as DiscountResource
from stripe._invoice import Invoice
from stripe._line_item import LineItem
from stripe._payment_intent import PaymentIntent
from stripe._payment_link import PaymentLink
from stripe._promotion_code import PromotionCode
from stripe._setup_intent import SetupIntent
from stripe._shipping_rate import ShippingRate
from stripe._subscription import Subscription
Expand Down Expand Up @@ -665,6 +667,16 @@ class TaxId(StripeObject):
"""
_inner_class_types = {"address": Address, "tax_ids": TaxId}

class Discount(StripeObject):
coupon: Optional[ExpandableField["Coupon"]]
"""
Coupon attached to the Checkout Session.
"""
promotion_code: Optional[ExpandableField["PromotionCode"]]
"""
Promotion code attached to the Checkout Session.
"""

class InvoiceCreation(StripeObject):
class InvoiceData(StripeObject):
class CustomField(StripeObject):
Expand Down Expand Up @@ -4970,6 +4982,10 @@ class RetrieveParams(RequestOptions):
on file. To access information about the customer once the payment flow is
complete, use the `customer` attribute.
"""
discounts: Optional[List[Discount]]
"""
List of coupons and promotion codes attached to the Checkout Session.
"""
expires_at: int
"""
The timestamp at which the Checkout Session will expire.
Expand Down Expand Up @@ -5536,6 +5552,7 @@ async def retrieve_async(
"custom_fields": CustomField,
"custom_text": CustomText,
"customer_details": CustomerDetails,
"discounts": Discount,
"invoice_creation": InvoiceCreation,
"payment_method_configuration_details": PaymentMethodConfigurationDetails,
"payment_method_options": PaymentMethodOptions,
Expand Down

0 comments on commit 7202fe1

Please sign in to comment.