airbyte-agent-stripe 0.5.28__py3-none-any.whl → 0.5.37__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.
@@ -22,34 +22,6 @@ class StripeAuthConfig(BaseModel):
22
22
 
23
23
  # ===== RESPONSE TYPE DEFINITIONS (PYDANTIC) =====
24
24
 
25
- class CustomerShippingAddress(BaseModel):
26
- """Customer shipping address"""
27
- model_config = ConfigDict(extra="allow", populate_by_name=True)
28
-
29
- city: Union[str | None, Any] = Field(default=None, description="City, district, suburb, town, or village")
30
- """City, district, suburb, town, or village"""
31
- country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
32
- """Two-letter country code (ISO 3166-1 alpha-2)"""
33
- line1: Union[str | None, Any] = Field(default=None, description="Address line 1, such as the street, PO Box, or company name")
34
- """Address line 1, such as the street, PO Box, or company name"""
35
- line2: Union[str | None, Any] = Field(default=None, description="Address line 2, such as the apartment, suite, unit, or building")
36
- """Address line 2, such as the apartment, suite, unit, or building"""
37
- postal_code: Union[str | None, Any] = Field(default=None, description="ZIP or postal code")
38
- """ZIP or postal code"""
39
- state: Union[str | None, Any] = Field(default=None, description="State, county, province, or region")
40
- """State, county, province, or region"""
41
-
42
- class CustomerShipping(BaseModel):
43
- """Mailing and shipping address for the customer"""
44
- model_config = ConfigDict(extra="allow", populate_by_name=True)
45
-
46
- address: Union[CustomerShippingAddress, Any] = Field(default=None, description="Customer shipping address")
47
- """Customer shipping address"""
48
- name: Union[str, Any] = Field(default=None, description="Customer name")
49
- """Customer name"""
50
- phone: Union[str | None, Any] = Field(default=None, description="Customer phone (including extension)")
51
- """Customer phone (including extension)"""
52
-
53
25
  class CustomerSourcesDataItem(BaseModel):
54
26
  """Nested schema for CustomerSources.data_item"""
55
27
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -100,37 +72,6 @@ class CustomerSources(BaseModel):
100
72
  url: Union[str, Any] = Field(default=None, description="The URL where this list can be accessed")
101
73
  """The URL where this list can be accessed"""
102
74
 
103
- class CustomerInvoiceSettingsCustomFieldsItem(BaseModel):
104
- """Nested schema for CustomerInvoiceSettings.custom_fields_item"""
105
- model_config = ConfigDict(extra="allow", populate_by_name=True)
106
-
107
- name: Union[str, Any] = Field(default=None, description="The name of the custom field")
108
- """The name of the custom field"""
109
- value: Union[str, Any] = Field(default=None, description="The value of the custom field")
110
- """The value of the custom field"""
111
-
112
- class CustomerInvoiceSettingsRenderingOptions(BaseModel):
113
- """Default options for invoice PDF rendering for this customer"""
114
- model_config = ConfigDict(extra="allow", populate_by_name=True)
115
-
116
- amount_tax_display: Union[str | None, Any] = Field(default=None, description="How line-item prices and amounts will be displayed with respect to tax on invoice PDFs")
117
- """How line-item prices and amounts will be displayed with respect to tax on invoice PDFs"""
118
- template: Union[str | None, Any] = Field(default=None, description="ID of the invoice rendering template to be used for this customer's invoices")
119
- """ID of the invoice rendering template to be used for this customer's invoices"""
120
-
121
- class CustomerInvoiceSettings(BaseModel):
122
- """The customer's default invoice settings"""
123
- model_config = ConfigDict(extra="allow", populate_by_name=True)
124
-
125
- custom_fields: Union[list[CustomerInvoiceSettingsCustomFieldsItem] | None, Any] = Field(default=None, description="Default custom fields to be displayed on invoices for this customer")
126
- """Default custom fields to be displayed on invoices for this customer"""
127
- default_payment_method: Union[str | None, Any] = Field(default=None, description="ID of a payment method that's attached to the customer")
128
- """ID of a payment method that's attached to the customer"""
129
- footer: Union[str | None, Any] = Field(default=None, description="Default footer to be displayed on invoices for this customer")
130
- """Default footer to be displayed on invoices for this customer"""
131
- rendering_options: Union[CustomerInvoiceSettingsRenderingOptions | None, Any] = Field(default=None, description="Default options for invoice PDF rendering for this customer")
132
- """Default options for invoice PDF rendering for this customer"""
133
-
134
75
  class CustomerAddress(BaseModel):
135
76
  """The customer's address"""
136
77
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -174,45 +115,36 @@ class CustomerCashBalance(BaseModel):
174
115
  settings: Union[CustomerCashBalanceSettings, Any] = Field(default=None, description="A hash of settings for this cash balance")
175
116
  """A hash of settings for this cash balance"""
176
117
 
177
- class CustomerDiscountSource(BaseModel):
178
- """The source of the discount"""
118
+ class CustomerInvoiceSettingsRenderingOptions(BaseModel):
119
+ """Default options for invoice PDF rendering for this customer"""
179
120
  model_config = ConfigDict(extra="allow", populate_by_name=True)
180
121
 
181
- coupon: Union[str | None, Any] = Field(default=None, description="The coupon that was redeemed to create this discount")
182
- """The coupon that was redeemed to create this discount"""
183
- type: Union[str, Any] = Field(default=None, description="The source type of the discount")
184
- """The source type of the discount"""
122
+ amount_tax_display: Union[str | None, Any] = Field(default=None, description="How line-item prices and amounts will be displayed with respect to tax on invoice PDFs")
123
+ """How line-item prices and amounts will be displayed with respect to tax on invoice PDFs"""
124
+ template: Union[str | None, Any] = Field(default=None, description="ID of the invoice rendering template to be used for this customer's invoices")
125
+ """ID of the invoice rendering template to be used for this customer's invoices"""
185
126
 
186
- class CustomerDiscount(BaseModel):
187
- """Describes the current discount active on the customer, if there is one"""
127
+ class CustomerInvoiceSettingsCustomFieldsItem(BaseModel):
128
+ """Nested schema for CustomerInvoiceSettings.custom_fields_item"""
188
129
  model_config = ConfigDict(extra="allow", populate_by_name=True)
189
130
 
190
- id: Union[str, Any] = Field(default=None, description="The ID of the discount object")
191
- """The ID of the discount object"""
192
- object: Union[str, Any] = Field(default=None, description="String representing the object's type")
193
- """String representing the object's type"""
194
- checkout_session: Union[str | None, Any] = Field(default=None, description="The Checkout session that this coupon is applied to, if applicable")
195
- """The Checkout session that this coupon is applied to, if applicable"""
196
- customer: Union[str | None, Any] = Field(default=None, description="The ID of the customer associated with this discount")
197
- """The ID of the customer associated with this discount"""
198
- customer_account: Union[str | None, Any] = Field(default=None, description="The ID of the account associated with this discount")
199
- """The ID of the account associated with this discount"""
200
- end: Union[int | None, Any] = Field(default=None, description="If the coupon has a duration of repeating, the date that this discount will end")
201
- """If the coupon has a duration of repeating, the date that this discount will end"""
202
- invoice: Union[str | None, Any] = Field(default=None, description="The invoice that the discount's coupon was applied to")
203
- """The invoice that the discount's coupon was applied to"""
204
- invoice_item: Union[str | None, Any] = Field(default=None, description="The invoice item that the discount's coupon was applied to")
205
- """The invoice item that the discount's coupon was applied to"""
206
- promotion_code: Union[str | None, Any] = Field(default=None, description="The promotion code applied to create this discount")
207
- """The promotion code applied to create this discount"""
208
- source: Union[CustomerDiscountSource, Any] = Field(default=None, description="The source of the discount")
209
- """The source of the discount"""
210
- start: Union[int, Any] = Field(default=None, description="Date that the coupon was applied")
211
- """Date that the coupon was applied"""
212
- subscription: Union[str | None, Any] = Field(default=None, description="The subscription that this coupon is applied to")
213
- """The subscription that this coupon is applied to"""
214
- subscription_item: Union[str | None, Any] = Field(default=None, description="The subscription item that this coupon is applied to")
215
- """The subscription item that this coupon is applied to"""
131
+ name: Union[str, Any] = Field(default=None, description="The name of the custom field")
132
+ """The name of the custom field"""
133
+ value: Union[str, Any] = Field(default=None, description="The value of the custom field")
134
+ """The value of the custom field"""
135
+
136
+ class CustomerInvoiceSettings(BaseModel):
137
+ """The customer's default invoice settings"""
138
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
139
+
140
+ custom_fields: Union[list[CustomerInvoiceSettingsCustomFieldsItem] | None, Any] = Field(default=None, description="Default custom fields to be displayed on invoices for this customer")
141
+ """Default custom fields to be displayed on invoices for this customer"""
142
+ default_payment_method: Union[str | None, Any] = Field(default=None, description="ID of a payment method that's attached to the customer")
143
+ """ID of a payment method that's attached to the customer"""
144
+ footer: Union[str | None, Any] = Field(default=None, description="Default footer to be displayed on invoices for this customer")
145
+ """Default footer to be displayed on invoices for this customer"""
146
+ rendering_options: Union[CustomerInvoiceSettingsRenderingOptions | None, Any] = Field(default=None, description="Default options for invoice PDF rendering for this customer")
147
+ """Default options for invoice PDF rendering for this customer"""
216
148
 
217
149
  class SubscriptionBillingCycleAnchorConfig(BaseModel):
218
150
  """The fixed values used to calculate the billing_cycle_anchor"""
@@ -229,14 +161,16 @@ class SubscriptionBillingCycleAnchorConfig(BaseModel):
229
161
  second: Union[int | None, Any] = Field(default=None, description="The second of the minute of the billing_cycle_anchor")
230
162
  """The second of the minute of the billing_cycle_anchor"""
231
163
 
232
- class SubscriptionPauseCollection(BaseModel):
233
- """If specified, payment collection for this subscription will be paused"""
164
+ class SubscriptionCancellationDetails(BaseModel):
165
+ """Details about why this subscription was cancelled"""
234
166
  model_config = ConfigDict(extra="allow", populate_by_name=True)
235
167
 
236
- behavior: Union[str, Any] = Field(default=None, description="The payment collection behavior for this subscription while paused")
237
- """The payment collection behavior for this subscription while paused"""
238
- resumes_at: Union[int | None, Any] = Field(default=None, description="The time after which the subscription will resume collecting payments")
239
- """The time after which the subscription will resume collecting payments"""
168
+ comment: Union[str | None, Any] = Field(default=None, description="Additional comments about why the user canceled the subscription")
169
+ """Additional comments about why the user canceled the subscription"""
170
+ feedback: Union[str | None, Any] = Field(default=None, description="The customer submitted reason for why they canceled")
171
+ """The customer submitted reason for why they canceled"""
172
+ reason: Union[str | None, Any] = Field(default=None, description="Why this subscription was canceled")
173
+ """Why this subscription was canceled"""
240
174
 
241
175
  class SubscriptionBillingModeFlexible(BaseModel):
242
176
  """Configure behavior for flexible billing mode"""
@@ -256,76 +190,6 @@ class SubscriptionBillingMode(BaseModel):
256
190
  updated_at: Union[int | None, Any] = Field(default=None, description="Details on when the current billing_mode was adopted")
257
191
  """Details on when the current billing_mode was adopted"""
258
192
 
259
- class SubscriptionPaymentSettings(BaseModel):
260
- """Payment settings passed on to invoices created by the subscription"""
261
- model_config = ConfigDict(extra="allow", populate_by_name=True)
262
-
263
- payment_method_options: Union[dict[str, Any] | None, Any] = Field(default=None, description="Payment-method-specific configuration to provide to invoices")
264
- """Payment-method-specific configuration to provide to invoices"""
265
- payment_method_types: Union[list[str] | None, Any] = Field(default=None, description="The list of payment method types to provide to every invoice")
266
- """The list of payment method types to provide to every invoice"""
267
-
268
- class SubscriptionDefaultTaxRatesItemFlatAmount(BaseModel):
269
- """The amount of the tax rate when the rate_type is flat_amount"""
270
- model_config = ConfigDict(extra="allow", populate_by_name=True)
271
-
272
- amount: Union[int, Any] = Field(default=None, description="Amount of the tax when the rate_type is flat_amount")
273
- """Amount of the tax when the rate_type is flat_amount"""
274
- currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code, in lowercase")
275
- """Three-letter ISO currency code, in lowercase"""
276
-
277
- class SubscriptionDefaultTaxRatesItem(BaseModel):
278
- """Nested schema for Subscription.default_tax_rates_item"""
279
- model_config = ConfigDict(extra="allow", populate_by_name=True)
280
-
281
- id: Union[str, Any] = Field(default=None, description="Unique identifier for the object")
282
- """Unique identifier for the object"""
283
- object: Union[str, Any] = Field(default=None, description="String representing the object's type")
284
- """String representing the object's type"""
285
- active: Union[bool, Any] = Field(default=None, description="Defaults to true")
286
- """Defaults to true"""
287
- country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
288
- """Two-letter country code (ISO 3166-1 alpha-2)"""
289
- created: Union[int, Any] = Field(default=None, description="Time at which the object was created")
290
- """Time at which the object was created"""
291
- description: Union[str | None, Any] = Field(default=None, description="An arbitrary string attached to the tax rate for your internal use only")
292
- """An arbitrary string attached to the tax rate for your internal use only"""
293
- display_name: Union[str, Any] = Field(default=None, description="The display name of the tax rates")
294
- """The display name of the tax rates"""
295
- effective_percentage: Union[float | None, Any] = Field(default=None, description="Actual/effective tax rate percentage out of 100")
296
- """Actual/effective tax rate percentage out of 100"""
297
- flat_amount: Union[SubscriptionDefaultTaxRatesItemFlatAmount | None, Any] = Field(default=None, description="The amount of the tax rate when the rate_type is flat_amount")
298
- """The amount of the tax rate when the rate_type is flat_amount"""
299
- inclusive: Union[bool, Any] = Field(default=None, description="This specifies if the tax rate is inclusive or exclusive")
300
- """This specifies if the tax rate is inclusive or exclusive"""
301
- jurisdiction: Union[str | None, Any] = Field(default=None, description="The jurisdiction for the tax rate")
302
- """The jurisdiction for the tax rate"""
303
- jurisdiction_level: Union[str | None, Any] = Field(default=None, description="The level of the jurisdiction that imposes this tax rate")
304
- """The level of the jurisdiction that imposes this tax rate"""
305
- livemode: Union[bool, Any] = Field(default=None, description="Has the value true if the object exists in live mode or false if in test mode")
306
- """Has the value true if the object exists in live mode or false if in test mode"""
307
- metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs")
308
- """Set of key-value pairs"""
309
- percentage: Union[float, Any] = Field(default=None, description="Tax rate percentage out of 100")
310
- """Tax rate percentage out of 100"""
311
- rate_type: Union[str | None, Any] = Field(default=None, description="Indicates the type of tax rate applied to the taxable amount")
312
- """Indicates the type of tax rate applied to the taxable amount"""
313
- state: Union[str | None, Any] = Field(default=None, description="ISO 3166-2 subdivision code, without country prefix")
314
- """ISO 3166-2 subdivision code, without country prefix"""
315
- tax_type: Union[str | None, Any] = Field(default=None, description="The high-level tax type")
316
- """The high-level tax type"""
317
-
318
- class SubscriptionCancellationDetails(BaseModel):
319
- """Details about why this subscription was cancelled"""
320
- model_config = ConfigDict(extra="allow", populate_by_name=True)
321
-
322
- comment: Union[str | None, Any] = Field(default=None, description="Additional comments about why the user canceled the subscription")
323
- """Additional comments about why the user canceled the subscription"""
324
- feedback: Union[str | None, Any] = Field(default=None, description="The customer submitted reason for why they canceled")
325
- """The customer submitted reason for why they canceled"""
326
- reason: Union[str | None, Any] = Field(default=None, description="Why this subscription was canceled")
327
- """Why this subscription was canceled"""
328
-
329
193
  class SubscriptionTrialSettingsEndBehavior(BaseModel):
330
194
  """Nested schema for SubscriptionTrialSettings.end_behavior"""
331
195
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -339,53 +203,6 @@ class SubscriptionTrialSettings(BaseModel):
339
203
 
340
204
  end_behavior: Union[SubscriptionTrialSettingsEndBehavior, Any] = Field(default=None)
341
205
 
342
- class SubscriptionBillingThresholds(BaseModel):
343
- """Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period"""
344
- model_config = ConfigDict(extra="allow", populate_by_name=True)
345
-
346
- amount_gte: Union[int | None, Any] = Field(default=None, description="Monetary threshold that triggers the subscription to create an invoice")
347
- """Monetary threshold that triggers the subscription to create an invoice"""
348
- reset_billing_cycle_anchor: Union[bool | None, Any] = Field(default=None, description="Indicates if the billing_cycle_anchor should be reset when a threshold is reached")
349
- """Indicates if the billing_cycle_anchor should be reset when a threshold is reached"""
350
-
351
- class SubscriptionInvoiceSettingsIssuer(BaseModel):
352
- """The connected account that issues the invoice"""
353
- model_config = ConfigDict(extra="allow", populate_by_name=True)
354
-
355
- account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
356
- """The connected account being referenced when type is account"""
357
- type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
358
- """Type of the account referenced"""
359
-
360
- class SubscriptionInvoiceSettings(BaseModel):
361
- """All invoices will be billed using the specified settings"""
362
- model_config = ConfigDict(extra="allow", populate_by_name=True)
363
-
364
- account_tax_ids: Union[list[str] | None, Any] = Field(default=None, description="The account tax IDs associated with the subscription")
365
- """The account tax IDs associated with the subscription"""
366
- issuer: Union[SubscriptionInvoiceSettingsIssuer, Any] = Field(default=None, description="The connected account that issues the invoice")
367
- """The connected account that issues the invoice"""
368
-
369
- class SubscriptionAutomaticTaxLiability(BaseModel):
370
- """The account that's liable for tax"""
371
- model_config = ConfigDict(extra="allow", populate_by_name=True)
372
-
373
- account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
374
- """The connected account being referenced when type is account"""
375
- type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
376
- """Type of the account referenced"""
377
-
378
- class SubscriptionAutomaticTax(BaseModel):
379
- """Automatic tax settings for this subscription"""
380
- model_config = ConfigDict(extra="allow", populate_by_name=True)
381
-
382
- disabled_reason: Union[str | None, Any] = Field(default=None, description="If Stripe disabled automatic tax, this enum describes why")
383
- """If Stripe disabled automatic tax, this enum describes why"""
384
- enabled: Union[bool, Any] = Field(default=None, description="Whether Stripe automatically computes tax on this subscription")
385
- """Whether Stripe automatically computes tax on this subscription"""
386
- liability: Union[SubscriptionAutomaticTaxLiability | None, Any] = Field(default=None, description="The account that's liable for tax")
387
- """The account that's liable for tax"""
388
-
389
206
  class SubscriptionItemsDataItemBillingThresholds(BaseModel):
390
207
  """Define thresholds at which an invoice will be sent"""
391
208
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -439,13 +256,128 @@ class SubscriptionItems(BaseModel):
439
256
  total_count: Union[int, Any] = Field(default=None, description="The total count of items in the list")
440
257
  """The total count of items in the list"""
441
258
 
442
- class Subscription(BaseModel):
443
- """Subscription type definition"""
259
+ class SubscriptionPaymentSettings(BaseModel):
260
+ """Payment settings passed on to invoices created by the subscription"""
444
261
  model_config = ConfigDict(extra="allow", populate_by_name=True)
445
262
 
446
- id: Union[str, Any] = Field(default=None)
447
- object: Union[str, Any] = Field(default=None)
448
- application: Union[str | None, Any] = Field(default=None)
263
+ payment_method_options: Union[dict[str, Any] | None, Any] = Field(default=None, description="Payment-method-specific configuration to provide to invoices")
264
+ """Payment-method-specific configuration to provide to invoices"""
265
+ payment_method_types: Union[list[str] | None, Any] = Field(default=None, description="The list of payment method types to provide to every invoice")
266
+ """The list of payment method types to provide to every invoice"""
267
+
268
+ class SubscriptionInvoiceSettingsIssuer(BaseModel):
269
+ """The connected account that issues the invoice"""
270
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
271
+
272
+ account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
273
+ """The connected account being referenced when type is account"""
274
+ type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
275
+ """Type of the account referenced"""
276
+
277
+ class SubscriptionInvoiceSettings(BaseModel):
278
+ """All invoices will be billed using the specified settings"""
279
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
280
+
281
+ account_tax_ids: Union[list[str] | None, Any] = Field(default=None, description="The account tax IDs associated with the subscription")
282
+ """The account tax IDs associated with the subscription"""
283
+ issuer: Union[SubscriptionInvoiceSettingsIssuer, Any] = Field(default=None, description="The connected account that issues the invoice")
284
+ """The connected account that issues the invoice"""
285
+
286
+ class SubscriptionAutomaticTaxLiability(BaseModel):
287
+ """The account that's liable for tax"""
288
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
289
+
290
+ account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
291
+ """The connected account being referenced when type is account"""
292
+ type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
293
+ """Type of the account referenced"""
294
+
295
+ class SubscriptionAutomaticTax(BaseModel):
296
+ """Automatic tax settings for this subscription"""
297
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
298
+
299
+ disabled_reason: Union[str | None, Any] = Field(default=None, description="If Stripe disabled automatic tax, this enum describes why")
300
+ """If Stripe disabled automatic tax, this enum describes why"""
301
+ enabled: Union[bool, Any] = Field(default=None, description="Whether Stripe automatically computes tax on this subscription")
302
+ """Whether Stripe automatically computes tax on this subscription"""
303
+ liability: Union[SubscriptionAutomaticTaxLiability | None, Any] = Field(default=None, description="The account that's liable for tax")
304
+ """The account that's liable for tax"""
305
+
306
+ class SubscriptionBillingThresholds(BaseModel):
307
+ """Define thresholds at which an invoice will be sent, and the subscription advanced to a new billing period"""
308
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
309
+
310
+ amount_gte: Union[int | None, Any] = Field(default=None, description="Monetary threshold that triggers the subscription to create an invoice")
311
+ """Monetary threshold that triggers the subscription to create an invoice"""
312
+ reset_billing_cycle_anchor: Union[bool | None, Any] = Field(default=None, description="Indicates if the billing_cycle_anchor should be reset when a threshold is reached")
313
+ """Indicates if the billing_cycle_anchor should be reset when a threshold is reached"""
314
+
315
+ class SubscriptionPauseCollection(BaseModel):
316
+ """If specified, payment collection for this subscription will be paused"""
317
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
318
+
319
+ behavior: Union[str, Any] = Field(default=None, description="The payment collection behavior for this subscription while paused")
320
+ """The payment collection behavior for this subscription while paused"""
321
+ resumes_at: Union[int | None, Any] = Field(default=None, description="The time after which the subscription will resume collecting payments")
322
+ """The time after which the subscription will resume collecting payments"""
323
+
324
+ class SubscriptionDefaultTaxRatesItemFlatAmount(BaseModel):
325
+ """The amount of the tax rate when the rate_type is flat_amount"""
326
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
327
+
328
+ amount: Union[int, Any] = Field(default=None, description="Amount of the tax when the rate_type is flat_amount")
329
+ """Amount of the tax when the rate_type is flat_amount"""
330
+ currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code, in lowercase")
331
+ """Three-letter ISO currency code, in lowercase"""
332
+
333
+ class SubscriptionDefaultTaxRatesItem(BaseModel):
334
+ """Nested schema for Subscription.default_tax_rates_item"""
335
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
336
+
337
+ id: Union[str, Any] = Field(default=None, description="Unique identifier for the object")
338
+ """Unique identifier for the object"""
339
+ object: Union[str, Any] = Field(default=None, description="String representing the object's type")
340
+ """String representing the object's type"""
341
+ active: Union[bool, Any] = Field(default=None, description="Defaults to true")
342
+ """Defaults to true"""
343
+ country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
344
+ """Two-letter country code (ISO 3166-1 alpha-2)"""
345
+ created: Union[int, Any] = Field(default=None, description="Time at which the object was created")
346
+ """Time at which the object was created"""
347
+ description: Union[str | None, Any] = Field(default=None, description="An arbitrary string attached to the tax rate for your internal use only")
348
+ """An arbitrary string attached to the tax rate for your internal use only"""
349
+ display_name: Union[str, Any] = Field(default=None, description="The display name of the tax rates")
350
+ """The display name of the tax rates"""
351
+ effective_percentage: Union[float | None, Any] = Field(default=None, description="Actual/effective tax rate percentage out of 100")
352
+ """Actual/effective tax rate percentage out of 100"""
353
+ flat_amount: Union[SubscriptionDefaultTaxRatesItemFlatAmount | None, Any] = Field(default=None, description="The amount of the tax rate when the rate_type is flat_amount")
354
+ """The amount of the tax rate when the rate_type is flat_amount"""
355
+ inclusive: Union[bool, Any] = Field(default=None, description="This specifies if the tax rate is inclusive or exclusive")
356
+ """This specifies if the tax rate is inclusive or exclusive"""
357
+ jurisdiction: Union[str | None, Any] = Field(default=None, description="The jurisdiction for the tax rate")
358
+ """The jurisdiction for the tax rate"""
359
+ jurisdiction_level: Union[str | None, Any] = Field(default=None, description="The level of the jurisdiction that imposes this tax rate")
360
+ """The level of the jurisdiction that imposes this tax rate"""
361
+ livemode: Union[bool, Any] = Field(default=None, description="Has the value true if the object exists in live mode or false if in test mode")
362
+ """Has the value true if the object exists in live mode or false if in test mode"""
363
+ metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs")
364
+ """Set of key-value pairs"""
365
+ percentage: Union[float, Any] = Field(default=None, description="Tax rate percentage out of 100")
366
+ """Tax rate percentage out of 100"""
367
+ rate_type: Union[str | None, Any] = Field(default=None, description="Indicates the type of tax rate applied to the taxable amount")
368
+ """Indicates the type of tax rate applied to the taxable amount"""
369
+ state: Union[str | None, Any] = Field(default=None, description="ISO 3166-2 subdivision code, without country prefix")
370
+ """ISO 3166-2 subdivision code, without country prefix"""
371
+ tax_type: Union[str | None, Any] = Field(default=None, description="The high-level tax type")
372
+ """The high-level tax type"""
373
+
374
+ class Subscription(BaseModel):
375
+ """Subscription type definition"""
376
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
377
+
378
+ id: Union[str, Any] = Field(default=None)
379
+ object: Union[str, Any] = Field(default=None)
380
+ application: Union[str | None, Any] = Field(default=None)
449
381
  application_fee_percent: Union[float | None, Any] = Field(default=None)
450
382
  automatic_tax: Union[SubscriptionAutomaticTax, Any] = Field(default=None)
451
383
  billing_cycle_anchor: Union[int, Any] = Field(default=None)
@@ -507,6 +439,74 @@ class CustomerSubscriptions(BaseModel):
507
439
  url: Union[str, Any] = Field(default=None, description="The URL where this list can be accessed")
508
440
  """The URL where this list can be accessed"""
509
441
 
442
+ class CustomerShippingAddress(BaseModel):
443
+ """Customer shipping address"""
444
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
445
+
446
+ city: Union[str | None, Any] = Field(default=None, description="City, district, suburb, town, or village")
447
+ """City, district, suburb, town, or village"""
448
+ country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
449
+ """Two-letter country code (ISO 3166-1 alpha-2)"""
450
+ line1: Union[str | None, Any] = Field(default=None, description="Address line 1, such as the street, PO Box, or company name")
451
+ """Address line 1, such as the street, PO Box, or company name"""
452
+ line2: Union[str | None, Any] = Field(default=None, description="Address line 2, such as the apartment, suite, unit, or building")
453
+ """Address line 2, such as the apartment, suite, unit, or building"""
454
+ postal_code: Union[str | None, Any] = Field(default=None, description="ZIP or postal code")
455
+ """ZIP or postal code"""
456
+ state: Union[str | None, Any] = Field(default=None, description="State, county, province, or region")
457
+ """State, county, province, or region"""
458
+
459
+ class CustomerShipping(BaseModel):
460
+ """Mailing and shipping address for the customer"""
461
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
462
+
463
+ address: Union[CustomerShippingAddress, Any] = Field(default=None, description="Customer shipping address")
464
+ """Customer shipping address"""
465
+ name: Union[str, Any] = Field(default=None, description="Customer name")
466
+ """Customer name"""
467
+ phone: Union[str | None, Any] = Field(default=None, description="Customer phone (including extension)")
468
+ """Customer phone (including extension)"""
469
+
470
+ class CustomerDiscountSource(BaseModel):
471
+ """The source of the discount"""
472
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
473
+
474
+ coupon: Union[str | None, Any] = Field(default=None, description="The coupon that was redeemed to create this discount")
475
+ """The coupon that was redeemed to create this discount"""
476
+ type: Union[str, Any] = Field(default=None, description="The source type of the discount")
477
+ """The source type of the discount"""
478
+
479
+ class CustomerDiscount(BaseModel):
480
+ """Describes the current discount active on the customer, if there is one"""
481
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
482
+
483
+ id: Union[str, Any] = Field(default=None, description="The ID of the discount object")
484
+ """The ID of the discount object"""
485
+ object: Union[str, Any] = Field(default=None, description="String representing the object's type")
486
+ """String representing the object's type"""
487
+ checkout_session: Union[str | None, Any] = Field(default=None, description="The Checkout session that this coupon is applied to, if applicable")
488
+ """The Checkout session that this coupon is applied to, if applicable"""
489
+ customer: Union[str | None, Any] = Field(default=None, description="The ID of the customer associated with this discount")
490
+ """The ID of the customer associated with this discount"""
491
+ customer_account: Union[str | None, Any] = Field(default=None, description="The ID of the account associated with this discount")
492
+ """The ID of the account associated with this discount"""
493
+ end: Union[int | None, Any] = Field(default=None, description="If the coupon has a duration of repeating, the date that this discount will end")
494
+ """If the coupon has a duration of repeating, the date that this discount will end"""
495
+ invoice: Union[str | None, Any] = Field(default=None, description="The invoice that the discount's coupon was applied to")
496
+ """The invoice that the discount's coupon was applied to"""
497
+ invoice_item: Union[str | None, Any] = Field(default=None, description="The invoice item that the discount's coupon was applied to")
498
+ """The invoice item that the discount's coupon was applied to"""
499
+ promotion_code: Union[str | None, Any] = Field(default=None, description="The promotion code applied to create this discount")
500
+ """The promotion code applied to create this discount"""
501
+ source: Union[CustomerDiscountSource, Any] = Field(default=None, description="The source of the discount")
502
+ """The source of the discount"""
503
+ start: Union[int, Any] = Field(default=None, description="Date that the coupon was applied")
504
+ """Date that the coupon was applied"""
505
+ subscription: Union[str | None, Any] = Field(default=None, description="The subscription that this coupon is applied to")
506
+ """The subscription that this coupon is applied to"""
507
+ subscription_item: Union[str | None, Any] = Field(default=None, description="The subscription item that this coupon is applied to")
508
+ """The subscription item that this coupon is applied to"""
509
+
510
510
  class Customer(BaseModel):
511
511
  """Customer type definition"""
512
512
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -551,204 +551,102 @@ class CustomerList(BaseModel):
551
551
  has_more: Union[bool, Any] = Field(default=None)
552
552
  url: Union[str, Any] = Field(default=None)
553
553
 
554
- class InvoiceConfirmationSecret(BaseModel):
555
- """The confirmation secret associated with this invoice"""
554
+ class CustomerCreateParamsAddress(BaseModel):
555
+ """The customer's address"""
556
556
  model_config = ConfigDict(extra="allow", populate_by_name=True)
557
557
 
558
- client_secret: Union[str, Any] = Field(default=None, description="The client_secret of the payment that Stripe creates for the invoice after finalization")
559
- """The client_secret of the payment that Stripe creates for the invoice after finalization"""
560
- type: Union[str, Any] = Field(default=None, description="The type of client_secret")
561
- """The type of client_secret"""
558
+ line1: Union[str, Any] = Field(default=None, description="Address line 1")
559
+ """Address line 1"""
560
+ line2: Union[str, Any] = Field(default=None, description="Address line 2")
561
+ """Address line 2"""
562
+ city: Union[str, Any] = Field(default=None, description="City, district, suburb, town, or village")
563
+ """City, district, suburb, town, or village"""
564
+ state: Union[str, Any] = Field(default=None, description="State, county, province, or region")
565
+ """State, county, province, or region"""
566
+ postal_code: Union[str, Any] = Field(default=None, description="ZIP or postal code")
567
+ """ZIP or postal code"""
568
+ country: Union[str, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
569
+ """Two-letter country code (ISO 3166-1 alpha-2)"""
562
570
 
563
- class InvoiceSubscriptionDetails(BaseModel):
564
- """Details about the subscription that this invoice was prepared for, if any"""
571
+ class CustomerCreateParams(BaseModel):
572
+ """CustomerCreateParams type definition"""
565
573
  model_config = ConfigDict(extra="allow", populate_by_name=True)
566
574
 
567
- metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs defined as subscription metadata when the invoice is created")
568
- """Set of key-value pairs defined as subscription metadata when the invoice is created"""
575
+ email: Union[str, Any] = Field(default=None)
576
+ name: Union[str, Any] = Field(default=None)
577
+ description: Union[str, Any] = Field(default=None)
578
+ phone: Union[str, Any] = Field(default=None)
579
+ address: Union[CustomerCreateParamsAddress, Any] = Field(default=None)
580
+ metadata: Union[dict[str, str], Any] = Field(default=None)
569
581
 
570
- class InvoiceIssuer(BaseModel):
571
- """The connected account that issues the invoice"""
582
+ class CustomerUpdateParamsAddress(BaseModel):
583
+ """The customer's address"""
572
584
  model_config = ConfigDict(extra="allow", populate_by_name=True)
573
585
 
574
- account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
575
- """The connected account being referenced when type is account"""
576
- type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
577
- """Type of the account referenced"""
586
+ line1: Union[str, Any] = Field(default=None, description="Address line 1")
587
+ """Address line 1"""
588
+ line2: Union[str, Any] = Field(default=None, description="Address line 2")
589
+ """Address line 2"""
590
+ city: Union[str, Any] = Field(default=None, description="City, district, suburb, town, or village")
591
+ """City, district, suburb, town, or village"""
592
+ state: Union[str, Any] = Field(default=None, description="State, county, province, or region")
593
+ """State, county, province, or region"""
594
+ postal_code: Union[str, Any] = Field(default=None, description="ZIP or postal code")
595
+ """ZIP or postal code"""
596
+ country: Union[str, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
597
+ """Two-letter country code (ISO 3166-1 alpha-2)"""
578
598
 
579
- class InvoiceTotalTaxAmountsItem(BaseModel):
580
- """Nested schema for Invoice.total_tax_amounts_item"""
599
+ class CustomerUpdateParams(BaseModel):
600
+ """CustomerUpdateParams type definition"""
581
601
  model_config = ConfigDict(extra="allow", populate_by_name=True)
582
602
 
583
- amount: Union[int, Any] = Field(default=None, description="The amount of the tax")
584
- """The amount of the tax"""
585
- inclusive: Union[bool, Any] = Field(default=None, description="Whether the tax amount is included in the line item amount")
586
- """Whether the tax amount is included in the line item amount"""
587
- tax_rate: Union[str, Any] = Field(default=None, description="The tax rate applied")
588
- """The tax rate applied"""
589
- taxability_reason: Union[str | None, Any] = Field(default=None, description="The reasoning behind the tax")
590
- """The reasoning behind the tax"""
591
- taxable_amount: Union[int, Any] = Field(default=None, description="The amount on which tax is calculated")
592
- """The amount on which tax is calculated"""
603
+ email: Union[str, Any] = Field(default=None)
604
+ name: Union[str, Any] = Field(default=None)
605
+ description: Union[str, Any] = Field(default=None)
606
+ phone: Union[str, Any] = Field(default=None)
607
+ address: Union[CustomerUpdateParamsAddress, Any] = Field(default=None)
608
+ metadata: Union[dict[str, str], Any] = Field(default=None)
593
609
 
594
- class InvoiceTotalDiscountAmountsItem(BaseModel):
595
- """Nested schema for Invoice.total_discount_amounts_item"""
610
+ class CustomerDeletedResponse(BaseModel):
611
+ """CustomerDeletedResponse type definition"""
596
612
  model_config = ConfigDict(extra="allow", populate_by_name=True)
597
613
 
598
- amount: Union[int, Any] = Field(default=None, description="The amount of the discount")
599
- """The amount of the discount"""
600
- discount: Union[str, Any] = Field(default=None, description="The discount that was applied")
601
- """The discount that was applied"""
614
+ id: Union[str, Any] = Field(default=None)
615
+ object: Union[str, Any] = Field(default=None)
616
+ deleted: Union[bool, Any] = Field(default=None)
602
617
 
603
- class InvoiceAutomaticTaxLiability(BaseModel):
604
- """The account that's liable for tax"""
618
+ class InvoiceCustomerTaxIdsItem(BaseModel):
619
+ """Nested schema for Invoice.customer_tax_ids_item"""
605
620
  model_config = ConfigDict(extra="allow", populate_by_name=True)
606
621
 
607
- account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
608
- """The connected account being referenced when type is account"""
609
- type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
610
- """Type of the account referenced"""
622
+ type: Union[str, Any] = Field(default=None, description="The type of the tax ID")
623
+ """The type of the tax ID"""
624
+ value: Union[str | None, Any] = Field(default=None, description="The value of the tax ID")
625
+ """The value of the tax ID"""
611
626
 
612
- class InvoiceAutomaticTax(BaseModel):
613
- """Settings and latest results for automatic tax lookup for this invoice"""
614
- model_config = ConfigDict(extra="allow", populate_by_name=True)
615
-
616
- disabled_reason: Union[str | None, Any] = Field(default=None, description="If Stripe disabled automatic tax, this enum describes why")
617
- """If Stripe disabled automatic tax, this enum describes why"""
618
- enabled: Union[bool, Any] = Field(default=None, description="Whether Stripe automatically computes tax on this invoice")
619
- """Whether Stripe automatically computes tax on this invoice"""
620
- liability: Union[InvoiceAutomaticTaxLiability | None, Any] = Field(default=None, description="The account that's liable for tax")
621
- """The account that's liable for tax"""
622
- provider: Union[str | None, Any] = Field(default=None, description="The tax provider powering automatic tax")
623
- """The tax provider powering automatic tax"""
624
- status: Union[str | None, Any] = Field(default=None, description="The status of the most recent automated tax calculation for this invoice")
625
- """The status of the most recent automated tax calculation for this invoice"""
626
-
627
- class InvoiceStatusTransitions(BaseModel):
628
- """Status transition timestamps"""
629
- model_config = ConfigDict(extra="allow", populate_by_name=True)
630
-
631
- finalized_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice draft was finalized")
632
- """The time that the invoice draft was finalized"""
633
- marked_uncollectible_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice was marked uncollectible")
634
- """The time that the invoice was marked uncollectible"""
635
- paid_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice was paid")
636
- """The time that the invoice was paid"""
637
- voided_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice was voided")
638
- """The time that the invoice was voided"""
639
-
640
- class InvoiceLinesDataItemDiscountAmountsItem(BaseModel):
641
- """Nested schema for InvoiceLinesDataItem.discount_amounts_item"""
642
- model_config = ConfigDict(extra="allow", populate_by_name=True)
643
-
644
- amount: Union[int, Any] = Field(default=None, description="The amount of the discount")
645
- """The amount of the discount"""
646
- discount: Union[str, Any] = Field(default=None, description="The discount that was applied")
647
- """The discount that was applied"""
648
-
649
- class InvoiceLinesDataItemPeriod(BaseModel):
650
- """The period this line_item covers"""
651
- model_config = ConfigDict(extra="allow", populate_by_name=True)
652
-
653
- end: Union[int, Any] = Field(default=None, description="The end of the period")
654
- """The end of the period"""
655
- start: Union[int, Any] = Field(default=None, description="The start of the period")
656
- """The start of the period"""
657
-
658
- class InvoiceLinesDataItem(BaseModel):
659
- """Nested schema for InvoiceLines.data_item"""
660
- model_config = ConfigDict(extra="allow", populate_by_name=True)
661
-
662
- id: Union[str, Any] = Field(default=None, description="Unique identifier for the object")
663
- """Unique identifier for the object"""
664
- object: Union[str, Any] = Field(default=None, description="String representing the object's type")
665
- """String representing the object's type"""
666
- amount: Union[int, Any] = Field(default=None, description="The amount in cents")
667
- """The amount in cents"""
668
- currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
669
- """Three-letter ISO currency code"""
670
- description: Union[str | None, Any] = Field(default=None, description="An arbitrary string attached to the object")
671
- """An arbitrary string attached to the object"""
672
- discount_amounts: Union[list[InvoiceLinesDataItemDiscountAmountsItem] | None, Any] = Field(default=None, description="The amount of discount calculated per discount for this line item")
673
- """The amount of discount calculated per discount for this line item"""
674
- discountable: Union[bool, Any] = Field(default=None, description="If true, discounts will apply to this line item")
675
- """If true, discounts will apply to this line item"""
676
- discounts: Union[list[str], Any] = Field(default=None, description="The discounts applied to the invoice line item")
677
- """The discounts applied to the invoice line item"""
678
- invoice: Union[str | None, Any] = Field(default=None, description="The ID of the invoice that contains this line item")
679
- """The ID of the invoice that contains this line item"""
680
- livemode: Union[bool, Any] = Field(default=None, description="Has the value true if the object exists in live mode")
681
- """Has the value true if the object exists in live mode"""
682
- metadata: Union[dict[str, str], Any] = Field(default=None, description="Set of key-value pairs")
683
- """Set of key-value pairs"""
684
- period: Union[InvoiceLinesDataItemPeriod, Any] = Field(default=None, description="The period this line_item covers")
685
- """The period this line_item covers"""
686
- proration: Union[bool, Any] = Field(default=None, description="Whether this is a proration")
687
- """Whether this is a proration"""
688
- quantity: Union[int | None, Any] = Field(default=None, description="The quantity of the subscription")
689
- """The quantity of the subscription"""
690
-
691
- class InvoiceLines(BaseModel):
692
- """The individual line items that make up the invoice"""
693
- model_config = ConfigDict(extra="allow", populate_by_name=True)
694
-
695
- object: Union[str, Any] = Field(default=None)
696
- data: Union[list[InvoiceLinesDataItem], Any] = Field(default=None)
697
- has_more: Union[bool, Any] = Field(default=None)
698
- total_count: Union[int | None, Any] = Field(default=None)
699
- url: Union[str | None, Any] = Field(default=None)
700
-
701
- class InvoiceShippingDetailsAddress(BaseModel):
702
- """Shipping address"""
703
- model_config = ConfigDict(extra="allow", populate_by_name=True)
704
-
705
- city: Union[str | None, Any] = Field(default=None, description="City, district, suburb, town, or village")
706
- """City, district, suburb, town, or village"""
707
- country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
708
- """Two-letter country code (ISO 3166-1 alpha-2)"""
709
- line1: Union[str | None, Any] = Field(default=None, description="Address line 1")
710
- """Address line 1"""
711
- line2: Union[str | None, Any] = Field(default=None, description="Address line 2")
712
- """Address line 2"""
713
- postal_code: Union[str | None, Any] = Field(default=None, description="ZIP or postal code")
714
- """ZIP or postal code"""
715
- state: Union[str | None, Any] = Field(default=None, description="State, county, province, or region")
716
- """State, county, province, or region"""
717
-
718
- class InvoiceShippingDetails(BaseModel):
719
- """Shipping details for the invoice"""
720
- model_config = ConfigDict(extra="allow", populate_by_name=True)
721
-
722
- address: Union[InvoiceShippingDetailsAddress, Any] = Field(default=None, description="Shipping address")
723
- """Shipping address"""
724
- name: Union[str, Any] = Field(default=None, description="Recipient name")
725
- """Recipient name"""
726
- phone: Union[str | None, Any] = Field(default=None, description="Recipient phone")
727
- """Recipient phone"""
728
-
729
- class InvoiceFromInvoice(BaseModel):
730
- """Details of the invoice that was cloned"""
627
+ class InvoiceFromInvoice(BaseModel):
628
+ """Details of the invoice that was cloned"""
731
629
  model_config = ConfigDict(extra="allow", populate_by_name=True)
732
630
 
733
631
  action: Union[str, Any] = Field(default=None)
734
632
  invoice: Union[str, Any] = Field(default=None)
735
633
 
736
- class InvoiceCustomerAddress(BaseModel):
737
- """The customer's address"""
634
+ class InvoiceTotalTaxesItem(BaseModel):
635
+ """Nested schema for Invoice.total_taxes_item"""
738
636
  model_config = ConfigDict(extra="allow", populate_by_name=True)
739
637
 
740
- city: Union[str | None, Any] = Field(default=None, description="City, district, suburb, town, or village")
741
- """City, district, suburb, town, or village"""
742
- country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
743
- """Two-letter country code (ISO 3166-1 alpha-2)"""
744
- line1: Union[str | None, Any] = Field(default=None, description="Address line 1")
745
- """Address line 1"""
746
- line2: Union[str | None, Any] = Field(default=None, description="Address line 2")
747
- """Address line 2"""
748
- postal_code: Union[str | None, Any] = Field(default=None, description="ZIP or postal code")
749
- """ZIP or postal code"""
750
- state: Union[str | None, Any] = Field(default=None, description="State, county, province, or region")
751
- """State, county, province, or region"""
638
+ amount: Union[int, Any] = Field(default=None, description="The amount of the tax")
639
+ """The amount of the tax"""
640
+ tax_behavior: Union[str, Any] = Field(default=None, description="Whether this tax is inclusive or exclusive")
641
+ """Whether this tax is inclusive or exclusive"""
642
+ tax_rate_details: Union[dict[str, Any] | None, Any] = Field(default=None, description="Additional details about the tax rate")
643
+ """Additional details about the tax rate"""
644
+ taxability_reason: Union[str, Any] = Field(default=None, description="The reasoning behind this tax")
645
+ """The reasoning behind this tax"""
646
+ taxable_amount: Union[int | None, Any] = Field(default=None, description="The amount on which tax is calculated")
647
+ """The amount on which tax is calculated"""
648
+ type: Union[str, Any] = Field(default=None, description="The type of tax information")
649
+ """The type of tax information"""
752
650
 
753
651
  class InvoiceThresholdReasonItemReasonsItem(BaseModel):
754
652
  """Nested schema for InvoiceThresholdReason.item_reasons_item"""
@@ -768,58 +666,79 @@ class InvoiceThresholdReason(BaseModel):
768
666
  item_reasons: Union[list[InvoiceThresholdReasonItemReasonsItem], Any] = Field(default=None, description="Indicates which line items triggered a threshold invoice")
769
667
  """Indicates which line items triggered a threshold invoice"""
770
668
 
771
- class InvoiceTotalPretaxCreditAmountsItem(BaseModel):
772
- """Nested schema for Invoice.total_pretax_credit_amounts_item"""
773
- model_config = ConfigDict(extra="allow", populate_by_name=True)
774
-
775
- amount: Union[int, Any] = Field(default=None, description="The amount of the pretax credit amount")
776
- """The amount of the pretax credit amount"""
777
- credit_balance_transaction: Union[str | None, Any] = Field(default=None, description="The credit balance transaction that was applied")
778
- """The credit balance transaction that was applied"""
779
- discount: Union[str | None, Any] = Field(default=None, description="The discount that was applied")
780
- """The discount that was applied"""
781
- type: Union[str, Any] = Field(default=None, description="Type of the pretax credit amount referenced")
782
- """Type of the pretax credit amount referenced"""
783
-
784
- class InvoicePaymentSettings(BaseModel):
785
- """Configuration settings for the PaymentIntent that is generated when the invoice is finalized"""
669
+ class InvoiceDefaultTaxRatesItemFlatAmount(BaseModel):
670
+ """The amount of the tax rate when the rate_type is flat_amount"""
786
671
  model_config = ConfigDict(extra="allow", populate_by_name=True)
787
672
 
788
- default_mandate: Union[str | None, Any] = Field(default=None, description="ID of the mandate to be used for this invoice")
789
- """ID of the mandate to be used for this invoice"""
790
- payment_method_options: Union[dict[str, Any] | None, Any] = Field(default=None, description="Payment-method-specific configuration to provide to the invoice's PaymentIntent")
791
- """Payment-method-specific configuration to provide to the invoice's PaymentIntent"""
792
- payment_method_types: Union[list[str] | None, Any] = Field(default=None, description="The list of payment method types to provide to the invoice's PaymentIntent")
793
- """The list of payment method types to provide to the invoice's PaymentIntent"""
673
+ amount: Union[int, Any] = Field(default=None, description="Amount of the tax when the rate_type is flat_amount")
674
+ """Amount of the tax when the rate_type is flat_amount"""
675
+ currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
676
+ """Three-letter ISO currency code"""
794
677
 
795
- class InvoiceCustomerTaxIdsItem(BaseModel):
796
- """Nested schema for Invoice.customer_tax_ids_item"""
678
+ class InvoiceDefaultTaxRatesItem(BaseModel):
679
+ """Nested schema for Invoice.default_tax_rates_item"""
797
680
  model_config = ConfigDict(extra="allow", populate_by_name=True)
798
681
 
799
- type: Union[str, Any] = Field(default=None, description="The type of the tax ID")
800
- """The type of the tax ID"""
801
- value: Union[str | None, Any] = Field(default=None, description="The value of the tax ID")
802
- """The value of the tax ID"""
682
+ id: Union[str, Any] = Field(default=None, description="Unique identifier for the object")
683
+ """Unique identifier for the object"""
684
+ object: Union[str, Any] = Field(default=None, description="String representing the object's type")
685
+ """String representing the object's type"""
686
+ active: Union[bool, Any] = Field(default=None, description="Defaults to true")
687
+ """Defaults to true"""
688
+ country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
689
+ """Two-letter country code (ISO 3166-1 alpha-2)"""
690
+ created: Union[int, Any] = Field(default=None, description="Time at which the object was created")
691
+ """Time at which the object was created"""
692
+ description: Union[str | None, Any] = Field(default=None, description="An arbitrary string attached to the tax rate for your internal use only")
693
+ """An arbitrary string attached to the tax rate for your internal use only"""
694
+ display_name: Union[str, Any] = Field(default=None, description="The display name of the tax rate")
695
+ """The display name of the tax rate"""
696
+ effective_percentage: Union[float | None, Any] = Field(default=None, description="Actual/effective tax rate percentage out of 100")
697
+ """Actual/effective tax rate percentage out of 100"""
698
+ inclusive: Union[bool, Any] = Field(default=None, description="This specifies if the tax rate is inclusive or exclusive")
699
+ """This specifies if the tax rate is inclusive or exclusive"""
700
+ jurisdiction: Union[str | None, Any] = Field(default=None, description="The jurisdiction for the tax rate")
701
+ """The jurisdiction for the tax rate"""
702
+ livemode: Union[bool, Any] = Field(default=None, description="Has the value true if the object exists in live mode")
703
+ """Has the value true if the object exists in live mode"""
704
+ metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs")
705
+ """Set of key-value pairs"""
706
+ percentage: Union[float, Any] = Field(default=None, description="Tax rate percentage out of 100")
707
+ """Tax rate percentage out of 100"""
708
+ flat_amount: Union[InvoiceDefaultTaxRatesItemFlatAmount | None, Any] = Field(default=None, description="The amount of the tax rate when the rate_type is flat_amount")
709
+ """The amount of the tax rate when the rate_type is flat_amount"""
710
+ jurisdiction_level: Union[str | None, Any] = Field(default=None, description="The level of the jurisdiction that imposes this tax rate")
711
+ """The level of the jurisdiction that imposes this tax rate"""
712
+ rate_type: Union[str | None, Any] = Field(default=None, description="Indicates the type of tax rate applied to the taxable amount")
713
+ """Indicates the type of tax rate applied to the taxable amount"""
714
+ state: Union[str | None, Any] = Field(default=None, description="ISO 3166-2 subdivision code")
715
+ """ISO 3166-2 subdivision code"""
716
+ tax_type: Union[str | None, Any] = Field(default=None, description="The high-level tax type")
717
+ """The high-level tax type"""
803
718
 
804
- class InvoiceRenderingPdf(BaseModel):
805
- """Invoice pdf rendering options"""
719
+ class InvoiceAutomaticTaxLiability(BaseModel):
720
+ """The account that's liable for tax"""
806
721
  model_config = ConfigDict(extra="allow", populate_by_name=True)
807
722
 
808
- page_size: Union[str | None, Any] = Field(default=None, description="Page size of invoice pdf")
809
- """Page size of invoice pdf"""
723
+ account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
724
+ """The connected account being referenced when type is account"""
725
+ type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
726
+ """Type of the account referenced"""
810
727
 
811
- class InvoiceRendering(BaseModel):
812
- """The rendering-related settings that control how the invoice is displayed"""
728
+ class InvoiceAutomaticTax(BaseModel):
729
+ """Settings and latest results for automatic tax lookup for this invoice"""
813
730
  model_config = ConfigDict(extra="allow", populate_by_name=True)
814
731
 
815
- amount_tax_display: Union[str | None, Any] = Field(default=None, description="How line-item prices and amounts will be displayed with respect to tax")
816
- """How line-item prices and amounts will be displayed with respect to tax"""
817
- pdf: Union[InvoiceRenderingPdf | None, Any] = Field(default=None, description="Invoice pdf rendering options")
818
- """Invoice pdf rendering options"""
819
- template: Union[str | None, Any] = Field(default=None, description="ID of the rendering template that the invoice is formatted by")
820
- """ID of the rendering template that the invoice is formatted by"""
821
- template_version: Union[int | None, Any] = Field(default=None, description="Version of the rendering template that the invoice is using")
822
- """Version of the rendering template that the invoice is using"""
732
+ disabled_reason: Union[str | None, Any] = Field(default=None, description="If Stripe disabled automatic tax, this enum describes why")
733
+ """If Stripe disabled automatic tax, this enum describes why"""
734
+ enabled: Union[bool, Any] = Field(default=None, description="Whether Stripe automatically computes tax on this invoice")
735
+ """Whether Stripe automatically computes tax on this invoice"""
736
+ liability: Union[InvoiceAutomaticTaxLiability | None, Any] = Field(default=None, description="The account that's liable for tax")
737
+ """The account that's liable for tax"""
738
+ provider: Union[str | None, Any] = Field(default=None, description="The tax provider powering automatic tax")
739
+ """The tax provider powering automatic tax"""
740
+ status: Union[str | None, Any] = Field(default=None, description="The status of the most recent automated tax calculation for this invoice")
741
+ """The status of the most recent automated tax calculation for this invoice"""
823
742
 
824
743
  class InvoiceLastFinalizationError(BaseModel):
825
744
  """The error encountered during the last finalization attempt"""
@@ -844,14 +763,47 @@ class InvoiceLastFinalizationError(BaseModel):
844
763
  type: Union[str, Any] = Field(default=None, description="The type of error returned")
845
764
  """The type of error returned"""
846
765
 
847
- class InvoiceDiscountCoupon(BaseModel):
848
- """Nested schema for InvoiceDiscount.coupon"""
766
+ class InvoiceCustomFieldsItem(BaseModel):
767
+ """Nested schema for Invoice.custom_fields_item"""
849
768
  model_config = ConfigDict(extra="allow", populate_by_name=True)
850
769
 
851
- id: Union[str, Any] = Field(default=None)
852
- object: Union[str, Any] = Field(default=None)
853
- amount_off: Union[int | None, Any] = Field(default=None)
854
- created: Union[int, Any] = Field(default=None)
770
+ name: Union[str, Any] = Field(default=None, description="The name of the custom field")
771
+ """The name of the custom field"""
772
+ value: Union[str, Any] = Field(default=None, description="The value of the custom field")
773
+ """The value of the custom field"""
774
+
775
+ class InvoiceCustomerAddress(BaseModel):
776
+ """The customer's address"""
777
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
778
+
779
+ city: Union[str | None, Any] = Field(default=None, description="City, district, suburb, town, or village")
780
+ """City, district, suburb, town, or village"""
781
+ country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
782
+ """Two-letter country code (ISO 3166-1 alpha-2)"""
783
+ line1: Union[str | None, Any] = Field(default=None, description="Address line 1")
784
+ """Address line 1"""
785
+ line2: Union[str | None, Any] = Field(default=None, description="Address line 2")
786
+ """Address line 2"""
787
+ postal_code: Union[str | None, Any] = Field(default=None, description="ZIP or postal code")
788
+ """ZIP or postal code"""
789
+ state: Union[str | None, Any] = Field(default=None, description="State, county, province, or region")
790
+ """State, county, province, or region"""
791
+
792
+ class InvoiceSubscriptionDetails(BaseModel):
793
+ """Details about the subscription that this invoice was prepared for, if any"""
794
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
795
+
796
+ metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs defined as subscription metadata when the invoice is created")
797
+ """Set of key-value pairs defined as subscription metadata when the invoice is created"""
798
+
799
+ class InvoiceDiscountCoupon(BaseModel):
800
+ """Nested schema for InvoiceDiscount.coupon"""
801
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
802
+
803
+ id: Union[str, Any] = Field(default=None)
804
+ object: Union[str, Any] = Field(default=None)
805
+ amount_off: Union[int | None, Any] = Field(default=None)
806
+ created: Union[int, Any] = Field(default=None)
855
807
  currency: Union[str | None, Any] = Field(default=None)
856
808
  duration: Union[str, Any] = Field(default=None)
857
809
  duration_in_months: Union[int | None, Any] = Field(default=None)
@@ -882,46 +834,190 @@ class InvoiceDiscount(BaseModel):
882
834
  subscription: Union[str | None, Any] = Field(default=None)
883
835
  subscription_item: Union[str | None, Any] = Field(default=None)
884
836
 
885
- class InvoicePaymentsDataItem(BaseModel):
886
- """Nested schema for InvoicePayments.data_item"""
837
+ class InvoiceTotalDiscountAmountsItem(BaseModel):
838
+ """Nested schema for Invoice.total_discount_amounts_item"""
839
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
840
+
841
+ amount: Union[int, Any] = Field(default=None, description="The amount of the discount")
842
+ """The amount of the discount"""
843
+ discount: Union[str, Any] = Field(default=None, description="The discount that was applied")
844
+ """The discount that was applied"""
845
+
846
+ class InvoiceTotalTaxAmountsItem(BaseModel):
847
+ """Nested schema for Invoice.total_tax_amounts_item"""
848
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
849
+
850
+ amount: Union[int, Any] = Field(default=None, description="The amount of the tax")
851
+ """The amount of the tax"""
852
+ inclusive: Union[bool, Any] = Field(default=None, description="Whether the tax amount is included in the line item amount")
853
+ """Whether the tax amount is included in the line item amount"""
854
+ tax_rate: Union[str, Any] = Field(default=None, description="The tax rate applied")
855
+ """The tax rate applied"""
856
+ taxability_reason: Union[str | None, Any] = Field(default=None, description="The reasoning behind the tax")
857
+ """The reasoning behind the tax"""
858
+ taxable_amount: Union[int, Any] = Field(default=None, description="The amount on which tax is calculated")
859
+ """The amount on which tax is calculated"""
860
+
861
+ class InvoiceIssuer(BaseModel):
862
+ """The connected account that issues the invoice"""
863
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
864
+
865
+ account: Union[str | None, Any] = Field(default=None, description="The connected account being referenced when type is account")
866
+ """The connected account being referenced when type is account"""
867
+ type: Union[str, Any] = Field(default=None, description="Type of the account referenced")
868
+ """Type of the account referenced"""
869
+
870
+ class InvoiceShippingCostTaxesItem(BaseModel):
871
+ """Nested schema for InvoiceShippingCost.taxes_item"""
872
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
873
+
874
+ amount: Union[int, Any] = Field(default=None, description="Amount of tax applied for this rate")
875
+ """Amount of tax applied for this rate"""
876
+ taxability_reason: Union[str | None, Any] = Field(default=None, description="The reasoning behind this tax")
877
+ """The reasoning behind this tax"""
878
+ taxable_amount: Union[int | None, Any] = Field(default=None, description="The amount on which tax is calculated")
879
+ """The amount on which tax is calculated"""
880
+
881
+ class InvoiceShippingCost(BaseModel):
882
+ """The details of the cost of shipping"""
883
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
884
+
885
+ amount_subtotal: Union[int, Any] = Field(default=None, description="Total shipping cost before any taxes are applied")
886
+ """Total shipping cost before any taxes are applied"""
887
+ amount_tax: Union[int, Any] = Field(default=None, description="Total tax amount applied due to shipping costs")
888
+ """Total tax amount applied due to shipping costs"""
889
+ amount_total: Union[int, Any] = Field(default=None, description="Total shipping cost after taxes are applied")
890
+ """Total shipping cost after taxes are applied"""
891
+ shipping_rate: Union[str | None, Any] = Field(default=None, description="The ID of the ShippingRate for this invoice")
892
+ """The ID of the ShippingRate for this invoice"""
893
+ taxes: Union[list[InvoiceShippingCostTaxesItem] | None, Any] = Field(default=None, description="The taxes applied to the shipping rate")
894
+ """The taxes applied to the shipping rate"""
895
+
896
+ class InvoiceLinesDataItemPeriod(BaseModel):
897
+ """The period this line_item covers"""
898
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
899
+
900
+ end: Union[int, Any] = Field(default=None, description="The end of the period")
901
+ """The end of the period"""
902
+ start: Union[int, Any] = Field(default=None, description="The start of the period")
903
+ """The start of the period"""
904
+
905
+ class InvoiceLinesDataItemDiscountAmountsItem(BaseModel):
906
+ """Nested schema for InvoiceLinesDataItem.discount_amounts_item"""
907
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
908
+
909
+ amount: Union[int, Any] = Field(default=None, description="The amount of the discount")
910
+ """The amount of the discount"""
911
+ discount: Union[str, Any] = Field(default=None, description="The discount that was applied")
912
+ """The discount that was applied"""
913
+
914
+ class InvoiceLinesDataItem(BaseModel):
915
+ """Nested schema for InvoiceLines.data_item"""
887
916
  model_config = ConfigDict(extra="allow", populate_by_name=True)
888
917
 
889
918
  id: Union[str, Any] = Field(default=None, description="Unique identifier for the object")
890
919
  """Unique identifier for the object"""
891
920
  object: Union[str, Any] = Field(default=None, description="String representing the object's type")
892
921
  """String representing the object's type"""
893
- amount_paid: Union[int | None, Any] = Field(default=None, description="Amount that was actually paid for this invoice")
894
- """Amount that was actually paid for this invoice"""
895
- amount_requested: Union[int, Any] = Field(default=None, description="Amount intended to be paid toward this invoice")
896
- """Amount intended to be paid toward this invoice"""
897
- created: Union[int, Any] = Field(default=None, description="Time at which the object was created")
898
- """Time at which the object was created"""
922
+ amount: Union[int, Any] = Field(default=None, description="The amount in cents")
923
+ """The amount in cents"""
899
924
  currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
900
925
  """Three-letter ISO currency code"""
901
- invoice: Union[str, Any] = Field(default=None, description="The invoice that was paid")
902
- """The invoice that was paid"""
903
- is_default: Union[bool, Any] = Field(default=None, description="Whether this is the default payment created when the invoice was finalized")
904
- """Whether this is the default payment created when the invoice was finalized"""
926
+ description: Union[str | None, Any] = Field(default=None, description="An arbitrary string attached to the object")
927
+ """An arbitrary string attached to the object"""
928
+ discount_amounts: Union[list[InvoiceLinesDataItemDiscountAmountsItem] | None, Any] = Field(default=None, description="The amount of discount calculated per discount for this line item")
929
+ """The amount of discount calculated per discount for this line item"""
930
+ discountable: Union[bool, Any] = Field(default=None, description="If true, discounts will apply to this line item")
931
+ """If true, discounts will apply to this line item"""
932
+ discounts: Union[list[str], Any] = Field(default=None, description="The discounts applied to the invoice line item")
933
+ """The discounts applied to the invoice line item"""
934
+ invoice: Union[str | None, Any] = Field(default=None, description="The ID of the invoice that contains this line item")
935
+ """The ID of the invoice that contains this line item"""
905
936
  livemode: Union[bool, Any] = Field(default=None, description="Has the value true if the object exists in live mode")
906
937
  """Has the value true if the object exists in live mode"""
907
- status: Union[str, Any] = Field(default=None, description="The status of the payment")
908
- """The status of the payment"""
938
+ metadata: Union[dict[str, str], Any] = Field(default=None, description="Set of key-value pairs")
939
+ """Set of key-value pairs"""
940
+ period: Union[InvoiceLinesDataItemPeriod, Any] = Field(default=None, description="The period this line_item covers")
941
+ """The period this line_item covers"""
942
+ proration: Union[bool, Any] = Field(default=None, description="Whether this is a proration")
943
+ """Whether this is a proration"""
944
+ quantity: Union[int | None, Any] = Field(default=None, description="The quantity of the subscription")
945
+ """The quantity of the subscription"""
909
946
 
910
- class InvoicePayments(BaseModel):
911
- """Payments for this invoice"""
947
+ class InvoiceLines(BaseModel):
948
+ """The individual line items that make up the invoice"""
912
949
  model_config = ConfigDict(extra="allow", populate_by_name=True)
913
950
 
914
- object: Union[str, Any] = Field(default=None, description="String representing the object's type")
915
- """String representing the object's type"""
916
- data: Union[list[InvoicePaymentsDataItem], Any] = Field(default=None, description="Details about each payment")
917
- """Details about each payment"""
918
- has_more: Union[bool, Any] = Field(default=None, description="True if this list has another page of items")
919
- """True if this list has another page of items"""
920
- url: Union[str, Any] = Field(default=None, description="The URL where this list can be accessed")
921
- """The URL where this list can be accessed"""
951
+ object: Union[str, Any] = Field(default=None)
952
+ data: Union[list[InvoiceLinesDataItem], Any] = Field(default=None)
953
+ has_more: Union[bool, Any] = Field(default=None)
954
+ total_count: Union[int | None, Any] = Field(default=None)
955
+ url: Union[str | None, Any] = Field(default=None)
922
956
 
923
- class InvoiceCustomerShippingAddress(BaseModel):
924
- """Customer shipping address"""
957
+ class InvoiceConfirmationSecret(BaseModel):
958
+ """The confirmation secret associated with this invoice"""
959
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
960
+
961
+ client_secret: Union[str, Any] = Field(default=None, description="The client_secret of the payment that Stripe creates for the invoice after finalization")
962
+ """The client_secret of the payment that Stripe creates for the invoice after finalization"""
963
+ type: Union[str, Any] = Field(default=None, description="The type of client_secret")
964
+ """The type of client_secret"""
965
+
966
+ class InvoiceParentQuoteDetails(BaseModel):
967
+ """Details about the quote that generated this invoice"""
968
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
969
+
970
+ quote: Union[str, Any] = Field(default=None, description="The quote that generated this invoice")
971
+ """The quote that generated this invoice"""
972
+
973
+ class InvoiceParentSubscriptionDetails(BaseModel):
974
+ """Details about the subscription that generated this invoice"""
975
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
976
+
977
+ metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs defined as subscription metadata")
978
+ """Set of key-value pairs defined as subscription metadata"""
979
+ subscription: Union[str, Any] = Field(default=None, description="The subscription that generated this invoice")
980
+ """The subscription that generated this invoice"""
981
+ subscription_proration_date: Union[int | None, Any] = Field(default=None, description="Only set for upcoming invoices that preview prorations")
982
+ """Only set for upcoming invoices that preview prorations"""
983
+
984
+ class InvoiceParent(BaseModel):
985
+ """The parent that generated this invoice"""
986
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
987
+
988
+ quote_details: Union[InvoiceParentQuoteDetails | None, Any] = Field(default=None, description="Details about the quote that generated this invoice")
989
+ """Details about the quote that generated this invoice"""
990
+ subscription_details: Union[InvoiceParentSubscriptionDetails | None, Any] = Field(default=None, description="Details about the subscription that generated this invoice")
991
+ """Details about the subscription that generated this invoice"""
992
+ type: Union[str, Any] = Field(default=None, description="The type of parent that generated this invoice")
993
+ """The type of parent that generated this invoice"""
994
+
995
+ class InvoiceTotalPretaxCreditAmountsItem(BaseModel):
996
+ """Nested schema for Invoice.total_pretax_credit_amounts_item"""
997
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
998
+
999
+ amount: Union[int, Any] = Field(default=None, description="The amount of the pretax credit amount")
1000
+ """The amount of the pretax credit amount"""
1001
+ credit_balance_transaction: Union[str | None, Any] = Field(default=None, description="The credit balance transaction that was applied")
1002
+ """The credit balance transaction that was applied"""
1003
+ discount: Union[str | None, Any] = Field(default=None, description="The discount that was applied")
1004
+ """The discount that was applied"""
1005
+ type: Union[str, Any] = Field(default=None, description="Type of the pretax credit amount referenced")
1006
+ """Type of the pretax credit amount referenced"""
1007
+
1008
+ class InvoicePaymentSettings(BaseModel):
1009
+ """Configuration settings for the PaymentIntent that is generated when the invoice is finalized"""
1010
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1011
+
1012
+ default_mandate: Union[str | None, Any] = Field(default=None, description="ID of the mandate to be used for this invoice")
1013
+ """ID of the mandate to be used for this invoice"""
1014
+ payment_method_options: Union[dict[str, Any] | None, Any] = Field(default=None, description="Payment-method-specific configuration to provide to the invoice's PaymentIntent")
1015
+ """Payment-method-specific configuration to provide to the invoice's PaymentIntent"""
1016
+ payment_method_types: Union[list[str] | None, Any] = Field(default=None, description="The list of payment method types to provide to the invoice's PaymentIntent")
1017
+ """The list of payment method types to provide to the invoice's PaymentIntent"""
1018
+
1019
+ class InvoiceShippingDetailsAddress(BaseModel):
1020
+ """Shipping address"""
925
1021
  model_config = ConfigDict(extra="allow", populate_by_name=True)
926
1022
 
927
1023
  city: Union[str | None, Any] = Field(default=None, description="City, district, suburb, town, or village")
@@ -937,147 +1033,115 @@ class InvoiceCustomerShippingAddress(BaseModel):
937
1033
  state: Union[str | None, Any] = Field(default=None, description="State, county, province, or region")
938
1034
  """State, county, province, or region"""
939
1035
 
940
- class InvoiceCustomerShipping(BaseModel):
941
- """The customer's shipping information"""
1036
+ class InvoiceShippingDetails(BaseModel):
1037
+ """Shipping details for the invoice"""
942
1038
  model_config = ConfigDict(extra="allow", populate_by_name=True)
943
1039
 
944
- address: Union[InvoiceCustomerShippingAddress, Any] = Field(default=None, description="Customer shipping address")
945
- """Customer shipping address"""
946
- name: Union[str, Any] = Field(default=None, description="Customer name")
947
- """Customer name"""
948
- phone: Union[str | None, Any] = Field(default=None, description="Customer phone (including extension)")
949
- """Customer phone (including extension)"""
1040
+ address: Union[InvoiceShippingDetailsAddress, Any] = Field(default=None, description="Shipping address")
1041
+ """Shipping address"""
1042
+ name: Union[str, Any] = Field(default=None, description="Recipient name")
1043
+ """Recipient name"""
1044
+ phone: Union[str | None, Any] = Field(default=None, description="Recipient phone")
1045
+ """Recipient phone"""
950
1046
 
951
- class InvoiceDefaultTaxRatesItemFlatAmount(BaseModel):
952
- """The amount of the tax rate when the rate_type is flat_amount"""
1047
+ class InvoiceStatusTransitions(BaseModel):
1048
+ """Status transition timestamps"""
953
1049
  model_config = ConfigDict(extra="allow", populate_by_name=True)
954
1050
 
955
- amount: Union[int, Any] = Field(default=None, description="Amount of the tax when the rate_type is flat_amount")
956
- """Amount of the tax when the rate_type is flat_amount"""
957
- currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
958
- """Three-letter ISO currency code"""
1051
+ finalized_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice draft was finalized")
1052
+ """The time that the invoice draft was finalized"""
1053
+ marked_uncollectible_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice was marked uncollectible")
1054
+ """The time that the invoice was marked uncollectible"""
1055
+ paid_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice was paid")
1056
+ """The time that the invoice was paid"""
1057
+ voided_at: Union[int | None, Any] = Field(default=None, description="The time that the invoice was voided")
1058
+ """The time that the invoice was voided"""
959
1059
 
960
- class InvoiceDefaultTaxRatesItem(BaseModel):
961
- """Nested schema for Invoice.default_tax_rates_item"""
1060
+ class InvoicePaymentsDataItem(BaseModel):
1061
+ """Nested schema for InvoicePayments.data_item"""
962
1062
  model_config = ConfigDict(extra="allow", populate_by_name=True)
963
1063
 
964
1064
  id: Union[str, Any] = Field(default=None, description="Unique identifier for the object")
965
1065
  """Unique identifier for the object"""
966
1066
  object: Union[str, Any] = Field(default=None, description="String representing the object's type")
967
1067
  """String representing the object's type"""
968
- active: Union[bool, Any] = Field(default=None, description="Defaults to true")
969
- """Defaults to true"""
970
- country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
971
- """Two-letter country code (ISO 3166-1 alpha-2)"""
1068
+ amount_paid: Union[int | None, Any] = Field(default=None, description="Amount that was actually paid for this invoice")
1069
+ """Amount that was actually paid for this invoice"""
1070
+ amount_requested: Union[int, Any] = Field(default=None, description="Amount intended to be paid toward this invoice")
1071
+ """Amount intended to be paid toward this invoice"""
972
1072
  created: Union[int, Any] = Field(default=None, description="Time at which the object was created")
973
- """Time at which the object was created"""
974
- description: Union[str | None, Any] = Field(default=None, description="An arbitrary string attached to the tax rate for your internal use only")
975
- """An arbitrary string attached to the tax rate for your internal use only"""
976
- display_name: Union[str, Any] = Field(default=None, description="The display name of the tax rate")
977
- """The display name of the tax rate"""
978
- effective_percentage: Union[float | None, Any] = Field(default=None, description="Actual/effective tax rate percentage out of 100")
979
- """Actual/effective tax rate percentage out of 100"""
980
- inclusive: Union[bool, Any] = Field(default=None, description="This specifies if the tax rate is inclusive or exclusive")
981
- """This specifies if the tax rate is inclusive or exclusive"""
982
- jurisdiction: Union[str | None, Any] = Field(default=None, description="The jurisdiction for the tax rate")
983
- """The jurisdiction for the tax rate"""
984
- livemode: Union[bool, Any] = Field(default=None, description="Has the value true if the object exists in live mode")
985
- """Has the value true if the object exists in live mode"""
986
- metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs")
987
- """Set of key-value pairs"""
988
- percentage: Union[float, Any] = Field(default=None, description="Tax rate percentage out of 100")
989
- """Tax rate percentage out of 100"""
990
- flat_amount: Union[InvoiceDefaultTaxRatesItemFlatAmount | None, Any] = Field(default=None, description="The amount of the tax rate when the rate_type is flat_amount")
991
- """The amount of the tax rate when the rate_type is flat_amount"""
992
- jurisdiction_level: Union[str | None, Any] = Field(default=None, description="The level of the jurisdiction that imposes this tax rate")
993
- """The level of the jurisdiction that imposes this tax rate"""
994
- rate_type: Union[str | None, Any] = Field(default=None, description="Indicates the type of tax rate applied to the taxable amount")
995
- """Indicates the type of tax rate applied to the taxable amount"""
996
- state: Union[str | None, Any] = Field(default=None, description="ISO 3166-2 subdivision code")
997
- """ISO 3166-2 subdivision code"""
998
- tax_type: Union[str | None, Any] = Field(default=None, description="The high-level tax type")
999
- """The high-level tax type"""
1000
-
1001
- class InvoiceCustomFieldsItem(BaseModel):
1002
- """Nested schema for Invoice.custom_fields_item"""
1003
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1004
-
1005
- name: Union[str, Any] = Field(default=None, description="The name of the custom field")
1006
- """The name of the custom field"""
1007
- value: Union[str, Any] = Field(default=None, description="The value of the custom field")
1008
- """The value of the custom field"""
1009
-
1010
- class InvoiceShippingCostTaxesItem(BaseModel):
1011
- """Nested schema for InvoiceShippingCost.taxes_item"""
1012
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1013
-
1014
- amount: Union[int, Any] = Field(default=None, description="Amount of tax applied for this rate")
1015
- """Amount of tax applied for this rate"""
1016
- taxability_reason: Union[str | None, Any] = Field(default=None, description="The reasoning behind this tax")
1017
- """The reasoning behind this tax"""
1018
- taxable_amount: Union[int | None, Any] = Field(default=None, description="The amount on which tax is calculated")
1019
- """The amount on which tax is calculated"""
1073
+ """Time at which the object was created"""
1074
+ currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
1075
+ """Three-letter ISO currency code"""
1076
+ invoice: Union[str, Any] = Field(default=None, description="The invoice that was paid")
1077
+ """The invoice that was paid"""
1078
+ is_default: Union[bool, Any] = Field(default=None, description="Whether this is the default payment created when the invoice was finalized")
1079
+ """Whether this is the default payment created when the invoice was finalized"""
1080
+ livemode: Union[bool, Any] = Field(default=None, description="Has the value true if the object exists in live mode")
1081
+ """Has the value true if the object exists in live mode"""
1082
+ status: Union[str, Any] = Field(default=None, description="The status of the payment")
1083
+ """The status of the payment"""
1020
1084
 
1021
- class InvoiceShippingCost(BaseModel):
1022
- """The details of the cost of shipping"""
1085
+ class InvoicePayments(BaseModel):
1086
+ """Payments for this invoice"""
1023
1087
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1024
1088
 
1025
- amount_subtotal: Union[int, Any] = Field(default=None, description="Total shipping cost before any taxes are applied")
1026
- """Total shipping cost before any taxes are applied"""
1027
- amount_tax: Union[int, Any] = Field(default=None, description="Total tax amount applied due to shipping costs")
1028
- """Total tax amount applied due to shipping costs"""
1029
- amount_total: Union[int, Any] = Field(default=None, description="Total shipping cost after taxes are applied")
1030
- """Total shipping cost after taxes are applied"""
1031
- shipping_rate: Union[str | None, Any] = Field(default=None, description="The ID of the ShippingRate for this invoice")
1032
- """The ID of the ShippingRate for this invoice"""
1033
- taxes: Union[list[InvoiceShippingCostTaxesItem] | None, Any] = Field(default=None, description="The taxes applied to the shipping rate")
1034
- """The taxes applied to the shipping rate"""
1089
+ object: Union[str, Any] = Field(default=None, description="String representing the object's type")
1090
+ """String representing the object's type"""
1091
+ data: Union[list[InvoicePaymentsDataItem], Any] = Field(default=None, description="Details about each payment")
1092
+ """Details about each payment"""
1093
+ has_more: Union[bool, Any] = Field(default=None, description="True if this list has another page of items")
1094
+ """True if this list has another page of items"""
1095
+ url: Union[str, Any] = Field(default=None, description="The URL where this list can be accessed")
1096
+ """The URL where this list can be accessed"""
1035
1097
 
1036
- class InvoiceTotalTaxesItem(BaseModel):
1037
- """Nested schema for Invoice.total_taxes_item"""
1098
+ class InvoiceCustomerShippingAddress(BaseModel):
1099
+ """Customer shipping address"""
1038
1100
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1039
1101
 
1040
- amount: Union[int, Any] = Field(default=None, description="The amount of the tax")
1041
- """The amount of the tax"""
1042
- tax_behavior: Union[str, Any] = Field(default=None, description="Whether this tax is inclusive or exclusive")
1043
- """Whether this tax is inclusive or exclusive"""
1044
- tax_rate_details: Union[dict[str, Any] | None, Any] = Field(default=None, description="Additional details about the tax rate")
1045
- """Additional details about the tax rate"""
1046
- taxability_reason: Union[str, Any] = Field(default=None, description="The reasoning behind this tax")
1047
- """The reasoning behind this tax"""
1048
- taxable_amount: Union[int | None, Any] = Field(default=None, description="The amount on which tax is calculated")
1049
- """The amount on which tax is calculated"""
1050
- type: Union[str, Any] = Field(default=None, description="The type of tax information")
1051
- """The type of tax information"""
1102
+ city: Union[str | None, Any] = Field(default=None, description="City, district, suburb, town, or village")
1103
+ """City, district, suburb, town, or village"""
1104
+ country: Union[str | None, Any] = Field(default=None, description="Two-letter country code (ISO 3166-1 alpha-2)")
1105
+ """Two-letter country code (ISO 3166-1 alpha-2)"""
1106
+ line1: Union[str | None, Any] = Field(default=None, description="Address line 1")
1107
+ """Address line 1"""
1108
+ line2: Union[str | None, Any] = Field(default=None, description="Address line 2")
1109
+ """Address line 2"""
1110
+ postal_code: Union[str | None, Any] = Field(default=None, description="ZIP or postal code")
1111
+ """ZIP or postal code"""
1112
+ state: Union[str | None, Any] = Field(default=None, description="State, county, province, or region")
1113
+ """State, county, province, or region"""
1052
1114
 
1053
- class InvoiceParentSubscriptionDetails(BaseModel):
1054
- """Details about the subscription that generated this invoice"""
1115
+ class InvoiceCustomerShipping(BaseModel):
1116
+ """The customer's shipping information"""
1055
1117
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1056
1118
 
1057
- metadata: Union[dict[str, str] | None, Any] = Field(default=None, description="Set of key-value pairs defined as subscription metadata")
1058
- """Set of key-value pairs defined as subscription metadata"""
1059
- subscription: Union[str, Any] = Field(default=None, description="The subscription that generated this invoice")
1060
- """The subscription that generated this invoice"""
1061
- subscription_proration_date: Union[int | None, Any] = Field(default=None, description="Only set for upcoming invoices that preview prorations")
1062
- """Only set for upcoming invoices that preview prorations"""
1119
+ address: Union[InvoiceCustomerShippingAddress, Any] = Field(default=None, description="Customer shipping address")
1120
+ """Customer shipping address"""
1121
+ name: Union[str, Any] = Field(default=None, description="Customer name")
1122
+ """Customer name"""
1123
+ phone: Union[str | None, Any] = Field(default=None, description="Customer phone (including extension)")
1124
+ """Customer phone (including extension)"""
1063
1125
 
1064
- class InvoiceParentQuoteDetails(BaseModel):
1065
- """Details about the quote that generated this invoice"""
1126
+ class InvoiceRenderingPdf(BaseModel):
1127
+ """Invoice pdf rendering options"""
1066
1128
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1067
1129
 
1068
- quote: Union[str, Any] = Field(default=None, description="The quote that generated this invoice")
1069
- """The quote that generated this invoice"""
1130
+ page_size: Union[str | None, Any] = Field(default=None, description="Page size of invoice pdf")
1131
+ """Page size of invoice pdf"""
1070
1132
 
1071
- class InvoiceParent(BaseModel):
1072
- """The parent that generated this invoice"""
1133
+ class InvoiceRendering(BaseModel):
1134
+ """The rendering-related settings that control how the invoice is displayed"""
1073
1135
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1074
1136
 
1075
- quote_details: Union[InvoiceParentQuoteDetails | None, Any] = Field(default=None, description="Details about the quote that generated this invoice")
1076
- """Details about the quote that generated this invoice"""
1077
- subscription_details: Union[InvoiceParentSubscriptionDetails | None, Any] = Field(default=None, description="Details about the subscription that generated this invoice")
1078
- """Details about the subscription that generated this invoice"""
1079
- type: Union[str, Any] = Field(default=None, description="The type of parent that generated this invoice")
1080
- """The type of parent that generated this invoice"""
1137
+ amount_tax_display: Union[str | None, Any] = Field(default=None, description="How line-item prices and amounts will be displayed with respect to tax")
1138
+ """How line-item prices and amounts will be displayed with respect to tax"""
1139
+ pdf: Union[InvoiceRenderingPdf | None, Any] = Field(default=None, description="Invoice pdf rendering options")
1140
+ """Invoice pdf rendering options"""
1141
+ template: Union[str | None, Any] = Field(default=None, description="ID of the rendering template that the invoice is formatted by")
1142
+ """ID of the rendering template that the invoice is formatted by"""
1143
+ template_version: Union[int | None, Any] = Field(default=None, description="Version of the rendering template that the invoice is using")
1144
+ """Version of the rendering template that the invoice is using"""
1081
1145
 
1082
1146
  class Invoice(BaseModel):
1083
1147
  """Invoice type definition"""
@@ -1183,17 +1247,26 @@ class InvoiceList(BaseModel):
1183
1247
  has_more: Union[bool, Any] = Field(default=None)
1184
1248
  url: Union[str, Any] = Field(default=None)
1185
1249
 
1186
- class ChargeRefunds(BaseModel):
1187
- """A list of refunds that have been applied to the charge"""
1250
+ class ChargeBillingDetailsAddress(BaseModel):
1251
+ """Nested schema for ChargeBillingDetails.address"""
1188
1252
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1189
1253
 
1190
- object: Union[str, Any] = Field(default=None)
1191
- data: Union[list[dict[str, Any]], Any] = Field(default=None)
1192
- has_more: Union[bool, Any] = Field(default=None)
1193
- total_count: Union[int, Any] = Field(default=None, description="Total number of refunds")
1194
- """Total number of refunds"""
1195
- url: Union[str, Any] = Field(default=None, description="URL to access the refunds list")
1196
- """URL to access the refunds list"""
1254
+ city: Union[str | None, Any] = Field(default=None)
1255
+ country: Union[str | None, Any] = Field(default=None)
1256
+ line1: Union[str | None, Any] = Field(default=None)
1257
+ line2: Union[str | None, Any] = Field(default=None)
1258
+ postal_code: Union[str | None, Any] = Field(default=None)
1259
+ state: Union[str | None, Any] = Field(default=None)
1260
+
1261
+ class ChargeBillingDetails(BaseModel):
1262
+ """Billing information associated with the payment method"""
1263
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1264
+
1265
+ address: Union[ChargeBillingDetailsAddress | None, Any] = Field(default=None)
1266
+ email: Union[str | None, Any] = Field(default=None)
1267
+ name: Union[str | None, Any] = Field(default=None)
1268
+ phone: Union[str | None, Any] = Field(default=None)
1269
+ tax_id: Union[str | None, Any] = Field(default=None)
1197
1270
 
1198
1271
  class ChargeOutcome(BaseModel):
1199
1272
  """Details about whether the payment was accepted, and why"""
@@ -1209,6 +1282,15 @@ class ChargeOutcome(BaseModel):
1209
1282
  seller_message: Union[str, Any] = Field(default=None)
1210
1283
  type: Union[str, Any] = Field(default=None)
1211
1284
 
1285
+ class ChargeFraudDetails(BaseModel):
1286
+ """Information on fraud assessments for the charge"""
1287
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1288
+
1289
+ stripe_report: Union[str | None, Any] = Field(default=None, description="Assessments from Stripe. If set, the value is `fraudulent`.")
1290
+ """Assessments from Stripe. If set, the value is `fraudulent`."""
1291
+ user_report: Union[str | None, Any] = Field(default=None, description="Assessments from you or your users. Possible values are `fraudulent` and `safe`")
1292
+ """Assessments from you or your users. Possible values are `fraudulent` and `safe`"""
1293
+
1212
1294
  class ChargePresentmentDetails(BaseModel):
1213
1295
  """Currency presentation information for multi-currency charges"""
1214
1296
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1220,41 +1302,31 @@ class ChargePresentmentDetails(BaseModel):
1220
1302
  currency: Union[str | None, Any] = Field(default=None, description="Three-letter ISO currency code for presentment")
1221
1303
  """Three-letter ISO currency code for presentment"""
1222
1304
 
1223
- class ChargeFraudDetails(BaseModel):
1224
- """Information on fraud assessments for the charge"""
1225
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1226
-
1227
- stripe_report: Union[str | None, Any] = Field(default=None, description="Assessments from Stripe. If set, the value is `fraudulent`.")
1228
- """Assessments from Stripe. If set, the value is `fraudulent`."""
1229
- user_report: Union[str | None, Any] = Field(default=None, description="Assessments from you or your users. Possible values are `fraudulent` and `safe`")
1230
- """Assessments from you or your users. Possible values are `fraudulent` and `safe`"""
1231
-
1232
- class ChargeBillingDetailsAddress(BaseModel):
1233
- """Nested schema for ChargeBillingDetails.address"""
1305
+ class ChargeRefunds(BaseModel):
1306
+ """A list of refunds that have been applied to the charge"""
1234
1307
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1235
1308
 
1236
- city: Union[str | None, Any] = Field(default=None)
1237
- country: Union[str | None, Any] = Field(default=None)
1238
- line1: Union[str | None, Any] = Field(default=None)
1239
- line2: Union[str | None, Any] = Field(default=None)
1240
- postal_code: Union[str | None, Any] = Field(default=None)
1241
- state: Union[str | None, Any] = Field(default=None)
1309
+ object: Union[str, Any] = Field(default=None)
1310
+ data: Union[list[dict[str, Any]], Any] = Field(default=None)
1311
+ has_more: Union[bool, Any] = Field(default=None)
1312
+ total_count: Union[int, Any] = Field(default=None, description="Total number of refunds")
1313
+ """Total number of refunds"""
1314
+ url: Union[str, Any] = Field(default=None, description="URL to access the refunds list")
1315
+ """URL to access the refunds list"""
1242
1316
 
1243
- class ChargeBillingDetails(BaseModel):
1244
- """Billing information associated with the payment method"""
1317
+ class ChargePaymentMethodDetailsCardMulticapture(BaseModel):
1318
+ """Multicapture details"""
1245
1319
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1246
1320
 
1247
- address: Union[ChargeBillingDetailsAddress | None, Any] = Field(default=None)
1248
- email: Union[str | None, Any] = Field(default=None)
1249
- name: Union[str | None, Any] = Field(default=None)
1250
- phone: Union[str | None, Any] = Field(default=None)
1251
- tax_id: Union[str | None, Any] = Field(default=None)
1321
+ status: Union[str, Any] = Field(default=None)
1252
1322
 
1253
- class ChargePaymentMethodDetailsCardNetworkToken(BaseModel):
1254
- """Network token details"""
1323
+ class ChargePaymentMethodDetailsCardChecks(BaseModel):
1324
+ """Check results by Card networks on Card address and CVC"""
1255
1325
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1256
1326
 
1257
- used: Union[bool, Any] = Field(default=None)
1327
+ address_line1_check: Union[str | None, Any] = Field(default=None)
1328
+ address_postal_code_check: Union[str | None, Any] = Field(default=None)
1329
+ cvc_check: Union[str | None, Any] = Field(default=None)
1258
1330
 
1259
1331
  class ChargePaymentMethodDetailsCardIncrementalAuthorization(BaseModel):
1260
1332
  """Incremental authorization details"""
@@ -1262,12 +1334,6 @@ class ChargePaymentMethodDetailsCardIncrementalAuthorization(BaseModel):
1262
1334
 
1263
1335
  status: Union[str, Any] = Field(default=None)
1264
1336
 
1265
- class ChargePaymentMethodDetailsCardMulticapture(BaseModel):
1266
- """Multicapture details"""
1267
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1268
-
1269
- status: Union[str, Any] = Field(default=None)
1270
-
1271
1337
  class ChargePaymentMethodDetailsCardOvercapture(BaseModel):
1272
1338
  """Overcapture details"""
1273
1339
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1275,20 +1341,18 @@ class ChargePaymentMethodDetailsCardOvercapture(BaseModel):
1275
1341
  maximum_amount_capturable: Union[int, Any] = Field(default=None)
1276
1342
  status: Union[str, Any] = Field(default=None)
1277
1343
 
1278
- class ChargePaymentMethodDetailsCardChecks(BaseModel):
1279
- """Check results by Card networks on Card address and CVC"""
1280
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1281
-
1282
- address_line1_check: Union[str | None, Any] = Field(default=None)
1283
- address_postal_code_check: Union[str | None, Any] = Field(default=None)
1284
- cvc_check: Union[str | None, Any] = Field(default=None)
1285
-
1286
1344
  class ChargePaymentMethodDetailsCardExtendedAuthorization(BaseModel):
1287
1345
  """Extended authorization details"""
1288
1346
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1289
1347
 
1290
1348
  status: Union[str, Any] = Field(default=None)
1291
1349
 
1350
+ class ChargePaymentMethodDetailsCardNetworkToken(BaseModel):
1351
+ """Network token details"""
1352
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1353
+
1354
+ used: Union[bool, Any] = Field(default=None)
1355
+
1292
1356
  class ChargePaymentMethodDetailsCard(BaseModel):
1293
1357
  """Nested schema for ChargePaymentMethodDetails.card"""
1294
1358
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1418,28 +1482,39 @@ class SubscriptionList(BaseModel):
1418
1482
  has_more: Union[bool, Any] = Field(default=None)
1419
1483
  url: Union[str, Any] = Field(default=None)
1420
1484
 
1421
- class RefundDestinationDetailsBrBankTransfer(BaseModel):
1422
- """If this is a br_bank_transfer refund, this hash contains the transaction specific details"""
1485
+ class RefundNextActionDisplayDetailsEmailSent(BaseModel):
1486
+ """Contains information about the email sent to the customer"""
1423
1487
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1424
1488
 
1425
- reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1426
- """The reference assigned to the refund"""
1427
- reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1428
- """Status of the reference on the refund"""
1489
+ email_sent_at: Union[int, Any] = Field(default=None, description="The timestamp when the email was sent")
1490
+ """The timestamp when the email was sent"""
1491
+ email_sent_to: Union[str, Any] = Field(default=None, description="The recipient's email address")
1492
+ """The recipient's email address"""
1429
1493
 
1430
- class RefundDestinationDetailsGbBankTransfer(BaseModel):
1431
- """If this is a gb_bank_transfer refund, this hash contains the transaction specific details"""
1494
+ class RefundNextActionDisplayDetails(BaseModel):
1495
+ """Contains the refund details"""
1432
1496
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1433
1497
 
1434
- reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1435
- """The reference assigned to the refund"""
1436
- reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1437
- """Status of the reference on the refund"""
1498
+ email_sent: Union[RefundNextActionDisplayDetailsEmailSent, Any] = Field(default=None, description="Contains information about the email sent to the customer")
1499
+ """Contains information about the email sent to the customer"""
1500
+ expires_at: Union[int, Any] = Field(default=None, description="The expiry timestamp")
1501
+ """The expiry timestamp"""
1438
1502
 
1439
- class RefundDestinationDetailsP24(BaseModel):
1440
- """If this is a p24 refund, this hash contains the transaction specific details"""
1503
+ class RefundNextAction(BaseModel):
1504
+ """If the refund has a status of requires_action, this property describes what the refund needs to continue processing"""
1505
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1506
+
1507
+ display_details: Union[RefundNextActionDisplayDetails | None, Any] = Field(default=None, description="Contains the refund details")
1508
+ """Contains the refund details"""
1509
+ type: Union[str, Any] = Field(default=None, description="Type of the next action to perform")
1510
+ """Type of the next action to perform"""
1511
+
1512
+ class RefundDestinationDetailsBlik(BaseModel):
1513
+ """If this is a blik refund, this hash contains the transaction specific details"""
1441
1514
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1442
1515
 
1516
+ network_decline_code: Union[str | None, Any] = Field(default=None, description="For refunds declined by the network, a decline code provided by the network")
1517
+ """For refunds declined by the network, a decline code provided by the network"""
1443
1518
  reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1444
1519
  """The reference assigned to the refund"""
1445
1520
  reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
@@ -1454,12 +1529,12 @@ class RefundDestinationDetailsThBankTransfer(BaseModel):
1454
1529
  reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1455
1530
  """Status of the reference on the refund"""
1456
1531
 
1457
- class RefundDestinationDetailsPaypal(BaseModel):
1458
- """If this is a paypal refund, this hash contains the transaction specific details"""
1532
+ class RefundDestinationDetailsCrypto(BaseModel):
1533
+ """If this is a crypto refund, this hash contains the transaction specific details"""
1459
1534
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1460
1535
 
1461
- network_decline_code: Union[str | None, Any] = Field(default=None, description="For refunds declined by the network, a decline code provided by the network")
1462
- """For refunds declined by the network, a decline code provided by the network"""
1536
+ reference: Union[str | None, Any] = Field(default=None, description="The transaction hash of the refund")
1537
+ """The transaction hash of the refund"""
1463
1538
 
1464
1539
  class RefundDestinationDetailsSwish(BaseModel):
1465
1540
  """If this is a swish refund, this hash contains the transaction specific details"""
@@ -1472,28 +1547,24 @@ class RefundDestinationDetailsSwish(BaseModel):
1472
1547
  reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1473
1548
  """Status of the reference on the refund"""
1474
1549
 
1475
- class RefundDestinationDetailsBlik(BaseModel):
1476
- """If this is a blik refund, this hash contains the transaction specific details"""
1550
+ class RefundDestinationDetailsMxBankTransfer(BaseModel):
1551
+ """If this is a mx_bank_transfer refund, this hash contains the transaction specific details"""
1477
1552
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1478
1553
 
1479
- network_decline_code: Union[str | None, Any] = Field(default=None, description="For refunds declined by the network, a decline code provided by the network")
1480
- """For refunds declined by the network, a decline code provided by the network"""
1481
1554
  reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1482
1555
  """The reference assigned to the refund"""
1483
1556
  reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1484
1557
  """Status of the reference on the refund"""
1485
1558
 
1486
- class RefundDestinationDetailsMbWay(BaseModel):
1487
- """If this is a mb_way refund, this hash contains the transaction specific details"""
1559
+ class RefundDestinationDetailsPaypal(BaseModel):
1560
+ """If this is a paypal refund, this hash contains the transaction specific details"""
1488
1561
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1489
1562
 
1490
- reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1491
- """The reference assigned to the refund"""
1492
- reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1493
- """Status of the reference on the refund"""
1563
+ network_decline_code: Union[str | None, Any] = Field(default=None, description="For refunds declined by the network, a decline code provided by the network")
1564
+ """For refunds declined by the network, a decline code provided by the network"""
1494
1565
 
1495
- class RefundDestinationDetailsEuBankTransfer(BaseModel):
1496
- """If this is a eu_bank_transfer refund, this hash contains the transaction specific details"""
1566
+ class RefundDestinationDetailsGbBankTransfer(BaseModel):
1567
+ """If this is a gb_bank_transfer refund, this hash contains the transaction specific details"""
1497
1568
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1498
1569
 
1499
1570
  reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
@@ -1514,15 +1585,17 @@ class RefundDestinationDetailsCard(BaseModel):
1514
1585
  type: Union[str, Any] = Field(default=None, description="The type of refund")
1515
1586
  """The type of refund"""
1516
1587
 
1517
- class RefundDestinationDetailsCrypto(BaseModel):
1518
- """If this is a crypto refund, this hash contains the transaction specific details"""
1588
+ class RefundDestinationDetailsEuBankTransfer(BaseModel):
1589
+ """If this is a eu_bank_transfer refund, this hash contains the transaction specific details"""
1519
1590
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1520
1591
 
1521
- reference: Union[str | None, Any] = Field(default=None, description="The transaction hash of the refund")
1522
- """The transaction hash of the refund"""
1592
+ reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1593
+ """The reference assigned to the refund"""
1594
+ reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1595
+ """Status of the reference on the refund"""
1523
1596
 
1524
- class RefundDestinationDetailsMxBankTransfer(BaseModel):
1525
- """If this is a mx_bank_transfer refund, this hash contains the transaction specific details"""
1597
+ class RefundDestinationDetailsMbWay(BaseModel):
1598
+ """If this is a mb_way refund, this hash contains the transaction specific details"""
1526
1599
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1527
1600
 
1528
1601
  reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
@@ -1539,8 +1612,8 @@ class RefundDestinationDetailsUsBankTransfer(BaseModel):
1539
1612
  reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1540
1613
  """Status of the reference on the refund"""
1541
1614
 
1542
- class RefundDestinationDetailsMultibanco(BaseModel):
1543
- """If this is a multibanco refund, this hash contains the transaction specific details"""
1615
+ class RefundDestinationDetailsP24(BaseModel):
1616
+ """If this is a p24 refund, this hash contains the transaction specific details"""
1544
1617
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1545
1618
 
1546
1619
  reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
@@ -1557,6 +1630,24 @@ class RefundDestinationDetailsJpBankTransfer(BaseModel):
1557
1630
  reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1558
1631
  """Status of the reference on the refund"""
1559
1632
 
1633
+ class RefundDestinationDetailsBrBankTransfer(BaseModel):
1634
+ """If this is a br_bank_transfer refund, this hash contains the transaction specific details"""
1635
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1636
+
1637
+ reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1638
+ """The reference assigned to the refund"""
1639
+ reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1640
+ """Status of the reference on the refund"""
1641
+
1642
+ class RefundDestinationDetailsMultibanco(BaseModel):
1643
+ """If this is a multibanco refund, this hash contains the transaction specific details"""
1644
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1645
+
1646
+ reference: Union[str | None, Any] = Field(default=None, description="The reference assigned to the refund")
1647
+ """The reference assigned to the refund"""
1648
+ reference_status: Union[str | None, Any] = Field(default=None, description="Status of the reference on the refund")
1649
+ """Status of the reference on the refund"""
1650
+
1560
1651
  class RefundDestinationDetails(BaseModel):
1561
1652
  """Transaction-specific details for the refund"""
1562
1653
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1634,33 +1725,6 @@ class RefundDestinationDetails(BaseModel):
1634
1725
  zip: Union[dict[str, Any] | None, Any] = Field(default=None, description="If this is a zip refund, this hash contains the transaction specific details")
1635
1726
  """If this is a zip refund, this hash contains the transaction specific details"""
1636
1727
 
1637
- class RefundNextActionDisplayDetailsEmailSent(BaseModel):
1638
- """Contains information about the email sent to the customer"""
1639
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1640
-
1641
- email_sent_at: Union[int, Any] = Field(default=None, description="The timestamp when the email was sent")
1642
- """The timestamp when the email was sent"""
1643
- email_sent_to: Union[str, Any] = Field(default=None, description="The recipient's email address")
1644
- """The recipient's email address"""
1645
-
1646
- class RefundNextActionDisplayDetails(BaseModel):
1647
- """Contains the refund details"""
1648
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1649
-
1650
- email_sent: Union[RefundNextActionDisplayDetailsEmailSent, Any] = Field(default=None, description="Contains information about the email sent to the customer")
1651
- """Contains information about the email sent to the customer"""
1652
- expires_at: Union[int, Any] = Field(default=None, description="The expiry timestamp")
1653
- """The expiry timestamp"""
1654
-
1655
- class RefundNextAction(BaseModel):
1656
- """If the refund has a status of requires_action, this property describes what the refund needs to continue processing"""
1657
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1658
-
1659
- display_details: Union[RefundNextActionDisplayDetails | None, Any] = Field(default=None, description="Contains the refund details")
1660
- """Contains the refund details"""
1661
- type: Union[str, Any] = Field(default=None, description="Type of the next action to perform")
1662
- """Type of the next action to perform"""
1663
-
1664
1728
  class Refund(BaseModel):
1665
1729
  """Refund type definition"""
1666
1730
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1697,6 +1761,18 @@ class RefundList(BaseModel):
1697
1761
  has_more: Union[bool, Any] = Field(default=None)
1698
1762
  url: Union[str, Any] = Field(default=None)
1699
1763
 
1764
+ class RefundCreateParams(BaseModel):
1765
+ """RefundCreateParams type definition"""
1766
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1767
+
1768
+ charge: Union[str, Any] = Field(default=None)
1769
+ payment_intent: Union[str, Any] = Field(default=None)
1770
+ amount: Union[int, Any] = Field(default=None)
1771
+ metadata: Union[dict[str, str], Any] = Field(default=None)
1772
+ reason: Union[str, Any] = Field(default=None)
1773
+ refund_application_fee: Union[bool, Any] = Field(default=None)
1774
+ reverse_transfer: Union[bool, Any] = Field(default=None)
1775
+
1700
1776
  class ProductPackageDimensions(BaseModel):
1701
1777
  """The dimensions of this product for shipping purposes"""
1702
1778
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1710,13 +1786,6 @@ class ProductPackageDimensions(BaseModel):
1710
1786
  width: Union[float, Any] = Field(default=None, description="Width, in inches")
1711
1787
  """Width, in inches"""
1712
1788
 
1713
- class ProductFeaturesItem(BaseModel):
1714
- """Nested schema for Product.features_item"""
1715
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1716
-
1717
- name: Union[str, Any] = Field(default=None, description="The feature name")
1718
- """The feature name"""
1719
-
1720
1789
  class ProductMarketingFeaturesItem(BaseModel):
1721
1790
  """Nested schema for Product.marketing_features_item"""
1722
1791
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1724,6 +1793,13 @@ class ProductMarketingFeaturesItem(BaseModel):
1724
1793
  name: Union[str | None, Any] = Field(default=None, description="The marketing feature name. Up to 80 characters long")
1725
1794
  """The marketing feature name. Up to 80 characters long"""
1726
1795
 
1796
+ class ProductFeaturesItem(BaseModel):
1797
+ """Nested schema for Product.features_item"""
1798
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1799
+
1800
+ name: Union[str, Any] = Field(default=None, description="The feature name")
1801
+ """The feature name"""
1802
+
1727
1803
  class Product(BaseModel):
1728
1804
  """Product type definition"""
1729
1805
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1769,6 +1845,90 @@ class ProductSearchResult(BaseModel):
1769
1845
  next_page: Union[str | None, Any] = Field(default=None)
1770
1846
  url: Union[str, Any] = Field(default=None)
1771
1847
 
1848
+ class ProductCreateParamsPackageDimensions(BaseModel):
1849
+ """The dimensions of this product for shipping purposes"""
1850
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1851
+
1852
+ height: Union[float, Any] = Field(default=None, description="Height, in inches")
1853
+ """Height, in inches"""
1854
+ length: Union[float, Any] = Field(default=None, description="Length, in inches")
1855
+ """Length, in inches"""
1856
+ weight: Union[float, Any] = Field(default=None, description="Weight, in ounces")
1857
+ """Weight, in ounces"""
1858
+ width: Union[float, Any] = Field(default=None, description="Width, in inches")
1859
+ """Width, in inches"""
1860
+
1861
+ class ProductCreateParamsMarketingFeaturesItem(BaseModel):
1862
+ """Nested schema for ProductCreateParams.marketing_features_item"""
1863
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1864
+
1865
+ name: Union[str, Any] = Field(default=None, description="The marketing feature name. Up to 80 characters long")
1866
+ """The marketing feature name. Up to 80 characters long"""
1867
+
1868
+ class ProductCreateParams(BaseModel):
1869
+ """ProductCreateParams type definition"""
1870
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1871
+
1872
+ name: Union[str, Any] = Field(default=None)
1873
+ active: Union[bool, Any] = Field(default=None)
1874
+ description: Union[str, Any] = Field(default=None)
1875
+ id: Union[str, Any] = Field(default=None)
1876
+ images: Union[list[str], Any] = Field(default=None)
1877
+ marketing_features: Union[list[ProductCreateParamsMarketingFeaturesItem], Any] = Field(default=None)
1878
+ metadata: Union[dict[str, str], Any] = Field(default=None)
1879
+ package_dimensions: Union[ProductCreateParamsPackageDimensions, Any] = Field(default=None)
1880
+ shippable: Union[bool, Any] = Field(default=None)
1881
+ statement_descriptor: Union[str, Any] = Field(default=None)
1882
+ tax_code: Union[str, Any] = Field(default=None)
1883
+ unit_label: Union[str, Any] = Field(default=None)
1884
+ url: Union[str, Any] = Field(default=None)
1885
+
1886
+ class ProductUpdateParamsMarketingFeaturesItem(BaseModel):
1887
+ """Nested schema for ProductUpdateParams.marketing_features_item"""
1888
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1889
+
1890
+ name: Union[str, Any] = Field(default=None, description="The marketing feature name. Up to 80 characters long")
1891
+ """The marketing feature name. Up to 80 characters long"""
1892
+
1893
+ class ProductUpdateParamsPackageDimensions(BaseModel):
1894
+ """The dimensions of this product for shipping purposes"""
1895
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1896
+
1897
+ height: Union[float, Any] = Field(default=None, description="Height, in inches")
1898
+ """Height, in inches"""
1899
+ length: Union[float, Any] = Field(default=None, description="Length, in inches")
1900
+ """Length, in inches"""
1901
+ weight: Union[float, Any] = Field(default=None, description="Weight, in ounces")
1902
+ """Weight, in ounces"""
1903
+ width: Union[float, Any] = Field(default=None, description="Width, in inches")
1904
+ """Width, in inches"""
1905
+
1906
+ class ProductUpdateParams(BaseModel):
1907
+ """ProductUpdateParams type definition"""
1908
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1909
+
1910
+ active: Union[bool, Any] = Field(default=None)
1911
+ name: Union[str, Any] = Field(default=None)
1912
+ description: Union[str, Any] = Field(default=None)
1913
+ default_price: Union[str, Any] = Field(default=None)
1914
+ images: Union[list[str], Any] = Field(default=None)
1915
+ marketing_features: Union[list[ProductUpdateParamsMarketingFeaturesItem], Any] = Field(default=None)
1916
+ metadata: Union[dict[str, str], Any] = Field(default=None)
1917
+ package_dimensions: Union[ProductUpdateParamsPackageDimensions, Any] = Field(default=None)
1918
+ shippable: Union[bool, Any] = Field(default=None)
1919
+ statement_descriptor: Union[str, Any] = Field(default=None)
1920
+ tax_code: Union[str, Any] = Field(default=None)
1921
+ unit_label: Union[str, Any] = Field(default=None)
1922
+ url: Union[str, Any] = Field(default=None)
1923
+
1924
+ class ProductDeletedResponse(BaseModel):
1925
+ """ProductDeletedResponse type definition"""
1926
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1927
+
1928
+ id: Union[str, Any] = Field(default=None)
1929
+ object: Union[str, Any] = Field(default=None)
1930
+ deleted: Union[bool, Any] = Field(default=None)
1931
+
1772
1932
  class BalanceAvailableItemSourceTypes(BaseModel):
1773
1933
  """Breakdown of balance by source types"""
1774
1934
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1791,17 +1951,6 @@ class BalanceAvailableItem(BaseModel):
1791
1951
  source_types: Union[BalanceAvailableItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
1792
1952
  """Breakdown of balance by source types"""
1793
1953
 
1794
- class BalanceInstantAvailableItemSourceTypes(BaseModel):
1795
- """Breakdown of balance by source types"""
1796
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1797
-
1798
- bank_account: Union[int | None, Any] = Field(default=None, description="Amount for bank_account")
1799
- """Amount for bank_account"""
1800
- card: Union[int | None, Any] = Field(default=None, description="Amount for card")
1801
- """Amount for card"""
1802
- fpx: Union[int | None, Any] = Field(default=None, description="Amount for fpx")
1803
- """Amount for fpx"""
1804
-
1805
1954
  class BalanceInstantAvailableItemNetAvailableItemSourceTypes(BaseModel):
1806
1955
  """Breakdown of balance by source types"""
1807
1956
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1824,6 +1973,17 @@ class BalanceInstantAvailableItemNetAvailableItem(BaseModel):
1824
1973
  source_types: Union[BalanceInstantAvailableItemNetAvailableItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
1825
1974
  """Breakdown of balance by source types"""
1826
1975
 
1976
+ class BalanceInstantAvailableItemSourceTypes(BaseModel):
1977
+ """Breakdown of balance by source types"""
1978
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
1979
+
1980
+ bank_account: Union[int | None, Any] = Field(default=None, description="Amount for bank_account")
1981
+ """Amount for bank_account"""
1982
+ card: Union[int | None, Any] = Field(default=None, description="Amount for card")
1983
+ """Amount for card"""
1984
+ fpx: Union[int | None, Any] = Field(default=None, description="Amount for fpx")
1985
+ """Amount for fpx"""
1986
+
1827
1987
  class BalanceInstantAvailableItem(BaseModel):
1828
1988
  """Nested schema for Balance.instant_available_item"""
1829
1989
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -1866,7 +2026,7 @@ class BalanceIssuing(BaseModel):
1866
2026
  available: Union[list[BalanceIssuingAvailableItem], Any] = Field(default=None, description="Funds available for issuing")
1867
2027
  """Funds available for issuing"""
1868
2028
 
1869
- class BalancePendingItemSourceTypes(BaseModel):
2029
+ class BalanceRefundAndDisputePrefundingAvailableItemSourceTypes(BaseModel):
1870
2030
  """Breakdown of balance by source types"""
1871
2031
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1872
2032
 
@@ -1877,18 +2037,18 @@ class BalancePendingItemSourceTypes(BaseModel):
1877
2037
  fpx: Union[int | None, Any] = Field(default=None, description="Amount for fpx")
1878
2038
  """Amount for fpx"""
1879
2039
 
1880
- class BalancePendingItem(BaseModel):
1881
- """Nested schema for Balance.pending_item"""
2040
+ class BalanceRefundAndDisputePrefundingAvailableItem(BaseModel):
2041
+ """Nested schema for BalanceRefundAndDisputePrefunding.available_item"""
1882
2042
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1883
2043
 
1884
- amount: Union[int, Any] = Field(default=None, description="Balance amount in the smallest currency unit")
1885
- """Balance amount in the smallest currency unit"""
1886
- currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code, in lowercase")
1887
- """Three-letter ISO currency code, in lowercase"""
1888
- source_types: Union[BalancePendingItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
2044
+ amount: Union[int, Any] = Field(default=None, description="Balance amount")
2045
+ """Balance amount"""
2046
+ currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
2047
+ """Three-letter ISO currency code"""
2048
+ source_types: Union[BalanceRefundAndDisputePrefundingAvailableItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
1889
2049
  """Breakdown of balance by source types"""
1890
2050
 
1891
- class BalanceConnectReservedItemSourceTypes(BaseModel):
2051
+ class BalanceRefundAndDisputePrefundingPendingItemSourceTypes(BaseModel):
1892
2052
  """Breakdown of balance by source types"""
1893
2053
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1894
2054
 
@@ -1899,18 +2059,27 @@ class BalanceConnectReservedItemSourceTypes(BaseModel):
1899
2059
  fpx: Union[int | None, Any] = Field(default=None, description="Amount for fpx")
1900
2060
  """Amount for fpx"""
1901
2061
 
1902
- class BalanceConnectReservedItem(BaseModel):
1903
- """Nested schema for Balance.connect_reserved_item"""
2062
+ class BalanceRefundAndDisputePrefundingPendingItem(BaseModel):
2063
+ """Nested schema for BalanceRefundAndDisputePrefunding.pending_item"""
1904
2064
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1905
2065
 
1906
- amount: Union[int, Any] = Field(default=None, description="Balance amount in the smallest currency unit")
1907
- """Balance amount in the smallest currency unit"""
1908
- currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code, in lowercase")
1909
- """Three-letter ISO currency code, in lowercase"""
1910
- source_types: Union[BalanceConnectReservedItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
2066
+ amount: Union[int, Any] = Field(default=None, description="Balance amount")
2067
+ """Balance amount"""
2068
+ currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
2069
+ """Three-letter ISO currency code"""
2070
+ source_types: Union[BalanceRefundAndDisputePrefundingPendingItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
1911
2071
  """Breakdown of balance by source types"""
1912
2072
 
1913
- class BalanceRefundAndDisputePrefundingAvailableItemSourceTypes(BaseModel):
2073
+ class BalanceRefundAndDisputePrefunding(BaseModel):
2074
+ """Funds reserved for covering future refunds or disputes"""
2075
+ model_config = ConfigDict(extra="allow", populate_by_name=True)
2076
+
2077
+ available: Union[list[BalanceRefundAndDisputePrefundingAvailableItem], Any] = Field(default=None, description="Available funds for refunds and disputes")
2078
+ """Available funds for refunds and disputes"""
2079
+ pending: Union[list[BalanceRefundAndDisputePrefundingPendingItem], Any] = Field(default=None, description="Pending funds for refunds and disputes")
2080
+ """Pending funds for refunds and disputes"""
2081
+
2082
+ class BalanceConnectReservedItemSourceTypes(BaseModel):
1914
2083
  """Breakdown of balance by source types"""
1915
2084
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1916
2085
 
@@ -1921,18 +2090,18 @@ class BalanceRefundAndDisputePrefundingAvailableItemSourceTypes(BaseModel):
1921
2090
  fpx: Union[int | None, Any] = Field(default=None, description="Amount for fpx")
1922
2091
  """Amount for fpx"""
1923
2092
 
1924
- class BalanceRefundAndDisputePrefundingAvailableItem(BaseModel):
1925
- """Nested schema for BalanceRefundAndDisputePrefunding.available_item"""
2093
+ class BalanceConnectReservedItem(BaseModel):
2094
+ """Nested schema for Balance.connect_reserved_item"""
1926
2095
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1927
2096
 
1928
- amount: Union[int, Any] = Field(default=None, description="Balance amount")
1929
- """Balance amount"""
1930
- currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
1931
- """Three-letter ISO currency code"""
1932
- source_types: Union[BalanceRefundAndDisputePrefundingAvailableItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
2097
+ amount: Union[int, Any] = Field(default=None, description="Balance amount in the smallest currency unit")
2098
+ """Balance amount in the smallest currency unit"""
2099
+ currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code, in lowercase")
2100
+ """Three-letter ISO currency code, in lowercase"""
2101
+ source_types: Union[BalanceConnectReservedItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
1933
2102
  """Breakdown of balance by source types"""
1934
2103
 
1935
- class BalanceRefundAndDisputePrefundingPendingItemSourceTypes(BaseModel):
2104
+ class BalancePendingItemSourceTypes(BaseModel):
1936
2105
  """Breakdown of balance by source types"""
1937
2106
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1938
2107
 
@@ -1943,26 +2112,17 @@ class BalanceRefundAndDisputePrefundingPendingItemSourceTypes(BaseModel):
1943
2112
  fpx: Union[int | None, Any] = Field(default=None, description="Amount for fpx")
1944
2113
  """Amount for fpx"""
1945
2114
 
1946
- class BalanceRefundAndDisputePrefundingPendingItem(BaseModel):
1947
- """Nested schema for BalanceRefundAndDisputePrefunding.pending_item"""
2115
+ class BalancePendingItem(BaseModel):
2116
+ """Nested schema for Balance.pending_item"""
1948
2117
  model_config = ConfigDict(extra="allow", populate_by_name=True)
1949
2118
 
1950
- amount: Union[int, Any] = Field(default=None, description="Balance amount")
1951
- """Balance amount"""
1952
- currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code")
1953
- """Three-letter ISO currency code"""
1954
- source_types: Union[BalanceRefundAndDisputePrefundingPendingItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
2119
+ amount: Union[int, Any] = Field(default=None, description="Balance amount in the smallest currency unit")
2120
+ """Balance amount in the smallest currency unit"""
2121
+ currency: Union[str, Any] = Field(default=None, description="Three-letter ISO currency code, in lowercase")
2122
+ """Three-letter ISO currency code, in lowercase"""
2123
+ source_types: Union[BalancePendingItemSourceTypes | None, Any] = Field(default=None, description="Breakdown of balance by source types")
1955
2124
  """Breakdown of balance by source types"""
1956
2125
 
1957
- class BalanceRefundAndDisputePrefunding(BaseModel):
1958
- """Funds reserved for covering future refunds or disputes"""
1959
- model_config = ConfigDict(extra="allow", populate_by_name=True)
1960
-
1961
- available: Union[list[BalanceRefundAndDisputePrefundingAvailableItem], Any] = Field(default=None, description="Available funds for refunds and disputes")
1962
- """Available funds for refunds and disputes"""
1963
- pending: Union[list[BalanceRefundAndDisputePrefundingPendingItem], Any] = Field(default=None, description="Pending funds for refunds and disputes")
1964
- """Pending funds for refunds and disputes"""
1965
-
1966
2126
  class Balance(BaseModel):
1967
2127
  """Balance type definition"""
1968
2128
  model_config = ConfigDict(extra="allow", populate_by_name=True)
@@ -2208,8 +2368,8 @@ class CustomersListResultMeta(BaseModel):
2208
2368
 
2209
2369
  has_more: Union[bool, Any] = Field(default=None)
2210
2370
 
2211
- class CustomersSearchResultMeta(BaseModel):
2212
- """Metadata for customers.search operation"""
2371
+ class CustomersApiSearchResultMeta(BaseModel):
2372
+ """Metadata for customers.api_search operation"""
2213
2373
  model_config = ConfigDict(extra="allow", populate_by_name=True)
2214
2374
 
2215
2375
  has_more: Union[bool, Any] = Field(default=None)
@@ -2244,8 +2404,8 @@ class ProductsListResultMeta(BaseModel):
2244
2404
 
2245
2405
  has_more: Union[bool, Any] = Field(default=None)
2246
2406
 
2247
- class ProductsSearchResultMeta(BaseModel):
2248
- """Metadata for products.search operation"""
2407
+ class ProductsApiSearchResultMeta(BaseModel):
2408
+ """Metadata for products.api_search operation"""
2249
2409
  model_config = ConfigDict(extra="allow", populate_by_name=True)
2250
2410
 
2251
2411
  has_more: Union[bool, Any] = Field(default=None)
@@ -2262,8 +2422,8 @@ class PaymentIntentsListResultMeta(BaseModel):
2262
2422
 
2263
2423
  has_more: Union[bool, Any] = Field(default=None)
2264
2424
 
2265
- class PaymentIntentsSearchResultMeta(BaseModel):
2266
- """Metadata for payment_intents.search operation"""
2425
+ class PaymentIntentsApiSearchResultMeta(BaseModel):
2426
+ """Metadata for payment_intents.api_search operation"""
2267
2427
  model_config = ConfigDict(extra="allow", populate_by_name=True)
2268
2428
 
2269
2429
  has_more: Union[bool, Any] = Field(default=None)
@@ -2315,8 +2475,8 @@ class StripeExecuteResultWithMeta(StripeExecuteResult[T], Generic[T, S]):
2315
2475
  CustomersListResult = StripeExecuteResultWithMeta[list[Customer], CustomersListResultMeta]
2316
2476
  """Result type for customers.list operation with data and metadata."""
2317
2477
 
2318
- CustomersSearchResult = StripeExecuteResultWithMeta[list[Customer], CustomersSearchResultMeta]
2319
- """Result type for customers.search operation with data and metadata."""
2478
+ CustomersApiSearchResult = StripeExecuteResultWithMeta[list[Customer], CustomersApiSearchResultMeta]
2479
+ """Result type for customers.api_search operation with data and metadata."""
2320
2480
 
2321
2481
  InvoicesListResult = StripeExecuteResultWithMeta[list[Invoice], InvoicesListResultMeta]
2322
2482
  """Result type for invoices.list operation with data and metadata."""
@@ -2333,8 +2493,8 @@ RefundsListResult = StripeExecuteResultWithMeta[list[Refund], RefundsListResultM
2333
2493
  ProductsListResult = StripeExecuteResultWithMeta[list[Product], ProductsListResultMeta]
2334
2494
  """Result type for products.list operation with data and metadata."""
2335
2495
 
2336
- ProductsSearchResult = StripeExecuteResultWithMeta[list[Product], ProductsSearchResultMeta]
2337
- """Result type for products.search operation with data and metadata."""
2496
+ ProductsApiSearchResult = StripeExecuteResultWithMeta[list[Product], ProductsApiSearchResultMeta]
2497
+ """Result type for products.api_search operation with data and metadata."""
2338
2498
 
2339
2499
  BalanceTransactionsListResult = StripeExecuteResultWithMeta[list[BalanceTransaction], BalanceTransactionsListResultMeta]
2340
2500
  """Result type for balance_transactions.list operation with data and metadata."""
@@ -2342,8 +2502,8 @@ BalanceTransactionsListResult = StripeExecuteResultWithMeta[list[BalanceTransact
2342
2502
  PaymentIntentsListResult = StripeExecuteResultWithMeta[list[PaymentIntent], PaymentIntentsListResultMeta]
2343
2503
  """Result type for payment_intents.list operation with data and metadata."""
2344
2504
 
2345
- PaymentIntentsSearchResult = StripeExecuteResultWithMeta[list[PaymentIntent], PaymentIntentsSearchResultMeta]
2346
- """Result type for payment_intents.search operation with data and metadata."""
2505
+ PaymentIntentsApiSearchResult = StripeExecuteResultWithMeta[list[PaymentIntent], PaymentIntentsApiSearchResultMeta]
2506
+ """Result type for payment_intents.api_search operation with data and metadata."""
2347
2507
 
2348
2508
  DisputesListResult = StripeExecuteResultWithMeta[list[Dispute], DisputesListResultMeta]
2349
2509
  """Result type for disputes.list operation with data and metadata."""